Your message dated Sun, 03 Jul 2016 10:24:39 -0300
with message-id <12336040.OANAOYJrgG@luna>
and subject line Re: Bug#829329: Error combining hardening flags with Qt5
has caused the Debian Bug report #829329,
regarding Error combining hardening flags with Qt5
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)
--
829329: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=829329
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: libqt5core5a
Version: 5.6.1+dfsg-3
Severity: normal
I'm trying to enable Qt5 support for the lyx package I maintain.
I have already enabled hardening flags, and I get the following error when
building the package:
g++ -DHAVE_CONFIG_H -I. -I../../../src/support -I../.. -Wall -Wextra
-I../../../src/support/.. -DQT_NO_STL -DQT_NO_KEYWORDS
-I/usr/include/x86_64 -linux-gnu/qt5/QtConcurrent
-I/usr/include/x86_64-linux-gnu/qt5
-I/usr/include/x86_64-linux-gnu/qt5/QtSvg
-I/usr/include/x86_64-linux-gnu/qt5
-I/usr/include/x86_64-linux-gnu/qt5/QtWidgets
-I/usr/include/x86_64-linux-gnu/qt5
-I/usr/include/x86_64-linux-gnu/qt5/QtGui
-I/usr/include/x86_64-linux-gnu/qt5
-I/usr/include/x86_64-linux-gnu/qt5/QtCore
-I/usr/include/x86_64-linux-gnu/qt5 -Wdate-time -D_FORTIFY_SOURCE=2
-std=c++11 -fPIC -O2 -Wno-deprecated-declarations -g -O2 -fPIE
-fstack-protector-strong -Wformat -Werror=format-security -c -o
ConsoleApplication.o ../../../src/support/ConsoleApplication.cpp
In file included from
/usr/include/x86_64-linux-gnu/qt5/QtCore/qcoreapplication.h:37:0,
from
/usr/include/x86_64-linux-gnu/qt5/QtCore/QCoreApplication:1,
from
../../../src/support/../support/ConsoleApplicationPrivate.h:16,
from ../../../src/support/ConsoleApplication.cpp:15:
/usr/include/x86_64-linux-gnu/qt5/QtCore/qglobal.h:1087:4: error:
#error "You must build your code with position independent code if Qt
was built with -reduce-relocations. " "Compile your code with -fPIC
(-fPIE is not enough)."
# error "You must build your code with position independent code if
Qt was built with -reduce-relocations. "\
^
By default, -fPIC is used for shared libraries and -fPIE for
executables such as lyx. The latter takes precedence as it is later in
the argument list.
I can get away with the problem if I append -fPIC to CXXFLAGS but I
think this is not the proper solution, but a workaround.
A similar issue was reported also on Bug: #828878 and the fix was the
aforementioned workaround.
Kind regards,
Nick
--
=Do-
N.AND
--- End Message ---
--- Begin Message ---
Hi Nikos!
On domingo, 3 de julio de 2016 2:52:15 A. M. ART Nikos Andrikos wrote:
> reopen -1
> thanks
In the future please do not reopen a bug like this except you have a very good
reason to say that there is really a bug.
> Hi Lisandro,
>
> The -fPIE flags comes from the automatically generated hardening
> options, which override the the -fPIC flag that comes from lyx
> Makefile, since it comes later in the argument list.
[snip]
> This means that every package that uses qt5 and enables hardening
> flags that include +pie (true by default for =all) will encounter this
> issue and the maintainers will need to append -fPIC as a workaround.
>
> If -fPIC is needed by design for qt5, then the issue (even as a
> wishlist) is in dpkg-buildflags.
> What do you think?
On domingo, 3 de julio de 2016 11:21:48 A. M. ART Nikos Andrikos wrote:
> Hi Dmitry,
[snip]
> The reason for this bug report is that packages that use qt5 with
> hardening flags will encounter this issue, exactly as the other bug I
> mentioned in my original report.
> I think this should be addressed more generally, without each
> maintainer needing to go through the process of trying to debug why
> enabling hardening flags might break builds with qt5 and coming up
> with this workaround.
>
> If you that this is too much of a hassle to address properly and it is
> preferable to just work around it each time it happens, then we can
> close this bug and I'm fine with it.
Let's get things straight:
- Qt *requires* stuff using it using -fPIC. This is by design and not a bug.
- -fPIC implies all what -fPIE does and something more.
- Hardening flags are there to set up a *minimum* of flags to improve a
binaries' hardening, but *not* the exact set of flags a maintainer should use
in his/her package.
- It is not a Qt bug that a compiler does not supports both flags being
passed.
- I'm pretty sure there is a good reason to not consider the above a compiler
bug.
So it's up to the maintainer's task to set up the correct set of flags for the
package [s]he is maintaining, in the same way [s]he does for the package's
relationships with other packages.
Hope that makes it clear.
Kinds regards, Lisandro.
--
7: Hay diferencia entre "cortar" un archivo y "borrarlo" o "eliminarlo"
* Depende cuando se "cuelgue" Windows
Damian Nadales
http://mx.grulic.org.ar/lurker/message/20080307.141449.a70fb2fc.es.html
Lisandro Damián Nicanor Pérez Meyer
http://perezmeyer.com.ar/
http://perezmeyer.blogspot.com/
signature.asc
Description: This is a digitally signed message part.
--- End Message ---