[PATCH] support for mingw-w64
Torbjorn Granlund
tg at gmplib.org
Fri Sep 11 11:49:07 CEST 2009
Ozkan Sezer <sezeroz at gmail.com> writes:
On Fri, Sep 11, 2009 at 12:26 PM, Torbjorn Granlund <tg at gmplib.org> wrote:
> Thanks for the GMP patch!
>
> Comments:
>
> * We unfortunately cannot use intptr_t unconditionally, since it is not
> available everywhere we want GMP to work; it is a C99 feature.
>
> I wonder if size_t could be used instead? While perhaps not elegant,
> it should work. Does anybody see any problem?
Hmm, ssize_t would be a better choice, IMHO, for matched
signedness, but ..
Is ssize_t standard? Is signedness really depended upon? (And what is
a signed pointer, anyway?)
> (Alternatively, we could define our own little type, gmp_intptr_t
> which we set up in gmp-impl.h. There are some precedents in that
> file.)
.. this would surely be a much better solution.
Are you willing to implement and test it?
> * Why is it necessarly to pass -std=c99 to gcc?
>
> Passing this flag to gcc might be a good idea for all configurations,
> but then it should better be done using a global feature test, perhaps
> via our _opt flags mechanism. Setting a globally avaiblable flags for
> one platform seems wrong.
Without c99 mode, gcc, rightfully, emits _a lot_ of warnings like:
fib_table.c:12:1: warning: use of C99 long long integer constant
.. which is because of long long.
If you want to make it global for all targets, I have no problems
with that at all.
It does? I've used longlong loads of time and GCC has been silent like
a lamb.
> Did you write this patch yourself? It is large enough to be covered by
Updated an old patch
Written by whom?
> copyright law, meaning that the GNU project needs paperwork from its
> authors. This is a few minutes of work, but we need to protect the
> legal status of GMP for the benefit of its users.
I already did copyright paperwork for gcc and binutils
with fsf. Is it necessary doing it again for gmp, too?
If you have assign-future in effect but it does not include GMP, then it
needs to be amended. (I don't think there is an "everything I produce"
assignment, which probably is a good thing. :-)
--
Torbjörn
More information about the gmp-devel
mailing list