Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 728804 - dev-libs/opencl-clang-10.0.0.1: ABI_X86_32 builds cannot find llvm-tblgen
Summary: dev-libs/opencl-clang-10.0.0.1: ABI_X86_32 builds cannot find llvm-tblgen
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal
Assignee: Marek Szuba (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-19 18:28 UTC by Jan Ziak (atomsymbol)
Modified: 2020-06-22 21:40 UTC (History)
0 users

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


Attachments
build.log (dev-libs:opencl-clang-10.0.0.1:20200619-181540.log,10.99 KB, text/x-log)
2020-06-19 18:28 UTC, Jan Ziak (atomsymbol)
Details
emerge-info.txt (emerge-info.txt,7.89 KB, text/plain)
2020-06-20 16:03 UTC, Jan Ziak (atomsymbol)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Ziak (atomsymbol) 2020-06-19 18:28:56 UTC
Created attachment 645266 [details]
build.log

The package build fails with the following error message:

* abi_x86_32.x86: running multilib-minimal_abi_src_compile
* Working in BUILD_DIR: "/var/tmp/portage/dev-libs/opencl-clang-10.0.0.1/work/opencl-clang-10.0.0.1_build-abi_x86_32.x86"
ninja: error: 'llvm-tblgen', needed by 'opencl_clang_options.inc', missing and no known rule to make it
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2020-06-20 16:00:35 UTC
Please provide emerge --info too.
Comment 2 Jan Ziak (atomsymbol) 2020-06-20 16:03:04 UTC
Created attachment 645430 [details]
emerge-info.txt
Comment 3 Marek Szuba (RETIRED) archtester gentoo-dev 2020-06-21 22:01:40 UTC
Could possibly you check whether this happens for abi_x86_64 as well?
Comment 4 Nicholas Santos 2020-06-22 00:32:33 UTC
(In reply to Marek Szuba from comment #3)
> Could possibly you check whether this happens for abi_x86_64 as well?

I'm running into the same problem.  The package installs correctly with -abi_x86_32 and just abi_x86_64.
Comment 5 Marek Szuba (RETIRED) archtester gentoo-dev 2020-06-22 11:10:38 UTC
This matches my own observations. The problem is not with a missing rule, llvm-tblgen is an executable provided by sys-devel/llvm - except for some reason upstream sets this using set() rather than find_executable().

Interesting that this problem only occurs with llvm-10, I've just double-checked and opencl-clang:9 builds find with ABI_X86: 32.
Comment 6 Larry the Git Cow gentoo-dev 2020-06-22 20:57:07 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=955640ef357de349e242eca5d7848286a450f35e

commit 955640ef357de349e242eca5d7848286a450f35e
Author:     Marek Szuba <marecki@gentoo.org>
AuthorDate: 2020-06-22 20:45:03 +0000
Commit:     Marek Szuba <marecki@gentoo.org>
CommitDate: 2020-06-22 20:55:57 +0000

    dev-libs/opencl-clang:10: Fix llvm-tblgen detection
    
    Upstream CMake scripts simply set LLVM_TABLEGEN_EXE to "llvm-tblgen".
    This works fine for 32-bit builds of SLOT=8 and 9 as well as 64-bit
    builds of all three slots, however 32-bit builds of SLOT=10 fail due to
    having been unable to locate the executable in question. Whatever the
    reason for this is, actually looking for llvm-tblgen with
    find_program() solves the issue, at least on my system anyway.
    
    Closes: https://bugs.gentoo.org/728804
    Signed-off-by: Marek Szuba <marecki@gentoo.org>

 .../files/opencl-clang-10.0.0.1_find-llvm-tblgen.patch        | 11 +++++++++++
 dev-libs/opencl-clang/opencl-clang-10.0.0.1.ebuild            |  1 +
 2 files changed, 12 insertions(+)
Comment 7 Nicholas Santos 2020-06-22 21:40:03 UTC
(In reply to Larry the Git Cow from comment #6)
> The bug has been closed via the following commit(s):
> 
> https://gitweb.gentoo.org/repo/gentoo.git/commit/
> ?id=955640ef357de349e242eca5d7848286a450f35e
> 
> commit 955640ef357de349e242eca5d7848286a450f35e
> Author:     Marek Szuba <marecki@gentoo.org>
> AuthorDate: 2020-06-22 20:45:03 +0000
> Commit:     Marek Szuba <marecki@gentoo.org>
> CommitDate: 2020-06-22 20:55:57 +0000
> 
>     dev-libs/opencl-clang:10: Fix llvm-tblgen detection
>     
>     Upstream CMake scripts simply set LLVM_TABLEGEN_EXE to "llvm-tblgen".
>     This works fine for 32-bit builds of SLOT=8 and 9 as well as 64-bit
>     builds of all three slots, however 32-bit builds of SLOT=10 fail due to
>     having been unable to locate the executable in question. Whatever the
>     reason for this is, actually looking for llvm-tblgen with
>     find_program() solves the issue, at least on my system anyway.
>     
>     Closes: https://bugs.gentoo.org/728804
>     Signed-off-by: Marek Szuba <marecki@gentoo.org>
> 
>  .../files/opencl-clang-10.0.0.1_find-llvm-tblgen.patch        | 11
> +++++++++++
>  dev-libs/opencl-clang/opencl-clang-10.0.0.1.ebuild            |  1 +
>  2 files changed, 12 insertions(+)

Thanks for the investigation and patch.  opencl-clang-10.0.0.1 now builds fine with both abi_x86_32 and just abi_x86_64 enabled.