[CMake] wxWidgets, cmake and parallels & msys is confused

Eric Torstenson eric.torstenson at mac.com
Fri May 9 11:36:06 EDT 2008


Hi all,

This is pretty weird, and most certainly due to the complex arrangement 
of the system I'm compiling things on.

First, I'm building the application using parallels running msys. The 
machine it's ultimately running on is a macbook pro, which has wxWidgets 
installed on as well.

When I don't define WIN32 on an msys build which needs to include and 
link to wxWidgets libraries, it magically is finding my mac's installed 
wx-config and uses those include paths-which don't map properly 
(luckily, since I don't think they would be appropriate for the build). 
What's cool is that msys

Is there a way to tell CMake to use the wx-config that is in the system 
path? If I do which wx-config, it returns the appropriate one.

Thanks for any help! If there is something I've done to confuse the 
module, please let me know!

FWIW, here is some info to show that it should find the one installed:

$ echo $PATH
.:/usr/local/bin:/mingw/bin:/bin:/mingw/bin:/c/WINDOWS/system32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/mingw/bin:/c/msys/1.0.10/bin:/c/Program 
Files/CMake/bin:/c/WATCOM/BINNT:/c/WATCOM/BINW:/c/boost/bin

---------------------------- Errors when I build 
---------------------------------------------------
make[3]: Entering directory `/z/Users/torstees/dev/build/Release/win32'
make[3]: Leaving directory `/z/Users/torstees/dev/build/Release/win32'
make[3]: Entering directory `/z/Users/torstees/dev/build/Release/win32'
make[3]: *** No rule to make target 
`/usr/local/include/wx-2.8/wx/mac/accel.h', needed by 
`src/wxgenomesimla/CMakeFiles/wxGenomeSIMLA.dir/appcontroller.cpp.obj'.  
Stop.

---------------------------- Where it really should be found 
-------------------------------------
$ which wx-config
/usr/local/bin/wx-config

$ /usr/local/bin/wx-config --cflags
-I/usr/local/lib/wx/include/msw-ansi-release-static-2.8 
-I/usr/local/include/wx-2.8 -D__WXMSW__ -mthreads

----------------------------- The one being found (I think) How it finds 
it, I'm not sure, since /z is nowhere to be found in my PATH
$ /z/usr/local/bin/wx-config --cflags
-I/usr/local/lib/wx/include/mac-ansi-release-static-2.8 
-I/usr/local/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES 
-D__WXMAC__


Something else that is weird, and is probably just an oddity of the msys 
environment, is that find / -name wx-config -print will show 
/local/bin/wx-config and neither of the two listed above. What I can 
tell from looking at the output of that file is that it's a link of some 
kind to the correct one or at least the same version (it reports the 
same information that the /usr/local/bin/wx-config does).

eric


More information about the CMake mailing list