changeset 940:77473affb9c0

Merge
author lana
date Thu, 17 Oct 2013 13:53:08 -0700
parents af81988013b5 (diff) ac748011cbbf (current diff)
children 35c14ec3e12f
files common/makefiles/JavaCompilation.gmk common/makefiles/RMICompilation.gmk
diffstat 3 files changed, 16 insertions(+), 43 deletions(-) [+]
line wrap: on
line diff
--- a/common/bin/hgforest.sh	Thu Oct 17 09:40:42 2013 -0700
+++ b/common/bin/hgforest.sh	Thu Oct 17 13:53:08 2013 -0700
@@ -1,7 +1,7 @@
 #!/bin/sh
 
 #
-# Copyright (c) 2009, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 #
 # This code is free software; you can redistribute it and/or modify it
@@ -27,37 +27,11 @@
 command="$1"
 pull_extra_base="$2"
 
-# Python always buffers stdout significantly, thus we will not see any output from hg clone jdk,
-# until a lot of time has passed! By passing -u to python, we get incremental updates
-# on stdout. Much nicer.
-whichhg="`which hg 2> /dev/null | grep -v '^no hg in'`"
-
-if [ "${whichhg}" = "" ] ; then
-  echo Cannot find hg!
-  exit 1
-fi
-
 if [ "" = "$command" ] ; then
   echo No command to hg supplied!
   exit 1
 fi
 
-has_hash_bang="`head -n 1 "${whichhg}" | cut -b 1-2`"
-python=""
-bpython=""
-
-if [ "#!" = "$has_hash_bang" ] ; then
-   python="`head -n 1 ${whichhg} | cut -b 3- | sed -e 's/^[ \t]*//;s/[ \t]*$//'`"
-   bpython="`basename "$python"`"
-fi
-
-if [ -x "$python" -a ! -d "$python" -a "`${python} -V 2>&1 | cut -f 1 -d ' '`" = "Python" ] ; then
-  hg="${python} -u ${whichhg}"
-else
-  echo Cannot find python from hg launcher. Running plain hg, which probably has buffered stdout.
-  hg="hg"
-fi
-
 # Clean out the temporary directory that stores the pid files.
 tmp=/tmp/forest.$$
 rm -f -r ${tmp}
@@ -171,7 +145,7 @@
     (
       if [ "${command}" = "clone" -o "${command}" = "fclone" ] ; then
         pull_newrepo="`echo ${pull_base}/${i} | sed -e 's@\([^:]/\)//*@\1@g'`"
-        echo ${hg} clone ${pull_newrepo} ${i}
+        echo hg clone ${pull_newrepo} ${i}
         path="`dirname ${i}`"
         if [ "${path}" != "." ] ; then
           times=0
@@ -184,10 +158,10 @@
             sleep 5
           done
         fi
-        (${hg} clone ${pull_newrepo} ${i}; echo "$?" > ${tmp}/${repopidfile}.pid.rc )&
+        (PYTHONUNBUFFERED=true hg clone ${pull_newrepo} ${i}; echo "$?" > ${tmp}/${repopidfile}.pid.rc )&
       else
-        echo "cd ${i} && ${hg} $*"
-        cd ${i} && (${hg} "$@"; echo "$?" > ${tmp}/${repopidfile}.pid.rc )&
+        echo "cd ${i} && hg $*"
+        cd ${i} && (PYTHONUNBUFFERED=true hg "$@"; echo "$?" > ${tmp}/${repopidfile}.pid.rc )&
       fi
       echo $! > ${tmp}/${repopidfile}.pid
     ) 2>&1 | sed -e "s@^@${reponame}:   @") &
--- a/common/makefiles/JavaCompilation.gmk	Thu Oct 17 09:40:42 2013 -0700
+++ b/common/makefiles/JavaCompilation.gmk	Thu Oct 17 13:53:08 2013 -0700
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 #
 # This code is free software; you can redistribute it and/or modify it
