From: Stefan Becker Date: Sat, 15 Jun 2013 14:16:28 +0000 (+0300) Subject: mingw: allow locally installed mingw root X-Git-Tag: 1.16.1~10 X-Git-Url: https://repo.or.cz/w/siplcs.git/commitdiff_plain/031d2d1edbfe2ef17ab89a467fdf27f60ff4ac00 mingw: allow locally installed mingw root This can be used e.g. on Fedora 19 to run the mingw cross-compilation with the Fedora 18 binaries, which are compatible to Pidgin Windows binaries. --- diff --git a/contrib/mingw-cross-compile/local.mak b/contrib/mingw-cross-compile/local.mak index 0f2e3276..fe82e71e 100644 --- a/contrib/mingw-cross-compile/local.mak +++ b/contrib/mingw-cross-compile/local.mak @@ -1,14 +1,19 @@ -ifneq ($(wildcard /bin/i686-w64-mingw32-*),) +# +# Fedora 19+: upgrade to mingw32-gcc 4.8.x breaks backward compatibility. +# Fetch F18 packages of mingw32-gcc and set PIDGIN_MINGW_ROOT +# and LD_LIBRARY_PATH to the local install root. +# +ifneq ($(wildcard $(PIDGIN_MINGW_ROOT)/bin/i686-w64-mingw32-*),) # Fedora 17+ -CC := /bin/i686-w64-mingw32-gcc -STRIP := /bin/i686-w64-mingw32-strip -WINDRES := /bin/i686-w64-mingw32-windres +CC := $(PIDGIN_MINGW_ROOT)/bin/i686-w64-mingw32-gcc +STRIP := $(PIDGIN_MINGW_ROOT)/bin/i686-w64-mingw32-strip +WINDRES := $(PIDGIN_MINGW_ROOT)/bin/i686-w64-mingw32-windres EXTUTILS := /usr/share/perl5/ExtUtils -else ifneq ($(wildcard /usr/bin/i686-pc-mingw32-*),) +else ifneq ($(wildcard $(PIDGIN_MINGW_ROOT)/usr/bin/i686-pc-mingw32-*),) # Fedora -CC := /usr/bin/i686-pc-mingw32-gcc -STRIP := /usr/bin/i686-pc-mingw32-strip -WINDRES := /usr/bin/i686-pc-mingw32-windres +CC := $(PIDGIN_MINGW_ROOT)/usr/bin/i686-pc-mingw32-gcc +STRIP := $(PIDGIN_MINGW_ROOT)/usr/bin/i686-pc-mingw32-strip +WINDRES := $(PIDGIN_MINGW_ROOT)/usr/bin/i686-pc-mingw32-windres EXTUTILS := /usr/share/perl5/ExtUtils else # Ubuntu