copy-jdk-configs-2.3-1.fc25$>H9q?zFbj>>4?4d  > %1TZdt |   X \l   (8 9 : G H 0I @X DY H\ T] d^ b d e f l t u ,v <w x y  34444Ccopy-jdk-configs2.31.fc25JDKs configuration files copierUtility script to transfer JDKs configuration files between updates or for archiving. With script to fix incorrectly created rpmnew filesYlbuildvm-10.phx2.fedoraproject.org8Fedora ProjectFedora ProjectBSDFedora ProjectUnspecifiedhttps://pagure.io/copy_jdk_configslinuxnoarch%DӁA큤YlfYlfYlYlf29ee15e1fda89278c355deaabc5a38f1d364bf9d72579a39e1c062828ece6df5160e19d8a796518c73bb646c4653612379896feb8ef741b65ef57bc6b9544eb0386eaf71633bf096e6c17471f50e867dabdf14d38a157ca27a0425dc583eb9ferootrootrootrootrootrootrootrootcopy-jdk-configs-2.3-1.fc25.src.rpmcopy-jdk-configs@ @     /bin/bash/bin/sh/usr/bin/lualualua-posixrpmlib(BuiltinLuaScripts)rpmlib(CompressedFileNames)rpmlib(FileDigests)rpmlib(PayloadFilesHavePrefix)rpmlib(PayloadIsXz)4.2.2-13.0.4-14.6.0-14.0-15.2-14.13.0.1X}@X}@X@XpXWWVVVqR@VUFedora Release Engineering - 2.2.3Fedora Release Engineering - 2.2.2Fedora Release Engineering - 2.1-2Jiri Vanek - 2.1-1Jiri Vanek - 2.0-1Jiri Vanek - 1.2-1Jiri Vanek - 1.1-5Fedora Release Engineering - 1.1-4Jiri Vanek - 1.1-3Jiri Vanek - 1.1-2Jiri Vanek - 1.1-1- updated to latest head- added "jre/lib/security/blacklisted.certs" to cared files- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild- moved to newest release 2.1- moved to new upstream at pagure.io - moved to newest release 2.0 - added new script of copy_jdk_configs_fixFiles.sh - copy_jdk_configs.lua aligned to it- updated to 1,3 which fixing nss minor issue- posttrans silenced, the error is appearing only in state, when there is nothing to copy- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild- 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 package2.3-1.fc25copy_jdk_configs.luacopy_jdk_configs_fixFiles.shcopy-jdk-configsLICENSE/usr/libexec//usr/share/licenses//usr/share/licenses/copy-jdk-configs/-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tablesdrpmxz2noarch-redhat-linux-gnuLua script, ASCII text executableBourne-Again shell script, ASCII text executabledirectoryASCII textRRfunction 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/java.policy", "jre/lib/security/java.security", "jre/lib/security/local_policy.jar", "jre/lib/security/nss.cfg", "jre/lib/security/cacerts", "jre/lib/security/blacklisted.certs", "jre/lib/ext", "lib/calendars.properties", "lib/content-types.properties", "lib/flavormap.properties", "lib/logging.properties", "lib/net.properties", "lib/psfontj2d.properties", "lib/sound.properties", "lib/deployment.properties", "lib/deployment.config", "lib/security/US_export_policy.jar", "lib/security/java.policy", "lib/security/java.security", "lib/security/local_policy.jar", "lib/security/nss.cfg", "lib/security/cacerts", "lib/security/blacklisted.certs", "lib/security/default.policy", "conf/security/policy/limited/exempt_local.policy", "conf/security/policy/limited/default_local.policy", "conf/security/policy/limited/default_US_export.policy", "conf/security/policy/unlimited/default_local.policy", "conf/security/policy/unlimited/default_US_export.policy", "conf/security/java.policy", "conf/security/java.security", "conf/logging.properties", "conf/security/nss.cfg", "conf/management/jmxremote.access", "conf/management/jmxremote.password.template", "conf/management/management.properties", "conf/net.properties", "conf/sound.properties", "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 --trasnform substitute names to lua patterns local name = string.gsub(string.gsub(origname, "%-", "%%-"), "%.", "%%.") local javaver = string.gsub(origjavaver, "%.", "%%.") local jvms = { } 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 if (debug) then print("started") end; foundJvms = posix.dir(jvmdir); if (foundJvms == nil) then if (debug) then print("no, or nothing in "..jvmdir.." exit") end; return end if (debug) then print("found "..#foundJvms.."jvms") end; 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 if (debug) then print("matched: "..p) end; if (currentjvm == p) then if (debug) then print("this jdk is already installed. exiting lua script") end; 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 if (debug) then print("NOT matched: "..p) end; end end if (#jvms <=0) then if (debug) then print("no matching jdk in "..jvmdir.." exit") end; return end; if (debug) then print("matched "..#jvms.." jdk in "..jvmdir) end; --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 if (debug) then print("executing "..linkExe) end; os.execute(linkExe) local link=trim(slurp(readlinkOutput)) if (debug) then print(" ...link is "..link) end if (not ((link) == (SOURCE))) then print("WARNING link "..link.." where file "..SOURCE.."expected!") end if (debug) then print("executing "..exe) end; if (not dry) then os.execute(exe) end else if (debug) then print(SOURCE.." does not exists") end; 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/shutf-8? 7zXZ !#,/@]"k%{AvX1ڋNHRFHh15"3Ik'k8ݶaP%%<eewlńE\~o}K#ݬ+ +o+2c0?$9PϚujO,V=8ɘ*V J}K7 1@XԢpD D| }F,LGbKJ'҄f TCAe5qI^]rӨM@ݟ2Ne󃵽%Bu)Etj֍?pvP:I7AZ|amzQ=zv~g>q1SWh DtiبSg)F^-Ӛd˳R=X'Dؗ7]"c4-_tF$|N(J`L'HhbC>DΕ_3$iiThk'![~D``Y#plQ%ؒT環b%2h,OOMC='05R&^S ^=ϣn05Aż;{H%L[SVQ6sg'|2 ЩnHe՛kGy`9~I=* ld\wbe$A@;.cVmE伅kl V]ttX/XEYbBK&=yW}~iomEsssF};H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