12.0
12.0-rc1
12.1
12.1-rc1
12.2-rc1
bdubbs/gcc13
multilib
renodr/libudev-from-systemd
trunk
xry111/arm64
xry111/arm64-12.0
xry111/clfs-ng
xry111/loongarch
xry111/loongarch-12.0
xry111/loongarch-12.1
xry111/mips64el
xry111/update-glibc
Line | |
---|
1 | #!/bin/bash
|
---|
2 |
|
---|
3 | if [ $# -lt 1 ] ; then
|
---|
4 | echo "This script needs the location of the xml file to update"
|
---|
5 | exit 1
|
---|
6 | fi
|
---|
7 |
|
---|
8 | FILE=$1
|
---|
9 |
|
---|
10 | ./make-aux-files.sh
|
---|
11 |
|
---|
12 | # Bootscript data
|
---|
13 | bootscripts=$(ls lfs-bootscripts*.xz)
|
---|
14 | base=$(basename $bootscripts .tar.xz)
|
---|
15 | bootsize=$(ls -l --block-size=1024 $bootscripts | cut -f5 -d" ")
|
---|
16 | bootmd5=$(md5sum $bootscripts | cut -f1 -d" ")
|
---|
17 |
|
---|
18 | # Figure intalled size of bootscripts
|
---|
19 | TOPDIR=$(pwd)
|
---|
20 | TMP_DIR=$(mktemp -d /tmp/lfsbootfiles.XXXXXX)
|
---|
21 | pushd $TMP_DIR > /dev/null
|
---|
22 | tar -xf $TOPDIR/$bootscripts
|
---|
23 | bootinstallsize=$(du -sk $TMP_DIR | cut -f1)
|
---|
24 | popd > /dev/null
|
---|
25 | rm -rf $TMP_DIR
|
---|
26 |
|
---|
27 | sed -i -e s/BOOTSCRIPTS-SIZE/$bootsize/ \
|
---|
28 | -e s/BOOTSCRIPTS-INSTALL-KB/$bootinstallsize/ \
|
---|
29 | -e s/BOOTSCRIPTS-MD5SUM/$bootmd5/ $FILE
|
---|
30 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.