7080479 X binaries change too much on rebuilds (avoid build race w/ lndir)
authorAlan Coopersmith <Alan.Coopersmith@Oracle.COM>
Sun, 28 Aug 2011 21:53:02 -0700
changeset 1195 5257d09d4f0a
parent 1194 2596c47a24c6
child 1196 1ce455dae979
7080479 X binaries change too much on rebuilds (avoid build race w/ lndir)
open-src/util/build-tools/Makefile
open-src/util/build-tools/sun-src/Makefile
--- a/open-src/util/build-tools/Makefile	Sun Aug 28 19:50:22 2011 -0700
+++ b/open-src/util/build-tools/Makefile	Sun Aug 28 21:53:02 2011 -0700
@@ -26,7 +26,7 @@
 MODULE_VERSION 		= src
 SOURCE_TARBALL_NAME	= NONE
 SOURCE_TARBALL_NAME_SET	= yes
-ADDITIONAL_SOURCE_DIR	= sun-src
+ACTUAL_SOURCE_DIR	= ../../sun-src
 
 # No configure script to run
 CONFIGURE_TARGETS	=
@@ -38,7 +38,8 @@
 
 # Since we don't have a configure script, pass configure flags to make
 MODULE_CONFIG_ENV	= MACH="$(MACH$(BUILD_TYPE))" DESTDIR="$(TOOLS_DIR)"
-MODULE_BUILD_MAKEFLAGS	= $(CONFIG_ENV)
-MODULE_INSTALL_MAKEFLAGS= $(CONFIG_ENV)
+MODULE_CONFIG_ENV      += srcdir="$(ACTUAL_SOURCE_DIR)"
+MODULE_BUILD_MAKEFLAGS	= $(CONFIG_ENV) -f "$(ACTUAL_SOURCE_DIR)/Makefile"
+MODULE_INSTALL_MAKEFLAGS= $(MODULE_BUILD_MAKEFLAGS)
 
 include ../Makefile.inc
--- a/open-src/util/build-tools/sun-src/Makefile	Sun Aug 28 19:50:22 2011 -0700
+++ b/open-src/util/build-tools/sun-src/Makefile	Sun Aug 28 21:53:02 2011 -0700
@@ -28,7 +28,7 @@
 
 install: $(DESTDIR)/time-$(MACH).so
 
-time-%.o:	time.c
+time-%.o:	$(srcdir)/time.c
 	$(CC) -Kpic $(CFLAGS) -c -o $@ $<
 
 time-%.so: time-%.o