[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Chicken-janitors] #979: chicken.h wrongly assumes that __x86_64__ impli
From: |
Chicken Trac |
Subject: |
[Chicken-janitors] #979: chicken.h wrongly assumes that __x86_64__ implies 64 bits |
Date: |
Fri, 08 Feb 2013 00:58:26 -0000 |
#979: chicken.h wrongly assumes that __x86_64__ implies 64 bits
--------------------------+-------------------------------------------------
Reporter: iraikov | Owner:
Type: defect | Status: new
Priority: major | Milestone: 4.9.0
Component: build system | Version: 4.8.x
Keywords: |
--------------------------+-------------------------------------------------
This bug was filed by a Debian maintainer against the Chicken 4.8.0
source:
{{{
In chicken.h, the following line:
# if defined (__alpha__) || defined(__ia64__) || defined(__x86_64__) ||
defined(__LP64__) || defined(__powerpc64__)
contains both a zoology of systems, and the actual feature it is looking
for. The zoology is wrong: if the CPU is capable of 64 bit code, this
does
not mean that the architecture you're building for has 64 bit pointers.
Because of compatibility with plenty of code that assumes sizeof(long) ==
sizeof(void*), x32 has longs of only 32 bits. What you want to check
here,
is whether longs are 64 bit.
A fix:
change that line to:
# ifdef __LP64__
This lets chicken build on both amd64 and x32.
}}}
--
Ticket URL: <http://bugs.call-cc.org/ticket/979>
Chicken Scheme <http://www.call-with-current-continuation.org/>
Chicken Scheme is a compiler for the Scheme programming language.
- [Chicken-janitors] #979: chicken.h wrongly assumes that __x86_64__ implies 64 bits,
Chicken Trac <=