summaryrefslogtreecommitdiffstats
path: root/share/mk/sys.mk
diff options
context:
space:
mode:
authorru <ru@FreeBSD.org>2002-04-17 13:49:29 +0000
committerru <ru@FreeBSD.org>2002-04-17 13:49:29 +0000
commitdc24ddd41e8f19486380221cdd30ad699719d0d2 (patch)
tree8ecd5d0c5dac332088910644780304ff8543ee61 /share/mk/sys.mk
parent2bc2f35287a64134db22c35a92872f32781bbb59 (diff)
downloadFreeBSD-src-dc24ddd41e8f19486380221cdd30ad699719d0d2.zip
FreeBSD-src-dc24ddd41e8f19486380221cdd30ad699719d0d2.tar.gz
Don't include bsd.own.mk from sys.mk, this makes it impossible
to use ``.if defined()'' inside bsd.own.mk to test for defines in individual makefiles. For example, setting DEBUG_FLAGS in Makefile didn't take the desired effect on the STRIP assignment. Added bsd.init.mk (like in NetBSD) that handles the inclusion of ../Makefile.inc and bsd.own.mk from all bsd.*.mk files that "build something". Back out bsd.own.mk,v 1.15: moved OBJFORMAT initialization back to sys.mk (several source tree makefiles want to check it early) and removed MACHINE_ARCH initialization (it's hard to see from looking at the commitlogs what the problem was at the time, but now it serves no purpose). Prohibit the direct inclusion of bsd.man.mk and bsd.libnames.mk. Protect bsd.obj.mk from repetitive inclusion. Prohibiting the direct inclusion of bsd.obj.mk might be a good idea too.
Diffstat (limited to 'share/mk/sys.mk')
-rw-r--r--share/mk/sys.mk11
1 files changed, 10 insertions, 1 deletions
diff --git a/share/mk/sys.mk b/share/mk/sys.mk
index 89ef00c..030c852 100644
--- a/share/mk/sys.mk
+++ b/share/mk/sys.mk
@@ -259,5 +259,14 @@ __MAKE_CONF?=/etc/make.conf
.include </etc/make.conf.local>
.endif
+#
+# The build tools are indirected by /usr/bin/objformat which determines the
+# object format from the OBJFORMAT environment variable and if this is not
+# defined, it reads /etc/objformat.
+#
+.if exists(/etc/objformat) && !defined(OBJFORMAT)
+.include "/etc/objformat"
+.endif
-.include <bsd.own.mk>
+# Default executable format
+OBJFORMAT?= elf
OpenPOWER on IntegriCloud