Last change
on this file since 2366 was
2131,
checked in by rgrieder, 16 years ago
|
Added CMakeLists.txt to every subfolder and adjusted accordingly.
The CMake script I have written can be used as follows:
ADD_SOURCE_DIRECTORY(_source_list directory) # Adds a new source subdirectory where _source_list is the name of the source list in CURRENT folder
ADD_SOURCE_FILES(_source_list) # Adds the source files in a subdirectory to the source list in the super directory (has to be called!)
Note: When adding more subdirectories in a subdirectory, call ADD_SOURCE_FILES after ADD_SOURCE_DIRECTORY!
|
-
Property svn:eol-style set to
native
|
File size:
993 bytes
|
Rev | Line | |
---|
[1505] | 1 | SET( NETWORK_SRC_FILES |
---|
[2087] | 2 | ChatListener.cc |
---|
[1505] | 3 | Client.cc |
---|
| 4 | ClientConnection.cc |
---|
| 5 | ClientInformation.cc |
---|
[2087] | 6 | ClientConnectionListener.cc |
---|
[1505] | 7 | ConnectionManager.cc |
---|
[1735] | 8 | GamestateManager.cc |
---|
| 9 | GamestateClient.cc |
---|
| 10 | GamestateHandler.cc |
---|
[1505] | 11 | PacketBuffer.cc |
---|
| 12 | Server.cc |
---|
| 13 | Synchronisable.cc |
---|
[1735] | 14 | Host.cc |
---|
[1505] | 15 | ) |
---|
| 16 | |
---|
[2131] | 17 | ADD_SOURCE_DIRECTORY(NETWORK_SRC_FILES packet) |
---|
| 18 | |
---|
[1505] | 19 | IF(WIN32) |
---|
| 20 | ADD_LIBRARY( network ${NETWORK_SRC_FILES} ) |
---|
| 21 | ELSE(WIN32) |
---|
| 22 | ADD_LIBRARY( network SHARED ${NETWORK_SRC_FILES} ) |
---|
| 23 | ENDIF(WIN32) |
---|
| 24 | |
---|
| 25 | TARGET_LINK_LIBRARIES( network |
---|
| 26 | ${ZLIB_LIBRARY} |
---|
| 27 | ${ENet_LIBRARY} |
---|
| 28 | ${Boost_thread_LIBRARIES} |
---|
| 29 | core |
---|
| 30 | ) |
---|
| 31 | |
---|
| 32 | |
---|
| 33 | # build those parts only on request. |
---|
| 34 | IF(NETWORK_TESTING_ENABLED) |
---|
| 35 | ##### test for gamestate stuff ##### |
---|
| 36 | SET( TEST_SRC_FILES |
---|
[1735] | 37 | ${NETWORK_SRC_FILES} |
---|
[1505] | 38 | ) |
---|
| 39 | ADD_EXECUTABLE(networktest ${TEST_SRC_FILES}) |
---|
| 40 | TARGET_LINK_LIBRARIES( networktest |
---|
| 41 | ${OGRE_LIBRARIES} |
---|
| 42 | network |
---|
| 43 | ${ENet_LIBRARY} |
---|
| 44 | ${ZLIB_LIBRARY} |
---|
| 45 | ${WINDOWS_ENET_DEPENDENCIES} |
---|
| 46 | ) |
---|
| 47 | ##### end test for gamestate stuff ##### |
---|
| 48 | ENDIF(NETWORK_TESTING_ENABLED) |
---|
Note: See
TracBrowser
for help on using the repository browser.