[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: stdint module rewrite
From: |
Bruno Haible |
Subject: |
Re: stdint module rewrite |
Date: |
Fri, 16 Jun 2006 15:09:06 +0200 |
User-agent: |
KMail/1.9.1 |
Simon Josefsson wrote:
> >> The essential difference is that the installed "idn-int.h" should work
> >> without assuming any config.h symbols, but instead rely on a
> >> combination of install-time "guesses" and CPP symbol checks to define
> >> the proper uint32_t types for the host and the compilers on that host.
> >
> > Sorry, I cannot see how a CPP symbol test can tell whether uint32_t is
> > defined, if I don't know the compiler a priori. And #ifdefs of known
> > systems is not the right approach - not autoconfiguring, hard to maintain.
>
> I was thinking of the 32-bit vs 64-bit problem, there is often some
> CPP symbol that indicate if the compiler is in 32-bit mode or 64-bit
> mode.
I have now changed the generated stdint.h so that it is independent of
config.h symbols (same trick as for stdbool.h).
But multi-arch support ("fat" include files that work in 32-bit mode and
64-bit mode, or binaries that work on different platforms of the same OS)
are outside the scope of autoconf and gnulib. You can glue together two
generated stdint.h files yourself.
> Use of int_fastN_t in public APIs is probably a bad idea anyway,
> since it isn't ABI-safe.
I added a comment about it in the file.
> >> (called something like "idn-int.h")
> >
> > Why not call it "stdint.h"?
>
> I'd think that would be too error-prone, all packages using the same
> scheme would then have colliding filenames.
But on the other hand, if you define types like uint32_t in "idn-int.h",
then another copy of gnulib's stdint.h will miss it, leading to collisions.
Bruno
- Re: [Cvs-dev] Re: [Cvs-test-results] Build CVS (TRUNK) failed., Derek R. Price, 2006/06/11
- Re: [Cvs-dev] Re: [Cvs-test-results] Build CVS (TRUNK) failed., Paul Eggert, 2006/06/12
- Re: [Cvs-dev] Re: [Cvs-test-results] Build CVS (TRUNK) failed., Mark D. Baushke, 2006/06/12
- stdint module rewrite (was: Re: Build CVS (TRUNK) failed.), Bruno Haible, 2006/06/13
- Re: stdint module rewrite, Simon Josefsson, 2006/06/13
- Re: stdint module rewrite, Bruno Haible, 2006/06/13
- Re: stdint module rewrite, Simon Josefsson, 2006/06/14
- Re: stdint module rewrite,
Bruno Haible <=
- Re: stdint module rewrite, Paul Eggert, 2006/06/13
- Re: stdint module rewrite, Bruno Haible, 2006/06/13
- Re: stdint module rewrite, Paul Eggert, 2006/06/13
- Re: stdint module rewrite, Bruno Haible, 2006/06/13
- Re: stdint module rewrite (was: Re: Build CVS (TRUNK) failed.), Ralf Wildenhues, 2006/06/13
- Re: stdint module rewrite (was: Re: Build CVS (TRUNK) failed.), Bruno Haible, 2006/06/13
- Re: stdint module rewrite (was: Re: Build CVS (TRUNK) failed.), Ralf Wildenhues, 2006/06/14
- Re: stdint module rewrite (was: Re: Build CVS (TRUNK) failed.), Bruno Haible, 2006/06/16
- Re: stdint module rewrite, Ralf Wildenhues, 2006/06/16
- Re: stdint module rewrite (was: Re: Build CVS (TRUNK) failed.), Mark D. Baushke, 2006/06/13