-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Jean-François Mertens wrote:
> Apparently, several sources have a hardcoded "/sw/" in them,
> which can wreak havoc when there is both a "/sw" tree on the machine
> and some other fink tree _ could be the private "sw" tree in some
> (possibly non-privileged) user's home dir, or a system-wide "swXY"
> or "/usr/local" tree ...
>
> For example, in the build-dir of emacs23, the following lines
> break everything if e.g. there is both a "sw" tree and another one
> (say "sw64"), and when working in the second ..
> (In this case, it visibly pre-pends completely wrong search dirs
> to all commands ..)
> Such crosstalk must be avoided ...
>
>> # fgrep -n -C1 "I/sw/include -L/sw/lib" configure*
>> configure-2493- if test -d /sw/include && test -d /sw/lib; then
>> configure:2494: GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
>> configure-2495- CPP="${CPP} ${GCC_TEST_OPTIONS}"
>> --
>> configure.in-388- if test -d /sw/include && test -d /sw/lib; then
>> configure.in:389: GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
>> configure.in-390- CPP="${CPP} ${GCC_TEST_OPTIONS}"
>
> Adding the following avoids it, and seems to lead to a sucessfull build
> (in either tree):
>
>> PatchScript: <<
>> %{default_script}
>> sed -i'' -e 's,-I/sw/include -L/sw/lib,,' configure{,.in}
>> <<
> Even for pkgs where this would break something, it has to be done :
> the src cannot know %p, it is up to the info file to set things up
> correctly.
>
> It may be useful to grep for hard-coded "/sw/" in the sources
> when preparing or checking a pkg .. ["sw" is (unluckily) a too short
> string, but "/sw/" should not give too many false positives,
> and should catch the bulk of the problems ..]
>
> Fink seems to have been too succesfull ! :)
>
> JF Mertens
>
Maybe it would be worth adding this check to the validator. "fink
validate <source tarball>" could unpack the tarball e.g. in /tmp and run
a check for /sw/, and the same operation could be run in fink's
maintainer mode on the unpacked tarball (analogous to "fink validate
<debfile>" and the maintainer mode deb-directory validation).
- --
Alexander Hansen
Fink User Liaison
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkrAuf8ACgkQB8UpO3rKjQ+OUACbBxiaOZ/YnneGKqwlRwwbUGCw
t5gAnjVxy9zJWP6hMrfqrIpdjUNeK8bv
=yeWm
-----END PGP SIGNATURE-----
------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
Fink-devel mailing list
[email protected]
http://news.gmane.org/gmane.os.apple.fink.devel
Subscription management:
https://lists.sourceforge.net/lists/listinfo/fink-devel