Showing posts with label macports. Show all posts
Showing posts with label macports. Show all posts

Application on OS X

I finally manage to run the application on OS X 10.5. I should say it was not easy. First of all I needed macports, the I installed the following packages:

  • boost
  • log4cxx
  • cppunit
  • argp-standalone

The last one was a little bit tricky since argp is part of the is part of the gnu C library, which means that in linux one does not need to do anything for it, just include the header.

Since macports does not install the files in standard folders (like /usr/lib) but in its own "/opt/local/lib" and "opt/local/include" one need to add these directories to the eclipse path. To do that one needs to right click (I'm using a windows mouse) on the project icon in eclipse, select Properties -> C/C++ General -> Paths and Symbols. In the includes tab select GNU C++ and there add the folder "/opt/local/include" then in the library paths tab add the folder "/opt/local/lib" and as I mentioned before, one need to specific add libargp.a to the linker options.

For some reason I still don't understand, I also needed to change the Command line pattern in the linker options. This is the one that worked for me:

${COMMAND} ${FLAGS} ${OUTPUT_FLAG} ${OUTPUT_PREFIX}${OUTPUT} ${INPUTS}
And that was pretty much all. I still need to build the link to prolog (I will use eclipse prolog) and GiNaC but I will tell about it when I'm done with that.