Added a patch to fix issue caused due to '&' in vendor bug url

8247874: Replacement in VersionProps.java.template not working when --with-vendor-bug-url contains '&'
Added Patch9: jdk8247874-fix_ampersand_in_vm_bug_url.patch
This commit is contained in:
Jayashree Huttanagoudar 2020-06-22 18:00:08 +05:30
parent b0b5128294
commit 5ba186239d
2 changed files with 22 additions and 0 deletions

View File

@ -1111,6 +1111,8 @@ Patch6: rh1566890-CVE_2018_3639-speculative_store_bypass.patch
Patch7: pr3695-toggle_system_crypto_policy.patch
# S390 ambiguous log2_intptr call
Patch8: s390-8214206_fix.patch
# Replacement in VersionProps.java.template not working when --with-vendor-bug-url contains '&'
Patch9: jdk8247874-fix_ampersand_in_vm_bug_url.patch
#############################################
#
@ -1378,6 +1380,7 @@ pushd %{top_level_dir_name}
%patch6 -p1
%patch7 -p1
%patch8 -p1
%patch9 -p1
popd # openjdk
%patch1000
@ -1941,6 +1944,9 @@ require "copy_jdk_configs.lua"
%changelog
* Mon Jun 22 2020 Jayashree Huttanagoudar <jhuttana@redhat.com> - 1:1.0.8.5-0.2.ea
- Added a patch jdk8247874-fix_ampersand_in_vm_bug_url.patch
* Thu Jun 18 2020 Jiri Vanek <jvanek@redhat.com> - 1:11.0.8.5-0.2.ea
- set vendor property and vendor urls
- made urls to be preconfigured by os

View File

@ -0,0 +1,16 @@
diff --git openjdk.orig/make/common/TextFileProcessing.gmk openjdk/make/common/TextFileProcessing.gmk.bkp
index de6ca5c..04bd9e5 100644
--- openjdk.orig/make/common/TextFileProcessing.gmk
+++ openjdk/make/common/TextFileProcessing.gmk.bkp
@@ -155,9 +155,10 @@ define SetupTextFileProcessingBody
# Convert the REPLACEMENTS syntax ( A => B ; C => D ; ...) to a sed command
# line (-e "s/A/B/g" -e "s/C/D/g" ...), basically by replacing '=>' with '/'
# and ';' with '/g" -e "s/', and adjusting for edge cases.
+ # '&' has special meaning in sed so needs to be escaped.
$1_REPLACEMENTS_COMMAND_LINE := $(SED) -e 's$$($1_SEP)$$(subst $$(SPACE);$$(SPACE),$$($1_SEP)g' \
-e 's$$($1_SEP),$$(subst $$(SPACE)=>$$(SPACE),$$($1_SEP),$$(subst $$(SPACE)=>$$(SPACE);$$(SPACE),$$($1_SEP)$$($1_SEP)g' \
- -e 's$$($1_SEP),$$(strip $$($1_REPLACEMENTS)))))$$($1_SEP)g'
+ -e 's$$($1_SEP),$$(subst &,\&,$$(strip $$($1_REPLACEMENTS))))))$$($1_SEP)g'
else
# We don't have any replacements, just pipe the file through cat.
$1_REPLACEMENTS_COMMAND_LINE := $(CAT)