diff options
| author | Carlos Martín Nieto <[email protected]> | 2014-12-31 19:43:20 +0000 |
|---|---|---|
| committer | Carlos Martín Nieto <[email protected]> | 2014-12-31 19:43:20 +0000 |
| commit | ef839080596bd9fbead5db1e91f698bebfd4024a (patch) | |
| tree | 5dbc19b7a1d5d6faa8fecf4c8b6b2c4559084d4e /script/with-static.sh | |
| parent | db3754ce8db412a7fd82cca2d0f91ddbcf90b475 (diff) | |
Revert "Make the cgo tool do more linking work"
Diffstat (limited to 'script/with-static.sh')
| -rwxr-xr-x | script/with-static.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/script/with-static.sh b/script/with-static.sh new file mode 100755 index 0000000..3f60e31 --- /dev/null +++ b/script/with-static.sh @@ -0,0 +1,12 @@ +#!/bin/sh + +set -ex + +export BUILD="$PWD/vendor/libgit2/build" +export PCFILE="$BUILD/libgit2.pc" + +FLAGS=$(pkg-config --static --libs $PCFILE) || exit 1 +export CGO_LDFLAGS="$BUILD/libgit2.a -L$BUILD ${FLAGS}" +export CGO_CFLAGS="-I$PWD/vendor/libgit2/include" + +$@ |
