cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: cURL: squeezing ./configure --help

From: Дилян Палаузов <dilyan.palauzov_at_aegee.org>
Date: Mon, 26 May 2014 20:19:35 +0200

Hello,

for "libcurl_option", running ./configure calls:

AC_MSG_CHECKING([whether to enable generation of C code])
AC_ARG_ENABLE(libcurl_option,
AC_HELP_STRING([--disable-libcurl-option],[Disable --libcurl C code
generation \
support]),
[ case "$enableval" in
   no)
        AC_MSG_RESULT(no)
        AC_DEFINE(CURL_DISABLE_LIBCURL_OPTION, 1, [to disable --libcurl
C code g\
eneration option])
        curl_libcurl_msg="no"
        ;;
   *) AC_MSG_RESULT(yes)
        ;;
   esac ],
        AC_MSG_RESULT(yes)
)

so it prints
   Checking whether to enable generation of C code ... yes
...
   --libcurl option: enabled (--disable-libcurl-option)

=> The default is enable.

I interpret the posting at
http://lists.gnu.org/archive/html/bug-autoconf/2014-05/msg00018.html in
a way, that either --enable-X or --disable-X shall be printed by
./configure --help for each feature X.

Currently curl/configure enforces explicitly providing the desired
parameters, as people cannot know what happens when both --enable-X and
--disable-X is listed by ./configure --help and ./configure is run
without explicitly providing option X. Sure, feature X will be either
enabled or disabled, but what is the default? In cases where the
options is detected at ./configure-time, printing:

--enable-X Enables feature X (default: auto)
or rather the --disable-X option with (default: auto) remarks shall make
it clear, that the system tries to enable the feature, but if
./configure thinks that the requirements are not met, then the feature
will be disabled. This logic applies for LDAPS and RTSP. If
./configure --help prints both --enable-X and --disable-X people cannot
know if the system tries to enable the feature, or what the default is.

Със здраве
   Дилян

On 26.05.2014 08:44, Dan Fandrich wrote:
> On Sun, May 25, 2014 at 06:20:17PM +0200, Дилян Палаузов wrote:
>> This patch reduces the output of ./configure --help by stripping
>> options, which have no added value, like --enable-http (as with them
>> and without them, ./configure behaves the same).
>
>> @@ -423,8 +419,7 @@ AC_HELP_STRING([--disable-ldap],[Disable LDAP support]),
>> )
>> AC_MSG_CHECKING([whether to support ldaps])
>> AC_ARG_ENABLE(ldaps,
>> -AC_HELP_STRING([--enable-ldaps],[Enable LDAPS support])
>> -AC_HELP_STRING([--disable-ldaps],[Disable LDAPS support]),
>> +AC_HELP_STRING([--disable-ldaps],[Disable LDAPS support (default:
>> depend on LDAP support)]),
>
> The default isn't clear in this case, so --enable-ldaps could provide "added
> value" in some cases.
>
>> [ case "$enableval" in
>> no)
>> AC_MSG_RESULT(no)
>> @@ -455,8 +450,7 @@ AC_HELP_STRING([--disable-ldaps],[Disable LDAPS
>> support]),
>>
>> AC_MSG_CHECKING([whether to support rtsp])
>> AC_ARG_ENABLE(rtsp,
>> -AC_HELP_STRING([--enable-rtsp],[Enable RTSP support])
>> -AC_HELP_STRING([--disable-rtsp],[Disable RTSP support]),
>> +AC_HELP_STRING([--disable-rtsp],[Disable RTSP support (default:
>> depend on HTTP support]),
>
> Same here.
>
>> @@ -635,7 +620,6 @@ dnl disable C code generation support
>> dnl
>> AC_MSG_CHECKING([whether to enable generation of C code])
>> AC_ARG_ENABLE(libcurl_option,
>> -AC_HELP_STRING([--enable-libcurl-option],[Enable --libcurl C code
>> generation support])
>> AC_HELP_STRING([--disable-libcurl-option],[Disable --libcurl C code
>> generation support]),
>
> The default for this one is definitely --disable, so the wrong help line is
> deleted.
>
>> @@ -3313,8 +3291,7 @@ dnl
>>
>> AC_MSG_CHECKING([whether to enforce SONAME bump])
>> AC_ARG_ENABLE(soname-bump,
>> -AC_HELP_STRING([--enable-soname-bump],[Enable enforced SONAME bump])
>> -AC_HELP_STRING([--disable-soname-bump],[Disable enforced SONAME bump]),
>> +AC_HELP_STRING([--enable-soname-bump],[Enable enforced SONAME bump]),
>
> On some systems the default is --enable, so --disable is the one people must
> use.
>
>>>> Dan
> -------------------------------------------------------------------
> List admin: http://cool.haxx.se/list/listinfo/curl-library
> Etiquette: http://curl.haxx.se/mail/etiquette.html
>

attached mail follows:


-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html

Received on 2014-05-26