From 02bb123e98718bb01ea30d44e613a5a4def06f3e Mon Sep 17 00:00:00 2001 From: Michael Forney Date: Tue, 28 May 2019 01:30:35 -0700 Subject: configure: Use /usr/libexec/cpp on OpenBSD --- configure | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'configure') diff --git a/configure b/configure index c4203f5..e504bcb 100755 --- a/configure +++ b/configure @@ -41,11 +41,6 @@ if [ "$host" != "$target" ] ; then toolprefix=$target- fi -: ${DEFAULT_PREPROCESSOR:=${toolprefix}cpp} -: ${DEFAULT_QBE:=qbe} -: ${DEFAULT_ASSEMBLER:=${toolprefix}as} -: ${DEFAULT_LINKER:=${toolprefix}ld} - case "$target" in x86_64*|amd64*) qbetarget=amd64_sysv ;; aarch64*) qbetarget=arm64 ;; @@ -110,6 +105,7 @@ case "$target" in ;; *-*openbsd*) : ${DEFAULT_DYNAMIC_LINKER:=/usr/libexec/ld.so} + test "$host" = "$target" && : ${DEFAULT_PREPROCESSOR:=/usr/libexec/cpp} startfiles='"-l", ":crt0.o", "-l", ":crtbegin.o"' endfiles='"-l", "c", "-l", ":crtend.o"' linkflags='"-L", "/usr/lib",' @@ -118,6 +114,11 @@ case "$target" in fail "unknown target '$target', please create config.h manually" esac +: ${DEFAULT_PREPROCESSOR:=${toolprefix}cpp} +: ${DEFAULT_QBE:=qbe} +: ${DEFAULT_ASSEMBLER:=${toolprefix}as} +: ${DEFAULT_LINKER:=${toolprefix}ld} + test "$DEFAULT_DYNAMIC_LINKER" && linkflags=$linkflags' "--dynamic-linker", "'$DEFAULT_DYNAMIC_LINKER'"' printf "creating config.h... " -- cgit v1.2.3