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

[Cluster-devel] cluster/fence/agents/xvm Makefile



CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	fabbione sourceware org	2007-07-05 14:27:27

Modified files:
	fence/agents/xvm: Makefile 

Log message:
	Overload Makefile to give Lon a build target and keep the style consistent
	across.
	
	Most important change (really) is to keep incdir as last or custom incdir
	build will break.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/xvm/Makefile.diff?cvsroot=cluster&r1=1.11&r2=1.12

--- cluster/fence/agents/xvm/Makefile	2007/06/27 13:32:56	1.11
+++ cluster/fence/agents/xvm/Makefile	2007/07/05 14:27:27	1.12
@@ -14,7 +14,7 @@
 
 TARGET1= fence_xvm
 TARGET2= fence_xvmd
-
+TARGET3= testprog
 
 OBJS1=	fence_xvm.o \
 	ip_lookup.o
@@ -25,6 +25,8 @@
 	vm_states.o \
 	xml.o
 
+OBJS3=	xml-standalone.o
+
 SHAREDOBJS=	mcast.o \
 		simple_auth.o \
 		tcp.o \
@@ -35,15 +37,17 @@
 CFLAGS += -Wall -Werror -Wstrict-prototypes -Wshadow -ggdb
 CFLAGS += -I${ccsincdir} -I${cmanincdir} -I${openaisincdir}
 CFLAGS += -I${virtincdir} -I${nssincdir} -I${nsprincdir}
-CFLAGS += -I${incdir}
 CFLAGS += `xml2-config --cflags`
+CFLAGS += -I${incdir}
+
+EXTRA_CFLAGS += -DSTANDALONE
 
 LDFLAGS += -L${ccslibdir} -L${cmanlibdir} -L${dlmlibdir}
 LDFLAGS += -L${nsslibdir} -L${nsprlibdir} -L${libdir}
-LDFLAGS += -lccs -lcman -ldlm -lnss3 -lnspr4 
+LDFLAGS += -lccs -lcman -ldlm -lnss3 -lnspr4
 
 EXTRA_LDFLAGS += -L${virtlibdir} -lvirt -L${openaislibdir} -lSaCkpt
-EXTRA_LDFLAGS += `xml2-config --libs`
+XML_LDFLAGS += `xml2-config --libs`
 
 all: ${TARGET1} ${TARGET2}
 
@@ -51,13 +55,19 @@
 	$(CC) -o $@ $^ $(LDFLAGS)
 
 ${TARGET2}: ${SHAREDOBJS} ${OBJS2}
-	$(CC) -o $@ $^ $(LDFLAGS) $(EXTRA_LDFLAGS)
+	$(CC) -o $@ $^ $(LDFLAGS) $(EXTRA_LDFLAGS) $(XML_LDFLAGS)
+
+${TARGET3}: ${OBJS3}
+	$(CC) -o $@ $^ $(XML_LDFLAGS)
 
 %.o: %.c
 	$(CC) $(CFLAGS) -c -o $@ $<
 
+%-standalone.o: %.c
+	$(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $<
+
 clean:
-	rm -f ${TARGET1} ${TARGET2} *~ *.o
+	rm -f ${TARGET1} ${TARGET2} ${TARGET3} *~ *.o 
 
 install: all
 	if [ ! -d ${sbindir} ]; then \


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