I want to compile objective-c from eclipse with foundation.h support.
I can do it with GNUStep inside the MSYS shell, but I want to do it directly from eclipse Makefile without launching the Shell
is is possible?
As default XCode and a MAC machine is the right solution, But it will be great if atleast I can play with NSDictionary in a window machine before I really do in XCode
Best How To :
After checking the environment variables inside the GNUStep, I made the Objective-C code working directly with eclipse without launching the MSYS terminal
Download and install GNUStep from http://www.gnustep.org/windows/installer.html Download and install Eclipse Luna for C/C++ https://eclipse.org/downloads/
You can launch GNUStep Shell and execute "set > paths.txt"
This paths.txt file will have all the related environment path with Unix directory structure
Convert all those paths to windows path structure and windows path delimiter ";"
You need to set few environment variables including GNUSTEP_MAKEFILES, LD_LIBRARY_PATH, GNUSTEP_PATHLIST, GNUSTEP_SYSTEM_ROOT, GNUSTEP_USER_ROOT, GNUSTEP_HOST, GNUSTEP_HOST_CPU, GNUSTEP_HOST_OS, LIBRARY_COMBO, WD, GNUSTEP_IS_FLATTENED, GNUSTEP_FLATTENED..... with absolute path locations using front slash (avoid back slashes)
Make sure you provide the TMP and TEMP folder paths as shown below
Create a C/C++ project in eclipse, You should name your makefile as GNUStepMakefile
As usual you can create the GNUMakefile with reference to GNUStep docs http://www.gnustep.it/nicola/Tutorials/WritingMakefiles/, introduce one extra target to execute the exe file
Now you can write your .m file
You have to add the .m file to the eclipse file types and default editor as C/C++ editor
Eclipse-Window-Show View->Other->Make->Make Target ........ introduce targets as all, clean, run
Double click "all" from the Make Target
Double click "run" from the Make Target
Now you can compile and run Objective-C without launching the GNUStep Shell
Note: you are only practising Objective-C with Foundation classes, you cannot create real IOS/MAC app here, for that you definitely need a MAC PC/Laptop
If you don't want to use Makefile and directly use CDT to compile the code you can use this Technique https://www.youtube.com/watch?v=JQ8aIe4p6ds