Hi,

 

I'm trying to get a build of GTK-3.22 working in MSYS2, and so far not
getting very far. I'm using the gtk-build.mak script from
https://gist.github.com/z-rui/61a6722d3c858197d0d8 with the version numbers
updated to the latest, and after successfully building zlib and win-iconv,
it then fails in gettext (0.9.18) with two problems:

 

1. libtool generates libintl.la with "-lc" in $dependency_libs. That causes
the link phase to try to link in libc.a, but mingw does not have that so it
instead uses the msys2 libc.a in /usr/lib which results in link errors. I
have to hack my way around this by manually editing libintl.la to remove the
-lc, then it links OK.

 

Is there an option to configure to prevent this "-lc" getting added in
there?

 

2. Trying to do a 32-bit build I get a compile error from a couple of the
files that use "struct stat" saying that "size of struct stat is not known".
This appears to be due to redefinition of it in _mingw_stat64.h and mingw's
stat.h, which try to redefine stat as _stat32i64. I ran the compile with -E
and found that where it is used in the gettext source files, "struct stat
st;" has been redefined to "struct _stat32i64 st;", but where that
_stat32i64 struct was declared in _mingw_stat64.h it got redefined to
instead (re-)declare struct stat, hence after the pre-processing there is no
full declaration of struct _stat32i64.

 

Also after trying to hack _mingw_stat64.h to make it declare the _stat32i64
struct, it then compiled but gave link errors not finding a __stat32i64
function in the libraries. Should the stat struct and function both be
redefined to _stat32i64 in a 32-bit build here?

 

This 2nd problem is only with the 32-bit compile. After the above hack to
remove "-lc" a 64-bit compile of gettext ran OK (but I'm now getting
failures in libffi).

 

Any ideas on these?

 

Ian

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Msys2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/msys2-users

Reply via email to