summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2011-02-16 17:29:57 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2011-02-16 17:29:57 +0100
commitc7b270a2f16bf666180fadf085eb1342a9e9a28c (patch)
tree341fa2b4f34485fc555a4b4164bb7feb98ce8749 /mk
parent57627f1608991eae124d39885a40e170f27b9a1c (diff)
use better defaults for native builds
Diffstat (limited to 'mk')
-rw-r--r--mk/package.mk5
-rw-r--r--mk/vars.mk11
2 files changed, 12 insertions, 4 deletions
diff --git a/mk/package.mk b/mk/package.mk
index 68142df0e..9b2b77559 100644
--- a/mk/package.mk
+++ b/mk/package.mk
@@ -3,10 +3,6 @@
all: build-all-pkgs
-ifeq ($(ADK_HOST_CYGWIN),y)
-EXEEXT:= .exe
-endif
-
# does not change CONFIGURE_ARGS in minimal mode
ifeq ($(filter minimal,${CONFIG_STYLE}),)
ifneq ($(ADK_DEBUG),)
@@ -25,6 +21,7 @@ CONFIGURE_ENV+= GCC_HONOUR_COPTS=s \
PKG_CONFIG_LIBDIR='${STAGING_TARGET_DIR}/usr/lib/pkgconfig'
ifeq ($(ADK_NATIVE),)
CONFIGURE_ENV+= ${TARGET_CONFIGURE_OPTS} \
+ cross_compiling=yes \
ac_cv_func_realloc_0_nonnull=yes \
ac_cv_func_malloc_0_nonnull=yes
endif
diff --git a/mk/vars.mk b/mk/vars.mk
index 420e71248..61e71de1d 100644
--- a/mk/vars.mk
+++ b/mk/vars.mk
@@ -18,7 +18,14 @@ STAGING_PKG_DIR:= ${BASE_DIR}/pkg_${ADK_TARGET_SYSTEM}_${ADK_TARGET_LIBC}
STAGING_PKG_DIR_PFX:= ${BASE_DIR}/pkg_*
STAGING_HOST_DIR:= ${BASE_DIR}/host_${CPU_ARCH}_${ADK_TARGET_LIBC}
STAGING_HOST_DIR_PFX:= ${BASE_DIR}/host_*
+# use headers and foo-config from system
+ifneq ($(ADK_NATIVE),)
+STAGING_TARGET_DIR:=
+SCRIPT_TARGET_DIR:= /usr/bin
+else
STAGING_TARGET_DIR:= ${BASE_DIR}/target_${CPU_ARCH}_${ADK_TARGET_LIBC}
+SCRIPT_TARGET_DIR:= ${STAGING_TARGET_DIR}/scripts
+endif
STAGING_TARGET_DIR_PFX:=${BASE_DIR}/target_*
# relation from STAGING_HOST_DIR to STAGING_TARGET_DIR (for gcc to find
# its sysroot while staying relocatable)
@@ -191,4 +198,8 @@ QUIET:= --quiet
endif
FETCH_CMD?= wget --timeout=30 $(QUIET)
+ifeq ($(ADK_HOST_CYGWIN),y)
+EXEEXT:= .exe
+endif
+
include $(TOPDIR)/mk/mirrors.mk