Bug 103367 - configure: error: libtasn1 not found...
Summary: configure: error: libtasn1 not found...
Status: NEW
Alias: None
Product: p11-glue
Classification: Unclassified
Component: p11-kit (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: low minor
Assignee: Stef Walter
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-20 04:35 UTC by Jeffrey Walton
Modified: 2017-10-21 10:43 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
config.log (11.56 KB, application/gzip)
2017-10-20 04:35 UTC, Jeffrey Walton
Details

Description Jeffrey Walton 2017-10-20 04:35:41 UTC
Created attachment 134932 [details]
config.log

I'm trying to build GnuTLS from sources on Fedora 26, x64. libtasn1 is installed in /usr/local (/usr/local/include and /usr/local/lib64). The issue does not occur on Ubuntu 17 x86_64, where libraries are installed in /usr/local/lib.

Configure claims it cannot be found:

checking for LIBTASN1... no
configure: error: libtasn1 not found. Building without it results in significant loss of functionality. To proceed use --without-libtasn1
Failed to configure p11-glue

I've tried --with-libtasn1=/usr/local and --with-libtasn1-prefix=/usr/local with no joy. Configure --help does not list them, but I thought it was worth a try.

**************************************************

$ cat config.log
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by p11-kit configure 0.23.2, which was
generated by GNU Autoconf 2.69.  Invocation command line was

  $ ./configure --enable-shared --prefix=/usr/local --libdir=/usr/local/lib64

## --------- ##
## Platform. ##
## --------- ##

hostname = skylake
uname -m = x86_64
uname -r = 4.13.5-200.fc26.x86_64
uname -s = Linux
uname -v = #1 SMP Thu Oct 5 16:53:13 UTC 2017
...

configure:16917: checking for LIBTASN1
configure:16924: $PKG_CONFIG --exists --print-errors "libtasn1 >= 2.3"
Package libtasn1 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libtasn1.pc'
to the PKG_CONFIG_PATH environment variable
Package 'libtasn1', required by 'virtual:world', not found
configure:16927: $? = 1
configure:16941: $PKG_CONFIG --exists --print-errors "libtasn1 >= 2.3"
Package libtasn1 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libtasn1.pc'
to the PKG_CONFIG_PATH environment variable
Package 'libtasn1', required by 'virtual:world', not found
configure:16944: $? = 1
configure:16958: result: no
Package 'libtasn1', required by 'virtual:world', not found
configure:16974: error: libtasn1 not found. Building without it results in significant loss of functionality. To proceed use --without-libtasn1

**************************************************

$ lsb_release -a
LSB Version:    :core-4.1-amd64:core-4.1-noarch
Distributor ID: Fedora
Description:    Fedora release 26 (Twenty Six)
Release:        26
Codename:       TwentySix

And:

$ ls /usr/local/include/*asn*
/usr/local/include/libtasn1.h

And:

$ ls /usr/local/lib64/*asn*
/usr/local/lib64/libtasn1.a   /usr/local/lib64/libtasn1.so.6
/usr/local/lib64/libtasn1.la  /usr/local/lib64/libtasn1.so.6.5.4
/usr/local/lib64/libtasn1.so

And:

$ ls /usr/local/lib64/pkgconfig/*asn*
/usr/local/lib64/pkgconfig/libtasn1.pc
Comment 1 Jeffrey Walton 2017-10-20 04:38:23 UTC
Also, /usr/local/lib64 is on the linker's path.

$ gcc -m64 -Xlinker --verbose  2>/dev/null | grep SEARCH | sed 's/SEARCH_DIR("=\?\([^"]\+\)"); */\1\n/g'

/usr/x86_64-redhat-linux/lib64
/usr/lib64
/usr/local/lib64
/lib64
/usr/x86_64-redhat-linux/lib
/usr/local/lib
/lib
/usr/lib
Comment 2 Jeffrey Walton 2017-10-20 05:07:32 UTC
Also see "Install to lib64", https://lists.gnu.org/archive/html/automake/2009-01/msg00043.html.

I'm using --libdir=/usr/local/lib64 as detailed in the thread.
Comment 3 Jeffrey Walton 2017-10-21 10:43:15 UTC
GnuTLS has the same issue on Fedira - it can't find things in lib64/ directories. Fedora's gnutls.spec file actually runs sed over the configure script (thnaks NM): http://pkgs.fedoraproject.org/cgit/rpms/gnutls.git/tree/gnutls.spec

Using sed seems wrong. I'm not an Autotools guy, but this seems like something Autoconf should handle for us. I'm trying to learn how things should be handled at https://lists.gnu.org/archive/html/autoconf/2017-10/msg00000.html.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.