[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Cluster-devel] cluster ccs/ccs_tool/Makefile ccs/daemon/Makef ...



CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	fabbione sourceware org	2008-02-12 05:45:34

Modified files:
	ccs/ccs_tool   : Makefile 
	ccs/daemon     : Makefile 
	dlm/lib        : Makefile 
	fence/agents/xvm: Makefile 
	gnbd/client    : Makefile 
	gnbd/server    : Makefile 
	gnbd/tools/gnbd_export: Makefile 
	gnbd/tools/gnbd_import: Makefile 
	rgmanager/src/daemons: Makefile 
	rgmanager/src/utils: Makefile 

Log message:
	Stop linking against unrequired libraries.
	
	A lot of small tools were linking against a bunch of libraries for no reasons.
	Clean them up as much as possible as static linking is not spotted automatically.
	
	Problem spotted by some Debian automatic test tools and reported by
	Frederik Schüler <fs at debian.org>

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/ccs/ccs_tool/Makefile.diff?cvsroot=cluster&r1=1.20&r2=1.21
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/ccs/daemon/Makefile.diff?cvsroot=cluster&r1=1.22&r2=1.23
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/dlm/lib/Makefile.diff?cvsroot=cluster&r1=1.27&r2=1.28
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/xvm/Makefile.diff?cvsroot=cluster&r1=1.20&r2=1.21
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gnbd/client/Makefile.diff?cvsroot=cluster&r1=1.21&r2=1.22
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gnbd/server/Makefile.diff?cvsroot=cluster&r1=1.21&r2=1.22
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gnbd/tools/gnbd_export/Makefile.diff?cvsroot=cluster&r1=1.22&r2=1.23
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gnbd/tools/gnbd_import/Makefile.diff?cvsroot=cluster&r1=1.19&r2=1.20
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/rgmanager/src/daemons/Makefile.diff?cvsroot=cluster&r1=1.31&r2=1.32
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/rgmanager/src/utils/Makefile.diff?cvsroot=cluster&r1=1.24&r2=1.25

--- cluster/ccs/ccs_tool/Makefile	2007/12/22 13:36:49	1.20
+++ cluster/ccs/ccs_tool/Makefile	2008/02/12 05:45:33	1.21
@@ -34,7 +34,7 @@
 CFLAGS += -I${incdir}
 
 LDFLAGS += -L${ccslibdir} -L${cmanlibdir} -lccs -lcman
-LDFLAGS += `xml2-config --libs` -L${libdir} -ldl
+LDFLAGS += `xml2-config --libs` -L${libdir}
 
 
 ${TARGET}: ${OBJS}
--- cluster/ccs/daemon/Makefile	2007/12/22 13:36:49	1.22
+++ cluster/ccs/daemon/Makefile	2008/02/12 05:45:33	1.23
@@ -34,7 +34,7 @@
 CFLAGS += -I${incdir}
 
 LDFLAGS += -L${cmanlibdir} -lcman -L${ccslibdir} -lccs
-LDFLAGS += -L${libdir} `xml2-config --libs` -lpthread -ldl
+LDFLAGS += -L${libdir} `xml2-config --libs` -lpthread
 
 
 ${TARGET}: ${OBJS}
--- cluster/dlm/lib/Makefile	2007/12/22 13:36:50	1.27
+++ cluster/dlm/lib/Makefile	2008/02/12 05:45:33	1.28
@@ -45,8 +45,7 @@
 CFLAGS += -I${incdir}
 CFLAGS += -I$(KERNEL_SRC)/include
 
-LDFLAGS += -lpthread 
-
+PTHREAD_LDFLAGS += -lpthread 
 
 $(TARGET).a: $(TARGET).o $(AISTARGET).o
 	${AR} r $@ $^
@@ -57,7 +56,7 @@
 	${RANLIB} $@
 
 $(TARGET).so.${RELEASE_MAJOR}.${RELEASE_MINOR}: $(TARGET).po $(AISTARGET).po
-	$(CC) $(LDFLAGS) -shared -o $@ -Wl,-soname=$(TARGET).so.$(RELEASE_MAJOR) $<
+	$(CC) $(PTHREAD_LDFLAGS) $(LDFLAGS) -shared -o $@ -Wl,-soname=$(TARGET).so.$(RELEASE_MAJOR) $<
 	ln -sf $(TARGET).so.$(RELEASE_MAJOR).$(RELEASE_MINOR) $(TARGET).so
 	ln -sf $(TARGET).so.$(RELEASE_MAJOR).$(RELEASE_MINOR) $(TARGET).so.$(RELEASE_MAJOR)
 
--- cluster/fence/agents/xvm/Makefile	2007/12/22 13:36:52	1.20
+++ cluster/fence/agents/xvm/Makefile	2008/02/12 05:45:33	1.21
@@ -50,10 +50,10 @@
 
 EXTRA_CFLAGS += -DSTANDALONE
 
-LDFLAGS += -L${ccslibdir} -L${cmanlibdir} -L${dlmlibdir}
-LDFLAGS += -L${nsslibdir} -L${nsprlibdir} -L${libdir}
-LDFLAGS += -lccs -lcman -ldlm -lnss3 -lnspr4
+LDFLAGS += -L${nsslibdir} -L${libdir}
+LDFLAGS += -lnss3
 
+EXTRA_LDFLAGS += -L${ccslibdir} -lccs -L${cmanlibdir} -lcman
 EXTRA_LDFLAGS += -L${virtlibdir} -lvirt -L${openaislibdir} -lSaCkpt
 XML_LDFLAGS += `xml2-config --libs`
 
--- cluster/gnbd/client/Makefile	2007/12/22 13:52:32	1.21
+++ cluster/gnbd/client/Makefile	2008/02/12 05:45:33	1.22
@@ -37,7 +37,7 @@
 CFLAGS += -I$(S)/../include -I$(S)/../server -I$(S)/../utils
 CFLAGS += -I${incdir}
 
-LDFLAGS += -L${libdir} -L${cmanlibdir} -lcman -ldl -lpthread
+LDFLAGS += -L${libdir} -L${cmanlibdir} -lcman
 
 ${TARGET1}: ${SHAREDOBJS} ${OBJS1}
 	$(CC) -o $@ $^ $(LDFLAGS)
--- cluster/gnbd/server/Makefile	2007/12/22 13:52:32	1.21
+++ cluster/gnbd/server/Makefile	2008/02/12 05:45:33	1.22
@@ -42,7 +42,7 @@
 CFLAGS += -I$(S)/../include -I$(S)/../utils
 CFLAGS += -I${incdir}
 
-LDFLAGS+= -L${libdir} -L${cmanlibdir} -lcman -ldl -lpthread
+LDFLAGS+= -L${libdir} -L${cmanlibdir} -lcman
 
 ${TARGET1}: ${SHAREDOBJS} ${OBJS1}
 	$(CC) -o $@ $^ $(LDFLAGS)
--- cluster/gnbd/tools/gnbd_export/Makefile	2007/12/22 13:52:32	1.22
+++ cluster/gnbd/tools/gnbd_export/Makefile	2008/02/12 05:45:33	1.23
@@ -32,7 +32,7 @@
 CFLAGS += -I$(S)/../../include -I$(S)/../../server -I$(S)/../../utils
 CFLAGS += -I${incdir}
 
-LDFLAGS += -L${libdir} -L${cmanlibdir} -lcman -ldl -lpthread
+LDFLAGS += -L${libdir} -L${cmanlibdir} -lcman
 
 ${TARGET}: ${OBJS}
 	$(CC) -o $@ $^ $(LDFLAGS)
--- cluster/gnbd/tools/gnbd_import/Makefile	2007/12/22 13:52:32	1.19
+++ cluster/gnbd/tools/gnbd_import/Makefile	2008/02/12 05:45:34	1.20
@@ -33,7 +33,7 @@
 CFLAGS += -I$(S)/../../utils -I$(S)/../../client
 CFLAGS += -I${incdir}
 
