Fix no libver handling.

This commit is contained in:
agibert 2002-02-26 16:51:47 +00:00
parent 1f50073641
commit 3002869e96
3 changed files with 15 additions and 9 deletions

View File

@ -1,9 +1,9 @@
all: demo0 demo0-static all: demo0 demo0-static
demo0-static: demo0.c ../../libver/ver.h ../lib/node.h ../../libver/libver.so ../lib/libnode.so Makefile demo0-static: demo0.c ../lib/node.h ../lib/libnode.a Makefile
gcc -g -o demo0-static -I ../lib -ldl demo0.c ../lib/libnode.a gcc -g -o demo0-static -I ../lib -ldl demo0.c ../lib/libnode.a
demo0: demo0.c ../../libver/ver.h ../lib/node.h ../../libver/libver.so ../lib/libnode.so Makefile demo0: demo0.c ../lib/node.h ../lib/libnode.so Makefile
gcc -g -o demo0 -I ../lib -L ../lib -ldl -lnode demo0.c gcc -g -o demo0 -I ../lib -L ../lib -ldl -lnode demo0.c
clean: clean:

View File

@ -1,7 +1,12 @@
ifdef _LIBVER_SUPPORT
INCLUDE_VER = ../../libver/ver.h
LIB_VER = -I ../../libver
endif
all: libnode.a libnode.so all: libnode.a libnode.so
libnode.o: libnode.c node.h libnode.h ../../libver/ver.h Makefile libnode.o: libnode.c node.h libnode.h $(INCLUDE_VER) Makefile
gcc -c -g -o libnode.o -I . -I ../../libver libnode.c gcc -c -g -o libnode.o -I . $(LIB_VER) libnode.c
libnode.a: libnode.o libnode.a: libnode.o
ar -r libnode.a libnode.o ar -r libnode.a libnode.o

View File

@ -1,15 +1,16 @@
ifdef _LIBVER_SUPPORT ifdef _LIBVER_SUPPORT
INCLUDE_VER = ../../libver/ver.h DEP_VER_STATIC = ../../libver/ver.h ../../libver/libver.a
DEP_VER_DYNAMIC = ../../libver/ver.h ../../libver/libver.so
LIB_VER_STATIC = -I ../../libver ../../libver/libver.a LIB_VER_STATIC = -I ../../libver ../../libver/libver.a
LIB_VER_DYNAMIC = -I ../../libver -L ../../libver -lver LIB_VER_DYNAMIC = -I ../../libver -L ../../libver -lver
endif endif
all: ndbench ndbench-static all: ndbench ndbench-static
ndbench-static: ndbench.c $(INCLUDE_VER) ../lib/node.h ../../libver/libver.so ../lib/libnode.so Makefile ndbench-static: ndbench.c $(DEP_VER_STATIC) ../lib/node.h ../lib/libnode.a Makefile
gcc -g -o ndbench-static -I ../lib ndbench.c -ldl $(LIB_VER_STATIC) ../lib/libnode.a gcc -g -o ndbench-static -I ../lib ndbench.c -ldl $(LIB_VER_STATIC) ../lib/libnode.a
ndbench: ndbench.c $(INCLUDE_VER) ../lib/node.h ../../libver/libver.so ../lib/libnode.so Makefile ndbench: ndbench.c $(DEP_VER_DYNAMIC) ../lib/node.h ../lib/libnode.so Makefile
gcc -g -o ndbench -ldl $(LIB_VER_DYNAMIC) -I ../lib -L ../lib -lnode ndbench.c gcc -g -o ndbench -ldl $(LIB_VER_DYNAMIC) -I ../lib -L ../lib -lnode ndbench.c
clean: clean: