aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile8
1 files changed, 6 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 2b0f5a4..1e10800 100644
--- a/Makefile
+++ b/Makefile
@@ -13,7 +13,6 @@ LDFLAGS = ${LIBS}
dist: static shared
-# ar -rc libaz.a libabc.a libxyz.a
static: libs
@make OPT='-O2 -pipe -Werror' ${LIBNAME:=.a}
rm -f ${OBJ}
@@ -29,13 +28,18 @@ ${LIBNAME:=.so}: ${OBJ}
${CC} ${LDFLAGS} -shared ${OBJ} -o $@
${LIBNAME:=.a}: ${OBJ}
- ar rcs $@ ${OBJ}
+# ar rcs $@ ${OBJ}
+ mkdir build
+ cd build && ar -x ../${LIBSTR_PATH}
+ ar rcs $@ ${OBJ} build/*
+ rm -rf build
.c.o:
${CC} ${CFLAGS} -c $< -o $@
clean:
rm -f ${OBJ} ${LIBNAME}.* *.core
+ rm -rf build
cd test && make clean
tests: dist