wifictld/.ci/build_pkgs.sh

36 lines
779 B
Bash
Executable File

#!/bin/sh
cd $CI_PROJECT_DIR/build_dir
PKGS=$(ls $CI_PROJECT_DIR/wireless/)
echo "=== Found new/modified packages: $PKGS"
for PKG in $PKGS ; do
echo "===+ Download: $PKG"
make "package/$PKG/download" V=s
echo "===+ Check package: $PKG"
make "package/$PKG/check" V=s 2>&1 | tee logtmp
if [ $RET -ne 0 ]; then
echo "=> Package check failed: $RET)"
exit $RET
fi
badhash_msg="HASH does not match "
badhash_msg+="|HASH uses deprecated hash,"
badhash_msg+="|HASH is missing,"
if grep -qE "$badhash_msg" logtmp; then
echo "=> Package HASH check failed"
exit 1
fi
echo "=> Package check OK"
done
for PKG in $PKGS ; do
echo "===+ Building: $PKG"
make "package/$PKG/compile" -j3 V=s
done