GNOME Bugzilla – Bug 749161
undefined reference to `__imp__stat32i64'
Last modified: 2015-09-27 20:09:08 UTC
Compiling glib 2.45.1 with gcc 4.9.2 64bit on windows 8.1 with Msys glocalfile.c: In function 'g_local_file_measure_size_of_file': glocalfile.c:2685:38: warning: passing argument 2 of '_wstat32i64' from incompatible pointer type retval = _wstat32i64 (wfilename, &buf); ^ In file included from glocalfile.c:24:0: z:/foss/gcc/64bit/gcc-4.9.2/x86_64-w64-mingw32/include/sys/stat.h:127:23: note: expected 'struct _stat32i64 *' but argument is of type 'struct _stat64 *' _CRTIMP int __cdecl _wstat32i64(const wchar_t *_Name,struct _stat32i64 *_Stat); ^ CCLD libgio-2.0.la libtool: link: warning: `z:/opts/opt64/lib/../lib/libffi.la' seems to be moved libtool: link: warning: `z:/opts/opt64/lib/../lib/libintl.la' seems to be moved .libs/libgio_2_0_la-glocalfile.o: In function `g_local_file_measure_size_of_file': Z:\src\gnome\glib-2.45.1\gio/glocalfile.c:2685: undefined reference to `__imp__wstat32i64' collect2.exe: error: ld returned 1 exit status Makefile:1919: recipe for target `libgio-2.0.la' failed make[4]: *** [libgio-2.0.la] Error 1 make[4]: Leaving directory `/usr/src/gnome/glib-2.45.1/gio' Makefile:3996: recipe for target `all-recursive' failed make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/usr/src/gnome/glib-2.45.1/gio' Makefile:1787: recipe for target `all' failed make[2]: *** [all] Error 2 make[2]: Leaving directory `/usr/src/gnome/glib-2.45.1/gio' Makefile:1215: recipe for target `all-recursive' failed make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/usr/src/gnome/glib-2.45.1' Makefile:857: recipe for target `all' failed make: *** [all] Error 2 Changing _wstat32i64 to _wstat64 seems to fix the issue.
Created attachment 312219 [details] [review] Fix
Review of attachment 312219 [details] [review]: I didn't verify the details here, but sounds good to me =)
Committed, thanks for the patch! https://git.gnome.org/browse/glib/commit/?id=4745c08220b90eac741ae3ca1913cbe90c9831ef