Merge ~paelzer/ubuntu/+source/nut:artful-bug-1540008-udevd-name-changed into ~usd-import-team/ubuntu/+source/nut:ubuntu/devel
| Status: | Merged | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Merge reported by: | Nish Aravamudan | ||||||||||||
| Merged at revision: | 5988ef43db83433c4ef38c9611b5cd67cc50e5cd | ||||||||||||
| Proposed branch: | ~paelzer/ubuntu/+source/nut:artful-bug-1540008-udevd-name-changed | ||||||||||||
| Merge into: | ~usd-import-team/ubuntu/+source/nut:ubuntu/devel | ||||||||||||
| Diff against target: |
112 lines (+65/-3) 5 files modified
debian/changelog (+16/-0) debian/libnutclient0.symbols (+2/-2) debian/nut-server.postinst (+1/-1) debian/patches/fix-snmp-driver-compile-options.patch (+45/-0) debian/patches/series (+1/-0) |
||||||||||||
| Related bugs: |
|
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Nish Aravamudan | 2017-08-16 | Approve on 2017-08-16 | |
|
Review via email:
|
|||
This proposal supersedes a proposal from 2017-08-09.
Description of the Change
This got some follow on fixes after our discussion.
Please pick up the tags and content from this branch to fix those.
| Nish Aravamudan (nacc) wrote : | # |
| Nish Aravamudan (nacc) wrote : | # |
Note this failed to build in Artful. I think it is probably unrelated to your change, but related to gcc changes? Can you check it out?
| ChristianEhrhardt (paelzer) wrote : | # |
Yeah since it is a postinst only change I doubt we affected the compilation with the upload.
Also it was building a week ago, so likely gcc7 as you expect, taking a look ...
View might first fall on:
al175.c:400:28: warning: ‘%2X’ directive output may be truncated writing between 2 and 4 bytes into a region of size between 3 and 5 [-Wformat-
But that is only a warning due to:
-Wformat-truncation being default on -Wall now [1]
But the actual "break" are errors like:
/usr/bin/ld: al175.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
Actually -fPIC was used on parts of the build pre and post gcc-7 as seen in the buildlogs [2] [3].
The root cause seems in a change that dropped the former:
"-fPIE"
options and replaced them with
-specs=
Since no change was made to nut this likely is from the toolchain upgrade.
This is kind of inverse to what I knew - like [4] where it is about enabling pie.
Did we intentionally drop that - I don't think so?
When analyzing the build it seems there are two times hardning options.
- The first one got the no-pie spec
- And the second lost the -fPIE
--- old 2017-08-16 09:14:46.667114832 +0200
+++ new 2017-08-16 09:14:47.275115931 +0200
@@ -1,15 +1,15 @@
gcc -DHAVE_CONFIG_H -I. -I../include -Wdate-time -D_FORTIFY_SOURCE=2 -I../include -DNETSNMP_
-
+-specs=
-fstack-
--fPIE
--fstack-
-/bin/bash ../libtool --tag=CC --mode=link gcc -I../include -DNETSNMP_
It almost seems to have two hardening entries one behaving one and one the other way.
I've found the source (form nut's POV) of both changes:
1. loosing -fPIE is the actual configure call changing from
CFLAGS="-g -O2 -fdebug-
to
CFLAGS="-g -O2 -fdebug-
This can be checked when comparing zesty with artful calling:
$ DEB_BUILD_
(Lets assume for now it is dropped because it is considered default anyway?)
2. gaining the no-pie spec is from net-snmp by configure
checking for Net-SNMP cflags... [...] -specs=
checking for Net-SNMP libs... [...] -specs=
While in the past this was without pie reference at all.
The options of #2 come later than #1 and so even if #1 would have -fPIE it would be disabled again.
The real source for the change ...
| ChristianEhrhardt (paelzer) wrote : | # |
Ok, I rechecked an all arch build on top of all I did and it is good now.
@nacc - please review the extra changes and upload the new version if you agree.
| ChristianEhrhardt (paelzer) wrote : | # |
Ah I see you merged this already - do you want/need a new MP or should we operate on this one reopening it?
| Nish Aravamudan (nacc) wrote : | # |
If you send a new one, based upon your current one, the history will work correctly (as I've already pushed your ubuntu3 as a upload tag and dputted). So propose a new ubuntu4, please.
| Nish Aravamudan (nacc) wrote : | # |
Upload tagged and sponsored.


Upload tagged and sponsored.