Mon Sep 7 15:07:54 2015 UTC ()
We currently detect $MACHINE_ARCH on OpenBSD/amd64 & Bitrig/amd64 as amd64.
Bitrig uses ELF on amd64 & arm and does not have any legacy dependency on a.out.
Remove if statement to check $MACHINE_ARCH is x86_64 in-order to set $OBJECT_FMT
to ELF, preventing $OBJECT_FMT being set to a.out by mistake.

Reviewed by joerg@


(sevan)
diff -r1.1 -r1.2 pkgsrc/pkgtools/bootstrap-mk-files/files/mods/Bitrig.bsd.own.mk.in

cvs diff -r1.1 -r1.2 pkgsrc/pkgtools/bootstrap-mk-files/files/mods/Attic/Bitrig.bsd.own.mk.in (expand / switch to unified diff)

--- pkgsrc/pkgtools/bootstrap-mk-files/files/mods/Attic/Bitrig.bsd.own.mk.in 2015/06/04 15:48:45 1.1
+++ pkgsrc/pkgtools/bootstrap-mk-files/files/mods/Attic/Bitrig.bsd.own.mk.in 2015/09/07 15:07:54 1.2
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1# $NetBSD: Bitrig.bsd.own.mk.in,v 1.1 2015/06/04 15:48:45 sevan Exp $ 1# $NetBSD: Bitrig.bsd.own.mk.in,v 1.2 2015/09/07 15:07:54 sevan Exp $
2 2
3.if !defined(_BSD_OWN_MK_) 3.if !defined(_BSD_OWN_MK_)
4_BSD_OWN_MK_=1 4_BSD_OWN_MK_=1
5 5
6# XXX On systems with a Berkeley-style make, perhaps we ought to check 6# XXX On systems with a Berkeley-style make, perhaps we ought to check
7# XXX for and source a file other than /etc/mk.conf 7# XXX for and source a file other than /etc/mk.conf
8 8
9.if defined(MAKECONF) && exists(${MAKECONF}) 9.if defined(MAKECONF) && exists(${MAKECONF})
10.include "${MAKECONF}" 10.include "${MAKECONF}"
11.elif exists(@SYSCONFDIR@/mk.conf) 11.elif exists(@SYSCONFDIR@/mk.conf)
12.include "@SYSCONFDIR@/mk.conf" 12.include "@SYSCONFDIR@/mk.conf"
13.elif exists(/etc/mk.conf) 13.elif exists(/etc/mk.conf)
14.include "/etc/mk.conf" 14.include "/etc/mk.conf"
@@ -80,31 +80,27 @@ INSTPRIV?= -U @@ -80,31 +80,27 @@ INSTPRIV?= -U
80STRIPFLAG?= -s 80STRIPFLAG?= -s
81 81
82# Define SYS_INCLUDE to indicate whether you want symbolic links to the system 82# Define SYS_INCLUDE to indicate whether you want symbolic links to the system
83# source (``symlinks''), or a separate copy (``copies''); (latter useful 83# source (``symlinks''), or a separate copy (``copies''); (latter useful
84# in environments where it's not possible to keep /sys publicly readable) 84# in environments where it's not possible to keep /sys publicly readable)
85#SYS_INCLUDE= symlinks 85#SYS_INCLUDE= symlinks
86 86
87# Data-driven table using make variables to control how  87# Data-driven table using make variables to control how
88# toolchain-dependent targets and shared libraries are built 88# toolchain-dependent targets and shared libraries are built
89# for different platforms and object formats. 89# for different platforms and object formats.
90# OBJECT_FMT: currently either "ELF" or "a.out". 90# OBJECT_FMT: currently either "ELF" or "a.out".
91# SHLIB_TYPE: "ELF" or "a.out" or "" to force static libraries. 91# SHLIB_TYPE: "ELF" or "a.out" or "" to force static libraries.
92# 92#
93.if ${MACHINE_ARCH} == "x86_64" 
94OBJECT_FMT?=ELF 93OBJECT_FMT?=ELF
95.else 
96OBJECT_FMT?=a.out 
97.endif 
98 94
99# Location of the file that contains the major and minor numbers of the 95# Location of the file that contains the major and minor numbers of the
100# version of a shared library. If this file exists a shared library 96# version of a shared library. If this file exists a shared library
101# will be built by <bsd.lib.mk>. 97# will be built by <bsd.lib.mk>.
102SHLIB_VERSION_FILE?= ${.CURDIR}/shlib_version 98SHLIB_VERSION_FILE?= ${.CURDIR}/shlib_version
103 99
104# GNU sources and packages sometimes see architecture names differently. 100# GNU sources and packages sometimes see architecture names differently.
105# This table maps an architecture name to its GNU counterpart. 101# This table maps an architecture name to its GNU counterpart.
106# Use as so: ${GNU_ARCH.${TARGET_ARCH}} or ${MACHINE_GNU_ARCH} 102# Use as so: ${GNU_ARCH.${TARGET_ARCH}} or ${MACHINE_GNU_ARCH}
107.ifndef MACHINE_GNU_ARCH 103.ifndef MACHINE_GNU_ARCH
108MACHINE_GNU_ARCH=${GNU_ARCH.${MACHINE_ARCH}} 104MACHINE_GNU_ARCH=${GNU_ARCH.${MACHINE_ARCH}}
109.endif 105.endif
110 106