libffi 481 Bytes
Newer Older
Kenneth Reitz's avatar
Kenneth Reitz committed
1
#!/usr/bin/env bash
Kenneth Reitz's avatar
Kenneth Reitz committed
2
# Build Path: /app/.heroku/vendor/
Kenneth Reitz's avatar
Kenneth Reitz committed
3 4 5

OUT_PREFIX=$1

Kenneth Reitz's avatar
Kenneth Reitz committed
6
# Skip the build for heroku-16.
Kenneth Reitz's avatar
changes  
Kenneth Reitz committed
7
if [[ $S3_PREFIX == "heroku-16" ]]; then
Kenneth Reitz's avatar
Kenneth Reitz committed
8 9 10
    exit 0
fi

Kenneth Reitz's avatar
Kenneth Reitz committed
11
# Use new path, containing autoconf.
David Zülke's avatar
David Zülke committed
12
export PATH="/app/.heroku/python/bin/:$PATH"
Kenneth Reitz's avatar
libffi  
Kenneth Reitz committed
13
hash -r
Kenneth Reitz's avatar
Kenneth Reitz committed
14

Kenneth Reitz's avatar
Kenneth Reitz committed
15

Kenneth Reitz's avatar
Kenneth Reitz committed
16
echo "Building libffi…"
Kenneth Reitz's avatar
Kenneth Reitz committed
17

Kenneth Reitz's avatar
Kenneth Reitz committed
18
SOURCE_TARBALL='ftp://sourceware.org/pub/libffi/libffi-3.1.tar.gz'
Kenneth Reitz's avatar
Kenneth Reitz committed
19

Kenneth Reitz's avatar
Kenneth Reitz committed
20
curl -L $SOURCE_TARBALL | tar x
Kenneth Reitz's avatar
Kenneth Reitz committed
21

Kenneth Reitz's avatar
Kenneth Reitz committed
22
cd libffi-3.1
Kenneth Reitz's avatar
Kenneth Reitz committed
23
./configure --prefix=$OUT_PREFIX --disable-static &&
Kenneth Reitz's avatar
Kenneth Reitz committed
24 25 26 27 28
make
make install

# Cleanup
cd ..