From 5b00ea717798eabe4bd0324a38d456629321017a Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Sun, 22 Apr 2012 18:34:48 -0400 Subject: Separate architecture table check. --- diff --git a/src/opkbuild.sh b/src/opkbuild.sh index 4bd6046..8d6e14a 100644 --- a/src/opkbuild.sh +++ b/src/opkbuild.sh @@ -194,11 +194,13 @@ EOF export OH_HOST_ARCH_CPU OH_HOST_ARCH_KERNEL OH_HOST_ARCH_LIBS export OH_HOST_PLATFORM="${host_platform}" -# Look up GNU architecture name and set toolchain environment variables. +# Make sure the architecture table exists. if [ ! -f "@@DATADIR@@/opkhelper/archtab" ]; then printf 'opkbuild: Error: architecture table not found.\n' >&2 exit 1 fi + +# Look up GNU architecture name and set toolchain environment variables. export OH_HOST_ARCH_GNU="$(sed -n \ "s/^${OH_HOST_ARCH_DIST}[ \\t][ \\t]*\\(.*\\)$/\\1/p" \ "@@DATADIR@@/opkhelper/archtab")" -- cgit v0.9.1