Setting compilation parameter for qt within portfile

Ryan Schmidt ryandesign at macports.org
Fri Dec 2 13:12:15 PST 2011


On Dec 2, 2011, at 09:33, Nicolas Pavillon wrote:

>>> Usually you would set the optimization level using:
>>> 
>>> configure.optflags -O0
> 
> I can confirm that qmake ignores this option. In fact, I tried standard to set within the portfile (and thus through environement/configure args) cflags, cmake cflags and qt cflags, but none worked for what I tried. This is a quite inconvenient behaviour. 

If this were a portgroup that would at least give you a single place to fix it. Is there value in creating a qmake portgroup? Or does this port already use the qt portgroup, and if so can it be fixed there?


>>> Are you sure -O0 is necessary? That means all optimization will be disabled, which means the program will be slow.
> 
> I am not sure unfortunately, as I am rather blind for this problem. It occurs only on Lion, and being on SL, I am not in position to test it. It was however reported by several people that it does not build, and that setting -O0 solves the issue. To note that trying to force compilation with gcc instead of clang does not solve it. 
> 
> As it breaks the port, I would vote for taking this as a workaround, at least until another solution is found.

Agreed.



More information about the macports-dev mailing list