how-lix-os-pkgs/json-c/default/inst.sh

14 lines
489 B
Bash
Executable File

#!/bin/sh
cd /mnt/build
DESTDIR=/ make -j$(nproc) install
# for some reason, json-c insists on installing itself to /local
# this isn't the cleanest solution, but it's simple and it'll work as long as
# lix's "no /usr/local" policy isn't violated.
echo "lix: moving /local contents to /"
[ ! -d /local/lib ] || rsync -a /local/lib/ /lib/
[ ! -d /local/lib64 ] || rsync -a /local/lib64/ /lib/
[ ! -d /local/include ] || rsync -a /local/include/ /include/
[ ! -d /local ] || rm -fr /local