[krbdev.mit.edu #1261] Creation of shared libraries ignore --with-ldopts

Sam Hartman via RT rt-comment at krbdev.mit.edu
Thu Nov 21 10:02:45 EST 2002


>>>>> "Tom" == Tom Yu via RT <rt-comment at krbdev.mit.edu> writes:

>>>>> "Ezra" == Ezra Peisach via RT <rt-comment at krbdev.mit.edu> writes:

    Ezra> a) config/lib.in: Change the invocation of LDCOMBINE in the
    Ezra> creation of the library to include $(LDFLAGS)

    Ezra> This would make the --ldopts a global change for all
    Ezra> architectures.

    Tom> One possible problem with this is that LDFLAGS is meant to be
    Tom> used during program link time.  It is therefore intended to
    Tom> be suitable for passing to the compiler driver.  Different
    Tom> architectures vary as to whether they use ld or $(CC) to
    Tom> build shared libraries, and we'd have to account for the
    Tom> possibility that LDFLAGS that are suitable for the compiler
    Tom> driver might not be suitable for ld.

I contend it is almost always wrong to use ld to build shared libraries:

* cc may link against aditional libraries that are required (see
  hppa/linux--using ld is guaranteed to fail)

* cc may need to include additional flags that may change over time.




More information about the krb5-bugs mailing list