void-packages/common/travis/build.sh
Juan RP fde04ae647 travis/build.sh: xbps-src takes care of everything now.
Also this file does not contain any bashism, so use /bin/sh.
2020-01-05 10:44:56 +01:00

21 lines
354 B
Bash
Executable file

#!/bin/sh
#
# build.sh
if [ "$1" != "$2" ]; then
arch="-a $2"
fi
PKGS=$(/hostrepo/xbps-src sort-dependencies $(cat /tmp/templates))
NPROCS=1
if [ -r /proc/cpuinfo ]; then
NPROCS=$(grep ^proc /proc/cpuinfo|wc -l)
fi
for pkg in ${PKGS}; do
/hostrepo/xbps-src -j$NPROCS -H "$HOME"/hostdir $arch pkg "$pkg"
[ $? -eq 1 ] && exit 1
done
exit 0