-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
55 lines (43 loc) · 1.56 KB
/
CMakeLists.txt
File metadata and controls
55 lines (43 loc) · 1.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# Top-level CMakeLists.txt file for pyosg++
#
# I typically configure with a command similar to the following:
#
# c:\d\pyosg++\build>cmake -DCMAKE_INCLUDE_PATH=c:\pt\externals\include \
# -DCMAKE_LIBRARY_PATH=c:\pt\externals\lib \
# -DCMAKE_PREFIX_PATH="C:\pt\externals\bin" ..
#
cmake_minimum_required(VERSION 2.6)
project(pyosg++)
# Put all libs and executables in a 'bin' subdir
set(LIBRARY_OUTPUT_PATH
${PROJECT_BINARY_DIR}/bin
CACHE PATH
"Single directory for all libraries.")
set(EXECUTABLE_OUTPUT_PATH
${PROJECT_BINARY_DIR}/bin
CACHE PATH
"Single directory for all executables.")
mark_as_advanced(LIBRARY_OUTPUT_PATH)
mark_as_advanced(EXECUTABLE_OUTPUT_PATH)
# Every wrapped lib needs these, so just find 'em here
find_package(OpenSceneGraph REQUIRED)
find_package(Boost REQUIRED COMPONENTS python)
find_package(GCCXML REQUIRED)
find_package(OpenSceneGraph REQUIRED)
find_package(PythonInterp REQUIRED)
find_package(PythonLibs REQUIRED)
# Include custom functions
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/CMakeModules;${CMAKE_MODULE_PATH}")
include(custom_functions)
# Invoke custom function to create a cmake.py settings module
create_cmake_py_module()
include_directories(${PYTHON_INCLUDE_PATH}
${Boost_INCLUDE_DIR}
${OSG_INCLUDE_DIR})
link_directories(${Boost_LIBRARY_DIRS})
# Don't prepend 'lib' to the names of modules built
set(CMAKE_SHARED_MODULE_PREFIX "")
add_subdirectory(osg)
#add_subdirectory(osgDB)
#add_subdirectory(osgFX)
# etc., etc.