Updated to latest upstream

This commit is contained in:
Jiri Vanek 2018-04-26 10:44:31 +02:00
parent 0d75b0c9a2
commit 4d8dcc1742
2 changed files with 10 additions and 6 deletions

View File

@ -6,9 +6,9 @@
Name: copy-jdk-configs
# hash relevant to version tag
%global htag f1cd4541f89ac601873ee16d6aa3b3cb1497f0d5
%global htag de7cb1123c5e519b2d946f3afb9812e976954d0d
Version: 3.3
Release: 5%{?dist}
Release: 9%{?dist}
Summary: JDKs configuration files copier
License: BSD

View File

@ -60,7 +60,7 @@ fi
listLinks(){
find $1 -type l -print0 | xargs -0 ls -ld | sed "s;.* $1;$1;" | sed "s; \+;_;g"
find $1 -type l -print0 | xargs -0 ls -ld | sed "s; \+-> \+;_->_;g" | sed "s;.* $1;$1;"
}
printIfExists(){
@ -76,6 +76,10 @@ createListOfLinksTargetsDirectories(){
pushd $source >/dev/null 2>&1
local links=`listLinks $1`
for x in $links ; do
echo "$x" | grep "jre-abrt" > /dev/null
if [ $? -eq 0 ] ; then
continue
fi
local ffileCandidate=$(echo $x | sed "s/.*_->_//") ;
# ignoring relative paths as they may lead who know where later
# there can be simlink relative to position, so push is not catching all
@ -129,8 +133,7 @@ work(){
if [ $? -gt 0 ] ; then
if [ "X$1" == "Xrpmnew" ] ; then
debug "$sf2 was NOT modified, removing possibly corrupted $sf1 and renaming from $file"
rm $rma $sf1
mv $rma $file $sf1
mv $rma -f $file $sf1
if [ $? -eq 0 ] ; then
echo "restored $file to $sf1"
else
@ -187,8 +190,9 @@ files=`find $sourceSearchPath | grep "\\.rpmsave$"`
#warning: file /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.131-11.b12.el7.x86_64-debug/jre/lib/applet: remove failed: No such file or directory
#warning: file /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.131-11.b12.el7.x86_64-debug/jre/lib/amd64/client: remove failed: No such file or directory
#warning: file /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.171-2.6.13.2.el7.x86_64/jre/lib/amd64/xawt: remove failed: No such file or directory
#those dirs might be mepty by installtion, filling to not be rmeoved later
blackdirs="$source/jre/lib/applet $source/jre/lib/*/client $source/jre/lib/locale/*/LC_MESSAGE"
blackdirs="$source/jre/lib/applet $source/jre/lib/*/client $source/jre/lib/locale/*/LC_MESSAGE $source/jre/lib/*/xawt"
for blackdir in $blackdirs; do
if [ -e $blackdir ] ; then
debug "nasty $blackdir exists, filling"