From 456b6ef3aba96aef32f14e3085fa470a06f11a2b Mon Sep 17 00:00:00 2001 From: ohair Date: Tue, 18 Sep 2012 13:15:28 -0700 Subject: [PATCH] 7198329: Add $(sort) to object files used in links makes binarties more consistent Reviewed-by: dholmes, tbell, erikj, ihse, ohrstrom --- make/bsd/makefiles/launcher.make | 2 +- make/bsd/makefiles/vm.make | 2 +- make/linux/makefiles/launcher.make | 2 +- make/linux/makefiles/vm.make | 2 +- make/solaris/makefiles/launcher.make | 2 +- make/solaris/makefiles/vm.make | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/make/bsd/makefiles/launcher.make b/make/bsd/makefiles/launcher.make index 37c4d6dca..de6313f1e 100644 --- a/make/bsd/makefiles/launcher.make +++ b/make/bsd/makefiles/launcher.make @@ -101,7 +101,7 @@ $(LAUNCHER_OUT)/%.o: $(LAUNCHERDIR)/%.c $(LAUNCHER): $(OBJS) $(LIBJVM) $(LAUNCHER_MAPFILE) $(QUIETLY) echo Linking launcher... $(QUIETLY) $(LINK_LAUNCHER/PRE_HOOK) - $(QUIETLY) $(LINK_LAUNCHER) $(LFLAGS_LAUNCHER) -o $@ $(OBJS) $(LIBS_LAUNCHER) + $(QUIETLY) $(LINK_LAUNCHER) $(LFLAGS_LAUNCHER) -o $@ $(sort $(OBJS)) $(LIBS_LAUNCHER) $(QUIETLY) $(LINK_LAUNCHER/POST_HOOK) # Sign the launcher with the development certificate (if present) so that it can be used # to run JStack, JInfo, et al. diff --git a/make/bsd/makefiles/vm.make b/make/bsd/makefiles/vm.make index f423408ac..9316f1cd6 100644 --- a/make/bsd/makefiles/vm.make +++ b/make/bsd/makefiles/vm.make @@ -311,7 +311,7 @@ $(LIBJVM): $(LIBJVM.o) $(LIBJVM_MAPFILE) $(LD_SCRIPT) echo Linking vm...; \ $(LINK_LIB.CXX/PRE_HOOK) \ $(LINK_VM) $(LD_SCRIPT_FLAG) \ - $(LFLAGS_VM) -o $@ $(LIBJVM.o) $(LIBS_VM); \ + $(LFLAGS_VM) -o $@ $(sort $(LIBJVM.o)) $(LIBS_VM); \ $(LINK_LIB.CXX/POST_HOOK) \ rm -f $@.1; ln -s $@ $@.1; \ [ -f $(LIBJVM_G) ] || { ln -s $@ $(LIBJVM_G); ln -s $@.1 $(LIBJVM_G).1; }; \ diff --git a/make/linux/makefiles/launcher.make b/make/linux/makefiles/launcher.make index 0c102eadc..d48a73dae 100644 --- a/make/linux/makefiles/launcher.make +++ b/make/linux/makefiles/launcher.make @@ -82,7 +82,7 @@ $(LAUNCHER_OUT)/%.o: $(LAUNCHERDIR)/%.c $(LAUNCHER): $(OBJS) $(LIBJVM) $(LAUNCHER_MAPFILE) $(QUIETLY) echo Linking launcher... $(QUIETLY) $(LINK_LAUNCHER/PRE_HOOK) - $(QUIETLY) $(LINK_LAUNCHER) $(LFLAGS_LAUNCHER) -o $@ $(OBJS) $(LIBS_LAUNCHER) + $(QUIETLY) $(LINK_LAUNCHER) $(LFLAGS_LAUNCHER) -o $@ $(sort $(OBJS)) $(LIBS_LAUNCHER) $(QUIETLY) $(LINK_LAUNCHER/POST_HOOK) $(LAUNCHER): $(LAUNCHER_SCRIPT) diff --git a/make/linux/makefiles/vm.make b/make/linux/makefiles/vm.make index 6e9794ba7..acb0f36d6 100644 --- a/make/linux/makefiles/vm.make +++ b/make/linux/makefiles/vm.make @@ -320,7 +320,7 @@ $(LIBJVM): $(LIBJVM.o) $(LIBJVM_MAPFILE) $(LD_SCRIPT) echo Linking vm...; \ $(LINK_LIB.CXX/PRE_HOOK) \ $(LINK_VM) $(LD_SCRIPT_FLAG) \ - $(LFLAGS_VM) -o $@ $(LIBJVM.o) $(LIBS_VM); \ + $(LFLAGS_VM) -o $@ $(sort $(LIBJVM.o)) $(LIBS_VM); \ $(LINK_LIB.CXX/POST_HOOK) \ rm -f $@.1; ln -s $@ $@.1; \ [ -f $(LIBJVM_G) ] || { ln -s $@ $(LIBJVM_G); ln -s $@.1 $(LIBJVM_G).1; }; \ diff --git a/make/solaris/makefiles/launcher.make b/make/solaris/makefiles/launcher.make index f735b20d3..090ff5ea7 100644 --- a/make/solaris/makefiles/launcher.make +++ b/make/solaris/makefiles/launcher.make @@ -96,7 +96,7 @@ $(LAUNCHER): $(OBJS) $(LIBJVM) $(LAUNCHER_MAPFILE) ifeq ($(filter -sbfast -xsbfast, $(CFLAGS_BROWSE)),) $(QUIETLY) echo Linking launcher... $(QUIETLY) $(LINK_LAUNCHER/PRE_HOOK) - $(QUIETLY) $(LINK_LAUNCHER) $(LFLAGS_LAUNCHER) -o $@ $(OBJS) $(LIBS_LAUNCHER) + $(QUIETLY) $(LINK_LAUNCHER) $(LFLAGS_LAUNCHER) -o $@ $(sort $(OBJS)) $(LIBS_LAUNCHER) $(QUIETLY) $(LINK_LAUNCHER/POST_HOOK) endif # filter -sbfast -xsbfast diff --git a/make/solaris/makefiles/vm.make b/make/solaris/makefiles/vm.make index 8f1a5e20a..d91cba351 100644 --- a/make/solaris/makefiles/vm.make +++ b/make/solaris/makefiles/vm.make @@ -288,7 +288,7 @@ $(LIBJVM): $(ADD_GNU_DEBUGLINK) $(FIX_EMPTY_SEC_HDR_FLAGS) $(LIBJVM.o) $(LIBJVM_ ifeq ($(filter -sbfast -xsbfast, $(CFLAGS_BROWSE)),) @echo Linking vm... $(QUIETLY) $(LINK_LIB.CXX/PRE_HOOK) - $(QUIETLY) $(LINK_VM) $(LFLAGS_VM) -o $@ $(LIBJVM.o) $(LIBS_VM) + $(QUIETLY) $(LINK_VM) $(LFLAGS_VM) -o $@ $(sort $(LIBJVM.o)) $(LIBS_VM) $(QUIETLY) $(LINK_LIB.CXX/POST_HOOK) $(QUIETLY) rm -f $@.1 && ln -s $@ $@.1 $(QUIETLY) [ -f $(LIBJVM_G) ] || ln -s $@ $(LIBJVM_G) -- GitLab