copy-jdk-configs-3.3-10.el7_5>t  DH`pZ\$ƨhoiaܚzp/aM30c9rRwn!杭^Ĵ qV[+UTxV&UPfFd5yb%k5[qW+b .h˻npt M7leٛ ht&l;g0j4mo\JP>}7գ@+ bAsp #\ sx+u(@oJ2 ~sHB)U85kbI崴!n7ꞸWCj+z&Y\bXڣɛwg~q:ccNB;f}BXޑq6״K +RIє?C476OWT֔BH1artd2S~Kq]F_ <f2MpjX*T#1h :7.B˴_IwZJlnP߰ WՈHzT  ^׻p--dbe71a94571d87a467c7bdb0b742578fd88d69a7OЉZ\$ƨ!yA3.5~Ǡ=V񪞈|! )0b_?|~UՂ:wV=d/%/ C:"eV  _$FU,B9rb̬/N=0AE[CI`f\L.x mu^2@ fD_a~8!s` ąJmzEc\(6b`tA~.x0M?po!C[0|[3@8)4"!wա#mZT<7qĩSbn 4@/:4můU+шķEǷЍ6Q?"p'd[Ok<Bp><6?6|d  @ #/RX`p x   T Xh|(89:G ,H <I LX PY T\ d] t^ b d e f l t u v $w x y  56h6n6xCcopy-jdk-configs3.310.el7_5JDKs configuration files copierUtility script to transfer JDKs configuration files between updates or for archiving. With script to fix incorrectly created rpmnew filesZx86-01.bsys.centos.org?CentOSBSDCentOS BuildSystem Unspecifiedhttps://pagure.io/copy_jdk_configslinuxnoarch%y<ӁA클ZZZZ41da8b07bd2896d1a704f8d05f3c411552f6ab37fe8cd356615f00a120c342ba5f4b632b3c0457880d6ca370ae1c4d9cae571ee4be608ca9a21e42cf2e596639386eaf71633bf096e6c17471f50e867dabdf14d38a157ca27a0425dc583eb9ferootrootrootrootrootrootrootrootcopy-jdk-configs-3.3-10.el7_5.src.rpmcopy-jdk-configs@      /bin/bash/bin/shluarpmlib(BuiltinLuaScripts)rpmlib(CompressedFileNames)rpmlib(FileDigests)rpmlib(PayloadFilesHavePrefix)rpmlib(PayloadIsXz)4.2.2-13.0.4-14.6.0-14.0-15.2-14.11.3Z@ZmYZ@YZ@YGY?X@WWW @W @VVqR@VUJiri Vanek - 3.3-10Jiri Vanek - 3.3-3Jiri Vanek - 3.3-2Jiri Vanek - 3.3-1Jiri Vanek - 2.2-3Jiri Vanek - 2.2-1Jiri Vanek - 1.3-1Jiri Vanek - 1.2-1Jiri Vanek - 1.1-5Jiri Vanek - 1.1-3Jiri Vanek - 1.1-3Jiri Vanek - 1.1-3Jiri Vanek - 1.1-2Jiri Vanek - 1.1-1- added javaws.policy and blacklist - Resolves: rhbz#1573163- fixes issue when java.security for openjdk7 was erased - Resolves: rhbz#1573163- added another subdirs for policies files - Resolves: rhbz#1503647 - Resolves: rhbz#1503668- updated to 3.3 - Resolves: rhbz#1503647 - Resolves: rhbz#1503668- updated to latest head - Resolves: rhbz#1427463- added "jre/lib/security/blacklisted.certs" to cared files - moved to newest release 2.1 - moved to new upstream at pagure.io - added new script of copy_jdk_configs_fixFiles.sh - copy_jdk_configs.lua aligned to it - Resolves: rhbz#1427463- updated to upstream 1.3 (adding jre/lib/security/cacerts file) - Resolves: rhbz#1399719- updated to 1,3 which fixing nss minor issue - Resolves: rhbz#1296430- posttrans silenced, the error is appearing only in state, when there is nothing to copy - Resolves: rhbz#1296430- commented requires on lua posix to stop blocking composes. - changed it to 644 to dont mislead by executable flags - Resolves: rhbz#1296430- inital commit to rhel - Resolves: rhbz#1296430- pretrasn lua call now done in pcall (protected call) - also posttrans now always return 0- package now "installs" also during pretrans, so pretrasn scripts can use it - pretrasn "install" is removed in postrans- initial package3.3-10.el7_5copy_jdk_configs.luacopy_jdk_configs_fixFiles.shcopy-jdk-configs-3.3LICENSE/usr/libexec//usr/share/licenses//usr/share/licenses/copy-jdk-configs-3.3/-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m32 -march=x86-64 -mtune=generic -mfpmath=sse -fasynchronous-unwind-tablescpioxz2noarch-redhat-linux-gnuLua script, ASCII text executableBourne-Again shell script, ASCII text executabledirectoryASCII textRfunction createPretransScript() -- the sript must be available during pretrans, so multiply it to tmp os.execute("mkdir -p /var/lib/rpm-state") temp_path="/var/lib/rpm-state/copy_jdk_configs.lua" -- print("generating " .. temp_path) file = io.open(temp_path, "w") file:write([[#!/usr/bin/lua -- rpm call -- lua -- copy_jdk_configs.lua --currentjvm "%{uniquesuffix %{nil}}" --jvmdir "%{_jvmdir %{nil}}" --origname "%{name}" --origjavaver "%{javaver}" --arch "%{_arch}" --debug true --test call --lua -- copy_jdk_configs.lua --currentjvm "java-1.8.0-openjdk-1.8.0.65-3.b17.fc22.x86_64" --jvmdir "/usr/lib/jvm" --origname "java-1.8.0-openjdk" --origjavaver "1.8.0" --arch "x86_64" --debug true --jvmDestdir /home/jvanek/Desktop local caredFiles = {"jre/lib/calendars.properties", "jre/lib/content-types.properties", "jre/lib/flavormap.properties", "jre/lib/logging.properties", "jre/lib/net.properties", "jre/lib/psfontj2d.properties", "jre/lib/sound.properties", "jre/lib/deployment.properties", "jre/lib/deployment.config", "jre/lib/security/US_export_policy.jar", "jre/lib/security/unlimited/US_export_policy.jar", "jre/lib/security/limited/US_export_policy.jar", "jre/lib/security/policy/unlimited/US_export_policy.jar", "jre/lib/security/policy/limited/US_export_policy.jar", "jre/lib/security/java.policy", "jre/lib/security/java.security", "jre/lib/security/local_policy.jar", "jre/lib/security/unlimited/local_policy.jar", "jre/lib/security/limited/local_policy.jar", "jre/lib/security/policy/unlimited/local_policy.jar", "jre/lib/security/policy/limited/local_policy.jar", "jre/lib/security/nss.cfg", "jre/lib/security/cacerts", "jre/lib/security/blacklisted.certs", "jre/lib/ext", "jre/lib/security/blacklist", "jre/lib/security/javaws.policy", "lib/security", "conf", "lib/ext"} -- before import to allow run from spec if (arg[1] == "--list") then for i,file in pairs(caredFiles) do print(file) end return 0; end -- yum install lua-posix local posix = require "posix" -- the one we are installing local currentjvm = nil local jvmdir = nil local jvmDestdir = nil local origname = nil local origjavaver = nil local arch = nil local debug = false; local temp = nil; local dry = false; for i=1,#arg,2 do if (arg[i] == "--help" or arg[i] == "-h") then print("all but jvmDestdir and debug are mandatory") print(" --currentjvm") print(" NVRA of currently installed java") print(" --jvmdir") print(" Directory where to find this kind of virtual machine. Generally /usr/lib/jvm") print(" --origname") print(" convinient switch to determine jdk. Generally java-1.X.0-vendor") print(" --origjavaver") print(" convinient switch to determine jdk's version. Generally 1.X.0") print(" --arch") print(" convinient switch to determine jdk's arch") print(" --jvmDestdir") print(" Migration/testing switch. Target Mostly same as jvmdir, but you may wont to copy ouside it.") print(" --debug") print(" Enables printing out whats going on. true/false. False by default") print(" --temp") print(" optional file to save intermediate result - directory configs were copied from") print(" --dry") print(" true/fase if true, then no changes will be written to disk except one tmp file. False by default") print(" **** specil parasm ****") print(" --list") print(" if present on cmdline, list all cared files and exists") os.exit(0) end if (arg[i] == "--currentjvm") then currentjvm=arg[i+1] end if (arg[i] == "--jvmdir") then jvmdir=arg[i+1] end if (arg[i] == "--origname") then origname=arg[i+1] end if (arg[i] == "--origjavaver") then origjavaver=arg[i+1] end if (arg[i] == "--arch") then arch=arg[i+1] end if (arg[i] == "--jvmDestdir") then jvmDestdir=arg[i+1] end if (arg[i] == "--debug") then --no string, boolean, workaround if (arg[i+1] == "true") then debug = true end end if (arg[i] == "--dry") then --no string, boolean, workaround if (arg[i+1] == "true") then dry = true end end if (arg[i] == "--temp") then temp=arg[i+1] end end if (jvmDestdir == nil) then jvmDestdir = jvmdir end if (debug) then print("--currentjvm:"); print(currentjvm); print("--jvmdir:"); print(jvmdir); print("--jvmDestdir:"); print(jvmDestdir); print("--origname:"); print(origname); print("--origjavaver:"); print(origjavaver); print("--arch:"); print(arch); print("--debug:"); print(debug); end local function debugOneLinePrint(string) if (debug) then print(string) end; end --trasnform substitute names to lua patterns local name = string.gsub(string.gsub(origname, "%-", "%%-"), "%.", "%%.") local javaver = string.gsub(origjavaver, "%.", "%%.") local jvms = { } function getPath(str,sep) sep=sep or '/' return str:match("(.*"..sep..")") end function splitToTable(source, pattern) local i1 = string.gmatch(source, pattern) local l1 = {} for i in i1 do table.insert(l1, i) end return l1 end local function slurp(path) local f = io.open(path) local s = f:read("*a") f:close() return s end function trim(s) return (s:gsub("^%s*(.-)%s*$", "%1")) end local function dirWithParents(path) local s = "" local dirs = splitToTable(path, "[^/]+") for i,d in pairs(dirs) do if (i == #dirs) then break end s = s.."/"..d local stat2 = posix.stat(s, "type"); if (stat2 == nil) then debugOneLinePrint(s.." does not exists, creating") if (not dry) then posix.mkdir(s) end else debugOneLinePrint(s.." exists,not creating") end end end debugOneLinePrint("started") foundJvms = posix.dir(jvmdir); if (foundJvms == nil) then debugOneLinePrint("no, or nothing in "..jvmdir.." exit") return end debugOneLinePrint("found "..#foundJvms.."jvms") for i,p in pairs(foundJvms) do -- regex similar to %{_jvmdir}/%{name}-%{javaver}*%{_arch} bash command if (string.find(p, name.."%-"..javaver..".*"..arch) ~= nil ) then debugOneLinePrint("matched: "..p) if (currentjvm == p) then debugOneLinePrint("this jdk is already installed. exiting lua script") return end ; if (string.match(p, ".*-debug$")) then print(p.." matched but seems to be debug variant. Skipping") else table.insert(jvms, p) end else debugOneLinePrint("NOT matched: "..p) end end if (#jvms <=0) then debugOneLinePrint("no matching jdk in "..jvmdir.." exit") return end; debugOneLinePrint("matched "..#jvms.." jdk in "..jvmdir) --full names are like java-1.7.0-openjdk-1.7.0.60-2.4.5.1.fc20.x86_64 table.sort(jvms , function(a,b) -- version-sort -- split on non word: . - local l1 = splitToTable(a, "[^%.-]+") local l2 = splitToTable(b, "[^%.-]+") for x = 1, math.min(#l1, #l2) do local l1x = tonumber(l1[x]) local l2x = tonumber(l2[x]) if (l1x ~= nil and l2x ~= nil)then --if hunks are numbers, go with them if (l1x < l2x) then return true; end if (l1x > l2x) then return false; end else if (l1[x] < l2[x]) then return true; end if (l1[x] > l2[x]) then return false; end end -- if hunks are equals then move to another pair of hunks end return a "..readlinkOutput debugOneLinePrint("executing "..linkExe) os.remove(readlinkOutput) os.execute(linkExe) local link=trim(slurp(readlinkOutput)) debugOneLinePrint(" ...link is "..link) if (not ((link) == (SOURCE))) then debugOneLinePrint("WARNING link "..link.." where file "..SOURCE.." expected!") debugOneLinePrint("Will try to copy link target rather then link itself!") --replacing any NVRA by future NVRA (still execting to have NVRA for any multiple-installable targets -- lua stubbornly consider dash as inteval. Replacing by dot to match X-Y more correct as X.Y rather then not at all local linkDest=string.gsub(link, latestjvm:gsub("-", "."), currentjvm) debugOneLinePrint("attempting to copy "..link.." to "..linkDest) if (link == linkDest) then debugOneLinePrint("Those are identical files! Nothing to do!") else local exe2 = "cp".." -ar "..link.." "..linkDest dirWithParents(linkDest) debugOneLinePrint("executing "..exe2) if (not dry) then os.execute(exe2) end end else debugOneLinePrint("executing "..exe) if (not dry) then os.execute(exe) end end else debugOneLinePrint(SOURCE.." does not exists") end end]]) file:close() end -- in netinst, the above call may fail. pcall should save instalation (as there is nothing to copy anyway) -- https://bugzilla.redhat.com/show_bug.cgi?id=1295701 -- todo, decide whether to check for {rpm_state_dir} and skip on not-existing, or keep creating if pcall(createPretransScript) then -- ok else -- print("Error running copy-jdk-configs pretrans.") end# remove file created in pretrans # echo "removing /var/lib/rpm-state/copy_jdk_configs.lua" || : rm "/var/lib/rpm-state/copy_jdk_configs.lua" 2> /dev/null || :/bin/sh?@7zXZ !#,Bo] b2u Q{K=҂tHИ&yXJia`5"=gcOӾC1E{>7a`Che/mcH?ؔPmaN'b`M]*h!d #]T9[quru~YpжM2&”r8Q-OB5G;_]ԋgW IZ ߷ O!uw̖7n<0%u ~(sg <ޭJOr[c^¨xBb!'Foo+0J5lƑ;+4]bYbRkQ>sIRګS$vr|> z")tI# xkЊrТ}~A; 7!\޸ (9GާS?_ ,FV݂;YʁژY) %c-erEڋPD0AOo$+߼UE-lҏuxF3PQQ r c*m;>YYIl;"7۴ןb XY=^߃cLjH #R=_i@zr7{,dvnQ΍<9E1]幩7*T.ߦSOwYQ _8^*hX}`'V8n҇E+伬v?M1q aZZd.onZ;gЭD["Ȟ>ʗ3rÒ}$Y(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