From: Jason Boyer Date: Sun, 7 Jan 2018 03:21:09 +0000 (-0500) Subject: LP1741309: Correct installed file permission X-Git-Tag: v0.3.2~24 X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=8bfe98456cc67be435c89221e3c53e05e469c597;p=Hatch.git LP1741309: Correct installed file permission Because of the machinations of the _ReplaceInFile macro the extension host JSON file does not inherit permissions correctly. Adding the AccessControl NSIS plugin and using the EnableFileInheritance function corrects this. Signed-off-by: Jason Boyer Signed-off-by: Chris Sharp --- diff --git a/installer/windows/AccessControl.dll b/installer/windows/AccessControl.dll new file mode 100755 index 0000000..0de0324 Binary files /dev/null and b/installer/windows/AccessControl.dll differ diff --git a/installer/windows/defines.nsh b/installer/windows/defines.nsh index e311794..8afcac3 100644 --- a/installer/windows/defines.nsh +++ b/installer/windows/defines.nsh @@ -14,7 +14,7 @@ ; Version numbers should be integers !define VERSIONMAJOR 0 !define VERSIONMINOR 1 -!define VERSIONBUILD 3 +!define VERSIONBUILD 5 !define FULLVERSION "${VERSIONMAJOR}.${VERSIONMINOR}.${VERSIONBUILD}" ;--------------------------- ; Add Remove info diff --git a/installer/windows/hatch.nsi b/installer/windows/hatch.nsi index 91d1db3..54adc2b 100644 --- a/installer/windows/hatch.nsi +++ b/installer/windows/hatch.nsi @@ -25,8 +25,11 @@ !include ReplaceInFile.nsh ;--------------------------------------------------------------- +; Add local copy of AccessControl plugin +!addplugindir . + ; Installer's filename -Outfile "${APPNAME} Installer.exe" +Outfile "${APPNAME} Installer ${FULLVERSION}.exe" RequestExecutionLevel admin @@ -174,6 +177,7 @@ section "install" ; Set path variable in org.ils_evergreen.hatch.json to $INSTDIR\hatch.bat ${StrRep} '$0' '$INSTDIR' '\' '\\' !insertmacro _ReplaceInFile "$INSTDIR\extension\host\org.evergreen_ils.hatch.json" "/path/to/hatch.sh" "$0\\hatch.bat" + AccessControl::EnableFileInheritance "$INSTDIR\extension\host\org.evergreen_ils.hatch.json" ; Uninstaller writeUninstaller "$INSTDIR\Uninstall ${APPNAME}.exe"