[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: shl_load/dld_link
From: |
Gary V . Vaughan |
Subject: |
Re: shl_load/dld_link |
Date: |
Sun, 5 Aug 2001 14:05:57 +0100 |
On Tuesday 31 July 2001 4:29 pm, address@hidden wrote:
> On Mon, Jul 30, 2001 at 03:03:39PM -0700, Steve Ellcey wrote:
> > I am not an autoconf expert so I may be missing something, but is this
> > right?
> >
> > >From line 741 of the latest mainline libtool.m4
> >
> > *)
> > AC_CHECK_FUNC(shl_load, lt_cv_dlopen="shl_load",
> > [AC_CHECK_LIB(dld, shl_load,
> > [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"],
> > [AC_CHECK_LIB(dl, dlopen,
> > [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
> > [AC_CHECK_FUNC(dlopen, lt_cv_dlopen="dlopen",
> > [AC_CHECK_LIB(svld, dlopen,
> > [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"])
> > ])
> > ])
> > ])
> > ])
> > ;;
> > esac
> >
> > Is it the case that if shl_load is found in libdld, then lt_cv_dlopen is
> > set to "dld_link"? That should be "shl_load", right? Did someone make
> > a cut-n-paste error here?
>
> I think you're correct. The 1.4 branch has the same error. I made the
> change you suggested and HP-UX 10.20 and 11.00 pass all tests.
I'm not so sure. Are there two flavours of shl_load (not necessarily on
HP-UX I guess), one in the standard libraries (lt_cv_dlopen="shl_load") and
one with the function in libdld (lt_cv_dlopen="shl_load";
lt_cv_dlopen_libs="-dld")?
My impression is that -dld is a typo for "-ldld" and the second "shl_load"
should be "dld_link", like this:
AC_CHECK_FUNC(shl_load, lt_cv_dlopen="shl_load",
[AC_CHECK_LIB(dld, dld_link,
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"],
[AC_CHECK_LIB(dl, dlopen,
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
[AC_CHECK_FUNC(dlopen, lt_cv_dlopen="dlopen",
[AC_CHECK_LIB(svld, dlopen,
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"])
])
])
])
])
If I'm correct, I think the dld_link test needs to be moved back to the end
of the list of checks, since it shouldn't override dlopen etc. (I think
reformatting into a lispy indented-true-expression; exdented-false-expression
is more readable too):
AC_CHECK_FUNC([shl_load],
[lt_cv_dlopen="shl_load"],
[AC_CHECK_LIB([dl], [dlopen],
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
[AC_CHECK_FUNC([dlopen],
[lt_cv_dlopen="dlopen"],
[AC_CHECK_LIB([svld], [dlopen],
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
[AC_CHECK_LIB([dld], [dld_link],
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
])
])
])
])
What do you think?
Cheers,
Gary.
--
())_. Gary V. Vaughan gary@(oranda.demon.co.uk|gnu.org)
( '/ Research Scientist http://www.oranda.demon.co.uk ,_())____
/ )= GNU Hacker http://www.gnu.org/software/libtool \' `&
`(_~)_ Tech' Author http://sources.redhat.com/autobook =`---d__/
- Re: shl_load/dld_link,
Gary V . Vaughan <=