Bug 625504 - qtcurve-gtk2 not built with $RPM_OPT_FLAGS
qtcurve-gtk2 not built with $RPM_OPT_FLAGS
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: qtcurve-gtk2 (Show other bugs)
rawhide
All Linux
low Severity medium
: ---
: ---
Assigned To: Thomas Janssen
Fedora Extras Quality Assurance
: Triaged
Depends On:
Blocks: DebugInfo
  Show dependency treegraph
 
Reported: 2010-08-19 12:29 EDT by Ville Skyttä
Modified: 2010-11-19 17:32 EST (History)
6 users (show)

See Also:
Fixed In Version: qtcurve-gtk2-1.7.0-1.fc14
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-11-19 17:32:19 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Ville Skyttä 2010-08-19 12:29:13 EDT
qtcurve-gtk2 1.5.2-1 is not built with $RPM_OPT_FLAGS, see the gcc line(s) in build output.

http://kojipkgs.fedoraproject.org/packages/qtcurve-gtk2/1.5.2/1.fc15/data/logs/i686/build.log
Comment 1 Ville Skyttä 2010-09-27 14:43:06 EDT
Problem still persists in 1.6.3-1.

http://kojipkgs.fedoraproject.org/packages/qtcurve-gtk2/1.6.3/1.fc15/data/logs/x86_64/build.log
Comment 2 Rex Dieter 2010-09-27 15:29:09 EDT
Looks like a generalized cmake problem.

The default %cmake macro ends up building with only '-O3 -NDEBUG' flags, which comes from
/usr/share/cmake/Platform/*.cmake

To address this, there are several (not necessarily mutually exclusive) options off the top of my head:

1.  munge the /usr/share/cmake/Platform/*.cmake stuff to include fedora's default $RPM_OPT_FLAGS

2.  modify %cmake macro to define the various,
CMAKE_C_FLAGS
CMAKE_CXX_FLAGS

some other better ideas?
Comment 3 Orion Poplawski 2010-09-27 23:29:29 EDT
I don't think so.  A simple cmake project will happily take the CFLAGS/CXXFLAGS environment variables.  qtcurve-gtk2 must be doing something to ignore/override them.

Here you go:

QtCurve-Gtk2-1.6.3/style/CMakeLists.txt:set(CMAKE_C_FLAGS "${GTK_CFLAGS}")
Comment 4 Rex Dieter 2010-09-28 12:52:47 EDT
Good catch, ugh, coulda swore my greping for FLAG munging in qtcurve came up empty.
Comment 5 Rex Dieter 2010-09-28 16:22:24 EDT
OK, closer, by changing the above to
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${GTK_CFLAGS}")

I'm seeing,
cd /home/rdieter1/pkgs.fedoraproject.org/qtcurve-gtk2/QtCurve-Gtk2-1.6.3/x86_64-redhat-linux-gnu/style && /usr/lib64/ccache/gcc  -Dqtcurve_EXPORTS -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -pthread -I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -O3 -DNDEBUG -fPIC -I/home/rdieter1/pkgs.fedoraproject.org/qtcurve-gtk2/QtCurve-Gtk2-1.6.3 -I/home/rdieter1/pkgs.fedoraproject.org/qtcurve-gtk2/QtCurve-Gtk2-1.6.3/x86_64-redhat-linux-gnu/style -I/home/rdieter1/pkgs.fedoraproject.org/qtcurve-gtk2/QtCurve-Gtk2-1.6.3/common -I/home/rdieter1/pkgs.fedoraproject.org/qtcurve-gtk2/QtCurve-Gtk2-1.6.3/x86_64-redhat-linux-gnu   -DQTC_MOZILLA_DIR=\"/usr/share/themes/QtCurve/mozilla\" -o CMakeFiles/qtcurve.dir/qtcurve.o   -c /home/rdieter1/pkgs.fedoraproject.org/qtcurve-gtk2/QtCurve-Gtk2-1.6.3/style/qtcurve.c


ie, -O3 -DNDEBUG still being added, -O3 in particular overriding our default -O2
Comment 6 Ville Skyttä 2010-09-29 02:19:39 EDT
(In reply to comment #5)
> ie, -O3 -DNDEBUG still being added, -O3 in particular overriding our default
> -O2

http://fedoraproject.org/wiki/Packaging:Guidelines#Compiler_flags

If you ask me, -O3 a _much_ smaller concern than the previously missing security related options and faulty debuginfo, and as far as I'm concerned there's no need to keep this bug open because of that (be sure to read the guidelines above though).  -DNDEBUG is possibly quite desirable to have there, with caveat: haven't looked at the source, this is just based on experience with other packages.
Comment 7 Fedora Update System 2010-11-11 07:53:53 EST
qtcurve-gtk2-1.7.0-1.fc14,qtcurve-kde4-1.7.0-1.fc14 has been submitted as an update for Fedora 14.
https://admin.fedoraproject.org/updates/qtcurve-gtk2-1.7.0-1.fc14,qtcurve-kde4-1.7.0-1.fc14
Comment 8 Fedora Update System 2010-11-11 17:16:01 EST
qtcurve-gtk2-1.7.0-1.fc14, qtcurve-kde4-1.7.0-1.fc14 has been pushed to the Fedora 14 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update qtcurve-gtk2 qtcurve-kde4'.  You can provide feedback for this update here: https://admin.fedoraproject.org/updates/qtcurve-gtk2-1.7.0-1.fc14,qtcurve-kde4-1.7.0-1.fc14
Comment 9 Fedora Update System 2010-11-19 17:32:09 EST
qtcurve-gtk2-1.7.0-1.fc14, qtcurve-kde4-1.7.0-1.fc14 has been pushed to the Fedora 14 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.