浏览代码

link with proper libs for NATIVE_NET case

David Rose 19 年之前
父节点
当前提交
b8e112e3ba
共有 4 个文件被更改,包括 9 次插入3 次删除
  1. 1 1
      direct/src/distributed/Sources.pp
  2. 1 0
      dtool/Config.pp
  3. 6 0
      dtool/pptempl/Global.pp
  4. 1 2
      panda/src/nativenet/Sources.pp

+ 1 - 1
direct/src/distributed/Sources.pp

@@ -2,7 +2,7 @@
 
 
 #begin lib_target
 #begin lib_target
   #define BUILD_TARGET $[HAVE_PYTHON]
   #define BUILD_TARGET $[HAVE_PYTHON]
-  #define USE_PACKAGES openssl nspr 
+  #define USE_PACKAGES openssl nspr native_net
 
 
   #define TARGET distributed
   #define TARGET distributed
   #define LOCAL_LIBS \
   #define LOCAL_LIBS \

+ 1 - 0
dtool/Config.pp

@@ -413,6 +413,7 @@
 // Define this true to build a native network implementation,
 // Define this true to build a native network implementation,
 // which does not require NSPR.
 // which does not require NSPR.
 #define WANT_NATIVE_NET 1
 #define WANT_NATIVE_NET 1
+#define NATIVE_NET_LIBS $[if $[WINDOWS_PLATFORM],Ws2_32.lib]
 
 
 // Is a third-party STL library installed, and where?  This is only
 // Is a third-party STL library installed, and where?  This is only
 // necessary if the default include and link lines that come with the
 // necessary if the default include and link lines that come with the

+ 6 - 0
dtool/pptempl/Global.pp

@@ -317,6 +317,12 @@
   #define net_libs $[NET_LIBS]
   #define net_libs $[NET_LIBS]
 #endif
 #endif
 
 
+#if $[WANT_NATIVE_NET]
+  #define native_net_ipath $[wildcard $[NATIVE_NET_IPATH]]
+  #define native_net_lpath $[wildcard $[NATIVE_NET_LPATH]]
+  #define native_net_libs $[NATIVE_NET_LIBS]
+#endif
+
 #if $[HAVE_RAD_MSS]
 #if $[HAVE_RAD_MSS]
   #define rad_mss_ipath $[wildcard $[RAD_MSS_IPATH]]
   #define rad_mss_ipath $[wildcard $[RAD_MSS_IPATH]]
   #define rad_mss_lpath $[wildcard $[RAD_MSS_LPATH]]
   #define rad_mss_lpath $[wildcard $[RAD_MSS_LPATH]]

+ 1 - 2
panda/src/nativenet/Sources.pp

@@ -1,5 +1,3 @@
-
-
 #define LOCAL_LIBS express pandabase
 #define LOCAL_LIBS express pandabase
 
 
 #define OTHER_LIBS \
 #define OTHER_LIBS \
@@ -7,6 +5,7 @@
     dtoolutil:c dtoolbase:c prc:c dtool:m
     dtoolutil:c dtoolbase:c prc:c dtool:m
 
 
 #define BUILD_DIRECTORY $[WANT_NATIVE_NET]
 #define BUILD_DIRECTORY $[WANT_NATIVE_NET]
+#define USE_PACKAGES native_net
 
 
 #begin lib_target
 #begin lib_target
   #define TARGET nativenet
   #define TARGET nativenet