#!/bin/sh -e

# Parallel make isn't supported yet.
export MAKEFLAGS='-j1'

make PLATFORM=linux PREFIX="$1" STATICBUILD=1
make PLATFORM=linux PREFIX="$1" STATICBUILD=1 install
mkdir -p "$1/usr/share"
mv "$1/share/chicken" "$1/usr/share/"
mv "$1/share/man" "$1/usr/share/"
