Skip to content

Commit

Permalink
please.sh build git: use the signtool alias when available
Browse files Browse the repository at this point in the history
In git-for-windows/MINGW-packages@4ddc5d6 we
changed the process to build the mingw-w64-git packages to allow for
code-signing by setting the SIGNTOOL environment variable to an
appropriate command-line that just needs the file names as additional
arguments.

Since we already have code in please.sh that expects an optional signtool
configuration as alias, let's just reuse that, if available.

This helps in environments where Windows File Protection is enabled, which
suffers greatly when being used with unsigned .exe files (everything gets
super slow).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
  • Loading branch information
dscho committed Aug 24, 2016
1 parent 676bef4 commit 3e9b835
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion please.sh
Original file line number Diff line number Diff line change
Expand Up @@ -289,9 +289,18 @@ pkg_build () {
die "Could not edit tag\n"
fi


if test -z "$(git --git-dir="$sdk64/usr/src/build-extra/.git" \
config alias.signtool)"
then
extra=
else
extra="SIGNTOOL=\"git --git-dir=\\\"$sdk64/usr/src"
extra="$extra/build-extra/.git\\\" signtool\" "
fi
"$sdk/git-cmd.exe" --command=usr\\bin\\sh.exe -l -c \
'MAKEFLAGS=-j5 MINGW_INSTALLS=mingw32\ mingw64 \
makepkg-mingw -s --noconfirm &&
'"$extra"'makepkg-mingw -s --noconfirm &&
MINGW_INSTALLS=mingw64 makepkg-mingw --allsource' ||
die "%s: could not build\n" "$sdk/$pkgpath"

Expand Down

0 comments on commit 3e9b835

Please sign in to comment.