- WINDOWS does not exist, use WIN32 (or defineWINDOWS if cygwin can not be used inUnix mode?),
- fix an un-closed IF,
- use same prefix for vars (and make it advanced)
This commit is contained in:
Sebastien Barre 2002-08-09 08:33:04 -04:00
parent a1e19675de
commit a75e78838f
1 changed files with 18 additions and 12 deletions

View File

@ -7,7 +7,8 @@
# WXWINDOWS_SHARED_LIBRARY = full path to the wxWindows shared import library
# WXWINDOWS_INCLUDE_PATH = path to wx.h
IF(WINDOWS)
IF(WIN32)
SET (WXWINDOWS_POSSIBLE_LIB_PATHS
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\wxWindows_is1;Inno Setup: App Path]/lib"
$ENV{WXWIN}/lib
@ -32,16 +33,21 @@ IF(WINDOWS)
wx.h
${WXWINDOWS_POSSIBLE_INCLUDE_PATHS}
)
IF(WXWINDOWS_SHARED_LIBRARY)
OPTION(WX_USE_SHARED_LIBS "Use shared versions of wxWindows libraries" ON)
IF(WXWINDOWS_SHARED_LIBRARY)
IF(WX_USE_SHARED_LIBS)
SET(WXWINDOWS_LIBRARY ${WXWINDOWS_SHARED_LIBRARY})
ELSE(WX_USE_SHARED_LIBS)
SET(WXWINDOWS_LIBRARY ${WXWINDOWS_STATIC_LIBRARY})
ENDIF(WX_USE_SHARED_LIBS)
ELSE(WINDOWS)
IF(WXWINDOWS_SHARED_LIBRARY)
OPTION(WXWINDOWS_USE_SHARED_LIBS
"Use shared versions of wxWindows libraries" ON)
MARK_AS_ADVANCED(WXWINDOWS_USE_SHARED_LIBS)
ENDIF(WXWINDOWS_SHARED_LIBRARY)
IF(WXWINDOWS_USE_SHARED_LIBS)
SET(WXWINDOWS_LIBRARY ${WXWINDOWS_SHARED_LIBRARY})
ELSE(WXWINDOWS_USE_SHARED_LIBS)
SET(WXWINDOWS_LIBRARY ${WXWINDOWS_STATIC_LIBRARY})
ENDIF(WXWINDOWS_USE_SHARED_LIBS)
ELSE(WIN32)
FIND_PROGRAM(CMAKE_WX_CONFIG wx-config)
# This has to be done at some point
#EXEC_PROGRAM(wx-config ARGS --cflags OUTPUT_VARIABLE WXWINDOWS_COMPILE_FLAGS RETURN_VALUE WX_CFLAGS_)
@ -52,11 +58,11 @@ ELSE(WINDOWS)
# MESSAGE("Cannot find \"wx-config\" or wxWindows is not configured properly")
#ENDIF(WX_CFLAGS_RVAL)
SET(CMAKE_WX_LIBRARIES "`${CMAKE_WX_CONFIG} --libs`")
ENDIF(WINDOWS)
ENDIF(WIN32)
MARK_AS_ADVANCED(
WXWINDOWS_STATIC_LIBRARY
WXWINDOWS_SHARED_LIBRARY
WXWINDOWS_INCLUDE_PATH
WXWINDOWS_SETUP_INCLUDE_PATH
)