1
0
Fork 0
mirror of https://github.com/pygos/build.git synced 2024-11-22 11:09:46 +01:00

cleanup: derive OPENSSL_TARGET from TARGET in OpenSSL package

Signed-off-by: David Oberhollenzer <david.oberhollenzer@tele2.at>
This commit is contained in:
David Oberhollenzer 2018-10-19 18:47:47 +02:00
parent 8e5c6d3a2e
commit 569f7d5e0c
4 changed files with 17 additions and 3 deletions

View file

@ -10,6 +10,5 @@ GCC_EXTRACFG="--enable-libmpx"
LINUXPKG="linux" LINUXPKG="linux"
LINUX_CPU="x86" LINUX_CPU="x86"
LINUX_TGT="bzImage modules" LINUX_TGT="bzImage modules"
OPENSSL_TARGET="linux-generic32 386"
TC_HARDENING="no" TC_HARDENING="no"

View file

@ -10,6 +10,5 @@ GCC_EXTRACFG="--enable-libmpx"
LINUXPKG="linux" LINUXPKG="linux"
LINUX_CPU="x86_64" LINUX_CPU="x86_64"
LINUX_TGT="bzImage" LINUX_TGT="bzImage"
OPENSSL_TARGET="linux-x86_64"
TC_HARDENING="no" TC_HARDENING="no"

View file

@ -10,6 +10,5 @@ GCC_EXTRACFG="--with-float=hard --with-fpu=neon-vfpv3"
LINUXPKG="linux-rpi3" LINUXPKG="linux-rpi3"
LINUX_CPU="arm" LINUX_CPU="arm"
LINUX_TGT="zImage" LINUX_TGT="zImage"
OPENSSL_TARGET="linux-generic32"
TC_HARDENING="no" TC_HARDENING="no"

View file

@ -10,6 +10,7 @@ prepare() {
} }
build() { build() {
local OPENSSL_TARGET=""
local cflags="" local cflags=""
local ldflags="" local ldflags=""
@ -18,6 +19,22 @@ build() {
ldflags="-z noexecstack -z relro -z now" ldflags="-z noexecstack -z relro -z now"
fi fi
case "$TARGET" in
i*86-*)
OPENSSL_TARGET="linux-generic32 386"
;;
x86_64-*)
OPENSSL_TARGET="linux-x86_64"
;;
arm-*)
OPENSSL_TARGET="linux-generic32"
;;
*)
echo "don't know how to map $TARGET to OpenSSL arch"
exit 1
;;
esac
$1/Configure --prefix=/ --cross-compile-prefix="${TARGET}-" \ $1/Configure --prefix=/ --cross-compile-prefix="${TARGET}-" \
--openssldir=/etc/ssl --libdir=/lib \ --openssldir=/etc/ssl --libdir=/lib \
CFLAGS="-DOPENSSL_NO_HEARTBEATS $cflags" \ CFLAGS="-DOPENSSL_NO_HEARTBEATS $cflags" \