[Hostname-devel] [SCM] Git repository for hostname branch, master, updated. debian/3.09-1-g9f4d05e
Michael Meskes
meskes at debian.org
Sun Jan 15 12:53:58 UTC 2012
The following commit has been merged in the master branch:
commit 9f4d05e5f3c3ed77522fdc6511ffd95ff21f3d9c
Author: Michael Meskes <meskes at debian.org>
Date: Sun Jan 15 13:51:32 2012 +0100
Enabled hardened build flag
Closes: #655874
Thanks: Moritz Muehlenhoff <jmm at debian.org>
diff --git a/Makefile b/Makefile
index c3cac06..078e34a 100644
--- a/Makefile
+++ b/Makefile
@@ -6,7 +6,7 @@ CFLAGS+=-O2 -Wall
OBJS=hostname.o
hostname: $(OBJS)
- $(CC) $(CFLAGS) -o $@ $(OBJS) -lnsl
+ $(CC) $(CFLAGS) -o $@ $(OBJS) $(LDFLAGS) -lnsl
ln -fs hostname dnsdomainname
ln -fs hostname domainname
ln -fs hostname ypdomainname
diff --git a/debian/changelog b/debian/changelog
index be2c5c2..7243bb3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+hostname (3.10) unstable; urgency=low
+
+ * Enabled hardened build flag.
+ Thanks to Moritz Muehlenhoff <jmm at debian.org> (Closes: #655874)
+
+ -- Michael Meskes <meskes at debian.org> Sun, 15 Jan 2012 13:52:38 +0100
+
hostname (3.09) unstable; urgency=low
* Order items alphabetically in manpage.
diff --git a/debian/rules b/debian/rules
index 14aa22b..09b46a3 100755
--- a/debian/rules
+++ b/debian/rules
@@ -6,13 +6,10 @@
DEBVERSION := $(shell dpkg-parsechangelog | awk '/Version:/ { print substr($$2,1,4)}')
PRGVERSION := $(shell awk '/define VERSION/ { print substr($$3,2,length($$3)-2)}' hostname.c)
-CFLAGS = -Wall -g
-
-ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
- CFLAGS += -O0
-else
- CFLAGS += -O2
-endif
+CFLAGS = `dpkg-buildflags --get CFLAGS`
+CFLAGS += -Wall
+LDFLAGS = `dpkg-buildflags --get LDFLAGS`
+CPPFLAGS = `dpkg-buildflags --get CPPFLAGS`
DEB_HOST_GNU_TYPE=$(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE=$(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
@@ -31,7 +28,7 @@ build-stamp:
# Building package
[ "$(DEBVERSION)" = "$(PRGVERSION)" ] || exit 1
- CFLAGS="$(CFLAGS)" $(MAKE) $(CROSS)
+ CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" LDFLAGS="$(LDFLAGS)" $(MAKE) $(CROSS)
touch build-stamp
diff --git a/hostname.c b/hostname.c
index 79cb4e7..3ff164a 100644
--- a/hostname.c
+++ b/hostname.c
@@ -45,7 +45,7 @@
#include <err.h>
#include <rpcsvc/ypclnt.h>
-#define VERSION "3.09"
+#define VERSION "3.10"
enum type_t { DEFAULT, DNS, FQDN, SHORT, ALIAS, IP, NIS, NIS_DEF, ALL_FQDNS, ALL_IPS };
--
Git repository for hostname
More information about the Hostname-devel
mailing list