2003-08-21 18:16:46 +02:00
|
|
|
# $NetBSD: bsd.prefs.mk,v 1.120 2003/08/21 16:16:46 gavan Exp $
|
1998-06-03 13:15:29 +02:00
|
|
|
#
|
|
|
|
# Make file, included to get the site preferences, if any. Should
|
|
|
|
# only be included by package Makefiles before any .if defined()
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
# statements or modifications to "passed" variables (CFLAGS, LDFLAGS, ...),
|
|
|
|
# to make sure any variables defined in /etc/mk.conf, $MAKECONF, or
|
|
|
|
# the system defaults (sys.mk and bsd.own.mk) are used.
|
1998-06-03 13:15:29 +02:00
|
|
|
|
1999-05-24 00:10:01 +02:00
|
|
|
# Do not recursively include mk.conf, redefine OPSYS, include bsd.own.mk, etc.
|
2003-01-15 11:06:48 +01:00
|
|
|
.ifndef BSD_PKG_MK
|
1999-05-24 00:10:01 +02:00
|
|
|
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
# Let mk.conf know that this is pkgsrc.
|
2003-01-15 11:06:48 +01:00
|
|
|
BSD_PKG_MK=1
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
__PREFIX_SET__:=${PREFIX}
|
1998-11-27 00:39:15 +01:00
|
|
|
|
1999-06-23 19:06:20 +02:00
|
|
|
.if exists(/usr/bin/uname)
|
|
|
|
UNAME=/usr/bin/uname
|
|
|
|
.elif exists(/bin/uname)
|
|
|
|
UNAME=/bin/uname
|
|
|
|
.else
|
|
|
|
UNAME=echo Unknown
|
|
|
|
.endif
|
|
|
|
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
.ifndef OPSYS
|
1999-06-23 19:06:20 +02:00
|
|
|
OPSYS!= ${UNAME} -s
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
.endif
|
2000-06-04 00:33:22 +02:00
|
|
|
MAKEFLAGS+= OPSYS=${OPSYS}
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
.ifndef OS_VERSION
|
1999-06-23 19:06:20 +02:00
|
|
|
OS_VERSION!= ${UNAME} -r
|
1998-06-03 13:15:29 +02:00
|
|
|
.endif
|
2001-12-12 13:31:14 +01:00
|
|
|
.ifndef LOWER_OS_VERSION
|
2003-03-28 22:16:10 +01:00
|
|
|
LOWER_OS_VERSION!= echo ${OS_VERSION} | tr 'A-Z' 'a-z'
|
2001-12-12 13:31:14 +01:00
|
|
|
.endif
|
2000-06-04 00:33:22 +02:00
|
|
|
MAKEFLAGS+= OS_VERSION=${OS_VERSION}
|
1998-06-03 13:15:29 +02:00
|
|
|
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
# Preload these for architectures not in all variations of bsd.own.mk.
|
|
|
|
GNU_ARCH.alpha?= alpha
|
2002-03-18 06:46:42 +01:00
|
|
|
GNU_ARCH.arm26?= arm
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
GNU_ARCH.arm32?= arm
|
|
|
|
GNU_ARCH.i386?= i386
|
1999-08-12 16:16:25 +02:00
|
|
|
GNU_ARCH.i486?= i386
|
|
|
|
GNU_ARCH.i586?= i386
|
|
|
|
GNU_ARCH.i686?= i386
|
2002-03-18 06:46:42 +01:00
|
|
|
GNU_ARCH.m68000?= m68010
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
GNU_ARCH.m68k?= m68k
|
|
|
|
GNU_ARCH.mips?= mipsel
|
2001-06-14 15:45:12 +02:00
|
|
|
GNU_ARCH.mipseb?= mipseb
|
2001-06-28 15:16:56 +02:00
|
|
|
GNU_ARCH.mipsel?= mipsel
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
GNU_ARCH.ns32k?= ns32k
|
2001-07-03 04:20:38 +02:00
|
|
|
GNU_ARCH.powerpc?= powerpc
|
2002-03-18 06:46:42 +01:00
|
|
|
GNU_ARCH.sh3eb?= sh
|
|
|
|
GNU_ARCH.sh3el?= shle
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
GNU_ARCH.sparc?= sparc
|
2001-08-14 13:00:44 +02:00
|
|
|
GNU_ARCH.sparc64?= sparc64
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
GNU_ARCH.vax?= vax
|
|
|
|
MACHINE_GNU_ARCH?= ${GNU_ARCH.${MACHINE_ARCH}}
|
1998-08-19 18:23:40 +02:00
|
|
|
|
1999-07-08 09:58:42 +02:00
|
|
|
.if ${OPSYS} == "NetBSD"
|
|
|
|
LOWER_OPSYS?= netbsd
|
2001-08-24 11:00:44 +02:00
|
|
|
|
2002-11-17 16:11:40 +01:00
|
|
|
.elif ${OPSYS} == "FreeBSD"
|
|
|
|
LOWER_OPSYS?= freebsd
|
|
|
|
LOWER_ARCH!= ${UNAME} -p
|
|
|
|
MACHINE_ARCH= ${LOWER_ARCH}
|
|
|
|
MAKEFLAGS+= LOWER_ARCH=${LOWER_ARCH}
|
2002-11-17 23:35:23 +01:00
|
|
|
. if ${LOWER_ARCH} == "i386"
|
2002-11-17 16:11:40 +01:00
|
|
|
LOWER_VENDOR?= pc
|
2002-11-17 23:35:23 +01:00
|
|
|
. else
|
|
|
|
LOWER_VENDOR?= unknown
|
|
|
|
. endif
|
2002-11-17 16:11:40 +01:00
|
|
|
|
1999-07-08 09:58:42 +02:00
|
|
|
.elif ${OPSYS} == "SunOS"
|
2002-10-12 19:17:22 +02:00
|
|
|
. if ${MACHINE_ARCH} == "sparc"
|
|
|
|
SPARC_TARGET_ARCH?= sparcv7
|
|
|
|
. elif ${MACHINE_ARCH} == "sun4"
|
|
|
|
MACHINE_ARCH= sparc
|
2002-10-12 22:25:49 +02:00
|
|
|
SPARC_TARGET_ARCH?= sparcv7
|
2002-10-12 19:17:22 +02:00
|
|
|
. elif ${MACHINE_ARCH} == "i86pc"
|
|
|
|
MACHINE_ARCH= i386
|
2003-04-21 03:54:33 +02:00
|
|
|
. elif ${MACHINE_ARCH} == "unknown"
|
|
|
|
. if !defined(LOWER_ARCH)
|
|
|
|
LOWER_ARCH!= ${UNAME} -p
|
|
|
|
. endif # !defined(LOWER_ARCH)
|
|
|
|
MAKEFLAGS+= LOWER_ARCH=${LOWER_ARCH}
|
2002-10-12 19:17:22 +02:00
|
|
|
. endif
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
LOWER_VENDOR?= sun
|
2003-04-21 03:54:33 +02:00
|
|
|
LOWER_OPSYS?= solaris
|
2001-08-24 11:00:44 +02:00
|
|
|
|
1999-07-08 09:58:42 +02:00
|
|
|
.elif ${OPSYS} == "Linux"
|
|
|
|
LOWER_OPSYS?= linux
|
2003-01-12 23:30:08 +01:00
|
|
|
MACHINE_ARCH:= ${MACHINE_ARCH:C/i.86/i386/}
|
2003-01-14 04:01:37 +01:00
|
|
|
. if !defined(LOWER_ARCH)
|
2003-01-12 23:30:08 +01:00
|
|
|
LOWER_ARCH!= ${UNAME} -m | sed -e 's/i.86/i386/'
|
2003-01-14 04:01:37 +01:00
|
|
|
. endif # !defined(LOWER_ARCH)
|
2003-07-09 13:38:17 +02:00
|
|
|
. if ${MACHINE_ARCH} == "unknown" || ${MACHINE_ARCH} == ""
|
2001-05-17 17:00:26 +02:00
|
|
|
MACHINE_ARCH= ${LOWER_ARCH}
|
2000-06-04 00:33:22 +02:00
|
|
|
MAKEFLAGS+= LOWER_ARCH=${LOWER_ARCH}
|
2003-01-25 23:39:56 +01:00
|
|
|
. endif
|
|
|
|
. if exists(/etc/debian_version)
|
|
|
|
LOWER_VENDOR?= debian
|
|
|
|
. elif exists(/etc/mandrake-release)
|
|
|
|
LOWER_VENDOR?= mandrake
|
|
|
|
. elif exists(/etc/redhat-version)
|
|
|
|
LOWER_VENDOR?= redhat
|
|
|
|
. elif exists(/etc/slackware-version)
|
|
|
|
LOWER_VENDOR?= slackware
|
|
|
|
. elif ${LOWER_ARCH} == "i386"
|
|
|
|
LOWER_VENDOR?= pc
|
|
|
|
. else
|
|
|
|
LOWER_VENDOR?= unknown
|
2000-06-03 09:16:51 +02:00
|
|
|
. endif
|
1999-08-12 16:16:25 +02:00
|
|
|
|
2001-10-30 14:53:15 +01:00
|
|
|
.elif ${OPSYS} == "Darwin"
|
|
|
|
LOWER_OPSYS?= darwin
|
|
|
|
LOWER_ARCH!= ${UNAME} -p
|
|
|
|
MACHINE_ARCH= ${LOWER_ARCH}
|
|
|
|
MAKEFLAGS+= LOWER_ARCH=${LOWER_ARCH}
|
|
|
|
LOWER_VENDOR?= apple
|
|
|
|
|
2002-12-12 04:02:41 +01:00
|
|
|
.elif ${OPSYS:MIRIX*} != ""
|
2003-06-05 02:23:29 +02:00
|
|
|
LOWER_ARCH!= ${UNAME} -p
|
|
|
|
LOWER_OPSYS?= irix${OS_VERSION}
|
2002-12-12 04:02:41 +01:00
|
|
|
LOWER_VENDOR?= sgi
|
|
|
|
|
1999-07-08 09:58:42 +02:00
|
|
|
.elif !defined(LOWER_OPSYS)
|
2003-01-12 23:36:14 +01:00
|
|
|
LOWER_OPSYS!= echo ${OPSYS} | tr A-Z a-z
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
.endif
|
2001-08-24 11:00:44 +02:00
|
|
|
|
2000-06-04 00:33:22 +02:00
|
|
|
MAKEFLAGS+= LOWER_OPSYS=${LOWER_OPSYS}
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
|
|
|
|
LOWER_VENDOR?=
|
|
|
|
LOWER_ARCH?= ${MACHINE_GNU_ARCH}
|
|
|
|
|
|
|
|
MACHINE_PLATFORM?= ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH}
|
2002-03-18 06:46:42 +01:00
|
|
|
MACHINE_GNU_PLATFORM?= ${LOWER_ARCH}-${LOWER_VENDOR}-${LOWER_OPSYS}${APPEND_ELF}
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
|
2001-09-21 17:28:35 +02:00
|
|
|
# Needed on NetBSD and SunOS (zoularis) to prevent an "install:" target
|
|
|
|
# from being created in bsd.own.mk.
|
|
|
|
NEED_OWN_INSTALL_TARGET=no
|
|
|
|
|
2001-11-28 20:58:13 +01:00
|
|
|
# This prevents default use of the cross-tool harness in the "src" tree,
|
|
|
|
# in the odd possible case of someone extracting "pkgsrc" underneath "src".
|
|
|
|
USETOOLS= no
|
|
|
|
MAKE_ENV+= USETOOLS=no
|
|
|
|
|
2002-05-31 00:15:40 +02:00
|
|
|
# Set this before <bsd.own.mk> does, since it doesn't know about Darwin
|
|
|
|
.if ${OPSYS} == "Darwin"
|
|
|
|
OBJECT_FMT?= Mach-O
|
|
|
|
.endif
|
|
|
|
|
2002-06-21 23:06:48 +02:00
|
|
|
.include <bsd.own.mk>
|
|
|
|
|
2002-06-21 19:49:47 +02:00
|
|
|
# /usr/share/mk/bsd.own.mk on NetBSD 1.3 does not define OBJECT_FMT
|
|
|
|
.if ${MACHINE_PLATFORM:MNetBSD-1.3*} != ""
|
|
|
|
.if ${MACHINE_ARCH} == "alpha" || \
|
|
|
|
${MACHINE_ARCH} == "mipsel" || ${MACHINE_ARCH} == "mipseb" || \
|
|
|
|
${MACHINE_ARCH} == "powerpc" || ${MACHINE_ARCH} == "sparc64"
|
|
|
|
OBJECT_FMT?= ELF
|
|
|
|
.else
|
|
|
|
OBJECT_FMT?= a.out
|
|
|
|
.endif
|
|
|
|
.endif
|
|
|
|
|
2001-09-18 23:30:05 +02:00
|
|
|
# include the defaults file
|
|
|
|
.if exists(${.CURDIR}/../../mk/bsd.pkg.defaults.mk)
|
|
|
|
.include "${.CURDIR}/../../mk/bsd.pkg.defaults.mk"
|
|
|
|
.elif exists(${.CURDIR}/../mk/bsd.pkg.defaults.mk)
|
|
|
|
.include "${.CURDIR}/../mk/bsd.pkg.defaults.mk"
|
|
|
|
.elif exists(${.CURDIR}/mk/bsd.pkg.defaults.mk)
|
|
|
|
.include "${.CURDIR}/mk/bsd.pkg.defaults.mk"
|
|
|
|
.endif
|
|
|
|
|
2002-03-18 06:46:42 +01:00
|
|
|
.if ${OPSYS} == "NetBSD"
|
|
|
|
. if ${OBJECT_FMT} == "ELF" && \
|
|
|
|
(${MACHINE_GNU_ARCH} == "arm" || \
|
|
|
|
${MACHINE_ARCH} == "i386" || \
|
|
|
|
${MACHINE_ARCH} == "m68k" || \
|
|
|
|
${MACHINE_ARCH} == "m68000" || \
|
|
|
|
${MACHINE_GNU_ARCH} == "sh" || \
|
|
|
|
${MACHINE_GNU_ARCH} == "shle" || \
|
|
|
|
${MACHINE_ARCH} == "sparc" || \
|
|
|
|
${MACHINE_ARCH} == "vax")
|
|
|
|
APPEND_ELF= elf
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
SHAREOWN?= ${DOCOWN}
|
|
|
|
SHAREGRP?= ${DOCGRP}
|
|
|
|
SHAREMODE?= ${DOCMODE}
|
1998-06-03 13:15:29 +02:00
|
|
|
|
1998-08-19 18:23:40 +02:00
|
|
|
.if defined(PREFIX) && (${PREFIX} != ${__PREFIX_SET__})
|
1998-08-11 21:30:48 +02:00
|
|
|
.BEGIN:
|
|
|
|
@${ECHO_MSG} "You can NOT set PREFIX manually or in mk.conf. Set LOCALBASE or X11BASE"
|
|
|
|
@${ECHO_MSG} "depending on your needs. See the pkg system documentation for more info."
|
|
|
|
@${FALSE}
|
|
|
|
.endif
|
1999-05-24 00:10:01 +02:00
|
|
|
|
Implement some parts of proposals posted to tech-pkg:
- Define OS_VERSION in bsd.prefs.mk (...if not already defined). Previously
was only set in a conditional block in bsd.pkg.mk.
- Define new values, MACHINE_PLATFORM and MACHINE_GNU_PLATFORM, which
default to ${OPSYS}-${OS_VERSION}-${MACHINE_ARCH} and
${LOWER_OPSYS}-${LOWER_VENDOR}-${LOWER_ARCH} respectively.
(Probably should nuke LOWER_ARCH and rename LOWER_VENDOR to something
like MACHINE_GNU_VENDOR.)
- Use ${MACHINE_GNU_PLATFORM} as the argument to `--host' in GNU_CONFIGURE
packages.
- Allow for ONLY_FOR_PLATFORM and NOT_FOR_PLATFORM, lists of patterns
in csh(1) glob style which are matched against MACHINE_PLATFORM above
and take the place of {ONLY,NOT}_FOR_{ARCHS,OPSYS}. (For now, until
all pkgs are converted, provide backwards compatibility.) *Both* may
be defined, in which case NOT_FOR_PLATFORM takes precedence.
- Also do some significant aesthetic cleanup, based on the idea
`define platform-specific overrides first, then define a generic case
with the ?= operator'. Lots more of this to do yet.
1999-05-24 20:42:00 +02:00
|
|
|
# Preload all default values for CFLAGS, LDFLAGS, etc. before bsd.pkg.mk
|
|
|
|
# or a pkg Makefile modifies them.
|
1999-05-24 13:17:05 +02:00
|
|
|
.include <sys.mk>
|
|
|
|
|
2001-06-14 18:04:06 +02:00
|
|
|
# Load the OS-specific definitions for program variables. Default to loading
|
|
|
|
# the NetBSD ones if an OS-specific file doesn't exist.
|
|
|
|
.if exists(${.CURDIR}/../../mk/defs.${OPSYS}.mk)
|
|
|
|
.include "${.CURDIR}/../../mk/defs.${OPSYS}.mk"
|
|
|
|
.elif exists(${.CURDIR}/../mk/defs.${OPSYS}.mk)
|
|
|
|
.include "${.CURDIR}/../mk/defs.${OPSYS}.mk"
|
|
|
|
.elif exists(${.CURDIR}/mk/defs.${OPSYS}.mk)
|
|
|
|
.include "${.CURDIR}/mk/defs.${OPSYS}.mk"
|
|
|
|
.elif exists(${.CURDIR}/../../mk/defs.NetBSD.mk)
|
|
|
|
.include "${.CURDIR}/../../mk/defs.NetBSD.mk"
|
|
|
|
.elif exists(${.CURDIR}/../mk/defs.NetBSD.mk)
|
|
|
|
.include "${.CURDIR}/../mk/defs.NetBSD.mk"
|
|
|
|
.else exists(${.CURDIR}/mk/defs.NetBSD.mk)
|
|
|
|
.include "${.CURDIR}/mk/defs.NetBSD.mk"
|
|
|
|
.endif
|
|
|
|
|
2002-12-18 07:18:14 +01:00
|
|
|
# if the system is IPv6-ready, compile with IPv6 support turned on.
|
|
|
|
.if empty(_OPSYS_HAS_INET6:M[nN][oO]) && !defined(USE_SOCKS)
|
|
|
|
USE_INET6?= YES
|
|
|
|
.else
|
|
|
|
USE_INET6?= NO
|
|
|
|
.endif
|
|
|
|
|
2001-05-17 17:08:17 +02:00
|
|
|
LOCALBASE?= ${DESTDIR}/usr/pkg
|
2002-10-21 23:46:00 +02:00
|
|
|
.if ${OPSYS} == "SunOS"
|
|
|
|
# On Solaris, we default to using OpenWindows for X11.
|
|
|
|
X11BASE?= ${DESTDIR}/usr/openwin
|
|
|
|
.else
|
2001-03-06 15:50:45 +01:00
|
|
|
X11BASE?= ${DESTDIR}/usr/X11R6
|
2002-10-21 23:46:00 +02:00
|
|
|
.endif
|
2001-03-06 15:50:45 +01:00
|
|
|
CROSSBASE?= ${LOCALBASE}/cross
|
2001-03-13 10:53:37 +01:00
|
|
|
|
2002-09-15 13:58:22 +02:00
|
|
|
# Set X11PREFIX to reflect the install directory of X11 packages.
|
|
|
|
# Set XMKMF_CMD properly if xpkgwedge is installed.
|
|
|
|
#
|
|
|
|
# The check for the existence of ${X11BASE}/lib/X11/config/xpkgwedge.def
|
|
|
|
# is to catch users of xpkgwedge<1.0.
|
|
|
|
#
|
|
|
|
XMKMF?= ${XMKMF_CMD} ${XMKMF_FLAGS} -a
|
|
|
|
XMKMF_FLAGS?= # empty
|
|
|
|
.if exists(${LOCALBASE}/lib/X11/config/xpkgwedge.def) || \
|
|
|
|
exists(${X11BASE}/lib/X11/config/xpkgwedge.def)
|
|
|
|
HAVE_XPKGWEDGE= yes
|
|
|
|
X11PREFIX= ${LOCALBASE}
|
|
|
|
XMKMF_CMD?= ${X11PREFIX}/bin/pkgxmkmf
|
|
|
|
.else
|
|
|
|
X11PREFIX= ${X11BASE}
|
|
|
|
XMKMF_CMD?= ${X11PREFIX}/bin/xmkmf
|
|
|
|
.endif
|
|
|
|
|
2003-03-14 20:37:30 +01:00
|
|
|
# RPATH_FLAG publicly exports the linker flag used to specify run-time
|
|
|
|
# library search paths.
|
|
|
|
#
|
|
|
|
RPATH_FLAG?= ${_OPSYS_RPATH_NAME}
|
2002-09-15 13:58:22 +02:00
|
|
|
|
2003-04-15 07:29:45 +02:00
|
|
|
# WHOLE_ARCHIVE_FLAG and NO_WHOLE_ARCHIVE_FLAG publically export the
|
|
|
|
# linker flags to extract all symbols from a static archive.
|
|
|
|
WHOLE_ARCHIVE_FLAG?= ${_OPSYS_WHOLE_ARCHIVE_FLAG}
|
|
|
|
NO_WHOLE_ARCHIVE_FLAG?= ${_OPSYS_NO_WHOLE_ARCHIVE_FLAG}
|
|
|
|
|
2001-03-06 15:50:45 +01:00
|
|
|
.ifndef DIGEST
|
|
|
|
DIGEST:= ${LOCALBASE}/bin/digest
|
|
|
|
MAKEFLAGS+= DIGEST=${DIGEST}
|
|
|
|
.endif
|
|
|
|
|
2001-03-13 10:53:37 +01:00
|
|
|
# Only add the DIGEST_VERSION value to MAKEFLAGS when we know
|
|
|
|
# we've got a valid version number, retrieved from the digest(1)
|
|
|
|
# binary. This is different to PKGTOOLS_VERSION, since, in that
|
2002-09-24 15:59:20 +02:00
|
|
|
# case, the build dies when pkg_info(1) is out of date.
|
2001-03-13 10:53:37 +01:00
|
|
|
|
2001-03-13 10:41:36 +01:00
|
|
|
.if !exists(${DIGEST})
|
|
|
|
DIGEST_VERSION= 20010301
|
|
|
|
.elif !defined(DIGEST_VERSION)
|
|
|
|
DIGEST_VERSION!= ${DIGEST} -V 2>/dev/null
|
2001-03-06 15:50:45 +01:00
|
|
|
MAKEFLAGS+= DIGEST_VERSION="${DIGEST_VERSION}"
|
|
|
|
.endif
|
|
|
|
|
2002-09-24 23:54:49 +02:00
|
|
|
PKG_DBDIR?= ${DESTDIR}/var/db/pkg
|
2002-12-10 13:50:48 +01:00
|
|
|
PKG_ADD?= PKG_DBDIR=${PKG_DBDIR} ${PKG_TOOLS_BIN}/pkg_add
|
2002-09-24 23:54:49 +02:00
|
|
|
PKG_ADMIN?= PKG_DBDIR=${PKG_DBDIR} ${PKG_TOOLS_BIN}/pkg_admin
|
|
|
|
PKG_CREATE?= PKG_DBDIR=${PKG_DBDIR} ${PKG_TOOLS_BIN}/pkg_create
|
|
|
|
PKG_DELETE?= PKG_DBDIR=${PKG_DBDIR} ${PKG_TOOLS_BIN}/pkg_delete
|
|
|
|
PKG_INFO?= PKG_DBDIR=${PKG_DBDIR} ${PKG_TOOLS_BIN}/pkg_info
|
|
|
|
|
2001-03-06 17:00:15 +01:00
|
|
|
.ifndef PKGTOOLS_VERSION
|
2002-09-24 23:54:49 +02:00
|
|
|
PKGTOOLS_VERSION!= ${PKG_INFO} -V 2>/dev/null || echo 20010302
|
|
|
|
MAKEFLAGS+= PKGTOOLS_VERSION="${PKGTOOLS_VERSION}"
|
2001-03-06 17:00:15 +01:00
|
|
|
.endif
|
|
|
|
|
2001-03-24 22:06:52 +01:00
|
|
|
.if (${OPSYS} == SunOS) && !defined(ZOULARIS_VERSION)
|
2001-04-08 16:14:11 +02:00
|
|
|
.if !exists(${ZOULARISBASE}/share/mk/zoularis.mk)
|
2001-03-23 16:47:21 +01:00
|
|
|
ZOULARIS_VERSION= 20000522
|
|
|
|
.else
|
2001-04-08 16:14:11 +02:00
|
|
|
.include "${ZOULARISBASE}/share/mk/zoularis.mk"
|
2001-03-23 16:47:21 +01:00
|
|
|
.endif
|
|
|
|
MAKEFLAGS+= ZOULARIS_VERSION="${ZOULARIS_VERSION}"
|
|
|
|
.endif
|
|
|
|
|
2002-10-19 22:33:59 +02:00
|
|
|
_PKGSRCDIR?= ${.CURDIR:C|/[^/]*/[^/]*$||}
|
|
|
|
PKGPATH?= ${.CURDIR:C|.*/([^/]*/[^/]*)$|\1|}
|
|
|
|
|
|
|
|
DISTDIR?= ${_PKGSRCDIR}/distfiles
|
|
|
|
PACKAGES?= ${_PKGSRCDIR}/packages
|
|
|
|
TEMPLATES?= ${_PKGSRCDIR}/templates
|
|
|
|
|
|
|
|
PATCHDIR?= ${.CURDIR}/patches
|
|
|
|
SCRIPTDIR?= ${.CURDIR}/scripts
|
|
|
|
FILESDIR?= ${.CURDIR}/files
|
|
|
|
PKGDIR?= ${.CURDIR}
|
|
|
|
|
2003-08-21 18:16:46 +02:00
|
|
|
_PKGSRC_DEPS?= # empty
|
|
|
|
|
2002-10-19 22:33:59 +02:00
|
|
|
# If WRKOBJDIR is set, use that tree to build
|
2002-11-01 07:19:47 +01:00
|
|
|
.if defined(WRKOBJDIR)
|
2002-10-19 22:33:59 +02:00
|
|
|
BUILD_DIR?= ${WRKOBJDIR}/${PKGPATH}
|
|
|
|
.else
|
2003-01-15 21:55:38 +01:00
|
|
|
BUILD_DIR!= cd ${.CURDIR} && ${PWD_CMD}
|
|
|
|
.endif
|
2002-10-19 22:33:59 +02:00
|
|
|
|
|
|
|
# If OBJHOSTNAME is set, use first component of hostname in directory name.
|
|
|
|
# If OBJMACHINE is set, use ${MACHINE_ARCH} in the working directory name.
|
|
|
|
#
|
|
|
|
.if defined(OBJHOSTNAME)
|
|
|
|
. if !defined(_HOSTNAME)
|
2002-12-10 13:50:48 +01:00
|
|
|
_HOSTNAME!= ${UNAME} -n
|
2002-10-19 22:33:59 +02:00
|
|
|
MAKEFLAGS+= _HOSTNAME=${_HOSTNAME}
|
|
|
|
. endif
|
|
|
|
WRKDIR_BASENAME?= work.${_HOSTNAME:C|\..*||}
|
2002-11-01 07:29:23 +01:00
|
|
|
MAKEFLAGS+= OBJHOSTNAME="${OBJHOSTNAME}"
|
2002-10-19 22:33:59 +02:00
|
|
|
.elif defined(OBJMACHINE)
|
|
|
|
WRKDIR_BASENAME?= work.${MACHINE_ARCH}
|
2002-11-01 07:29:23 +01:00
|
|
|
MAKEFLAGS+= OBJMACHINE="${OBJMACHINE}"
|
2002-10-19 22:33:59 +02:00
|
|
|
.else
|
|
|
|
WRKDIR_BASENAME?= work
|
2002-12-10 13:50:48 +01:00
|
|
|
.endif
|
2002-10-19 22:33:59 +02:00
|
|
|
|
|
|
|
WRKDIR?= ${BUILD_DIR}/${WRKDIR_BASENAME}
|
|
|
|
|
2003-08-16 10:39:17 +02:00
|
|
|
# There are many uses for a common log file, so define one that may be
|
|
|
|
# picked up and used by tools.mk, bsd.buildlink2.mk, etc.
|
|
|
|
#
|
|
|
|
WRKLOG?= ${WRKDIR}/.work.log
|
|
|
|
|
2003-07-13 15:10:43 +02:00
|
|
|
# Sun C++ compilers don't support passing ld flags with -Wl to CC.
|
|
|
|
#
|
|
|
|
.if defined(USE_SUNPRO)
|
|
|
|
_COMPILER_LD_FLAG= # pattern for Sun compilers
|
|
|
|
.else
|
|
|
|
_COMPILER_LD_FLAG= -Wl, # pattern for GCC and others
|
|
|
|
.endif
|
|
|
|
|
2003-01-15 11:06:48 +01:00
|
|
|
.endif # BSD_PKG_MK
|