Browse Source

cmake: Build pstatclient.

Sam Edwards 11 years ago
parent
commit
ea4043d689
3 changed files with 24 additions and 36 deletions
  1. 3 0
      dtool/Config.cmake
  2. 2 2
      panda/CMakeLists.txt
  3. 19 34
      panda/src/pstatclient/CMakeLists.txt

+ 3 - 0
dtool/Config.cmake

@@ -803,6 +803,9 @@ build (such as, for instance, for the iPhone)." ON)
 option(HAVE_AUDIO
   "Do you want to build the audio interface?" ON)
 
+option(DO_PSTATS
+  "Enable the pstats client?" ON)
+
 # These image formats don't require the assistance of a third-party
 # library to read and write, so there's normally no reason to disable
 # them int he build, unless you are looking to reduce the memory footprint.

+ 2 - 2
panda/CMakeLists.txt

@@ -23,6 +23,8 @@ add_subdirectory(src/pandabase)
 add_subdirectory(src/express)
 add_subdirectory(src/downloader)
 add_subdirectory(src/pipeline)
+add_subdirectory(src/nativenet)
+add_subdirectory(src/net)
 add_subdirectory(src/putil)
 add_subdirectory(src/pstatclient)
 add_subdirectory(src/linmath)
@@ -60,8 +62,6 @@ add_subdirectory(src/tform)
 add_subdirectory(src/pgui)
 add_subdirectory(src/recorder)
 add_subdirectory(src/collide)
-add_subdirectory(src/nativenet)
-add_subdirectory(src/net)
 add_subdirectory(src/egg)
 add_subdirectory(src/egg2pg)
 add_subdirectory(src/framework)

+ 19 - 34
panda/src/pstatclient/CMakeLists.txt

@@ -1,43 +1,28 @@
 set(P3PSTATCLIENT_HEADERS
-  config_pstats.h pStatClient.I pStatClient.h
-  pStatClientImpl.I pStatClientImpl.h
-  pStatClientVersion.I 
-  pStatClientVersion.h pStatClientControlMessage.h 
-  pStatCollector.I pStatCollector.h pStatCollectorDef.h 
-  pStatCollectorForward.I pStatCollectorForward.h
-  pStatFrameData.I pStatFrameData.h pStatProperties.h 
-  pStatServerControlMessage.h pStatThread.I pStatThread.h 
-  pStatTimer.I pStatTimer.h
-)
+    config_pstats.h pStatClient.I pStatClient.h
+    pStatClientImpl.I pStatClientImpl.h
+    pStatClientVersion.I
+    pStatClientVersion.h pStatClientControlMessage.h
+    pStatCollector.I pStatCollector.h pStatCollectorDef.h
+    pStatCollectorForward.I pStatCollectorForward.h
+    pStatFrameData.I pStatFrameData.h pStatProperties.h
+    pStatServerControlMessage.h pStatThread.I pStatThread.h
+    pStatTimer.I pStatTimer.h)
 
 set(P3PSTATCLIENT_SOURCES
-  config_pstats.cxx pStatClient.cxx pStatClientImpl.cxx
-  pStatClientVersion.cxx 
-  pStatClientControlMessage.cxx
-  pStatCollector.cxx
-  pStatCollectorDef.cxx 
-  pStatCollectorForward.cxx
-  pStatFrameData.cxx pStatProperties.cxx 
-  pStatServerControlMessage.cxx
-  pStatThread.cxx
-)
+    config_pstats.cxx pStatClient.cxx pStatClientImpl.cxx
+    pStatClientVersion.cxx
+    pStatClientControlMessage.cxx
+    pStatCollector.cxx
+    pStatCollectorDef.cxx
+    pStatCollectorForward.cxx
+    pStatFrameData.cxx pStatProperties.cxx
+    pStatServerControlMessage.cxx
+    pStatThread.cxx)
 
 composite_sources(p3pstatclient P3PSTATCLIENT_SOURCES)
 add_library(p3pstatclient ${P3PSTATCLIENT_HEADERS} ${P3PSTATCLIENT_SOURCES})
-target_link_libraries(p3pstatclient p3putil)
+target_link_libraries(p3pstatclient p3net p3putil p3express)
 target_interrogate(p3pstatclient ALL)
 
 install(TARGETS p3pstatclient DESTINATION lib)
-
-#begin test_bin_target
-  #define LOCAL_LIBS \
-   # p3pstatclient 
-  #define OTHER_LIBS \
-  #  $[OTHER_LIBS] p3pystub
-
-  #define TARGET test_client
-
-  #define SOURCES \
-  #  test_client.cxx
-
-#end test_bin_target