[PATCH 0 of 1] Enable building on MSYS/Cygwin shell using native GCC when configure executed via abs path.

Ray Donnelly mingw.android at gmail.com
Mon Jul 15 13:02:22 CEST 2013

I sent the patch immediately following the first email, as literal
text rather than an attachment. I got nothing to indicate any
filtering had happened (unless some spam filter ate that), could it be
awaiting moderation?

I am sending it now as an attachment and crossing my fingers. I hope this is ok?

> Which namespace differences?

The bug the patch addresses is this one:

The test-case for failure is:
Install MSYS from
(I used rev13)
Install MinGW-w64 GCC from
Extract to both to e.g. C:\mingw-builds, so that you have
C:\mingw-builds\msys and C:\mingw-builds\mingw32 folders.
Run msys.bat in C:\mingw-builds\msys folder then in the MSYS shell do:

export PATH=/c/mingw-builds/mingw32/bin:$PATH
mkdir /gmplib-src
pushd /gmplib-src
wget -c ftp://ftp.gnu.org/gnu/gmp/gmp-5.1.2.tar.xz
tar -xf gmp-5.1.2.tar.xz
mkdir /gmplib-build
pushd /gmplib-build

.. the above call to make will fail with:
checking size of mp_limb_t... 0
configure: error: Oops, mp_limb_t doesn't seem to work

.. the reason being that there are #include directives for files
/gmplib-src/gmp-5.1.2/gmp-h.in and /gmplib-src/gmp-5.1.2/gmp-impl.h in
a native GCC, where those paths to not natively exist
(C:/mingw-builds/msys/gmplib-src/gmp-5.1.2/gmp-h.in does though).
Using relative paths is a workaround for these path namespace

Best regards,

Ray Donnelly.

On Mon, Jul 15, 2013 at 10:33 AM, Torbjorn Granlund <tg at gmplib.org> wrote:
> Ray Donnelly <mingw.android at gmail.com> writes:
>   The following patch for GMP 5.1.2 works around path namespace
>   differences between MSYS/Cygwin and native Windows GCC in configure by
>   calculating and using relative paths instead of absolute ones.
> Which namespace differences?
> An incompatibility between MSYS/Cygwin and Windows GCC, should that be
> handled in GMP?
> Do you have a test case which the "following patch" makes work?  (And
> where is the patch?)
> --
> Torbjörn
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 100-use-srcdirrel-to-avoid-MSYS-path-namespace-mismatch.patch
Type: application/octet-stream
Size: 30044 bytes
Desc: not available
URL: <http://gmplib.org/list-archives/gmp-bugs/attachments/20130715/fc978214/attachment-0001.obj>

More information about the gmp-bugs mailing list