1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
|
#!/bin/sh
kpBuild="$(pwd)"
kpRoot="${kpBuild}/.."
# Mono's resource compiler/linker doesn't support ICO files
# containing high resolution images (in PNG format)
kpIco="${kpRoot}/Ext/Icons_15_VA/LowResIcons/KeePass_LR.ico"
kpIcoG="${kpRoot}/Ext/Icons_15_VA/LowResIcons/KeePass_LR_G.ico"
kpIcoR="${kpRoot}/Ext/Icons_15_VA/LowResIcons/KeePass_LR_R.ico"
kpIcoY="${kpRoot}/Ext/Icons_15_VA/LowResIcons/KeePass_LR_Y.ico"
fnPrepSolution()
{
cd "${kpRoot}"
local kpSln="KeePass.sln"
# Update solution format to 11 (this targets Mono 4 rather than 3.5)
sed -i 's!Format Version 10\.00!Format Version 11\.00!g' "${kpSln}"
}
fnPrepKeePass()
{
cd "${kpRoot}/KeePass"
local kpCsProj="KeePass.csproj"
sed -i 's! ToolsVersion="3\.5"!!g' "${kpCsProj}"
sed -i 's!<SignAssembly>true</SignAssembly>!<SignAssembly>false</SignAssembly>!g' "${kpCsProj}"
sed -i '/sgen\.exe/d' "${kpCsProj}"
cp -f "${kpIco}" KeePass.ico
cp -f "${kpIco}" Resources/Icons/KeePass.ico
cp -f "${kpIcoG}" Resources/Icons/KeePass_G.ico
cp -f "${kpIcoR}" Resources/Icons/KeePass_R.ico
cp -f "${kpIcoY}" Resources/Icons/KeePass_Y.ico
}
fnPrepKeePassLib()
{
cd "${kpRoot}/KeePassLib"
local kpCsProj="KeePassLib.csproj"
sed -i 's! ToolsVersion="3\.5"!!g' "${kpCsProj}"
sed -i 's!<SignAssembly>true</SignAssembly>!<SignAssembly>false</SignAssembly>!g' "${kpCsProj}"
}
fnPrepTrlUtil()
{
cd "${kpRoot}/Translation/TrlUtil"
local kpCsProj="TrlUtil.csproj"
sed -i 's! ToolsVersion="3\.5"!!g' "${kpCsProj}"
cp -f "${kpIco}" Resources/KeePass.ico
}
fnPrepSolution
fnPrepKeePass
fnPrepKeePassLib
fnPrepTrlUtil
cd "${kpBuild}"
|