Yo folks,
as Jean-Francois Mertens suggested in the past, maybe we should now
consider a change in our approach on how to get stuff to link against
Fink libs & to use /sw/include header file.
Right now, fink by default sets CPPFLAGS to -I/sw/include and LDFLAGS
to -L/sw/lib by default for every package (unless explicitly
disabled). This works in most cases, but at always, that's why in
various package we have to use NoSetCPPFLAGS etc. and use tricks to
achieve the right behaviour.
Recently this has turned up again becaus both cyrus-sasl and libmd
install(ed) a /sw/include/md5.h file. Now when building dpkg, which
also has a md5.h header file in its sources, dpkg would use the
/sw/include/md5.h file, not its own - which of course breaks the
build.
The reason being that with our default approach, headers are always
first searched in the Fink include directoy.
jfm suggested as an alternative to set CPATH and LIBRARY_PATH to
appropriate value (and also DYLD_FALLBACK_LIBRARY_PATH, though I am
not quite sure why it would be needed - can you give me an example
scenario where it might be beneficial to have that?).
The first idea was to modify base-files (init.sh and init.csh in
particular) to do that, but now that we are using a clean build
environment, that is not going to work, and in fact not necessary.
Rather, we could simply modify fink to set it at the start of each
build (in particular, in PkgVersion.pm the set_env() method would do
it). Of course, we'd also provide NoSetCPATH and NoSet LIBRARY_PATH
fields.
What do you people think? My suggestion would be to try that ASAP. I
could disable the default values of CPPFLAGS/LDFLAGS and instead give
default values to CPATH/LIBRARY_PATH. That's 5 minutes to change it
(and also 5 minutes to back it out if it works badly :-). The major
issue with this is that we should basically recompile *every single
package*. I don't see why it should break anything, but you never
know for sure. On the positive side, it should allow us to get rid of
various fixes/patches, and also should prevent certain typical
problems from cropping up in the future.
Your feedback is welcome :-)
Max
--
-----------------------------------------------
Max Horn
Software Developer
email: <mailto:max@;quendi.de>
phone: (+49) 6151-494890
-------------------------------------------------------
This sf.net email is sponsored by: Influence the future
of Java(TM) technology. Join the Java Community
Process(SM) (JCP(SM)) program now.
http://ad.doubleclick.net/clk;4729346;7592162;s?http://www.sun.com/javavote
_______________________________________________
Fink-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-devel
- Re: [Fink-devel] CPATH / LIBRARY_PATH Justin Hallett
- Re: [Fink-devel] CPATH / LIBRARY_PATH Justin Hallett
- Re: [Fink-devel] CPATH / LIBRARY_PATH Max Horn
- Re: [Fink-devel] CPATH / LIBRARY_PATH Peter O'Gorman