On 22.04.2014, at 17:19, Alexander Hansen <alexanderk.han...@gmail.com> wrote:

> On 4/22/14, 8:12 AM, Max Horn wrote:

[...]

> 
> It can and does work for clang versions other than the one for Xcode 5.0 
> because I tested it against clang from Xcode 4.6.3 and clang from Xcode 5.1.0 
> (and missed 5.0.x).

Well, it cannot work for clang in Xcode 5.0.x... so I see no contradiction here.

>  You somehow still have the compiler_wrapper from fink-0.36.4;

I did nothing fancy to update, just a "cvs up" followed by a "fink update-all". 
If it happened for me, it is highly likely to happen for other people, too. 

Aha, and looking at the code, that's pretty much guaranteed to be the reason: 
Because unlike a "fink selfupdate", this process does *not* restart fink after 
updating fink. So this happens:

* fink rebuilds fink
* fink installs the new fink.deb; the postinst script is triggered, which 
removes the clang wrapper
* the old fink is still running and updates some other package
* this recreates the "old" wrapper.


So this would have been avoided if I did run "fink selfupdate". But there might 
be other ways to trigger this or similar breakage. Hence I think it would be 
preferable if things were arranged in a way that such problems are impossible 
by design.

So, why don't we simply re-create the wrapper each time we start a build 
process? Of course, care must be taken to not affect concurrent build 
processes... but this could be achieved by creating per-package wrappers on the 
fly for each build. That shouldn't be too hard. E.g. when preparing the build, 
we create %b/../bin/clang etc. and then add this to the build-time PATH, just 
like we add %p/var/lib/fink/path-prefix-clang/compiler_wrapper

Hmm, that said... why exactly are those wrappers not part of the .deb to begin 
with? That would be even simpler, wouldn't it?


Cheers,
Max


> in fink-0.36.4.1 the test is strictly against the clang version instead:
> 
> if [[ "`clang --version | head -n1 | cut -d- -f2 | cut -d')' -f1`" < 
> "503.0.38" ]]; then
>        suppress_hard_error=""
> else
> suppress_hard_error="-Wno-error=unused-command-line-argument-hard-error-in-future"
> 
> -- 
> Alexander Hansen, Ph.D.
> Fink User Liaison
> My package updates: http://finkakh.wordpress.com/
> 

Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

------------------------------------------------------------------------------
Start Your Social Network Today - Download eXo Platform
Build your Enterprise Intranet with eXo Platform Software
Java Based Open Source Intranet - Social, Extensible, Cloud Ready
Get Started Now And Turn Your Intranet Into A Collaboration Platform
http://p.sf.net/sfu/ExoPlatform
_______________________________________________
fink-core mailing list
fink-core@lists.sourceforge.net
List archive:
http://news.gmane.org/gmane.os.apple.fink.core
Subscription management:
https://lists.sourceforge.net/lists/listinfo/fink-core

Reply via email to