@@ -32,6 +32,11 @@ set(tmx_SRCS
32
32
)
33
33
34
34
add_library (${PROJECT_NAME} ${tmx_HDRS} ${tmx_SRCS} )
35
+ install (TARGETS pugi ${PROJECT_NAME} LIBRARY DESTINATION lib)
36
+ install (FILES ${pugi_HDRS} ${tmx_HDRS} DESTINATION include )
37
+
38
+ FILE (GLOB maps "${CMAKE_CURRENT_SOURCE_DIR} /maps/*" )
39
+ install (FILES ${maps} DESTINATION share/tmx/examples/maps)
35
40
36
41
#set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
37
42
find_package (SFML 2 REQUIRED system window graphics)
@@ -44,30 +49,35 @@ if (SFML_FOUND)
44
49
target_link_libraries (BenchMark pugi)
45
50
target_link_libraries (BenchMark ${SFML_LIBRARIES} )
46
51
target_link_libraries (BenchMark ${ZLIB_LIBRARIES} )
52
+ install (TARGETS BenchMark RUNTIME DESTINATION share/tmx/examples)
47
53
48
54
add_executable (DrawWithDebug examples/DrawMapWithDebug.cpp)
49
55
target_link_libraries (DrawWithDebug ${PROJECT_NAME} )
50
56
target_link_libraries (DrawWithDebug pugi)
51
57
target_link_libraries (DrawWithDebug ${SFML_LIBRARIES} )
52
58
target_link_libraries (DrawWithDebug ${ZLIB_LIBRARIES} )
59
+ install (TARGETS DrawWithDebug RUNTIME DESTINATION share/tmx/examples)
53
60
54
61
add_executable (Isometric examples/IsometricWithConvertCoords.cpp)
55
62
target_link_libraries (Isometric ${PROJECT_NAME} )
56
63
target_link_libraries (Isometric pugi)
57
64
target_link_libraries (Isometric ${SFML_LIBRARIES} )
58
65
target_link_libraries (Isometric ${ZLIB_LIBRARIES} )
66
+ install (TARGETS Isometric RUNTIME DESTINATION share/tmx/examples)
59
67
60
68
add_executable (QuadTree examples/MapWithQuadTree.cpp)
61
69
target_link_libraries (QuadTree ${PROJECT_NAME} )
62
70
target_link_libraries (QuadTree pugi)
63
71
target_link_libraries (QuadTree ${SFML_LIBRARIES} )
64
72
target_link_libraries (QuadTree ${ZLIB_LIBRARIES} )
73
+ install (TARGETS QuadTree RUNTIME DESTINATION share/tmx/examples)
65
74
66
75
add_executable (ShaderEffects examples/ShaderEffects.cpp)
67
76
target_link_libraries (ShaderEffects ${PROJECT_NAME} )
68
77
target_link_libraries (ShaderEffects pugi)
69
78
target_link_libraries (ShaderEffects ${SFML_LIBRARIES} )
70
79
target_link_libraries (ShaderEffects ${ZLIB_LIBRARIES} )
80
+ install (TARGETS ShaderEffects RUNTIME DESTINATION share/tmx/examples)
71
81
72
82
if (BOX2D_FOUND)
73
83
add_executable (Box2D examples/Box2D.cpp src/tmx2box2d.cpp)
@@ -76,6 +86,7 @@ if (SFML_FOUND)
76
86
target_link_libraries (Box2D ${SFML_LIBRARIES} )
77
87
target_link_libraries (Box2D ${ZLIB_LIBRARIES} )
78
88
target_link_libraries (Box2D ${BOX2D_LIBRARIES} )
89
+ install (TARGETS Box2D RUNTIME DESTINATION share/tmx/examples)
79
90
80
91
endif (BOX2D_FOUND)
81
92
0 commit comments