-
Notifications
You must be signed in to change notification settings - Fork 12k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CMake Error at cmake/modules/CMakeLists.txt #53281
Comments
If you're using a sparse-checkout, you'll need to add the recently added |
I'm on Gentoo, using the llvm-14.0.0.9999 ebuild. I don't even know where the "sparse-checkout" file is on my system. I don't seem to have a ".git" directory in my home directory or llvm directory. |
Yeah I get this issue too. The checkout is fine, the files in /cmake/modules exist, but there's some sort of cmake related bug that isn't too clear. |
Hitting this issue in conda-forge (conda-forge/llvmdev-feedstock#143), where we have until now built llvm (the subproject) only from the llvm sources (and not llvm-project as a whole). Do I understand correctly that that's not possible anymore? Is that intentional? Should the From the POV of our build it's a regression (though we'll survive if it is declared unsupported), hence tagging @tstellar, as I cannot set milestones. |
I also got this issue. I checked recent changes in cmake/Modules/ folder. This commit looks related to it: 44e3365. I used its parent commit (git checkout b99833d) to build llvm with coverage, and it seems to work (after turning off LLVM_INCLUDE_BENCHMARKS flag). It builds version 14.0.0. |
Seems likely. @Ericson2314, why put these files in cmake instead of llvm/cmake? Are there projects that don't have access to the latter? @tstellar, if this stands I think we'll need to provide a tarball for this cmake top-level directory as well, otherwise none of the subproject tarballs are usable anymore. |
Actually the readme answers that, but I'm not sure I understand:
Fair enough, but who is forcing us to install all files in
They are not part of e.g. the llvm subproject tarball though. That used to be self-contained prior to LLVM 14. |
@aaronpuchert This solution exists in the main branch: https://reviews.llvm.org/D118481 Is this OK or would you prefer to have a separate cmake tarball? |
@tstellar, thanks for pointing that out. I guess it came to late for rc1? I've worked with a separate tarball for now, but this should also work, perhaps even without changes on my side. It would give me multiple copies of that directory, but that should be bearable since it's pretty small. |
That's great news, thanks! Does 32a0482 need to be marked for backport in a separate issue, or is this one enough? |
/cherry-pick 32a0482 |
Failed to cherry-pick: 32a0482 https://github.com/llvm/llvm-project/actions/runs/1913260431 Please manually backport the fix and push it to your github fork. Once this is done, please add a comment like this:
|
Glad |
/branch h-vetinari/llvm-project/backport_D118481 |
/pull-request llvmbot#110 |
@tstellar |
@aaronpuchert I guess a 14.0.4 will be fixed then? Or did you re-release the 14.0.3 files with paulhdk@4959d29 |
The bug is closed because by our understanding the issue has been fixed with 14.0.0, and only release candidates were affected. So what is the issue that you're seeing? The files are there, so somehow the build that you're doing doesn't pick them up. |
Well, just open the 14.0.3 release tarball (https://github.com/llvm/llvm-project/releases/download/llvmorg-14.0.3/llvm-14.0.3.src.tar.xz). There is a |
Using |
Here is a proposed change to remove the cmake bundling from each tarball and package it separately: https://reviews.llvm.org/D125798 |
As a packaging manager - I would ask that each Whilst the updated I would support NOT having 2 parent directories in the tar.gz file as |
The issue described here stems from the
Isn't that #54716 instead of this issue? |
This issue present in llvm-15.0.1 as well. |
Also, this is throwing error: llvm-project/llvm/CMakeLists.txt Line 329 in 329fda3
With file not found which is right. There is no Edit: |
With LLVM 15 you'll have to download the
I'm quite sympathetic, but large parts of the community don't care anymore about being able to build projects separately without checking out the whole monorepo.
Exactly. Usually there is no strong reason for these interdependencies and there is a way to pull them apart. |
FWIW, we consume source tarballs from released assets and build rpm from it. We don't want the full repo for that purpose and we start with the assumption that released assets are good enough to build rpms without much hassle. |
15 requires some CMake tweaks, so punting for now - llvm/llvm-project#53281
I'm very new to LLVM, cmake and all that for some project I need to modify the LLVM and build it. |
Pass this while invoking cmake -DLLVM_INCLUDE_BENCHMARKS=OFF |
I had actually used this pass -DLLVM_INCLUDE_BENCHMARKS=OFF but it still shows the error |
Which error? Note that If you see this error with the project tarballs, note that the packaging changed with LLVM 15. We're now packaging the top-level cmake directory separately, so you'll need to download that as well and unpack it next to the |
The following error
|
Can't find the setup of the sources there, so I assume you have done that manually. Where you unpack the |
@aaronpuchert |
You should rename the directory coming out of
After extraction into the same directory you should get two directories: |
The CL is for the most part changing '10' to '16'. Extra changes: * Add `/cmake/` to `.git/info/sparce-checkout`. See llvm/llvm-project#53281 * Turn OFF `LLVM_INCLUDE_BENCHMARKS` and `LLVM_INCLUDE_TESTS`. * Copy generated files from additional directories: - include/llvm/TargetParser - include/llvm/Frontend - lib/ExecutionEngine Bug: b/272710814 Change-Id: I5e18df6ba54ade60fd0e0c13069749342af99a0e Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/70950 Commit-Queue: Jean-François Geyelin <jif@google.com> Reviewed-by: Geoff Lang <geofflang@google.com> Tested-by: Jean-François Geyelin <jif@google.com>
bug is still present in release 16.0.0 |
From the master branch,copy an ExtendPath.cmake and a FindPrefixFromConfig.cmake from the dir cmake/Modules/ to your relative path cmake/modules/. |
I'm not sure which commit caused this, but when compiling against LLVM master branch, I get the following errors. Full logs attached.
Build Log:
CMakeError Log:
CMakeOutput Log:
build.log - 6WV53QV2L.txt
CMakeError.log - 99FFXC737.txt
CMakeOutput.log - HMHA288ZK.txt
The text was updated successfully, but these errors were encountered: