Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 340106 - sys-devel/llvm-2.8 defines a wrong PACKAGE_VERSION "2.8rc"
Summary: sys-devel/llvm-2.8 defines a wrong PACKAGE_VERSION "2.8rc"
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Bernard Cafarelli
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-10-07 20:59 UTC by Alexey Charkov
Modified: 2010-10-08 13:52 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch to llvm-2.8.ebuild to fix the issue (llvm-2.8-ebuild.patch,365 bytes, patch)
2010-10-07 21:10 UTC, Alexey Charkov
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Charkov 2010-10-07 20:59:21 UTC
Line 583 of /usr/include/llvm/Config/config.h in my system states (with sys-devel/llvm-2.8):

#define PACKAGE_VERSION "2.8rc"

The result of this "rc" suffix is a failure in compilation of media-libs/mesa[gallium,llvm] as follows:

In file included from draw/draw_context.c:39:
draw/draw_vs.h:176:5: error: invalid suffix "rc" on integer constant
draw/draw_context.c:42:5: error: invalid suffix "rc" on integer constant
draw/draw_context.c:72:5: error: invalid suffix "rc" on integer constant

I am using the live mesa ebuild from x11 overlay. Its configure script invokes `/usr/bin/llvm-config --version` to obtain LLVM version and pass it as a -DHAVE_LLVM=0x0208rc argument to the preprocessor.

NB: Removing the "rc" suffix in LLVM version string fixes Mesa compilation (checked by hardcoding "2.8" in Mesa's configure.ac).

Reproducible: Always

Steps to Reproduce:
1. Upgrade LLVM to version 2.8 in portage
2. Try to recompile mesa[gallium,llvm]

Actual Results:  
Mesa compilation fails.

Expected Results:  
LLVM version is detected and passed in correctly, Mesa compiles.
Comment 1 Alexey Charkov 2010-10-07 21:10:30 UTC
Created attachment 249886 [details, diff]
Patch to llvm-2.8.ebuild to fix the issue

This adds a trivial sed to replace the version string in 'configure' for LLVM with a correct value.
Comment 2 Bernard Cafarelli gentoo-dev 2010-10-08 13:17:42 UTC
Looks like they found it too upstream, svn branch is fixed and the tarball was silently updated... Thanks for the report, I'll look in fixing this
Comment 3 Bernard Cafarelli gentoo-dev 2010-10-08 13:52:33 UTC
Thanks to SRC_URI arrow, we can use the updated tarball (renamed on our mirrors to -r1 to get the new one)

Fixed in 2.8-r1, thanks for the report!