@@ -371,8 +371,8 @@
   #   INCLUDE_FILES:="com/sun/SolarisFoobar.java" means only compile this file!
   #   EXCLUDE_FILES:="com/sun/SolarisFoobar.java" means do not compile this particular file!
   #       "SolarisFoobar.java" means do not compile SolarisFoobar, wherever it is found.
-  #   JAVAC_SOURCE_PATH_UGLY_OVERRIDE:=Don't use this. This forces an explicit -sourcepath to javac.
-  #       Its only here until we cleanup some nasty source code pasta in the jdk.
+  #   JAVAC_SOURCE_PATH_OVERRIDE:=This forces an explicit -sourcepath to javac instead of the complete
+  #       source roots from SRC. This is sometimes needed when compiling specific subsets of the source.
   #   HEADERS:=path to directory where all generated c-headers are written.
   #   DEPENDS:=Extra dependecy
   $(foreach i,2 3 4 5 6 7 8 9 10 11 12 13 14 15, $(if $($i),$1_$(strip $($i)))$(NEWLINE))
@@ -474,8 +474,8 @@
   endif
 
   # Prep the source paths.
-  ifneq ($$($1_JAVAC_SOURCE_PATH_UGLY_OVERRIDE),)
-    $$(eval $$(call replace_space_with_pathsep,$1_SRCROOTSC,$$($1_JAVAC_SOURCE_PATH_UGLY_OVERRIDE)))
+  ifneq ($$($1_JAVAC_SOURCE_PATH_OVERRIDE),)
+    $$(eval $$(call replace_space_with_pathsep,$1_SRCROOTSC,$$($1_JAVAC_SOURCE_PATH_OVERRIDE)))
   else
     $$(eval $$(call replace_space_with_pathsep,$1_SRCROOTSC,$$($1_SRC)))
   endif
--- a/common/makefiles/RMICompilation.gmk	Thu Oct 17 09:40:42 2013 -0700
+++ b/common/makefiles/RMICompilation.gmk	Thu Oct 17 13:53:08 2013 -0700
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 #
 # This code is free software; you can redistribute it and/or modify it
@@ -38,7 +38,7 @@
   $(call LogSetupMacroEntry,SetupRMICompilation($1),$2,$3,$4,$5,$6,$7,$8,$9,$(10),$(11),$(12),$(13),$(14),$(15))
   $(if $(16),$(error Internal makefile error: Too many arguments to SetupRMICompilation, please update RMICompilation.gmk))
 
-  $1_DEP_FILE := $$($1_STUB_CLASSES_DIR)/$1_rmic
+  $1_DEP_FILE := $$($1_STUB_CLASSES_DIR)/_the.$1_rmic.generated
 
   $1_CLASSES_SLASH := $$(subst .,/,$$($1_CLASSES))
   $1_CLASS_FILES := $$(addprefix $$($1_CLASSES_DIR)/,$$(addsuffix .class,$$($1_CLASSES_SLASH)))
@@ -60,11 +60,11 @@
 
   ifneq (,$$($1_RUN_IIOP))
     $1_TARGETS += $$($1_TIE_FILES)
-    $1_ARGS += -iiop
+    $1_ARGS += -iiop -emitPermissionCheck
   endif
   ifneq (,$$($1_RUN_IIOP_STDPKG))
     $1_TARGETS += $$($1_TIE_STDPKG_FILES)
-    $1_ARGS2 := -iiop -standardPackage
+    $1_ARGS2 := -iiop -emitPermissionCheck -standardPackage
   endif
 
   ifneq (,$$($1_KEEP_GENERATED))
@@ -88,10 +88,9 @@
 	  $(RMIC) $$($1_ARGS2) -classpath "$$($1_CLASSES_DIR)" \
 	      -d $$($1_STUB_CLASSES_DIR) $$($1_DOLLAR_SAFE_CLASSES); \
 	fi;
+	$(TOUCH) $$@
 
 
-  $1 := $$($1_TARGETS)
+  $1 := $$($1_TARGETS) $$($1_DEP_FILE)
 
-  # By marking as secondary, this "touch" file doesn't need to be touched and will never exist.
-  .SECONDARY: $$($1_DEP_FILE)
 endef