2023-04-22 08:19:45 -07:00
|
|
|
#!/bin/sh
|
|
|
|
%
|
|
|
|
if [ "$REBUILD" = "core" ]; then
|
2024-01-14 14:57:09 -08:00
|
|
|
echo "# Busting Cache, Forcing Rebuild starting at core RUN "
|
|
|
|
echo # $(date)
|
2023-04-22 08:19:45 -07:00
|
|
|
fi
|
|
|
|
%
|
|
|
|
if ! { [ "$VERBOSE" = "core" ] || [ "$VERBOSE" = "all" ]; }; then unset VERBOSE; fi
|
|
|
|
|
2024-01-29 15:11:57 -08:00
|
|
|
echo "**************************************"
|
|
|
|
echo "****** Building UCI Image Core ******"
|
|
|
|
|
2024-09-15 18:47:22 -07:00
|
|
|
|
2024-01-29 15:11:57 -08:00
|
|
|
echo copying core rootfs to image
|
2024-01-14 14:57:09 -08:00
|
|
|
/bin/cp -R -f -p rootfs/. /
|
2023-04-22 08:19:45 -07:00
|
|
|
. /opt/lib/verbose.lib
|
|
|
|
|
2024-09-15 18:47:22 -07:00
|
|
|
quiet env
|
2023-04-22 08:19:45 -07:00
|
|
|
quiet echo core build directory
|
|
|
|
quiet pwd
|
|
|
|
quiet ls -la
|
|
|
|
quiet echo "--------------------------------------"
|
|
|
|
. /opt/lib/distro.lib
|
|
|
|
if validate_distro; then
|
|
|
|
echo distro $LINUX_DISTRO was validated...continuing
|
|
|
|
set_distro
|
|
|
|
/bin/sh ./packages.sh
|
|
|
|
/bin/bash -l ./core.sh
|
2024-10-17 16:17:59 -07:00
|
|
|
if [ -f ./custom/run ]; then
|
|
|
|
echo custom directory exists with run file inside
|
|
|
|
cd ./custom || exit
|
|
|
|
echo sourcing that run file now
|
|
|
|
/bin/bash -l ./run
|
|
|
|
cd ..
|
|
|
|
fi
|
2023-04-22 08:19:45 -07:00
|
|
|
echo
|
|
|
|
echo "************* End UCI CORE build ********************"
|
|
|
|
else
|
|
|
|
echo !!! FATAL ERROR: distro of base image $BASE_IMAGE does not match linux distro $LINUX_DISTRO !!!
|
|
|
|
exit 1
|
|
|
|
fi
|