fredag den 14 september 2012 klockan 00:42 skrev Simon Josefsson detta:
> Mats Erik Andersson <[email protected]> writes:
>
> With AC_LIB_HAVE_LINKFLAGS I think you would deal with it in the
> following ways:
>
> 1) ./configure --with-idn (finds idna.h and libidn.so directly)
>
> 2) ./configure CPPFLAGS=-I/usr/include/idn --with-idn
> (also search /usr/include/idn for idna.h)
>
> 3) ./configure --with-idn --with-libidn-prefix=/usr/pkg
>
> why wouldn't this work?
It is exactly the insertion of CPPFLAGS I would like to circumvent.
Personally, I regard the selection of options as flawed whenever
I need to resort to the CPPFLAGS trickery.
> I agree it would be a nicer symmetry if AC_LIB_HAVE_LINKFLAGS provided
> two parameters, one for includedir and one for libdir. But it is mostly
> an aesthetic improvement, as the code should deal with setting CPPFLAGS
> to the includedir and --with-libidn-prefix to the libdir.
Could a reformulation with AC_LIB_HAVE_LINKFLAGS achieve the following,
simplified use case set? My present implementation does not!
* Library and header file in system path:
./configure --with-idn
* Library and header use common base directory, outside
of system path (remove need for extra --with-idn):
./configure --with-libidn-prefix=/usr/pkg
* Header file in private directory, library in system path:
./configure --with-idn=/usr/include/idn
* Header file tucked away, library not detectable by system:
./configure --with-idn=/usr/local/idn --with-libidn-prefix=/usr/local
In case you can achieve this, I would very much like to see that
you commit it to our repository.
Regards,
Mats