Building diffutils 3.6 on macOS 10.3.3 with the newly-released command-line
tools for Xcode 9.3 causes a test failure:

-------8<-------------------------------------------------------------
FAIL: test-vasnprintf
=====================

FAIL test-vasnprintf (exit status: 132)
------>8--------------------------------------------------------------

gnulib-tests/test-suite.log carries no further information than that.

In configure.log, I find the following:

-------8<-------------------------------------------------------------
configure:7678: checking for vasnprintf
configure:7678: gcc -o conftest -g -O2   conftest.c  >&5
Undefined symbols for architecture x86_64:
  "_vasnprintf", referenced from:
      _main in conftest-25dffe.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
------>8--------------------------------------------------------------


I'm really wondering whether a diffutils 3.6 that fails this test is safe
to keep using.

The exact same failure happens when building grep, and I have emailed
bug-g...@gnu.org to report this.

I'm not sure if this is related or not, but config.log also has:

------>8--------------------------------------------------------------
configure:7678: checking for snprintf
configure:7678: gcc -o conftest -g -O2   conftest.c  >&5
conftest.c:108:6: warning: incompatible redeclaration of library function
'snprintf' [-Wincompatible-library-redeclaration]
char snprintf ();
     ^
conftest.c:108:6: note: 'snprintf' is a builtin with type 'int (char *,
unsigned long, const char *, ...)'
1 warning generated.
------>8--------------------------------------------------------------


I'm also not sure if *this* is related or not, but I see the following
compiler warning during build:


CC       diff.o
diff.c:1016:21: warning: adding 'int' to a string does not append to the
string
      [-Wstring-plus-int]
          printf ("  %s\n" + 2 * (*msg != ' ' && *msg != '-'), msg);
                  ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
diff.c:1016:21: note: use array indexing to silence this warning
          printf ("  %s\n" + 2 * (*msg != ' ' && *msg != '-'), msg);
                           ^
                  &        [                                 ]


-Charles

Reply via email to