You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by fu...@apache.org on 2007/04/08 14:49:58 UTC

svn commit: r526549 - in /apr/apr-util/trunk/dbd: NWGNUdbdmysql NWGNUdbdpgsql NWGNUdbdsqli2 NWGNUdbdsqli3

Author: fuankg
Date: Sun Apr  8 05:49:57 2007
New Revision: 526549

URL: http://svn.apache.org/viewvc?view=rev&rev=526549
Log:
enabled static linking of dependent external libs.

Modified:
    apr/apr-util/trunk/dbd/NWGNUdbdmysql
    apr/apr-util/trunk/dbd/NWGNUdbdpgsql
    apr/apr-util/trunk/dbd/NWGNUdbdsqli2
    apr/apr-util/trunk/dbd/NWGNUdbdsqli3

Modified: apr/apr-util/trunk/dbd/NWGNUdbdmysql
URL: http://svn.apache.org/viewvc/apr/apr-util/trunk/dbd/NWGNUdbdmysql?view=diff&rev=526549&r1=526548&r2=526549
==============================================================================
--- apr/apr-util/trunk/dbd/NWGNUdbdmysql (original)
+++ apr/apr-util/trunk/dbd/NWGNUdbdmysql Sun Apr  8 05:49:57 2007
@@ -23,10 +23,13 @@
 # Make sure all needed macro's are defined
 #
 
+# LINK_STATIC = 1
+
 # for now defined here - should finally go into build/NWGNUenvironment.inc
-MYSQL_INC=$(MYSQLSDK)/include
-MYSQL_IMP=$(MYSQLSDK)/lib/libmysql.imp
-MYSQL_NLM=libmysql
+MYSQL_INC = $(MYSQLSDK)/include
+MYSQL_IMP = $(MYSQLSDK)/lib/libmysql.imp
+MYSQL_LIB = $(MYSQLSDK)/lib/libmysqlclient_r.lib $(MYSQLSDK)/lib/libz.lib
+MYSQL_NLM = libmysql
 
 #
 # These directories will be at the beginning of the include list, followed by
@@ -61,6 +64,12 @@
 XLFLAGS		+= \
 			$(EOLIST)
 
+ifdef LINK_STATIC
+XLFLAGS		+= \
+			-l $(MYSQLSDK)/lib \
+			$(EOLIST)
+endif
+
 #
 # These values will be appended to the correct variables based on the value of
 # RELEASE
@@ -121,6 +130,12 @@
 NLM_DESCRIPTION	= Apache Portability Runtime Library $(VERSION_STR) DBD MySQL Driver Module
 
 #
+# This is used by the link '-copy ' directive.
+# If left blank, the ASF copyright defined in NWGNUtail.inc will be used.
+#
+NLM_COPYRIGHT	= Copyright (c) 2003-2007 WebThing Ltd and other contributors 
+
+#
 # This is used by the '-threadname' directive.  If left blank,
 # NLM_NAME Thread will be used.
 #
@@ -194,6 +209,12 @@
 	libcpre.o \
 	$(EOLIST)
 
+ifeq ($(LINK_STATIC),1)
+FILES_nlm_libs += \
+	$(MYSQL_LIB) \
+	$(EOLIST)
+endif
+
 #
 # These are the modules that the above NLM target depends on to load.
 # These will be added as a module command in the link.opt file.
@@ -201,8 +222,13 @@
 FILES_nlm_modules = \
 	aprlib \
 	libc \
+	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_modules += \
 	$(MYSQL_NLM) \
 	$(EOLIST)
+endif
 
 #
 # If the nlm has a msg file, put it's path here
@@ -225,8 +251,13 @@
 FILES_nlm_Ximports = \
 	@$(APR)/aprlib.imp \
 	@libc.imp \
+	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_Ximports += \
 	@$(MYSQL_IMP) \
 	$(EOLIST)
+endif
 
 #
 # Any symbols exported to here

Modified: apr/apr-util/trunk/dbd/NWGNUdbdpgsql
URL: http://svn.apache.org/viewvc/apr/apr-util/trunk/dbd/NWGNUdbdpgsql?view=diff&rev=526549&r1=526548&r2=526549
==============================================================================
--- apr/apr-util/trunk/dbd/NWGNUdbdpgsql (original)
+++ apr/apr-util/trunk/dbd/NWGNUdbdpgsql Sun Apr  8 05:49:57 2007
@@ -23,10 +23,13 @@
 # Make sure all needed macro's are defined
 #
 
+# LINK_STATIC = 1
+
 # for now defined here - should finally go into build/NWGNUenvironment.inc
-PGSQL_INC=$(PGSQLSDK)/inc
-PGSQL_IMP=$(PGSQLSDK)/imp/libpq.imp
-PGSQL_NLM=libpq
+PGSQL_INC = $(PGSQLSDK)/inc
+PGSQL_IMP = $(PGSQLSDK)/imp/libpq.imp
+PGSQL_LIB = $(PGSQLSDK)/lib/libpq.lib
+PGSQL_NLM = libpq
 
 #
 # These directories will be at the beginning of the include list, followed by
@@ -61,6 +64,12 @@
 XLFLAGS		+= \
 			$(EOLIST)
 
+ifdef LINK_STATIC
+XLFLAGS		+= \
+			-l $(PGSQLSDK)/lib \
+			$(EOLIST)
+endif
+
 #
 # These values will be appended to the correct variables based on the value of
 # RELEASE
@@ -194,6 +203,12 @@
 	libcpre.o \
 	$(EOLIST)
 
+ifeq ($(LINK_STATIC),1)
+FILES_nlm_libs += \
+	$(PGSQL_LIB) \
+	$(EOLIST)
+endif
+
 #
 # These are the modules that the above NLM target depends on to load.
 # These will be added as a module command in the link.opt file.
