Hi

Yes I checked there was no -D__APPLE__ defined.

I will try a simple hello world app as suggested in the first response...

Regards

Tim

2007/3/22, E. Wing <[EMAIL PROTECTED]>:
Very weird. I've never had this problem myself when running on
FreeBSD. I agree with Philip and make sure something isn't defining it
somewhere in the code. Also make sure the person didn't generate the
CMake stuff in Apple first, and then reboot or used a shared disk in
FreeBSD and tried reusing the generated CMake stuff and Makefiles.

One other thing caught my attention. Why are you including <malloc.h>
if Apple? In general, you shouldn't have to do this unless you're
doing some really weird stuff. (Also, Darwin is a BSD sibling so in
many respects, the common code should be very close to FreeBSD.)

-Eric


> Tim Sutton wrote:
> > The code in question looks like this:
> >
> > 4 #ifdef __APPLE__
> > 5 #include <malloc.h>
> > 6 #endif
> >
> > So cmake has decided its an APPLE machine and is incorrectly entering
> > this ifdef. Can any one point me to some notes on making things behave
> > correctly on FreeBSD?
>
> I'd double check and make sure that __APPLE__ isn't getting accidentally
>   defined somehow by something you're #including.
>
>
> Alternatively, make a small Hello World project for CMake and verify
> that it's actually defining __APPLE__ when you generate on FreeBSD.
>
> CMakeLists.txt:
> ADD_EXECUTABLE(hello hello.cc)
>
> hello.cc:
>
> #include <iostream>
> int main()
> #ifdef __APPLE__
>     std::cout << "Apple is defined!" << std::endl;
> #endif
>     return 0;
> }
>
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake



--
--
Tim Sutton

Visit http://qgis.org for a great Open Source GIS
Home Page: http://linfiniti.com
Skype: timlinux
MSN: [EMAIL PROTECTED]
Yahoo: [EMAIL PROTECTED]
Jabber: timlinux
Irc: timlinux on #qgis at freenode.net
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to