cURL / Mailing Lists / curl-library / Single Mail

curl-library

compilation error of libcurl 7.21.7 with mingw-w64 (i686, gcc 4.7)

From: Vincent Torri <vincent.torri_at_gmail.com>
Date: Thu, 8 Sep 2011 08:50:58 +0200

Hey,

I tried to compile libcurl 7.21.7 with mingw-w64 (i686, mingw, gcc 4.7) on
Windows and I get that error:

make[3]: Entering directory
`/home/torri/packages/curl-7.21.7-src/release/mingw-w64-x86_32-curl-7.21.7/src'
if i686-w64-mingw32-gcc -DHAVE_CONFIG_H -I../include/curl -I../include
-I../include -I../lib -I../src -I../lib -I../src -isystem /opt/efl/include
-IC:/MinGW_PKG/msys/1.0/opt/efl/include -I\{exec_prefix\}/include
-IC:/MinGW_PKG/msys/1.0/opt/efl/include -I\{exec_prefix\}/include
-march=i686 -mtune=i686 -mms-bitfields -O2 -pipe -g0 -Wno-system-headers
-MT main.o -MD -MP -MF ".deps/main.Tpo" -c -o main.o main.c; \
        then mv -f ".deps/main.Tpo" ".deps/main.Po"; else rm -f
".deps/main.Tpo"; exit 1; fi
In file included from ../lib/strtoofft.h:25:0,
                 from ../lib/curlx.h:40,
                 from main.c:144:
../lib/setup.h:317:0: warning: "lseek" redefined [enabled by default]
c:\mingw_pkg\mingw-w32\bin\../lib/gcc/i686-w64-mingw32/4.7.0/../../../../i686-w64-mingw32/include/io.h:336:0:
note: this is the location of the previous definition
main.c:467:12: error: static declaration of 'ftruncate64' follows non-static
declaration
c:\mingw_pkg\mingw-w32\bin\../lib/gcc/i686-w64-mingw32/4.7.0/../../../../i686-w64-mingw32/include/unistd.h:30:5:
note: previous declaration of 'ftruncate64' was here
main.c:476:0: warning: "ftruncate" redefined [enabled by default]
c:\mingw_pkg\mingw-w32\bin\../lib/gcc/i686-w64-mingw32/4.7.0/../../../../i686-w64-mingw32/include/unistd.h:56:0:
note: this is the location of the previous definition
make[3]: *** [main.o] Error 1

Maybe a check in configure.ac should be added to check the availability of
ftruncate64() and guard the definition of ftruncate64 correctly.

regards

Vincent Torri

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-09-08