mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-28 11:43:25 +02:00
autoupdate kernel version at package install and core update scripts.
This commit is contained in:
@@ -196,6 +196,7 @@ define PAK
|
|||||||
fi
|
fi
|
||||||
cp -v /usr/src/config/rootfiles/packages/$(PROG) /install/packages/package/ROOTFILES
|
cp -v /usr/src/config/rootfiles/packages/$(PROG) /install/packages/package/ROOTFILES
|
||||||
sed -e 's/KVER/$(KVER)/g' -i /install/packages/package/ROOTFILES
|
sed -e 's/KVER/$(KVER)/g' -i /install/packages/package/ROOTFILES
|
||||||
|
sed -e 's/xxxKVERxxx/$(KVER)/g' -i /install/packages/package/install.sh
|
||||||
chmod 755 /install/packages/package/{{,un}install,update}.sh
|
chmod 755 /install/packages/package/{{,un}install,update}.sh
|
||||||
cd / && tar cf /install/packages/package/files.tmp --files-from=/install/packages/package/ROOTFILES --exclude='#*' \
|
cd / && tar cf /install/packages/package/files.tmp --files-from=/install/packages/package/ROOTFILES --exclude='#*' \
|
||||||
-p --numeric-owner
|
-p --numeric-owner
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ core/%:
|
|||||||
|
|
||||||
#Change KVER to Kernelversion
|
#Change KVER to Kernelversion
|
||||||
sed -e "s/KVER/$(KVER)/g" -i /tmp/ROOTFILES
|
sed -e "s/KVER/$(KVER)/g" -i /tmp/ROOTFILES
|
||||||
|
|
||||||
#Remove doubled files with tar/untar/tar to save space
|
#Remove doubled files with tar/untar/tar to save space
|
||||||
tar -c -C / --files-from=/tmp/ROOTFILES \
|
tar -c -C / --files-from=/tmp/ROOTFILES \
|
||||||
-f /$(SNAME).tar --exclude='#*' --exclude='dev/pts/*' \
|
-f /$(SNAME).tar --exclude='#*' --exclude='dev/pts/*' \
|
||||||
@@ -80,6 +80,9 @@ core/%:
|
|||||||
#build package
|
#build package
|
||||||
cp -f $(DIR_SRC)/config/rootfiles/$@/update.sh /install/packages/package
|
cp -f $(DIR_SRC)/config/rootfiles/$@/update.sh /install/packages/package
|
||||||
chmod 755 /install/packages/package/update.sh
|
chmod 755 /install/packages/package/update.sh
|
||||||
|
#Change xxxKVERxxx to Kernelversion
|
||||||
|
sed -e "s/xxxKVERxxx/$(KVER)/g" -i /install/packages/package/update.sh
|
||||||
|
|
||||||
cd /install/packages/package && tar cf ../core-upgrade-$(VERSION)-$$(basename $@).ipfire \
|
cd /install/packages/package && tar cf ../core-upgrade-$(VERSION)-$$(basename $@).ipfire \
|
||||||
update.sh files ROOTFILES
|
update.sh files ROOTFILES
|
||||||
rm -rf /install/packages/package
|
rm -rf /install/packages/package
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
. /opt/pakfire/lib/functions.sh
|
. /opt/pakfire/lib/functions.sh
|
||||||
extract_files
|
extract_files
|
||||||
#
|
#
|
||||||
KVER=2.6.32.41
|
KVER=xxxKVERxxx
|
||||||
ROOT=`mount | grep " / " | cut -d" " -f1`
|
ROOT=`mount | grep " / " | cut -d" " -f1`
|
||||||
ROOTUUID=`blkid -c /dev/null -sUUID $ROOT | cut -d'"' -f2`
|
ROOTUUID=`blkid -c /dev/null -sUUID $ROOT | cut -d'"' -f2`
|
||||||
if [ ! -z $ROOTUUID ]; then
|
if [ ! -z $ROOTUUID ]; then
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
. /opt/pakfire/lib/functions.sh
|
. /opt/pakfire/lib/functions.sh
|
||||||
extract_files
|
extract_files
|
||||||
#
|
#
|
||||||
KVER=2.6.32.40
|
KVER=xxxKVERxxx
|
||||||
ROOT=`mount | grep " / " | cut -d" " -f1`
|
ROOT=`mount | grep " / " | cut -d" " -f1`
|
||||||
ROOTUUID=`blkid -c /dev/null -sUUID $ROOT | cut -d'"' -f2`
|
ROOTUUID=`blkid -c /dev/null -sUUID $ROOT | cut -d'"' -f2`
|
||||||
if [ ! -z $ROOTUUID ]; then
|
if [ ! -z $ROOTUUID ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user