view src/libsndfile-1.0.25/src/make-static-lib-hidden-privates.sh @ 14:48209aa7aa51

Add Vamp builds
author Chris Cannam
date Wed, 20 Mar 2013 16:05:58 +0000
parents c7265573341e
children
line wrap: on
line source
#!/bin/bash -e

# This script takes a static library and removes all non-public symbols.
# Ie, it makes a static lib whose symbols are far less likely to clash with
# the symbols of another shared or static library.

grep sf_ Symbols.gnu-binutils | sed -e "s/[ ;]//g" > Symbols.static

ld -r --whole-archive .libs/libsndfile.a -o libsndfile_a.o

objcopy --keep-global-symbols=Symbols.static libsndfile_a.o libsndfile.o

rm -f libsndfile.a
ar cru libsndfile.a libsndfile.o