mirror of
https://github.com/motioneye-project/motioneyeos.git
synced 2025-07-24 19:56:35 +00:00
build.sh: cleanup /var/lib symlink before build
This commit is contained in:
parent
a051dabe09
commit
fcf5807caa
9
build.sh
9
build.sh
@ -66,6 +66,13 @@ if ! [ -f $basedir/configs/${board}_defconfig ]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
function prepare_target_dir() {
|
||||||
|
if [ -L $outputdir/target/var/lib ]; then
|
||||||
|
rm $outputdir/target/var/lib
|
||||||
|
mkdir $outputdir/target/var/lib
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
mkdir -p $outputdir
|
mkdir -p $outputdir
|
||||||
|
|
||||||
if ! [ -f $outputdir/.config ]; then
|
if ! [ -f $outputdir/.config ]; then
|
||||||
@ -135,9 +142,11 @@ elif [[ "$target" == initramfs* ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
elif [ "$target" == "all" ]; then
|
elif [ "$target" == "all" ]; then
|
||||||
|
prepare_target_dir
|
||||||
make O=$outputdir all
|
make O=$outputdir all
|
||||||
|
|
||||||
elif [ -n "$target" ]; then
|
elif [ -n "$target" ]; then
|
||||||
|
prepare_target_dir
|
||||||
make O=$outputdir $target
|
make O=$outputdir $target
|
||||||
|
|
||||||
else # if [ -z "$target ]
|
else # if [ -z "$target ]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user