{"thread":{"id":"19730","subject":"[PATCH] fix handling of iconv configuration options","startedAt":"2009-06-08T00:45:48Z","lastAt":"2009-06-08T23:51:18Z","messageCount":3,"participants":["Marco Nelissen","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"115757","messageId":"3a3d9e520906071745k1fde4215xba310d945db37979@mail.gmail.com","threadId":"19730","inReplyTo":null,"subject":"[PATCH] fix handling of iconv configuration options","fromName":"Marco Nelissen","fromEmail":"marcone@xs4all.nl","sentAt":"2009-06-08T00:45:48Z","receivedAt":"2009-06-08T00:45:48Z","isPatch":true,"sender":{"key":"marcone@xs4all.nl","avatar":null},"body":"Fix the way in which the configure script handles --without-iconv\n(and --with-iconv=no), which it  used to essentially ignore.\nAlso fix the way the configure script determines the value of\nNEEDS_LIBICONV, which would be incorrectly set to 'YesPlease' on\nsystems that lack iconv entirely.\n\nSigned-off-by: Marco Nelissen <marcone@xs4all.nl>\n---\n\nSince configure.ac uses a mix of 2, 3 and 4 space indentation and tabs, I\nwasn't quite sure what to do with regard to that. I decided to keep the\nnumber of lines changed to a minimum, rather than changing indentation\nfor a bunch of lines.\n\n configure.ac |    8 ++++++++\n 1 files changed, 8 insertions(+), 0 deletions(-)\n\ndiff --git a/configure.ac b/configure.ac\nindex 108a97f..3388036 100644\n--- a/configure.ac\n+++ b/configure.ac\n@@ -385,6 +385,8 @@ AC_SUBST(NO_EXPAT)\n # some Solaris installations).\n # Define NO_ICONV if neither libc nor libiconv support iconv.\n\n+if test -z $NO_ICONV; then\n+\n GIT_STASH_FLAGS($ICONVDIR)\n\n AC_DEFUN([ICONVTEST_SRC], [\n@@ -431,6 +433,12 @@ GIT_UNSTASH_FLAGS($ICONVDIR)\n AC_SUBST(NEEDS_LIBICONV)\n AC_SUBST(NO_ICONV)\n\n+if test -n $NO_ICONV; then\n+    NEEDS_LIBICONV=\n+fi\n+\n+fi\n+\n #\n # Define NO_DEFLATE_BOUND if deflateBound is missing from zlib.\n\n-- \n1.6.3.1\n"},{"id":"115848","messageId":"7vhbyqwg2y.fsf@alter.siamese.dyndns.org","threadId":"19730","inReplyTo":"3a3d9e520906071745k1fde4215xba310d945db37979@mail.gmail.com","subject":"Re: [PATCH] fix handling of iconv configuration options","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-06-08T21:50:13Z","receivedAt":"2009-06-08T21:50:13Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Marco Nelissen <marcone@xs4all.nl> writes:\n\n> diff --git a/configure.ac b/configure.ac\n> index 108a97f..3388036 100644\n> --- a/configure.ac\n> +++ b/configure.ac\n> @@ -385,6 +385,8 @@ AC_SUBST(NO_EXPAT)\n>  # some Solaris installations).\n>  # Define NO_ICONV if neither libc nor libiconv support iconv.\n>\n> +if test -z $NO_ICONV; then\n> +\n>  GIT_STASH_FLAGS($ICONVDIR)\n>\n>  AC_DEFUN([ICONVTEST_SRC], [\n> @@ -431,6 +433,12 @@ GIT_UNSTASH_FLAGS($ICONVDIR)\n>  AC_SUBST(NEEDS_LIBICONV)\n>  AC_SUBST(NO_ICONV)\n>\n> +if test -n $NO_ICONV; then\n> +    NEEDS_LIBICONV=\n> +fi\n> +\n> +fi\n> +\n\nHmm, have you tested this with both NO_ICONV defined and undefined?\n\nBecause ...\n\n\t$ test -z ; echo $?\n        0\n\t$ test -n ; echo $?\n        0\n\n... I would feel better if you had dq around $NO_ICONV in both tests.\n"},{"id":"115864","messageId":"3a3d9e520906081651r33b485c2v745c4275a25c0f58@mail.gmail.com","threadId":"19730","inReplyTo":"7vhbyqwg2y.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] fix handling of iconv configuration options","fromName":"Marco Nelissen","fromEmail":"marcone@xs4all.nl","sentAt":"2009-06-08T23:51:18Z","receivedAt":"2009-06-08T23:51:18Z","isPatch":true,"sender":{"key":"marcone@xs4all.nl","avatar":null},"body":"On Mon, Jun 8, 2009 at 2:50 PM, Junio C Hamano<gitster@pobox.com> wrote:\n> Marco Nelissen <marcone@xs4all.nl> writes:\n>\n>> diff --git a/configure.ac b/configure.ac\n>> index 108a97f..3388036 100644\n>> --- a/configure.ac\n>> +++ b/configure.ac\n>> @@ -385,6 +385,8 @@ AC_SUBST(NO_EXPAT)\n>>  # some Solaris installations).\n>>  # Define NO_ICONV if neither libc nor libiconv support iconv.\n>>\n>> +if test -z $NO_ICONV; then\n>> +\n>>  GIT_STASH_FLAGS($ICONVDIR)\n>>\n>>  AC_DEFUN([ICONVTEST_SRC], [\n>> @@ -431,6 +433,12 @@ GIT_UNSTASH_FLAGS($ICONVDIR)\n>>  AC_SUBST(NEEDS_LIBICONV)\n>>  AC_SUBST(NO_ICONV)\n>>\n>> +if test -n $NO_ICONV; then\n>> +    NEEDS_LIBICONV=\n>> +fi\n>> +\n>> +fi\n>> +\n>\n> Hmm, have you tested this with both NO_ICONV defined and undefined?\n>\n> Because ...\n>\n>        $ test -z ; echo $?\n>        0\n>        $ test -n ; echo $?\n>        0\n>\n> ... I would feel better if you had dq around $NO_ICONV in both tests.\n\nAh, you're right. I tested that it didn't incorrectly set\nNEEDS_LIBICONV on a system that doesn't have/need it, but didn't test\nthat it doesn't unset it on a system that does need it (because I\ndon't have such a system).\n"}]}