diff options
author | Max Kellermann <max@duempel.org> | 2008-11-07 13:42:31 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-11-07 13:42:31 +0100 |
commit | b2617354f437ac905057f521b47b8be6c3addcd1 (patch) | |
tree | 0f468e9782d88a1c98212224a6f11e8122e812c6 /src/Makefile.am | |
parent | 9f05576990bca5fc8aeebe2fd84a11d78d87f72a (diff) | |
download | mpd-b2617354f437ac905057f521b47b8be6c3addcd1.tar.gz mpd-b2617354f437ac905057f521b47b8be6c3addcd1.tar.xz mpd-b2617354f437ac905057f521b47b8be6c3addcd1.zip |
Makefile.am: added custom rule with -fwhole-program
To make the ncmpc binary even smaller, you can compile all sources at
once with "--combine -fwhole-program". Unfortunately, automake does
not support this mode. For further experiments, this patch adds a
custom rule which creates the binary named "ncmpc-tiny" this way.
Diffstat (limited to '')
-rw-r--r-- | src/Makefile.am | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index 4664630e5..bd0168f5a 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,3 +1,5 @@ +CLEANFILES = ncmpc-tiny + AM_CPPFLAGS = \ $(GLIB_CFLAGS)\ $(GTHREAD_CFLAGS)\ @@ -101,6 +103,10 @@ endif ncmpc_SOURCES+=${ncmpc_headers} +# build the smalles possible ncmpc binary +ncmpc-tiny: $(filter-out %.h,$(ncmpc_SOURCES)) + $(COMPILE) --combine -fwhole-program $(ncmpc_LDFLAGS) $(ncmpc_LDADD) $(LIBS) $^ -o $@ + strip --strip-all $@ # # sparse |