[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: darwin patch
From: |
Robert Boehne |
Subject: |
Re: darwin patch |
Date: |
Sun, 09 Feb 2003 22:49:53 -0600 |
Peter,
I'm looking into the question about the paths, and I think there are
good ideas in this patch. You were right however about #5 on your
list, the change to ltmain.in. If ranlib needs to be run, it needs
to be run by having it set in old_archive_cmds, so it would (should?)
have
already been in concat_cmds if it were set. If it isn't that's probably
where we should look. I'll post when I've got more to say, like maybe
"commit". ;)
Thanks,
Robert
Peter O'Gorman wrote:
>
> Hi, here is my proposed patch for, I hope, improved darwin support.
>
> 1) always append /lib /usr/lib and /usr/local/lib to the search path,
> done this way so that even if apple changes the output of
> -print-search-dirs yet again, libtool will look in the same places as
> ld.
>
> 2) add C specific archive commands so not everything is single module
> bind_at_load
>
> 3) add support for archive_expsym_commands
>
> 4) enable_shared_with_static_runtimes=yes to stop complaints about
> static only libgcc and libstdc++
>
> 5) (and you might not want to apply this) make the incremental linking
> run ranlib
>
> There are other things I'd like to do:
>
> 1) add support for -dylib_file so that relinking in unnecessary on
> darwin. I have no idea how to do this cleanly, libtool seems to expect
> the dir to be coded into the binary, but on darwin the whole path
> including the libname is encoded. To link against and uninstalled
> shared library, I'd like to add -dylib_file
> libfoo.1.dylib:/path/to/build/dir/libfoo.1.dylib somewhere in the link
> commands. No idea how to do this cleanly.
>
> 2) add twolevel_namespace support
>
> 3) remove -bind_at_load from ltmain.in for darwin. First I need to
> figure out how to add it only when new libs/executables are linked
> against c++ shared libraries, perhaps by writing something to the
> dependency_libs of the c++ library when it is built?
>
> Then, here is the patch, inline and attached, if you add it please use
> address@hidden as the ChangeLog committer.
>
> Thanks,
> Peter
>
> Index: ltmain.in
> ===================================================================
> RCS file: /cvsroot/libtool/libtool/ltmain.in,v
> retrieving revision 1.322
> diff -u -d -b -w -r1.322 ltmain.in
> --- ltmain.in 29 Jan 2003 04:53:18 -0000 1.322
> +++ ltmain.in 9 Feb 2003 15:31:19 -0000
> @@ -4866,7 +4866,7 @@
> RANLIB=$save_RANLIB
> oldobjs=$objlist
> if test "X$oldobjs" = "X" ; then
> - eval cmds=\"\$concat_cmds\"
> + eval cmds=\"\$concat_cmds~$RANLIB $oldlib\"
> else
> eval cmds=\"\$concat_cmds~$old_archive_cmds\"
> fi
>
> ------------------------------------------------------------------------
> Name: darwin.diff.gz
> darwin.diff.gz Type: application/x-gzip
> Encoding: base64
>
> ------------------------------------------------------------------------
> _______________________________________________
> Libtool-patches mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/libtool-patches