-LDFLAGS += -L${libdir} -L${cmanlibdir} -lcman -ldl -lpthread
+LDFLAGS += -L${libdir} -L${cmanlibdir} -lcman
 
 ${TARGET}: ${OBJS}
 	$(CC) -o $@ $^ $(LDFLAGS)
--- cluster/rgmanager/src/daemons/Makefile	2007/12/22 13:36:59	1.31
+++ cluster/rgmanager/src/daemons/Makefile	2008/02/12 05:45:34	1.32
@@ -77,7 +77,7 @@
 DLM_LDFLAGS += -L${dlmlibdir} -ldlm
 XML2_LDFLAGS += `xml2-config --libs`
 SLANG_LDFLAGS += -L${slanglibdir} -lslang
-EXTRA_LDFLAGS += -lpthread -ldl
+EXTRA_LDFLAGS += -lpthread
 LOCAL_LDFLAGS += -llalloc
 READLINE_LDFLAGS += -L${readlinelibdir} -lreadline
 
@@ -106,8 +106,7 @@
 #
 ${TARGET3}: ${SHAREDOBJS} ${OBJS3}
 	$(CC) -o $@ $^ $(LDFLAGS) $(CCS_LDFLAGS) $(CMAN_LDFLAGS) \
-			$(LOCAL_LDFLAGS) $(EXTRA_LDFLAGS) $(XML2_LDFLAGS) \
-			$(SLANG_LDFLAGS)
+			$(LOCAL_LDFLAGS) $(EXTRA_LDFLAGS) $(XML2_LDFLAGS)
 
 ${TARGET4}: ${SHAREDOBJS} ${OBJS4}
 	$(CC) -o $@ $^ $(LDFLAGS) $(CCS_LDFLAGS) $(CMAN_LDFLAGS) \
--- cluster/rgmanager/src/utils/Makefile	2007/12/22 13:36:59	1.24
+++ cluster/rgmanager/src/utils/Makefile	2008/02/12 05:45:34	1.25
@@ -34,10 +34,14 @@
 CFLAGS += -I$(S)/../../include
 CFLAGS += -I${incdir}
 
-LDFLAGS += -L${libdir} -L${ccslibdir} -L${cmanlibdir} -L${ncurseslibdir}
-LDFLAGS += -lcman -lpthread -ldl -lncurses -lccs
+LDFLAGS += -L${libdir}
 LDFLAGS += -L../clulib -lclulib
 
+CCS_LDFLAGS += -L${ccslibdir} -lccs
+CMAN_LDFLAGS += -L${cmanlibdir} -lcman
+NCURSES_LDFLAGS += -L${ncurseslibdir} -lncurses
+PTHREAD_LDFLAGS += -lpthread 
+
 
 ${TARGET1}: ${TARGET1:=.o}
 	$(CC) -o $@ $^ $(LDFLAGS)
@@ -46,13 +50,14 @@
 	$(CC) -o $@ $^ $(LDFLAGS)
 
 ${TARGET3}: ${TARGET3:=.o}
-	$(CC) -o $@ $^ $(LDFLAGS)
+	$(CC) -o $@ $^ $(LDFLAGS) $(CCS_LDFLAGS) $(CMAN_LDFLAGS) \
+			$(NCURSES_LDFLAGS) $(PTHREAD_LDFLAGS)
 
 ${TARGET4}: ${TARGET4:=.o}
-	$(CC) -o $@ $^ $(LDFLAGS)
+	$(CC) -o $@ $^ $(LDFLAGS) $(CMAN_LDFLAGS) $(PTHREAD_LDFLAGS)
 
 ${TARGET5}: ${TARGET5:=.o}
-	$(CC) -o $@ $^ $(LDFLAGS)
+	$(CC) -o $@ $^ $(LDFLAGS) $(CCS_LDFLAGS)
 
 ${TARGET6}:
 	cp $(S)/${TARGET6}.sh ${TARGET6}


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]