#!/bin/bash # arm/build # Check package dependencies, set metadata and launch # package build script. # by Stuart Winter # source /usr/share/slackdev/buildkit.sh # Package metadata: export PKGNAM=hal export VERSION=${VERSION:-0.5.14} export PKGARCH=${PKGARCH:-arm} export BUILD=${BUILD:-2} export PKGSERIES=${PKGSERIES:-l} export SLACKPACKAGE=$PKGNAM-$VERSION-$PKGARCH-$BUILD.tgz ## ******************************************************************* ## # For test packages - best to store in another location rather than # overwriting the working copy in the main tree: #export PKGSTORE=/tmp/ ## ******************************************************************* ## # Reset the ARM file system: restore it to the 'factory settings' # as it were (this has no effect when building natively): sboxsysrestore # Ensure base ARM packages are installed first: slackbasedeps # Ensure $PKGNAM isn't already installed: slackfailpkgdeps $PKGNAM || removepkg $PKGNAM # Ensure specific build dependencies (mainly libraries): { slackcheckpkgdeps e2fsprogs || installpkg $PKGSTORE/a/e2fsprogs-*.tgz || exit 99 ; } { slackcheckpkgdeps pciutils || installpkg $PKGSTORE/a/pciutils-*.tgz || exit 99 ; } { slackcheckpkgdeps udev || installpkg $PKGSTORE/a/udev-*.tgz || exit 99 ; } { slackcheckpkgdeps dbus || installpkg $PKGSTORE/a/dbus-*.tgz || exit 99 ; } { slackcheckpkgdeps dbus-glib || installpkg $PKGSTORE/l/dbus-glib-*.tgz || exit 99 ; } { slackcheckpkgdeps expat || installpkg $PKGSTORE/l/expat-*.tgz || exit 99 ; } { slackcheckpkgdeps glib2 || installpkg $PKGSTORE/l/glib2-*.tgz || exit 99 ; } { slackcheckpkgdeps libusb || installpkg $PKGSTORE/l/libusb-*.tgz || exit 99 ; } { slackcheckpkgdeps parted || installpkg $PKGSTORE/l/parted-*.tgz || exit 99 ; } { slackcheckpkgdeps libxml2 || installpkg $PKGSTORE/l/libxml2-*.tgz || exit 99 ; } # Launch build: BUILDLOG=$( basename $SLACKPACKAGE .tgz ).build.log ( ./$PKGNAM.SlackBuild ) >& /dev/stdout | tee $BUILDLOG # Compress the build log: bzip2 -9f $BUILDLOG