Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 3, 2008, 2:51:06 PM (16 years ago)
Author:
adrfried
Message:

cmake for mingw improved

Location:
code/branches/buildsystem
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • code/branches/buildsystem/cmake/CheckOrxonoxWinDeps.cmake

    r2253 r2318  
    3333IF (MINGW)
    3434  MESSAGE(STATUS "Running on MinGW. Using customized paths.")
    35   SET(MINGW_LIBRARY_DIR "../libs")
     35  SET(MINGW_LIBRARY_DIR "${CMAKE_SOURCE_DIR}/../libs")
    3636  #SET(Boost_ADDITIONAL_VERSIONS "1.36")
    37   SET(BOOST_INCLUDEDIR ".${MINGW_LIBRARY_DIR}/boost_1_34_1")
    38   SET(BOOST_LIBRARYDIR ".${MINGW_LIBRARY_DIR}/boost_1_34_1/stage/lib")
    39   SET(ENV{ENETDIR} ".${MINGW_LIBRARY_DIR}/enet-1.1")
    40   SET(ENV{ALUTDIR} ".${MINGW_LIBRARY_DIR}/freealut-1.1.0")
    41   SET(ENV{OPENALDIR} ".${MINGW_LIBRARY_DIR}/openal-0.0.8/common")
    42   SET(ENV{LUA_DIR} ".${MINGW_LIBRARY_DIR}/lua-5.1.3")
    43   SET(ENV{OGGVORBISDIR} ".${MINGW_LIBRARY_DIR}/libogg-1.1.3")
     37  SET(BOOST_INCLUDEDIR "${MINGW_LIBRARY_DIR}/boost_1_34_1")
     38  SET(BOOST_LIBRARYDIR "${MINGW_LIBRARY_DIR}/boost_1_34_1/stage/lib")
     39  SET(ENV{ENETDIR} "${MINGW_LIBRARY_DIR}/enet-1.1")
     40  SET(ENV{ALUTDIR} "${MINGW_LIBRARY_DIR}/freealut-1.1.0")
     41  SET(ENV{OPENALDIR} "${MINGW_LIBRARY_DIR}/openal-0.0.8/common")
     42  SET(ENV{LUA_DIR} "${MINGW_LIBRARY_DIR}/lua-5.1.3")
     43  SET(ENV{OGGVORBISDIR} "${MINGW_LIBRARY_DIR}/libogg-1.1.3")
    4444  #SET(TCL_INCLUDE_PATH "/usr/pack/tcltk-8.4.9.linux-mo/include")
    45   SET(ENV{CEGUIDIR} ".${MINGW_LIBRARY_DIR}/cegui-0.6.1")
    46   SET(ENV{OGREDIR} ".${MINGW_LIBRARY_DIR}/ogre/OgreMain;.${MINGW_LIBRARY_DIR}/ogre/Samples/Common/bin/Release")
     45  SET(ENV{CEGUIDIR} "${MINGW_LIBRARY_DIR}/cegui-0.6.1")
     46  SET(ENV{OGREDIR} "${MINGW_LIBRARY_DIR}/ogre/OgreMain;${MINGW_LIBRARY_DIR}/ogre/Samples/Common/bin/Release")
     47  #IF (NOT ENV{DXSDK_DIR})
     48  #  SET(ENV{DXSDK_DIR} "${MINGW_LIBRARY_DIR}/DXSDK")
     49  #ENDIF (NOT ENV{DXSDK_DIR})
    4750ENDIF (MINGW)
     51
     52#MARK_AS_ADVANCED(MINGW_LIBRARY_DIR)
  • code/branches/buildsystem/cmake/FindCEGUI.cmake

    r2197 r2318  
    2929)
    3030
    31 #SET(CEGUI_LIBRARIES debug CEGUIBase_d optimized CEGUIBase)
    32 FIND_LIBRARY(CEGUI_LIBRARY
    33     NAMES CEGUIBase
    34     PATHS
    35     $ENV{CEGUIDIR}
    36     /usr/local
    37     /usr
    38     PATH_SUFFIXES lib
    39 )
     31IF(WIN32)
     32    FIND_LIBRARY(CEGUI_LIBRARY_
     33        NAMES CEGUIBase
     34        PATHS
     35        $ENV{CEGUIDIR}
     36        PATH_SUFFIXES lib
     37    )
     38    FIND_LIBRARY(CEGUI_LIBRARY_d
     39        NAMES CEGUIBase_d
     40        PATHS
     41        $ENV{CEGUIDIR}
     42        PATH_SUFFIXES lib
     43    )
     44    IF(CEGUI_LIBRARY_)
     45        IF(CEGUI_LIBRARY_d)
     46            SET(CEGUI_LIBRARY optimized ${CEGUI_LIBRARY_} debug ${CEGUI_LIBRARY_d})
     47        ELSE(CEGUI_LIBRARY_d)
     48            SET(CEGUI_LIBRARY ${CEGUI_LIBRARY_})
     49        ENDIF(CEGUI_LIBRARY_d)
     50    ENDIF(CEGUI_LIBRARY_)
     51ELSE(WIN32)
     52    FIND_LIBRARY(CEGUI_LIBRARY
     53        NAMES CEGUIBase
     54        PATHS
     55        $ENV{CEGUIDIR}
     56        /usr/local
     57        /usr
     58        PATH_SUFFIXES lib
     59    )
     60ENDIF(WIN32)
    4061
    4162#    IF (NOT CEGUI_SCRIPT_LIBDIR)
     
    6586MARK_AS_ADVANCED(
    6687    CEGUI_LIBRARY
     88    CEGUI_LIBRARY_
     89    CEGUI_LIBRARY_d
    6790    CEGUI_INCLUDE_DIR
    6891    #CEGUI_SCRIPT_LIBRARIES
  • code/branches/buildsystem/cmake/FindDirectX.cmake

    r2278 r2318  
    99  #                 > www.orxonox.net <
    1010
    11   IF (DirectX_INCLUDE_DIR AND DirectX_LIB_DIR)
    12     SET(DirectX_FIND_QUIETLY TRUE)
    13   ENDIF (DirectX_INCLUDE_DIR AND DirectX_LIB_DIR)
    14 
    15   set(DirectX_FOUND "NO")
    16 
    17   FIND_PATH(DirectX_INCLUDE_DIR "dinput.h"
    18     ../libs/DXSDK/Include
    19     $ENV{DXSDK_DIR}/Include
     11  FIND_PATH(DirectX_INCLUDE_DIR dinput.h
     12    PATHS
     13    $ENV{DXSDK_DIR}
     14    PATH_SUFFIXES include
    2015  )
    2116
    22   FIND_PATH(DirectX_LIB_DIR "dinput8.lib"
    23     ../libs/DXSDK/Lib
    24     ../libs/DXSDK/Lib/x86
    25     $ENV{DXSDK_DIR}/lib/x86
     17  FIND_PATH(DirectX_LIB_DIR dinput8.lib
     18    $ENV{DXSDK_DIR}
     19    PATH_SUFFIXES lib lib/x86
    2620  )
    2721
    28   IF (DirectX_INCLUDE_DIR AND DirectX_LIB_DIR)
    29     SET (DirectX_FOUND "YES")
    30   ENDIF (DirectX_INCLUDE_DIR AND DirectX_LIB_DIR)
     22  INCLUDE(FindPackageHandleStandardArgs)
     23  FIND_PACKAGE_HANDLE_STANDARD_ARGS(DirectX DEFAULT_MSG DirectX_INCLUDE_DIR DirectX_LIB_DIR)
    3124
    32   IF (DirectX_FOUND)
    33     IF (NOT DirectX_FIND_QUIETLY)
    34       MESSAGE(STATUS "DirectX was found.")
    35       IF (VERBOSE_FIND)
    36         MESSAGE (STATUS "  include path: ${DirectX_INCLUDE_DIR}")
    37         MESSAGE (STATUS "  library path: ${DirectX_LIB_DIR}")
    38         MESSAGE (STATUS "  libraries:    dinput8.lib")
    39       ENDIF (VERBOSE_FIND)
    40     ENDIF (NOT DirectX_FIND_QUIETLY)
    41   ELSE (DirectX_FOUND)
    42     IF (NOT DirectX_INCLUDE_DIR)
    43       MESSAGE(SEND_ERROR "DirectX include path was not found.")
    44     ENDIF (NOT DirectX_INCLUDE_DIR)
    45     IF (NOT DirectX_LIB_DIR)
    46       MESSAGE(SEND_ERROR "DirectX library was not found.")
    47     ENDIF (NOT DirectX_LIB_DIR)
    48   ENDIF (DirectX_FOUND)
    4925ENDIF(WIN32)
     26
     27MARK_AS_ADVANCED(DirectX_INCLUDE_DIR DirectX_LIB_DIR)
  • code/branches/buildsystem/cmake/FindENet.cmake

    r2054 r2318  
    4646ENDIF (ENET_FOUND)
    4747
    48 MARK_AS_ADVANCED(ENet_LIBRARY ENet_INCLUDE_DIR)
     48MARK_AS_ADVANCED(ENet_LIBRARY ENet_LIBRARIES ENet_INCLUDE_DIR)
  • code/branches/buildsystem/cmake/FindOGRE.cmake

    r2198 r2318  
    2323)
    2424
    25 #SET(OGRE_LIBRARIES debug OgreMain_d optimized OgreMain)
    26 FIND_LIBRARY(OGRE_LIBRARY
    27     NAMES OgreMain
    28     PATHS
    29     $ENV{OGREDIR}
    30     /usr/local
    31     /usr
    32     PATH_SUFFIXES lib
    33 )
     25IF(WIN32)
     26    FIND_LIBRARY(OGRE_LIBRARY_
     27        NAMES OgreMain
     28        PATHS
     29        $ENV{OGREDIR}
     30        PATH_SUFFIXES lib
     31    )
     32    FIND_LIBRARY(OGRE_LIBRARY_d
     33        NAMES OgreMain_d
     34        PATHS
     35        $ENV{OGREDIR}
     36        PATH_SUFFIXES lib
     37    )
     38    IF(OGRE_LIBRARY_)
     39        IF(OGRE_LIBRARY_d)
     40            SET(OGRE_LIBRARY optimized ${OGRE_LIBRARY_} debug ${OGRE_LIBRARY_d})
     41        ELSE(OGRE_LIBRARY_d)
     42            SET(OGRE_LIBRARY ${OGRE_LIBRARY_})
     43        ENDIF(OGRE_LIBRARY_d)
     44    ENDIF(OGRE_LIBRARY_)
     45ELSE(WIN32)
     46    FIND_LIBRARY(OGRE_LIBRARY
     47        NAMES OgreMain
     48        PATHS
     49        $ENV{OGREDIR}
     50        /usr/local
     51        /usr
     52        PATH_SUFFIXES lib
     53    )
     54ENDIF(WIN32)
    3455
    3556INCLUDE(FindPackageHandleStandardArgs)
     
    4162MARK_AS_ADVANCED(
    4263    OGRE_LIBRARY
     64    OGRE_LIBRARY_
     65    OGRE_LIBRARY_d
    4366    OGRE_INCLUDE_DIR
    4467)
  • code/branches/buildsystem/cmake/FindOggVorbis.cmake

    r2061 r2318  
    7373  VORBIS_LIBRARY
    7474  VORBISFILE_LIBRARY
     75  #VORBISENC_LIBRARY
    7576  VORBIS_INCLUDE_DIR
    7677)
  • code/branches/buildsystem/src/CMakeLists.txt

    r2239 r2318  
    3333ADD_SUBDIRECTORY(tolua)
    3434
    35 # TODO: write include file for this stuff
     35# TODO: FIXME
    3636# Some people may not have CEGUILua installed, espc. with version 0.5
    3737# And we don't know what lua version it was linked against, so we compile
Note: See TracChangeset for help on using the changeset viewer.