Bug 54817 - autoconf fails if gcrypt isn't installed on the system
Summary: autoconf fails if gcrypt isn't installed on the system
Status: RESOLVED WONTFIX
Alias: None
Product: systemd
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: All Linux (All)
: medium normal
Assignee: systemd-bugs
QA Contact: systemd-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-12 14:28 UTC by Jonathan Maw
Modified: 2012-09-12 21:46 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
Superficial fix to autoconf failing if libgcrypt isn't installed (706 bytes, text/plain)
2012-09-12 14:28 UTC, Jonathan Maw
Details

Description Jonathan Maw 2012-09-12 14:28:35 UTC
Created attachment 67052 [details]
Superficial fix to autoconf failing if libgcrypt isn't installed

gcrypt is an optional dependency, but the configure.ac script uses the macro AM_PATH_LIBGCRYPT which is not defined if gcrypt isn't installed on the system.
As a result, when attempting to build from source with ./autogen.sh in a system that does not have gcrypt installed, it fails with:
  configure.ac:328: error: possibly undefined macro: AM_PATH_LIBGCRYPT

To reproduce:
 * Download systemd source code
 * Ensure the system does not have gcrypt installed
 * run autogen.sh

Expected results:
  Tells user to run ./configure with a long string of command-line parameters

Actual results:
  configure.ac:328: error: possibly undefined macro: AM_PATH_LIBGCRYPT
  autoreconf: /usr/bin/autoconf failed with exit status: 1

Additional information:
If I put the AM_PATH_LIBGCRYPT macro expansion inside an m4_ifdef, I can make it build successfully on a system with gcrypt installed, and one without gcrypt installed. I have attached a git diff of an example of those changes.
Comment 1 Lennart Poettering 2012-09-12 21:46:45 UTC
When building from git you need additional dependencies over when you build from a tarball. Among these are autoconf, automake, xsltproc and gcrypt. That's expected and we are not optimizing for that.

(If you do care about this, you can try to convince the gcrypt maintainer to include a .pc file, like everybody else does.)


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.