]> rtime.felk.cvut.cz Git - sojka/sterm.git/commitdiff
Compile with debug information and strip them during install 20160921
authorMichal Sojka <sojkam1@fel.cvut.cz>
Wed, 21 Sep 2016 14:33:23 +0000 (16:33 +0200)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Wed, 21 Sep 2016 14:33:23 +0000 (16:33 +0200)
Debian automatically creates debug symbol package of the binary is
compiled with debug information. If it is compiled without -g, lintian
warns about empty debug symbols.

Makefile
debian/rules

index 8636bce5387a7b61a14bcd3d1b858463aa47b58c..2cc363c84a0090c45235e75c9c8642e738d27431 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,8 @@
-CFLAGS = -O2 -Wall
+CFLAGS = -O2 -Wall -g
 LDLIBS = -llockdev
 
 PREFIX ?= /usr/local
+INSTALL ?= install -s
 
 all: sterm
 
@@ -9,10 +10,10 @@ clean:
        rm -f sterm
 
 install: all
-       install -d $(DESTDIR)$(PREFIX)/bin
-       install -m 755 sterm $(DESTDIR)$(PREFIX)/bin
+       $(INSTALL) -d $(DESTDIR)$(PREFIX)/bin
+       $(INSTALL) -m 755 sterm $(DESTDIR)$(PREFIX)/bin
 ifneq ($(NO_MAN),1)
-       install -d $(DESTDIR)$(PREFIX)/share/man/man1
-       install -m 644 sterm.man $(DESTDIR)$(PREFIX)/share/man/man1/sterm.1
+       $(INSTALL) -d $(DESTDIR)$(PREFIX)/share/man/man1
+       $(INSTALL) -m 644 sterm.man $(DESTDIR)$(PREFIX)/share/man/man1/sterm.1
        gzip -f $(DESTDIR)$(PREFIX)/share/man/man1/sterm.1
 endif
index 9fffce80bfaad63593f866cc7f2f964141177051..3fde8d78a112349e424a007e9f75fd0bc3fe9322 100755 (executable)
@@ -19,6 +19,7 @@ include /usr/share/dpkg/default.mk
 # Variables to pass to sterm Makefile
 export PREFIX=/usr
 export NO_MAN=1
+export INSTALL=install # Do not strip - this will be handled by dh_strip
 
 # main packaging script based on dh7 syntax
 %: