diff options
Diffstat (limited to 'src/opkbuild')
-rw-r--r-- | src/opkbuild | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/opkbuild b/src/opkbuild index 1f0317b..2c7e974 100644 --- a/src/opkbuild +++ b/src/opkbuild @@ -27,6 +27,7 @@ print_usage() } # Sanity checks. +printf 'opkbuild: Checking for sanity...\n' if [ ! -f format -o ! -f build -o ! -f control ]; then printf 'Error: Current working directory is not a source package.\n' >&2 exit 1 @@ -36,12 +37,18 @@ if [ "$(cat format)" != '1.0' ]; then exit 1 fi +# Make work area. +printf 'opkbuild: Making work area...\n' mkdir tmp cd tmp -# Build *-src package. +# Get source package name and version. +printf 'opkbuild: Reading source package control fields...\n\n' srcpkg=$(oh_get_field Source) version=$(oh_get_field Version) + +# Build *-src package. +printf 'opkbuild: Installing files for package "%s"...\n' "${srcpkg}-src" mkdir -p ${srcpkg}-src/usr/src/${srcpkg}_${version} for file in ../*; do case ${file} in @@ -55,6 +62,7 @@ done oh-gencontrol -s oh-buildopk ${srcpkg}-src rm -Rf dest +printf 'opkbuild: Package "%s" complete!\n\n' "${srcpkg}-src" # Build other binary packages. for binpkgdir in ../*.pkg/; do @@ -74,6 +82,7 @@ for binpkgdir in ../*.pkg/; do binpkg=${binpkg%'.pkg/'} # Build the package. ../build ${binpkg} + printf 'opkbuild: Package "%s" complete!\n\n' "${binpkg}" # Clean up everything except the build stamps. for file in *; do case ${file} in |