@@ -201,8 +216,13 @@
 FILES_nlm_modules = \
 	aprlib \
 	libc \
+	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_modules += \
 	$(PGSQL_NLM) \
 	$(EOLIST)
+endif
 
 #
 # If the nlm has a msg file, put it's path here
@@ -225,8 +245,13 @@
 FILES_nlm_Ximports = \
 	@$(APR)/aprlib.imp \
 	@libc.imp \
+	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_Ximports += \
 	@$(PGSQL_IMP) \
 	$(EOLIST)
+endif
 
 #
 # Any symbols exported to here

Modified: apr/apr-util/trunk/dbd/NWGNUdbdsqli2
URL: http://svn.apache.org/viewvc/apr/apr-util/trunk/dbd/NWGNUdbdsqli2?view=diff&rev=526549&r1=526548&r2=526549
==============================================================================
--- apr/apr-util/trunk/dbd/NWGNUdbdsqli2 (original)
+++ apr/apr-util/trunk/dbd/NWGNUdbdsqli2 Sun Apr  8 05:49:57 2007
@@ -23,6 +23,14 @@
 # Make sure all needed macro's are defined
 #
 
+# LINK_STATIC = 1
+
+# for now defined here - should finally go into build/NWGNUenvironment.inc
+SQLITE2_INC = $(SQLITE2SDK)/src
+SQLITE2_IMP = $(SQLITE2SDK)/lsqlite2.imp
+SQLITE2_LIB = $(SQLITE2SDK)/lsqlite2.lib
+SQLITE2_NLM = lsqlite2
+
 #
 # These directories will be at the beginning of the include list, followed by
 # INCDIRS
@@ -55,6 +63,12 @@
 XLFLAGS		+= \
 			$(EOLIST)
 
+ifdef LINK_STATIC
+XLFLAGS		+= \
+			-l $(SQLITE2SDK) \
+			$(EOLIST)
+endif
+
 #
 # These values will be appended to the correct variables based on the value of
 # RELEASE
@@ -188,6 +202,12 @@
 	libcpre.o \
 	$(EOLIST)
 
+ifeq ($(LINK_STATIC),1)
+FILES_nlm_libs += \
+	$(SQLITE2_LIB) \
+	$(EOLIST)
+endif
+
 #
 # These are the modules that the above NLM target depends on to load.
 # These will be added as a module command in the link.opt file.
@@ -195,8 +215,13 @@
 FILES_nlm_modules = \
 	aprlib \
 	libc \
+	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_modules += \
 	$(SQLITE2_NLM) \
 	$(EOLIST)
+endif
 
 #
 # If the nlm has a msg file, put it's path here
@@ -219,8 +244,13 @@
 FILES_nlm_Ximports = \
 	@$(APR)/aprlib.imp \
 	@libc.imp \
-	$(SQLITE2_IMP) \
 	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_Ximports += \
+	@$(SQLITE2_IMP) \
+	$(EOLIST)
+endif
 
 #
 # Any symbols exported to here

Modified: apr/apr-util/trunk/dbd/NWGNUdbdsqli3
URL: http://svn.apache.org/viewvc/apr/apr-util/trunk/dbd/NWGNUdbdsqli3?view=diff&rev=526549&r1=526548&r2=526549
==============================================================================
--- apr/apr-util/trunk/dbd/NWGNUdbdsqli3 (original)
+++ apr/apr-util/trunk/dbd/NWGNUdbdsqli3 Sun Apr  8 05:49:57 2007
@@ -22,10 +22,14 @@
 #
 # Make sure all needed macro's are defined
 #
+
+# LINK_STATIC = 1
+
+# for now defined here - should finally go into build/NWGNUenvironment.inc
 SQLITE3_INC = $(SQLITE3SDK)/src
 SQLITE3_IMP = $(SQLITE3SDK)/lsqlite3.imp
 SQLITE3_LIB = $(SQLITE3SDK)/lsqlite3.lib
-SQLITE3_LIB = lsqlite3.nlm
+SQLITE3_NLM = lsqlite3
 
 #
 # These directories will be at the beginning of the include list, followed by
@@ -59,6 +63,12 @@
 XLFLAGS		+= \
 			$(EOLIST)
 
+ifdef LINK_STATIC
+XLFLAGS		+= \
+			-l $(SQLITE3SDK) \
+			$(EOLIST)
+endif
+
 #
 # These values will be appended to the correct variables based on the value of
 # RELEASE
@@ -192,6 +202,12 @@
 	libcpre.o \
 	$(EOLIST)
 
+ifeq ($(LINK_STATIC),1)
+FILES_nlm_libs += \
+	$(SQLITE3_LIB) \
+	$(EOLIST)
+endif
+
 #
 # These are the modules that the above NLM target depends on to load.
 # These will be added as a module command in the link.opt file.
@@ -199,8 +215,13 @@
 FILES_nlm_modules = \
 	aprlib \
 	libc \
+	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_modules += \
 	$(SQLITE3_NLM) \
 	$(EOLIST)
+endif
 
 #
 # If the nlm has a msg file, put it's path here
@@ -223,10 +244,15 @@
 FILES_nlm_Ximports = \
 	@$(APR)/aprlib.imp \
 	@libc.imp \
-	@$(SQLITE3_IMP) \
 	apr_dbd_mutex_lock \
 	apr_dbd_mutex_unlock \
 	$(EOLIST)
+
+ifneq ($(LINK_STATIC),1)
+FILES_nlm_Ximports += \
+	@$(SQLITE3_IMP) \
+	$(EOLIST)
+endif
 
 #
 # Any symbols exported to here