--- a/make-rules/shared-macros.mk Wed Apr 17 19:17:06 2013 -0700
+++ b/make-rules/shared-macros.mk Thu Apr 18 08:16:56 2013 -0700
@@ -18,7 +18,7 @@
#
# CDDL HEADER END
#
-# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
#
PATH=/usr/bin:/usr/gnu/bin
@@ -41,7 +41,9 @@
export DOWNLOAD_SEARCH_PATH += $(EXTERNAL_ARCHIVE_MIRROR)
# The workspace starts at the mercurial root
-export WS_TOP ?= $(shell hg root)
+ifeq ($(origin WS_TOP), undefined)
+export WS_TOP := $(shell hg root)
+endif
WS_LOGS = $(WS_TOP)/$(MACH)/logs
WS_REPO = $(WS_TOP)/$(MACH)/repo
@@ -71,7 +73,7 @@
ROOT = /
-OS_VERSION = $(shell uname -r)
+OS_VERSION := $(shell uname -r)
SOLARIS_VERSION = $(OS_VERSION:5.%=2.%)
include $(WS_MAKE_RULES)/ips-buildinfo.mk
@@ -91,7 +93,7 @@
COMPONENT_SRC_NAME = $(COMPONENT_NAME)
-COMPONENT_DIR = $(shell pwd)
+COMPONENT_DIR := $(shell pwd)
SOURCE_DIR = $(COMPONENT_DIR)/$(COMPONENT_SRC)
BUILD_DIR = $(COMPONENT_DIR)/build
PROTO_DIR = $(BUILD_DIR)/prototype/$(MACH)
@@ -172,7 +174,7 @@
CONSTANT_TIME += TIME_CONSTANT=$(TIME_CONSTANT)
# set MACH from uname -p to either sparc or i386
-MACH = $(shell uname -p)
+MACH := $(shell uname -p)
# set MACH32 from MACH to either sparcv7 or i86
MACH32_1 = $(MACH:sparc=sparcv7)
@@ -307,13 +309,13 @@
PERL = $(PERL.$(PERL_VERSION))
-PERL_ARCH = $(shell $(PERL) -e 'use Config; print $$Config{archname}')
+PERL_ARCH := $(shell $(PERL) -e 'use Config; print $$Config{archname}')
# Optimally we should ask perl which C compiler was used but it doesn't
# result in a full path name. Only "c" is being recorded
# inside perl builds while we actually need a full path to
# the studio compiler.
-#PERL_CC = $(shell $(PERL) -e 'use Config; print $$Config{cc}')
-PERL_OPTIMIZE = $(shell $(PERL) -e 'use Config; print $$Config{optimize}')
+#PERL_CC := $(shell $(PERL) -e 'use Config; print $$Config{cc}')
+PERL_OPTIMIZE := $(shell $(PERL) -e 'use Config; print $$Config{optimize}')
PKG_MACROS += PERL_ARCH=$(PERL_ARCH)
PKG_MACROS += PERL_VERSION=$(PERL_VERSION)
@@ -369,8 +371,8 @@
# Enables large file support for components that have no other means of doing
# so. Use CPP_LARGEFILES and not the .32/.64 variety directly
-CPP_LARGEFILES.32 = $(shell getconf LFS_CFLAGS)
-CPP_LARGEFILES.64 = $(shell getconf LFS64_CFLAGS)
+CPP_LARGEFILES.32 := $(shell getconf LFS_CFLAGS)
+CPP_LARGEFILES.64 := $(shell getconf LFS64_CFLAGS)
CPP_LARGEFILES = $(CPP_LARGEFILES.$(BITS))
# Enables some #pragma redefine_extname to POSIX-compliant Standard C Library