Merge branch 'feature-debian-packages' into develop

lintian improvements
This commit is contained in:
6543 2018-05-12 22:41:08 +02:00
commit 727cf6ed3c
3 changed files with 27 additions and 3 deletions

1
DEBIAN/conffiles Normal file
View File

@ -0,0 +1 @@
/etc/remaster/config.sample.cfg

View File

@ -4,7 +4,7 @@ Version: 1.9.3
Architecture: all Architecture: all
Maintainer: 6543 <6543@obermui.de> Maintainer: 6543 <6543@obermui.de>
Installed-Size: <SIZE> Installed-Size: <SIZE>
Depends: squashfs-tools, xorriso, wget, sed, sendemail, bash Depends: squashfs-tools, xorriso, wget, sed (>= 4.2), sendemail, bash (>= 4.3)
Suggests: nfs-kernel-server, isc-dhcp-server Suggests: nfs-kernel-server, isc-dhcp-server
Section: utils Section: utils
Priority: optional Priority: optional

View File

@ -27,7 +27,7 @@ function copy() {
#changelog #changelog
mkdir -p build/usr/share/doc/remaster mkdir -p build/usr/share/doc/remaster
cp -v changes/remaster.md build/usr/share/doc/remaster/changelog cp -v changes/remaster.md build/usr/share/doc/remaster/changelog
gzip build/usr/share/doc/remaster/changelog gzip --best build/usr/share/doc/remaster/changelog
} }


#config ... #config ...
@ -47,19 +47,37 @@ function set_libdir() {
#modes #modes
function debug() { function debug() {
clean clean

#prebuild
copy copy
set_rootdir "`pwd`/build" set_rootdir "`pwd`/build"
set_libdir "`pwd`/build/usr/lib/remaster" set_libdir "`pwd`/build/usr/lib/remaster"
} }
function install() { function install() {
#überprüfe auf root
[ "`id -u`" != "0" ] && { echo "Error start as root"; exit 1; }

#lösche alltes build dir
clean clean

#prebuild
copy copy
set_rootdir "" set_rootdir ""
set_libdir "/usr/lib/remaster" set_libdir "/usr/lib/remaster"
#cp -f -r build/* /
#set owner
chown -r root:root build/

#install
cp -f -r build/* /
} }
function build-deb() { function build-deb() {
#überprüfe auf root
[ "`id -u`" != "0" ] && { echo "Error start as root"; exit 1; }

#lösche alltes build dir
clean clean

#prebuild #prebuild
copy copy
set_rootdir "" set_rootdir ""
@ -70,10 +88,15 @@ function build-deb() {
cp -v -r -f DEBIAN build/ cp -v -r -f DEBIAN build/
#create md5sums #create md5sums
find ./build -type f -exec md5sum {} \; | grep -v './build/DEBIAN' | sed 's/\.\/build\///g' > build/DEBIAN/md5sums find ./build -type f -exec md5sum {} \; | grep -v './build/DEBIAN' | sed 's/\.\/build\///g' > build/DEBIAN/md5sums
chmod 0644 build/DEBIAN/md5sums

#set size #set size
SIZE="`du --exclude=build/DEBIAN -c build/ | cut -f 1 | tail -n 1`" SIZE="`du --exclude=build/DEBIAN -c build/ | cut -f 1 | tail -n 1`"
sed -i "s/<SIZE>/$SIZE/g" build/DEBIAN/control sed -i "s/<SIZE>/$SIZE/g" build/DEBIAN/control


#set owner
chown -r root:root build/

## ##
#build deb #build deb
## ##