cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: autoconf/makefile problem

From: Dan Grayson <dan_at_math.uiuc.edu>
Date: Wed, 2 Jul 2003 18:38:54 -0500 (CDT)

Oops, you're right. Here is the offending line from lib/ca-bundle.h.

  #define CURL_CA_BUNDLE "${prefix}/share/curl/curl-ca-bundle.crt"

But the problem is a standard one, and the solution is addressed in the info
page for autoconf:

       A corollary is that you should not use these variables except in
    Makefiles. For instance, instead of trying to evaluate `datadir' in
    `configure' and hard-coding it in Makefiles using e.g.,
    `AC_DEFINE_UNQUOTED(DATADIR, "$datadir")', you should add
    `-DDATADIR="$(datadir)"' to your `CPPFLAGS'.

-----------------------------------------------------------------------------

   Date: Wed, 2 Jul 2003 23:12:48 +0200 (CEST)
   From: Daniel Stenberg <daniel_at_haxx.se>
   cc: Curl Mailinglist <curl-users_at_lists.sourceforge.net>

   On Tue, 1 Jul 2003, Dan Grayson wrote:

> This code from configure.ac (curl-7.10.5) prevents the user from overriding
> the install directory at install-time by setting "prefix" to something else.

   [snip]

> Here is a fix.
>
> AC_HELP_STRING([--without-ca-bundle], [Don't install the CA bundle]),
> [ ca="$withval" ],
> [
> if test "x$prefix" != xNONE; then
> ca="\${prefix}/share/curl/curl-ca-bundle.crt"

   Does this really work? The full path must be set in the lib/ca-bundle.h file
   after configure has run, and I believe this fix makes a bad #define line.

   (I don't have time to test this, I just recall myself having tried exactly
   this and failed.)

   --
    Daniel Stenberg -- curl: been grokking URLs since 1998

-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01
Received on 2003-07-04