8010465: Can't enable sjavac when building in jprt.

Tue, 09 Apr 2013 09:45:48 +0200

author
erikj
date
Tue, 09 Apr 2013 09:45:48 +0200
changeset 673
2ef28c12d649
parent 672
2f43964043c2
child 674
a09e9c9ca963

8010465: Can't enable sjavac when building in jprt.
Reviewed-by: ohair, tbell

common/makefiles/JavaCompilation.gmk file | annotate | diff | comparison | revisions
common/makefiles/Jprt.gmk file | annotate | diff | comparison | revisions
common/makefiles/MakeBase.gmk file | annotate | diff | comparison | revisions
common/makefiles/MakeHelpers.gmk file | annotate | diff | comparison | revisions
     1.1 --- a/common/makefiles/JavaCompilation.gmk	Tue Apr 09 09:42:20 2013 +0200
     1.2 +++ b/common/makefiles/JavaCompilation.gmk	Tue Apr 09 09:45:48 2013 +0200
     1.3 @@ -86,7 +86,7 @@
     1.4      # NOTE: $2 is dependencies, not a named argument!
     1.5      $(foreach i,3 4 5 6 7 8 9 10 11 12 13 14 15, $(if $($i),$1_$(strip $($i)))$(NEWLINE))
     1.6      $(call LogSetupMacroEntry,SetupArchive($1),<dependencies>,$3,$4,$5,$6,$7,$8,$9,$(10),$(11),$(12),$(13),$(14),$(15))
     1.7 -    $(if $(findstring $(LOG),debug trace), $(info *[2] <dependencies> = $(strip $2)))
     1.8 +    $(if $(findstring $(LOG_LEVEL),debug trace), $(info *[2] <dependencies> = $(strip $2)))
     1.9      $(if $(16),$(error Internal makefile error: Too many arguments to SetupArchive, please update JavaCompilation.gmk))
    1.10  
    1.11      $1_JARMAIN:=$(strip $$($1_JARMAIN))
    1.12 @@ -505,7 +505,7 @@
    1.13  			--permit-unidentified-artifacts \
    1.14  			--permit-sources-without-package \
    1.15  			--compare-found-sources $$($1_BIN)/_the.batch.tmp \
    1.16 -			--log=$(LOG) \
    1.17 +			--log=$(LOG_LEVEL) \
    1.18  			$$($1_SJAVAC_ARGS) \
    1.19  			$$($1_FLAGS) \
    1.20  			$$($1_HEADERS_ARG) \
     2.1 --- a/common/makefiles/Jprt.gmk	Tue Apr 09 09:42:20 2013 +0200
     2.2 +++ b/common/makefiles/Jprt.gmk	Tue Apr 09 09:45:48 2013 +0200
     2.3 @@ -103,6 +103,9 @@
     2.4  ifdef ALT_FREETYPE_HEADERS_PATH
     2.5  	@$(ECHO) " --with-freetype=$(call UnixPath,$(ALT_FREETYPE_HEADERS_PATH)/..) " >> $@.tmp
     2.6  endif
     2.7 +ifdef ENABLE_SJAVAC
     2.8 +	@$(ECHO) " --enable-sjavac" >> $@.tmp
     2.9 +endif
    2.10  ifeq ($(HOTSPOT_AVAILABLE),false)
    2.11    ifdef ALT_JDK_IMPORT_PATH
    2.12  	@$(ECHO) " --with-import-hotspot=$(call UnixPath,$(ALT_JDK_IMPORT_PATH)) " >> $@.tmp
     3.1 --- a/common/makefiles/MakeBase.gmk	Tue Apr 09 09:42:20 2013 +0200
     3.2 +++ b/common/makefiles/MakeBase.gmk	Tue Apr 09 09:45:48 2013 +0200
     3.3 @@ -328,7 +328,7 @@
     3.4  endef
     3.5  
     3.6  define SetupLogging
     3.7 -    ifeq ($$(LOG), trace)
     3.8 +    ifeq ($$(LOG_LEVEL),trace)
     3.9          # Shell redefinition trick inspired by http://www.cmcrossroads.com/ask-mr-make/6535-tracing-rule-execution-in-gnu-make
    3.10          # For each target executed, will print
    3.11          # Building <TARGET> (from <FIRST PREREQUISITE>) (<ALL NEWER PREREQUISITES> newer)
    3.12 @@ -339,17 +339,17 @@
    3.13      endif
    3.14      # Never remove warning messages; this is just for completeness
    3.15      LOG_WARN= 
    3.16 -    ifneq ($$(findstring $$(LOG),info debug trace),)
    3.17 +    ifneq ($$(findstring $$(LOG_LEVEL),info debug trace),)
    3.18          LOG_INFO=
    3.19      else
    3.20          LOG_INFO=> /dev/null
    3.21      endif
    3.22 -    ifneq ($$(findstring $$(LOG),debug trace),)
    3.23 +    ifneq ($$(findstring $$(LOG_LEVEL),debug trace),)
    3.24          LOG_DEBUG=
    3.25      else
    3.26          LOG_DEBUG=> /dev/null
    3.27      endif
    3.28 -    ifneq ($$(findstring $$(LOG),trace),)
    3.29 +    ifneq ($$(findstring $$(LOG_LEVEL),trace),)
    3.30          LOG_TRACE=
    3.31      else
    3.32          LOG_TRACE=> /dev/null
    3.33 @@ -362,7 +362,7 @@
    3.34  # This is to be called by all SetupFoo macros
    3.35  define LogSetupMacroEntry
    3.36      $(if $(26),$(error Internal makefile error: Too many arguments to LogSetupMacroEntry, please update MakeBase.gmk))
    3.37 -    $(if $(findstring $(LOG),debug trace), $(info $1 $(foreach i,2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25,$(if $($i),$(NEWLINE) $(strip [$i] $($i))))))
    3.38 +    $(if $(findstring $(LOG_LEVEL),debug trace), $(info $1 $(foreach i,2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25,$(if $($i),$(NEWLINE) $(strip [$i] $($i))))))
    3.39  endef
    3.40  
    3.41  # Make directory without forking mkdir if not needed
     4.1 --- a/common/makefiles/MakeHelpers.gmk	Tue Apr 09 09:42:20 2013 +0200
     4.2 +++ b/common/makefiles/MakeHelpers.gmk	Tue Apr 09 09:45:48 2013 +0200
     4.3 @@ -184,26 +184,34 @@
     4.4            LOG_STRIPPED2=$$(subst nofile,,$$(LOG_STRIPPED1))
     4.5            # We might have ended up with a leading comma. Remove it
     4.6            LOG_STRIPPED3=$$(strip $$(patsubst $$(COMMA)%,%,$$(LOG_STRIPPED2)))
     4.7 -          override LOG:=$$(LOG_STRIPPED3)
     4.8 +          LOG_LEVEL:=$$(LOG_STRIPPED3)
     4.9 +        else
    4.10 +          LOG_LEVEL:=$$(LOG)
    4.11          endif
    4.12  
    4.13 -        ifeq ($$(LOG),)
    4.14 +        ifeq ($$(LOG_LEVEL),)
    4.15              # Set LOG to "warn" as default if not set (and no VERBOSE given)
    4.16 -            override LOG=warn
    4.17 +            override LOG_LEVEL=warn
    4.18          endif
    4.19 -        ifeq ($$(LOG),warn)
    4.20 +        ifeq ($$(LOG_LEVEL),warn)
    4.21              VERBOSE=-s
    4.22 -        else ifeq ($$(LOG),info)
    4.23 +        else ifeq ($$(LOG_LEVEL),info)
    4.24              VERBOSE=-s
    4.25 -        else ifeq ($$(LOG),debug)
    4.26 +        else ifeq ($$(LOG_LEVEL),debug)
    4.27              VERBOSE=
    4.28 -        else ifeq ($$(LOG),trace)
    4.29 +        else ifeq ($$(LOG_LEVEL),trace)
    4.30              VERBOSE=
    4.31          else
    4.32              $$(info Error: LOG must be one of: warn, info, debug or trace.)
    4.33              $$(eval $$(call FatalError))
    4.34          endif
    4.35      else
    4.36 +        # Provide resonable interpretations of LOG_LEVEL if VERBOSE is given.
    4.37 +        ifeq ($(VERBOSE),)
    4.38 +            LOG_LEVEL:=debug
    4.39 +        else
    4.40 +            LOG_LEVEL:=warn
    4.41 +        endif
    4.42          ifneq ($$(LOG),)
    4.43              # We have both a VERBOSE and a LOG argument. This is OK only if this is a repeated call by ourselves,
    4.44              # but complain if this is the top-level make call.

mercurial