dockcross/imagefiles/build-and-install-flatcc.sh
2022-05-24 09:21:42 -04:00

24 lines
425 B
Bash
Executable File

#!/usr/bin/env bash
set -ex
if ! command -v git &> /dev/null; then
echo >&2 'error: "git" not found!'
exit 1
fi
if [[ "${FLATCC_VERSION}" == "" ]]; then
echo >&2 'error: FLATCC_VERSION env. variable must be set to a non-empty value'
exit 1
fi
cd /usr/src
git clone https://github.com/dvidelabs/flatcc.git -b v$FLATCC_VERSION
cd flatcc
cmake -DFLATCC_INSTALL=on && make install > /dev/null
./scripts/cleanall.sh