Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 5 Apr 2014 14:24:07 GMT
From:      Pawel Pekala <pawel@FreeBSD.org>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/188287: [PATCH] Mk/Uses/qmake.mk reset default qmake cflags settings
Message-ID:  <201404051424.s35EO7ar037933@cgiserv.freebsd.org>
Resent-Message-ID: <201404051430.s35EU0QX021708@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         188287
>Category:       ports
>Synopsis:       [PATCH] Mk/Uses/qmake.mk reset default qmake cflags settings
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sat Apr 05 14:30:00 UTC 2014
>Closed-Date:
>Last-Modified:
>Originator:     Pawel Pekala
>Release:        10.0
>Organization:
>Environment:
FreeBSD caprica.slowicza.org 10.0-STABLE FreeBSD 10.0-STABLE #2 r262297: Fri Feb 21 17:42:25 CET 2014     root@caprica.slowicza.org:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
Qmake's default settings break our CFLAGS policy. In current state qmake
adds cflags to our global ones.

QMAKE_CFLAGS_RELEASE and QMAKE_CXXFLAGS_RELEASE are set to '-O2' by default

So when our cflags is '-O2 -pipe -fno-strict-aliasing' after generating Makefile from pro file it is '-O2 -pipe -fno-strict-aliasing -O2' and our global cflags
are tainted.

QMAKE_CFLAGS_DEBUG and QMAKE_CXXFLAGS_DEBUG are set to '-g', but I think is
good practice to reset them too.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

Index: qmake.mk
===================================================================
--- qmake.mk	(wersja 350228)
+++ qmake.mk	(kopia robocza)
@@ -61,6 +61,10 @@
 		QMAKE_CFLAGS="${CFLAGS}" \
 		QMAKE_CXXFLAGS="${CXXFLAGS}" \
 		QMAKE_LFLAGS="${LDFLAGS}" \
+		QMAKE_CFLAGS_DEBUG="" \
+		QMAKE_CFLAGS_RELEASE="" \
+		QMAKE_CXXFLAGS_DEBUG="" \
+		QMAKE_CXXFLAGS_RELEASE="" \
 		PREFIX="${PREFIX}"
 
 .if defined(WITH_DEBUG)


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201404051424.s35EO7ar037933>