# Exit on error:
set -e

wget http://www.x.org/releases/individual/proto/xproto-7.0.24.tar.bz2
tar xf xproto-7.0.24.tar.bz2
cd xproto-7.0.24

CC=/static/bin/musl-gcc \
    LDFLAGS='-s -L/static/lib -static -static-libgcc' \
    ./configure --prefix=/static

make install
cd ..
rm -rf xproto-7.0.24
rm xproto-7.0.24.tar.bz2

exit 0
