From 0495bb6a17cfd70ae36946e61ff3de0e87d6e9a7 Mon Sep 17 00:00:00 2001 From: "Ira W. Snyder" Date: Thu, 17 Jan 2008 18:01:37 -0800 Subject: [PATCH] Add ability to build in "see what symbols aren't used" mode This is a very performance-degrading option, if turned on. Luckily, it's only at build time. Since this project isn't autoconfed yet, we'll just uncomment the proper options by hand. --- Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index c743125..e3c574a 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,10 @@ GCC=gcc + +# Normal CFLAGS CFLAGS=-ggdb -O1 -pipe -DDEBUG=1 +LDFLAGS=-Wl,-O1 -Wl,--sort-common -Wl,--as-needed +#CFLAGS=-ggdb -O1 -pipe -DDEBUG=1 -ffunction-sections -fdata-sections +#LDFLAGS=-Wl,--gc-sections -Wl,--print-gc-sections GOBJ_CFLAGS=`pkg-config --cflags gobject-2.0` GOBJ_LIBS=`pkg-config --libs gobject-2.0` @@ -11,7 +16,7 @@ ALL_LIBS=`pkg-config --libs gtk+-2.0 vte dbus-glib-1` all: tilda tilda: tilda.o tilda-window.o tilda-terminal.o tomboykeybinder.o tomboyutil.o eggaccelerators.o - $(GCC) $(CFLAGS) $^ -o $@ $(ALL_LIBS) + $(GCC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(ALL_LIBS) tilda.o: tilda.c $(GCC) $(CFLAGS) -c -o $@ $< $(ALL_CFLAGS) -- 2.34.1