Changeset 52
- Timestamp:
- May 26, 2010, 10:00:16 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
osgVisual/CMakeLists.txt
r51 r52 1 ################################################################################################# 2 # This file allows to configure osgVisual with CMAKE to generate native build solutions. # 3 # # 4 # Specify the following environment variables to use osgVisual and this CMAKE script: # 5 # * OSG_ROOT: Path to your 32 bit (x86) OSG, e.g. D:\OSG\OpenSceneGraph-2.9.8_x86 # 6 # * OSG_ROOT_X64: Path to your 64 bit (x64) OSG, e.g. D:\OSG\OpenSceneGraph-2.9.8_x64 # 7 # * OSG: Path to your 32 bit (x86) OSG and 3rdParty binary folder, # 8 # e.g. %OSG_ROOT%\bin;D:\OSG\3rdParty\bin\x86 # 9 # * OSG_X64: Path to your 64 bit (x64) OSG and 3rdParty binary folder, # 10 # e.g. %OSG_ROOT_X64%\bin;D:\OSG\3rdParty\bin\x64 # 11 # * PATH: Extend with %OSG% or %OSG_X64% to use OSG and osgVisual from command line, # 12 # e.g. PATH=%PATH%;%OSG% # 13 # # 14 # NOTE: On Visual Studio and x64 Arch, CMAKE uses the project settings to specify the # 15 # correct x64 OSG path, so you can use osg as 32 bit in your system path. # 16 # # 17 # # 18 ################################################################################################# 19 1 20 cmake_minimum_required(VERSION 2.8) 21 2 22 3 23 PROJECT(osgVisual) … … 15 35 ENDIF() 16 36 37 17 38 # Get OSG Settings 18 # SET(OpenSceneGraph_MARK_AS_ADVANCED ON) 39 IF(DESTINATION_ARCH STREQUAL "x64") 40 SET(OSG_ROOT_BKP $ENV{OSG_ROOT}) # BACKUP old OSG_ROOT 41 SET(ENV{OSG_ROOT} $ENV{OSG_ROOT_X64}) # Replace OSGROOT with OSG_ROOT_X64 to force CMAKE to find the correct OSG version (64 bit) 42 ENDIF () 43 44 SET(OpenSceneGraph_MARK_AS_ADVANCED ON) 19 45 FIND_PACKAGE(OpenSceneGraph 2.9.7 REQUIRED osgViewer OpenThreads osgDB osgTerrain osgGA osgText osgSim osgUtil) 20 46 FIND_PACKAGE(OpenGL REQUIRED) 47 48 IF(DESTINATION_ARCH STREQUAL "x64") 49 SET(ENV{OSG_ROOT} ${OSG_ROOT_BKP}) # Restore old OSG_ROOT 50 UNSET(OSG_ROOT_BKP) # Delete backup 51 ENDIF () 52 53 21 54 22 55 # Module sky-silverlining - At the moment only for Win32, will be opened to Unix ASAP
Note: See TracChangeset
for help on using the changeset viewer.