Re: cvs commit: fptools/mk target.mk package.mk fptools/ghc/lib/compat Makefile fptools/ghc/compiler/main Packages.lhs DriverPipeline.hs fptools/ghc/compiler/ghci Linker.lhs
Wolfgang Thaller <[email protected]>
| Newsgroups | gmane.comp.lang.haskell.cvs.fptools,gmane.comp.lang.haskell.cvs.ghc |
|---|---|
| Message-ID | <[email protected]> |
On 18.01.2005, at 13:00, Andre Pang wrote: > On 14/01/2005, at 7:01 PM, Wolfgang Thaller wrote: > >> mk/target.mk: >> When installing .dylibs (Darwin only), update the install_name >> to point >> to the final location. >> (Somebody please read Apple's documentation on what >> install_names are, >> and then comment on whether this is a useful feature or whether >> it should >> be done the "normal" unix way). > > I'm 99% sure that the way you're doing it is right: e.g. GNU libtool > does the same thing when it installs libraries in their final > locations. (I'm not exactly sure what you mean by the "normal" UNIX > way). The "normal UNIX way" is what you get when you don't have install_names (or set the install_names to just the file name, without a path). The dynamic linker will then look for the library in a few standard locations plus whatever [DY]LD_LIBRARY_PATH happens to be set to when the program is invoked. By using install_name, GHC-compiled -dynamic executables will always look for their libs at /usr/local/lib/ghc-6.3/, without respecting the DYLD_LIBRARY_PATH settings. > Awesome work in getting the dynamic library support integrated into > the build system, by the way! There's much work left to be done. Right now, you need a nontrivial build.mk file to make it work, and what's even worse, you have to change it slightly after building stage1 of the compiler (but before building the libraries). Not nice. Cheers, Wolfgang