Bug#673449: lintian: fix Ubuntu compatibility in binaries-hardening test
Package: lintian
Version: 2.5.7
Severity: normal
Tags: patch
User: ubuntu-devel@lists.ubuntu.com
Usertags: origin-ubuntu quantal ubuntu-patch
*** /tmp/tmphAWAWQ/bug_body
In Ubuntu, the attached patch was applied to achieve the following:
* t/tests/binaries-hardening/debian/Makefile: stack protector and relro
are enabled by default in Ubuntu. Make sure we specifically disable
them to properly test lintian.
Thanks for considering the patch.
-- System Information:
Debian Release: wheezy/sid
APT prefers precise-updates
APT policy: (500, 'precise-updates'), (500, 'precise-security'), (500, 'precise-proposed'), (500, 'precise')
Architecture: amd64 (x86_64)
Kernel: Linux 3.2.0-24-generic (SMP w/4 CPU cores)
Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
diff -Nru lintian-2.5.7/t/tests/binaries-hardening/debian/Makefile lintian-2.5.7ubuntu1/t/tests/binaries-hardening/debian/Makefile
--- lintian-2.5.7/t/tests/binaries-hardening/debian/Makefile 2012-05-12 17:04:48.000000000 -0400
+++ lintian-2.5.7ubuntu1/t/tests/binaries-hardening/debian/Makefile 2012-05-18 14:01:58.000000000 -0400
@@ -1,6 +1,10 @@
all: weak.1 strong.1
# Build without dpkg-buildflags.
- gcc -o weak hello.c
+ gcc -o weak \
+ -fno-stack-protector \
+ -Wl,-z,norelro \
+ -U_FORTIFY_SOURCE \
+ hello.c
gcc -o strong \
$(shell dpkg-buildflags --get CPPFLAGS) \
$(shell dpkg-buildflags --get CFLAGS) \
Reply to: