summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormeem <none@none>2007-10-22 16:50:32 -0700
committermeem <none@none>2007-10-22 16:50:32 -0700
commit2032ea7bd13069ba4884066ed18f83bf12b3e247 (patch)
tree6d4cb43d8fd80695b778494c44df393fc1bb3cd4
parentb9238976491622ad75a67ab0c12edf99e36212b9 (diff)
downloadillumos-gate-2032ea7bd13069ba4884066ed18f83bf12b3e247.tar.gz
6599659 Makefiles shouldn't have to tear $(RELEASE) apart
Contributed by Roland Mainz <roland.mainz@nrubsig.org>
-rw-r--r--usr/src/Makefile.master6
-rw-r--r--usr/src/cmd/ipf/Makefile.ipf5
-rw-r--r--usr/src/cmd/sendmail/Makefile.cmd5
-rw-r--r--usr/src/lib/libast/amd64/Makefile5
-rw-r--r--usr/src/lib/libast/i386/Makefile5
-rw-r--r--usr/src/lib/libast/sparc/Makefile5
-rw-r--r--usr/src/lib/libast/sparcv9/Makefile5
-rw-r--r--usr/src/lib/libdll/amd64/Makefile5
-rw-r--r--usr/src/lib/libdll/i386/Makefile5
-rw-r--r--usr/src/lib/libdll/sparc/Makefile5
-rw-r--r--usr/src/lib/libdll/sparcv9/Makefile5
-rw-r--r--usr/src/uts/intel/ipf/Makefile3
-rw-r--r--usr/src/uts/sparc/ipf/Makefile3
13 files changed, 20 insertions, 42 deletions
diff --git a/usr/src/Makefile.master b/usr/src/Makefile.master
index 8b4832a09f..098a9efdbe 100644
--- a/usr/src/Makefile.master
+++ b/usr/src/Makefile.master
@@ -874,6 +874,8 @@ $(EXPORT_RELEASE_BUILD)ELFSIGN_OBJECT= $(ELFSIGN_O) sign \
# which is used to label all binaries in the build:
#
# RELEASE Specific release of the build, eg: 5.2
+# RELEASE_MAJOR Major version number part of $(RELEASE)
+# RELEASE_MINOR Minor version number part of $(RELEASE)
# VERSION Version of the build (alpha, beta, Generic)
# PATCHID If this is a patch this value should contain
# the patchid value (eg: "Generic 100832-01"), otherwise
@@ -883,7 +885,9 @@ $(EXPORT_RELEASE_BUILD)ELFSIGN_OBJECT= $(ELFSIGN_O) sign \
# will default to the RELEASE_DATE
#
ONVERS= "11.11"
-RELEASE= 5.11
+RELEASE_MAJOR= 5
+RELEASE_MINOR= 11
+RELEASE= $(RELEASE_MAJOR).$(RELEASE_MINOR)
VERSION= SunOS Development
PATCHID= $(VERSION)
RELEASE_DATE= October 2007
diff --git a/usr/src/cmd/ipf/Makefile.ipf b/usr/src/cmd/ipf/Makefile.ipf
index 7a6d8c4c16..ca910f5877 100644
--- a/usr/src/cmd/ipf/Makefile.ipf
+++ b/usr/src/cmd/ipf/Makefile.ipf
@@ -1,5 +1,5 @@
#
-# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
#ident "%Z%%M% %I% %E% SMI"
@@ -14,6 +14,5 @@ LIBIPF64= ../../lib/$(MACH64)/libipf.a
COMMONIPF= $(SRC)/uts/common/inet/ipf
KERNELIPF= $(SRC)/uts/common/inet/pfil
-MINOR= echo $(RELEASE) | cut -d. -f2
CPPFLAGS += -I$(COMMONIPF) -I$(KERNELIPF) -DSUNDDI -DUSE_INET6 \
- -DSOLARIS2=$(MINOR:sh)
+ -DSOLARIS2=$(RELEASE_MINOR)
diff --git a/usr/src/cmd/sendmail/Makefile.cmd b/usr/src/cmd/sendmail/Makefile.cmd
index 44ba192f31..04ea924717 100644
--- a/usr/src/cmd/sendmail/Makefile.cmd
+++ b/usr/src/cmd/sendmail/Makefile.cmd
@@ -20,11 +20,12 @@
#
#
-# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
# ident "%Z%%M% %I% %E% SMI"
#
-CPPFLAGS.sm= $(CPPFLAGS.master) -DSOLARIS=21100 -D_FILE_OFFSET_BITS=64
+CPPFLAGS.sm= $(CPPFLAGS.master) -DSOLARIS=2$(RELEASE_MINOR)00 \
+ -D_FILE_OFFSET_BITS=64
DBMDEF= -DNDBM -DNEWDB -DNIS -DNISPLUS -DUSERDB -DMAP_REGEX -DLDAPMAP
diff --git a/usr/src/lib/libast/amd64/Makefile b/usr/src/lib/libast/amd64/Makefile
index 1d299936f6..f2819b166d 100644
--- a/usr/src/lib/libast/amd64/Makefile
+++ b/usr/src/lib/libast/amd64/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).i386"'
+ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).i386"'
# platform-specific sources
OBJECTS = \
diff --git a/usr/src/lib/libast/i386/Makefile b/usr/src/lib/libast/i386/Makefile
index c19736e711..647e6e2ab3 100644
--- a/usr/src/lib/libast/i386/Makefile
+++ b/usr/src/lib/libast/i386/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).i386"'
+ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).i386"'
# platform-specific sources
OBJECTS = \
diff --git a/usr/src/lib/libast/sparc/Makefile b/usr/src/lib/libast/sparc/Makefile
index aa4e2edd78..7ca62b2d77 100644
--- a/usr/src/lib/libast/sparc/Makefile
+++ b/usr/src/lib/libast/sparc/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).sun4"'
+ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).sun4"'
# platform-specific sources
OBJECTS = \
diff --git a/usr/src/lib/libast/sparcv9/Makefile b/usr/src/lib/libast/sparcv9/Makefile
index 2c6089c89c..be8a95ce37 100644
--- a/usr/src/lib/libast/sparcv9/Makefile
+++ b/usr/src/lib/libast/sparcv9/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).sun4"'
+ASTPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).sun4"'
# platform-specific sources
OBJECTS = \
diff --git a/usr/src/lib/libdll/amd64/Makefile b/usr/src/lib/libdll/amd64/Makefile
index 5511ce5642..859cc09364 100644
--- a/usr/src/lib/libdll/amd64/Makefile
+++ b/usr/src/lib/libdll/amd64/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).i386"'
+DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).i386"'
include ../Makefile.com
include ../../Makefile.lib.64
diff --git a/usr/src/lib/libdll/i386/Makefile b/usr/src/lib/libdll/i386/Makefile
index 8577dbfcc9..8ba7064a6b 100644
--- a/usr/src/lib/libdll/i386/Makefile
+++ b/usr/src/lib/libdll/i386/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).i386"'
+DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).i386"'
include ../Makefile.com
diff --git a/usr/src/lib/libdll/sparc/Makefile b/usr/src/lib/libdll/sparc/Makefile
index b45208ffc9..0c579f5e22 100644
--- a/usr/src/lib/libdll/sparc/Makefile
+++ b/usr/src/lib/libdll/sparc/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).sun4"'
+DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).sun4"'
include ../Makefile.com
diff --git a/usr/src/lib/libdll/sparcv9/Makefile b/usr/src/lib/libdll/sparcv9/Makefile
index dab99d2e2d..bd91ecadc8 100644
--- a/usr/src/lib/libdll/sparcv9/Makefile
+++ b/usr/src/lib/libdll/sparcv9/Makefile
@@ -25,12 +25,9 @@
# ident "%Z%%M% %I% %E% SMI"
#
-# Fetch minor version from RELEASE, e.g. "10" for "5.10", "11" for "5.11" etc.
-GETRELEASEMINOR = /usr/bin/ksh -c 'x=$(RELEASE) ; print "$${x$(POUND_SIGN)$(POUND_SIGN)*.}"'
-
# Platform-specific config
# Note that "HOSTTYPE" matches the value used by AT&T upstream.
-DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(GETRELEASEMINOR:sh).sun4"'
+DLLPLATFORMCPPFLAGS = '-DHOSTTYPE="sol$(RELEASE_MINOR).sun4"'
include ../Makefile.com
include ../../Makefile.lib.64
diff --git a/usr/src/uts/intel/ipf/Makefile b/usr/src/uts/intel/ipf/Makefile
index 4529dbaab9..d23d2e9b11 100644
--- a/usr/src/uts/intel/ipf/Makefile
+++ b/usr/src/uts/intel/ipf/Makefile
@@ -58,9 +58,8 @@ ALL_TARGET = $(BINARY) $(SRC_CONFFILE)
LINT_TARGET = $(MODULE).lint
INSTALL_TARGET = $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
-MINOR= echo $(RELEASE) | cut -d. -f2
CPPFLAGS += -DIPFILTER_LKM -DIPFILTER_LOG -DIPFILTER_LOOKUP -DUSE_INET6
-CPPFLAGS += -DSUNDDI -DSOLARIS2=$(MINOR:sh) -DIRE_ILL_CN
+CPPFLAGS += -DSUNDDI -DSOLARIS2=$(RELEASE_MINOR) -DIRE_ILL_CN
LDFLAGS += -dy -Ndrv/ip -Nmisc/md5 -Nmisc/neti
INC_PATH += -I$(UTSBASE)/common/inet/ipf
diff --git a/usr/src/uts/sparc/ipf/Makefile b/usr/src/uts/sparc/ipf/Makefile
index b0431a04d1..cc1bc4eb02 100644
--- a/usr/src/uts/sparc/ipf/Makefile
+++ b/usr/src/uts/sparc/ipf/Makefile
@@ -62,10 +62,9 @@ INSTALL_TARGET = $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
#
# lint pass one enforcement and OS version
#
-MINOR= echo $(RELEASE) | cut -d. -f2
CFLAGS += $(CCVERBOSE)
CPPFLAGS += -DIPFILTER_LKM -DIPFILTER_LOG -DIPFILTER_LOOKUP
-CPPFLAGS += -DSUNDDI -DSOLARIS2=$(MINOR:sh) -DIRE_ILL_CN -DUSE_INET6
+CPPFLAGS += -DSUNDDI -DSOLARIS2=$(RELEASE_MINOR) -DIRE_ILL_CN -DUSE_INET6
LDFLAGS += -dy -Ndrv/ip -Nmisc/md5 -Nmisc/neti
INC_PATH += -I$(UTSBASE)/common/inet/ipf