diff options
Diffstat (limited to 'libmysqld/Makefile.am')
-rw-r--r-- | libmysqld/Makefile.am | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/libmysqld/Makefile.am b/libmysqld/Makefile.am index 91b0c4c17bb..9d8c5edaa12 100644 --- a/libmysqld/Makefile.am +++ b/libmysqld/Makefile.am @@ -157,6 +157,22 @@ if DARWIN_MWCC mwld -lib -o $@ libmysqld_int.a `echo $(INC_LIB) | sort -u` $(storageobjects) else -rm -f libmysqld.a + current_dir=`pwd`; \ + rm -rf tmp; mkdir tmp; \ + (for arc in $(INC_LIB) ./libmysqld_int.a; do \ + arpath=`echo $$arc|sed 's|[^/]*$$||'|sed 's|\.libs/$$||'`; \ + artmp=`echo $$arc|sed 's|^.*/|tmp/lib-|'`; \ + for F in `$(AR) t $$arc | grep -v SYMDEF`; do \ + if test -e "$$arpath/$$F" ; then echo "$$arpath/$$F"; else \ + mkdir $$artmp; cd $$artmp > /dev/null; \ + $(AR) x ../../$$arc; \ + cd $$current_dir > /dev/null; \ + ls $$artmp/* | grep -v SYMDEF; \ + continue 2; fi; done; \ + done; echo $(libmysqld_a_DEPENDENCIES) ) | sort -u | xargs $(AR) cq libmysqld.a; \ + $(AR) r libmysqld.a $(storageobjects); \ + $(RANLIB) libmysqld.a ; \ + rm -rf tmp endif ## XXX: any time the client interface changes, we'll need to bump |