diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2013-03-22 15:59:01 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2013-03-22 15:59:01 +0100 |
commit | 6e5f5b3adbb22301942804a2a08af5048e7a9bca (patch) | |
tree | 983a3705993dca7c2b12416075abcd4023b5cd5f /build_static_example.sh | |
parent | c8938e08ad06ae7bf0f50872ddbb0efbe7bf7560 (diff) | |
download | strace-6e5f5b3adbb22301942804a2a08af5048e7a9bca.tar.gz strace-6e5f5b3adbb22301942804a2a08af5048e7a9bca.tar.bz2 strace-6e5f5b3adbb22301942804a2a08af5048e7a9bca.tar.xz |
Add example script which builds static (possibly cross-compiled) strace
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'build_static_example.sh')
-rwxr-xr-x | build_static_example.sh | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/build_static_example.sh b/build_static_example.sh new file mode 100755 index 0000000..5e5fb42 --- /dev/null +++ b/build_static_example.sh @@ -0,0 +1,20 @@ +#!/bin/sh -e + +#export CC="i686-gcc" +export CC="x86_64-gcc" + +export CFLAGS="-Os\ + -fomit-frame-pointer\ + -static\ + -static-libgcc\ + -ffunction-sections -fdata-sections\ + -falign-functions=1 -falign-jumps=1 -falign-labels=1 -falign-loops=1\ + -fno-unwind-tables\ + -fno-asynchronous-unwind-tables\ + -Wl,--gc-sections\ + -Wl,-Map=strace.mapfile\ +" + +autoreconf -i -f +./configure #--enable-maintainer-mode +make CC="$CC" CFLAGS="$CFLAGS" |