Summary: | qt4 eclasses (qt4-build, qt4-r2, qt4): CC/CXX need quoting | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Harald van Dijk (RETIRED) <truedfx> |
Component: | [OLD] Unspecified | Assignee: | Qt Bug Alias <qt> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | ahipp0 |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | escape quotes in qt4-build.eclass |
Description
Harald van Dijk (RETIRED)
2010-08-13 20:50:35 UTC
I've seen tons of ebuilds without quotes around CC/CXX, does this mean they're all broken? BTW could you show an example of CC/CXX containing spaces please? (In reply to comment #1) > I've seen tons of ebuilds without quotes around CC/CXX, does this mean they're > all broken? Possibly, but not necessarily. There are cases where quoting CC/CXX would be redundant because the shell doesn't do word splitting anyway. There are also cases where quoting CC/CXX would be wrong because you want the shell to do word splitting, because you're trying to compile something. > BTW could you show an example of CC/CXX containing spaces please? CC="/usr/bin/x86_64-pc-linux-gnu-gcc -specs=/path/to/my/custom/specs/file" But if you just want to test to see what fails and doesn't, you can just as easily use CC="/usr/bin/env gcc". If you do try this, by the way, and notice something breaks, please don't file bug reports here if the wrong quoting is in the upstream package. I'm not going to do that either; those bugs can just go upstream. :) (In reply to comment #2) Thanks a lot for the explanation! I suppose eqmake4 is broken in a similar way then... around line 252 of qt4-r2.eclass: QMAKE_CC=$(tc-getCC) \ QMAKE_CXX=$(tc-getCXX) \ QMAKE_LINK=$(tc-getCXX) \ Yes, thanks, those should be updated too, in both the qt4-r2 and qt4 eclasses. Fixed. I didn't fix qt4.eclass because it is deprecated anyway (In reply to comment #5) > Fixed. I didn't fix qt4.eclass because it is deprecated anyway Looks like the fix [1] is incorrect for qt4-build.eclass. Each quote inside sed argument must be escaped with a backslash. Let's look through the changesets more carefully: sed -e "s:\(\$MAKE\):\1 CC="$(tc-getCC)" CXX="$(tc-getCXX)" LD="$(tc-getCXX)" LINK="$(tc-getCXX)":g" It is actually (except spaces): sed -e "s:\(\$MAKE\):\1 CC=" \ $(tc-getCC) \ " CXX=" \ $(tc-getCXX) \ " LD=" \ $(tc-getCXX) \ " LINK=" \ $(tc-getCXX) \ ":g" [1] http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/eclass/qt4-build.eclass?r1=1.80&r2=1.82 Created attachment 246369 [details, diff]
escape quotes in qt4-build.eclass
I would like to reopen this bug, but I guess, I can't do it.:( Reopening per request Someone fix this please, it's trivial. Ugh, fixed now. Sorry for taking this long for something as trivial as this... Hope we got it right this time. |