#10566 closed bug (fixed)
POSIX UINT16_C (and other) macros are incorrect in stdint.h
Reported by: | kallisti5 | Owned by: | kallisti5 |
---|---|---|---|
Priority: | normal | Milestone: | R1/beta1 |
Component: | Build System | Version: | R1/Development |
Keywords: | Cc: | ||
Blocked By: | Blocking: | #9362 | |
Platform: | x86-64 |
Description
LLVM doesn't build on x86_64. Tracked it down to a bug in our stdint.h. I found the solution when I ran onto a DragonflyBSD post seeing the same LLVM build error.
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/2a61a4766f203ace8a0d0ed677e146bd3959dd58
That shows a fix for the same issue present in our stdint.h
Working on a patch now, but need to do some in-depth testing before I commit it.
Attachments (1)
Change History (11)
comment:1 by , 11 years ago
comment:2 by , 11 years ago
Found the core issue.
headers/config/types.h:
If platform is 64-bit, uint64 is signed long If platform is not 64-bit, uint64 is signed long long
Our stdint.h UINT64_C defines need adjusted to match this logic.
comment:3 by , 11 years ago
Blocking: | 9362 added |
---|
follow-up: 9 comment:5 by , 11 years ago
wget and findutils should be moved to packages, anyway. Maybe coreutils could be moved as well.
follow-up: 7 comment:6 by , 11 years ago
Replying to korli:
Which LLVM version?
LLVM 3.4 (latest) I never actually tried building llvm on x86_64, so i'm guessing this bug has always existed.
working through testing the changes above now. Hopefully i'll have enough time to try an llvm build this evening before commiting the modifications.
comment:7 by , 11 years ago
Replying to kallisti5:
Replying to korli:
Which LLVM version?
LLVM 3.4 (latest) I never actually tried building llvm on x86_64, so i'm guessing this bug has always existed.
Weirdly haikuporter builds only version 3.2 of llvm instead of 3.4 on x86_64 when asking for a mesa 10.0.2 build. Hence why this problem wasn't met before.
comment:8 by , 11 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
resolved as of hrev46902. Confirmed in llvm that they moved from using 1ull to UINT64_C(1) recently uncovering this issue.
LLVM 3.4 compiled successfully as did x86_64 Haiku.
comment:9 by , 11 years ago
Replying to pulkomandy:
wget and findutils should be moved to packages, anyway. Maybe coreutils could be moved as well.
Absolutely. Cf. #10267.
comment:10 by , 10 years ago
Milestone: | R1/alpha5 → R1/beta1 |
---|
I also should note that I see the same type defined in the following headers:
Need to check those projects to see if they also updated that headers.