This is the mail archive of the
cygwin-apps
mailing list for the Cygwin project.
Re: [PATCH 2/4] setup.exe
>From a8ffe947b5e64b9f29cecc8c404d0d508ab7be67 Mon Sep 17 00:00:00 2001
From: Achim Gratz
Date: Fri, 18 Jan 2013 14:33:29 +0100
Subject: [PATCH 2/4] Makefile: additional targets "strip" and "upx"
* setup/Makefile.am: Provide new targets "strip" and "upx" to remove
debugging symbols and compress the executable using UPX,
respectively. Check for an executable "upx" in path and bail with a
warning message if not found.
* setup/README: Change the description of how to produce stripped and
compressed binaries to use the new make targets.
---
setup/Makefile.am | 11 +++++++++++
setup/README | 9 +++++----
2 files changed, 16 insertions(+), 4 deletions(-)
diff --git a/setup/Makefile.am b/setup/Makefile.am
index 7bd4546..6d06f01 100755
--- a/setup/Makefile.am
+++ b/setup/Makefile.am
@@ -299,3 +299,14 @@ setup-src:
sort | tar -T - -cjf ${CURDIR}/$$ver-src.tar.bz2;\
echo $$ver-src.tar.bz2; exec rm -f $$ver
+# optional: strip and compress executable
+.PHONY: strip upx
+
+strip: all
+ $(STRIP) -s setup$(EXEEXT)
+upx: strip
+ @if [ -e `which upx` ]; then\
+ upx -9 setup$(EXEEXT) ;\
+ else \
+ echo "UPX doesn't seem to be installed, cannot compress setup$(EXEEXT)." ;\
+ fi
diff --git a/setup/README b/setup/README
index f6eb520..e70965f 100755
--- a/setup/README
+++ b/setup/README
@@ -38,10 +38,11 @@ Build commands:
2) $ make
3) Wondering why your binary is so much bigger than the official releases?
- Remove debugging symbols:
- $ strip -s setup.exe
- Compress using UPX:
- $ upx -9 setup.exe
+ This removes debugging symbols:
+ $ make strip
+ This additionally compresses it using UPX
+ (requires package upx to be installed):
+ $ make upx
CODING GUIDELINES:
------------------
--
1.8.1.1
Achim.
--
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+
SD adaptations for KORG EX-800 and Poly-800MkII V0.9:
http://Synth.Stromeko.net/Downloads.html#KorgSDada