prepare-root.sh: change CURDIR to BASEDIR for most
This commit is contained in:
parent
b3954c30be
commit
1e5e5bd550
|
@ -25,7 +25,6 @@ EOF
|
||||||
}
|
}
|
||||||
|
|
||||||
CURDIR=$(pwd)
|
CURDIR=$(pwd)
|
||||||
|
|
||||||
PROGNAME=${0##*/}
|
PROGNAME=${0##*/}
|
||||||
BASEDIR=${0%/*}
|
BASEDIR=${0%/*}
|
||||||
WITH_UPDATES=1
|
WITH_UPDATES=1
|
||||||
|
@ -331,7 +330,7 @@ for i in passwd shadow group gshadow subuid subgid; do
|
||||||
chmod u+r "${STATEDIR}/$i"
|
chmod u+r "${STATEDIR}/$i"
|
||||||
done
|
done
|
||||||
|
|
||||||
cp "$CURDIR"/FedoraBook.te "$CURDIR"/FedoraBook.fc "$sysroot"/var/tmp
|
cp "$BASEDIR"/FedoraBook.te "$BASEDIR"/FedoraBook.fc "$sysroot"/var/tmp
|
||||||
chroot "$sysroot" bash -c '
|
chroot "$sysroot" bash -c '
|
||||||
cd /var/tmp
|
cd /var/tmp
|
||||||
make -f /usr/share/selinux/devel/Makefile
|
make -f /usr/share/selinux/devel/Makefile
|
||||||
|
@ -339,13 +338,13 @@ chroot "$sysroot" bash -c '
|
||||||
'
|
'
|
||||||
chroot "$sysroot" semanage fcontext --noreload -a -e /etc /cfg
|
chroot "$sysroot" semanage fcontext --noreload -a -e /etc /cfg
|
||||||
|
|
||||||
cp "$CURDIR/clonedisk.sh" "$sysroot"/usr/bin/fedorabook-clonedisk
|
cp "$BASEDIR/clonedisk.sh" "$sysroot"/usr/bin/fedorabook-clonedisk
|
||||||
cp "$CURDIR/update.sh" "$sysroot"/usr/bin/fedorabook-update
|
cp "$BASEDIR/update.sh" "$sysroot"/usr/bin/fedorabook-update
|
||||||
cp "$CURDIR/mkimage.sh" "$sysroot"/usr/bin/fedorabook-mkimage
|
cp "$BASEDIR/mkimage.sh" "$sysroot"/usr/bin/fedorabook-mkimage
|
||||||
|
|
||||||
mkdir -p "$sysroot"/etc/pki/${NAME}
|
mkdir -p "$sysroot"/etc/pki/${NAME}
|
||||||
openssl x509 -in "${CURDIR}/${CRT}" -pubkey -noout > "$sysroot"/etc/pki/${NAME}/pubkey
|
openssl x509 -in "${BASEDIR}/${CRT}" -pubkey -noout > "$sysroot"/etc/pki/${NAME}/pubkey
|
||||||
cp "${CURDIR}/${CRT}" "$sysroot"/etc/pki/${NAME}/crt
|
cp "${BASEDIR}/${CRT}" "$sysroot"/etc/pki/${NAME}/crt
|
||||||
|
|
||||||
rpm --root "$sysroot" -qa | sort > "$sysroot"/usr/rpm-list.txt
|
rpm --root "$sysroot" -qa | sort > "$sysroot"/usr/rpm-list.txt
|
||||||
|
|
||||||
|
@ -829,7 +828,7 @@ fi
|
||||||
mkdir -p "$sysroot"/efi/EFI/${NAME}
|
mkdir -p "$sysroot"/efi/EFI/${NAME}
|
||||||
for i in LockDown.efi Shell.efi startup.nsh; do
|
for i in LockDown.efi Shell.efi startup.nsh; do
|
||||||
[[ -e "${BASEDIR}"/$i ]] || continue
|
[[ -e "${BASEDIR}"/$i ]] || continue
|
||||||
cp "$i" "$sysroot"/efi/EFI/${NAME}/
|
cp "${BASEDIR}"/$i "$sysroot"/efi/EFI/${NAME}/
|
||||||
done
|
done
|
||||||
|
|
||||||
find "$sysroot"/efi -xdev -newermt "@${SOURCE_DATE_EPOCH}" -print0 \
|
find "$sysroot"/efi -xdev -newermt "@${SOURCE_DATE_EPOCH}" -print0 \
|
||||||
|
|
Loading…
Reference in a new issue