Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sun, 26 May 2013 22:05:58 -0400
From:  <jfoug@....net>
To: john-dev@...ts.openwall.com
Cc: magnum <john.magnum@...hmail.com>
Subject: Re: X32 build, anyone?


---- magnum <john.magnum@...hmail.com> wrote: 
> On 22 May, 2013, at 3:10 , magnum <john.magnum@...hmail.com> wrote:
> It builds without a warning, but first I had to change the definiton of ARCH_WORD in x86-64.h to "long long" instead of just "long". Could that somehow be a problem? I think http://sourceware.org/glibc/wiki/x32 says we could test for X32 using the macro __ILP32__ but I can't see any reason to not always use long long.

Why not change all of these, to :

#include "stdint.h"
#define ARCH_WORD uint64_t  (or uint32_t for 32 bit systems)  ?

We already have issues with compilers giving portability warnings that things like ARCH_WORD64 and uint64_t have portability issues.  These warnings are fully spurious, since we have taken care, so that within a single build, ARCH_WORD64 and uint64_t ARE always compatible, but the compiler does not know this, and thus complains, so we add more and more extraneous type casts to mute the warnings. If we simply defined these initially, then we would likely not have to continually add more and more of these typecasts, and have fewer portability warnings (unsafe / non portable conversion type warnings).

Jim.

Jim.

Powered by blists - more mailing lists

Your e-mail address:

Powered by Openwall GNU/*/Linux - Powered by OpenVZ