mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-16 04:35:45 +02:00
Bug 572878: Rewrite signing of dlls to preserve full file name
This is a fixup of the previous commits which has some basic shell errors Change-Id: I9572148d0fa9c6fdad5c6e256d6ccabaed9c8a9c
This commit is contained in:
parent
2ec6d64b1b
commit
02286a6a34
2 changed files with 30 additions and 10 deletions
|
@ -12,7 +12,7 @@
|
||||||
# QNX Software Systems - initial API and implementation
|
# QNX Software Systems - initial API and implementation
|
||||||
# Torbjörn Svensson - Bug 521515 - Adopted jenkins build
|
# Torbjörn Svensson - Bug 521515 - Adopted jenkins build
|
||||||
#*******************************************************************************/
|
#*******************************************************************************/
|
||||||
|
SHELL=/bin/bash -o pipefail
|
||||||
ifeq ($(JAVA_HOME),)
|
ifeq ($(JAVA_HOME),)
|
||||||
$(error JAVA_HOME not set in environment)
|
$(error JAVA_HOME not set in environment)
|
||||||
endif
|
endif
|
||||||
|
@ -73,12 +73,22 @@ MAC_TO_SIGN=$(OS_DIR_MACOS_X86_64)/libspawner.jnilib \
|
||||||
WIN_TO_SIGN=$(OS_DIR_WIN32_X86_64)/starter.exe \
|
WIN_TO_SIGN=$(OS_DIR_WIN32_X86_64)/starter.exe \
|
||||||
$(OS_DIR_WIN32_X86_64)/spawner.dll \
|
$(OS_DIR_WIN32_X86_64)/spawner.dll \
|
||||||
$(OS_DIR_WIN32_X86_64)/pty.dll
|
$(OS_DIR_WIN32_X86_64)/pty.dll
|
||||||
|
### This block of code also exists in native/org.eclipse.cdt.native.serial/native_src/Makefile
|
||||||
TMPDIR := $(shell mktemp -d -t production-XXXXXXXXXX)
|
TMPDIR := $(shell mktemp -d -t production-XXXXXXXXXX)
|
||||||
|
.PHONY: production
|
||||||
production: $(MAC_TO_SIGN) $(WIN_TO_SIGN)
|
production: $(MAC_TO_SIGN) $(WIN_TO_SIGN)
|
||||||
$(foreach tosign,$(MAC_TO_SIGN) $(WIN_TO_SIGN),mv $(tosign) $(TMPDIR)$(tosign) &&) true
|
set -x ; $(foreach tosign,$(MAC_TO_SIGN),\
|
||||||
$(foreach tosign,$(MAC_TO_SIGN),curl -f --silent --show-error -o $(tosign) -F file=@$(TMPDIR)$(tosign) https://cbi.eclipse.org/macos/codesign/sign &&) true
|
temp=$(TMPDIR)/$(shell basename $(tosign)) && \
|
||||||
$(foreach tosign,$(WIN_TO_SIGN),curl -f --silent --show-error -o $(tosign) -F file=@$(TMPDIR)$(tosign) https://cbi.eclipse.org/authenticode/sign &&) true
|
mv $(tosign) $$temp && \
|
||||||
$(foreach tosign,$(MAC_TO_SIGN) $(WIN_TO_SIGN),rm $(TMPDIR)$(tosign) &&) true
|
curl -f --silent --show-error -o $(tosign) -F file=@$$temp https://cbi.eclipse.org/macos/codesign/sign && \
|
||||||
|
rm $$temp && \
|
||||||
|
) true
|
||||||
|
set -x ; $(foreach tosign,$(WIN_TO_SIGN),\
|
||||||
|
temp=$(TMPDIR)/$(shell basename $(tosign)) && \
|
||||||
|
mv $(tosign) $$temp && \
|
||||||
|
curl -f --silent --show-error -o $(tosign) -F file=@$$temp https://cbi.eclipse.org/authenticode/sign && \
|
||||||
|
rm $$temp && \
|
||||||
|
) true
|
||||||
rmdir $(TMPDIR)
|
rmdir $(TMPDIR)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
# QNX Software Systems - initial API and implementation
|
# QNX Software Systems - initial API and implementation
|
||||||
# Alex Blewitt - MacOSX with a 64-bit vm
|
# Alex Blewitt - MacOSX with a 64-bit vm
|
||||||
#*******************************************************************************/
|
#*******************************************************************************/
|
||||||
|
SHELL=/bin/bash -o pipefail
|
||||||
ifeq ($(JAVA_HOME),)
|
ifeq ($(JAVA_HOME),)
|
||||||
$(error Please define JAVA_HOME)
|
$(error Please define JAVA_HOME)
|
||||||
endif
|
endif
|
||||||
|
@ -49,12 +49,22 @@ clean :
|
||||||
|
|
||||||
MAC_TO_SIGN=$(OS_DIR)/macosx/x86_64/libserial.jnilib
|
MAC_TO_SIGN=$(OS_DIR)/macosx/x86_64/libserial.jnilib
|
||||||
WIN_TO_SIGN=$(OS_DIR)/win32/x86_64/serial.dll
|
WIN_TO_SIGN=$(OS_DIR)/win32/x86_64/serial.dll
|
||||||
|
### This block of code also exists in core/org.eclipse.cdt.core.native/native_src/Makefile
|
||||||
TMPDIR := $(shell mktemp -d -t production-XXXXXXXXXX)
|
TMPDIR := $(shell mktemp -d -t production-XXXXXXXXXX)
|
||||||
|
.PHONY: production
|
||||||
production: $(MAC_TO_SIGN) $(WIN_TO_SIGN)
|
production: $(MAC_TO_SIGN) $(WIN_TO_SIGN)
|
||||||
$(foreach tosign,$(MAC_TO_SIGN) $(WIN_TO_SIGN),mv $(tosign) $(TMPDIR)$(tosign) &&) true
|
set -x ; $(foreach tosign,$(MAC_TO_SIGN),\
|
||||||
$(foreach tosign,$(MAC_TO_SIGN),curl -f --silent --show-error -o $(tosign) -F file=@$(TMPDIR)$(tosign) https://cbi.eclipse.org/macos/codesign/sign &&) true
|
temp=$(TMPDIR)/$(shell basename $(tosign)) && \
|
||||||
$(foreach tosign,$(WIN_TO_SIGN),curl -f --silent --show-error -o $(tosign) -F file=@$(TMPDIR)$(tosign) https://cbi.eclipse.org/authenticode/sign &&) true
|
mv $(tosign) $$temp && \
|
||||||
$(foreach tosign,$(MAC_TO_SIGN) $(WIN_TO_SIGN),rm $(TMPDIR)$(tosign) &&) true
|
curl -f --silent --show-error -o $(tosign) -F file=@$$temp https://cbi.eclipse.org/macos/codesign/sign && \
|
||||||
|
rm $$temp && \
|
||||||
|
) true
|
||||||
|
set -x ; $(foreach tosign,$(WIN_TO_SIGN),\
|
||||||
|
temp=$(TMPDIR)/$(shell basename $(tosign)) && \
|
||||||
|
mv $(tosign) $$temp && \
|
||||||
|
curl -f --silent --show-error -o $(tosign) -F file=@$$temp https://cbi.eclipse.org/authenticode/sign && \
|
||||||
|
rm $$temp && \
|
||||||
|
) true
|
||||||
rmdir $(TMPDIR)
|
rmdir $(TMPDIR)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue