CMakeLists.txt
branchstable-2.0
changeset 1132 ff6943f29c3e
parent 1082 94771621792f
child 1141 2ad0dd5a701f
equal deleted inserted replaced
1095:69b884a15de1 1132:ff6943f29c3e
   106 
   106 
   107 IF(BEOS)
   107 IF(BEOS)
   108     # We add this explicitly, since we don't want CMake to think this
   108     # We add this explicitly, since we don't want CMake to think this
   109     #  is a C++ project unless we're on BeOS.
   109     #  is a C++ project unless we're on BeOS.
   110     SET(PHYSFS_BEOS_SRCS platform/beos.cpp)
   110     SET(PHYSFS_BEOS_SRCS platform/beos.cpp)
   111     SET(OPTIONAL_LIBRARY_LIBS ${OPTIONAL_LIBRARY_LIBS} be root)
   111     FIND_LIBRARY(BE_LIBRARY be)
       
   112     FIND_LIBRARY(ROOT_LIBRARY root)
       
   113     SET(OPTIONAL_LIBRARY_LIBS ${OPTIONAL_LIBRARY_LIBS} ${BE_LIBRARY} ${ROOT_LIBRARY})
   112 ENDIF(BEOS)
   114 ENDIF(BEOS)
   113 
   115 
   114 # Almost everything is "compiled" here, but things that don't apply to the
   116 # Almost everything is "compiled" here, but things that don't apply to the
   115 #  build are #ifdef'd out. This is to make it easy to embed PhysicsFS into
   117 #  build are #ifdef'd out. This is to make it easy to embed PhysicsFS into
   116 #  another project or bring up a new build system: just compile all the source
   118 #  another project or bring up a new build system: just compile all the source
   296 MARK_AS_ADVANCED(PHYSFS_BUILD_TEST)
   298 MARK_AS_ADVANCED(PHYSFS_BUILD_TEST)
   297 IF(PHYSFS_BUILD_TEST)
   299 IF(PHYSFS_BUILD_TEST)
   298     FIND_PATH(READLINE_H readline/readline.h)
   300     FIND_PATH(READLINE_H readline/readline.h)
   299     FIND_PATH(HISTORY_H readline/history.h)
   301     FIND_PATH(HISTORY_H readline/history.h)
   300     IF(READLINE_H AND HISTORY_H)
   302     IF(READLINE_H AND HISTORY_H)
   301         SET(CMAKE_REQUIRED_LIBRARIES curses)
   303         FIND_LIBRARY(CURSES_LIBRARY NAMES curses ncurses)
       
   304         SET(CMAKE_REQUIRED_LIBRARIES ${CURSES_LIBRARY})
   302         FIND_LIBRARY(READLINE_LIBRARY readline)
   305         FIND_LIBRARY(READLINE_LIBRARY readline)
   303         FIND_LIBRARY(HISTORY_LIBRARY history)
   306         FIND_LIBRARY(HISTORY_LIBRARY history)
   304         IF(READLINE_LIBRARY AND HISTORY_LIBRARY)
   307         IF(READLINE_LIBRARY AND HISTORY_LIBRARY)
   305             SET(HAVE_SYSTEM_READLINE TRUE)
   308             SET(HAVE_SYSTEM_READLINE TRUE)
   306             SET(TEST_PHYSFS_LIBS ${TEST_PHYSFS_LIBS} ${READLINE_LIBRARY} ${CURSES_LIBRARY})
   309             SET(TEST_PHYSFS_LIBS ${TEST_PHYSFS_LIBS} ${READLINE_LIBRARY} ${CURSES_LIBRARY})