Skip to content
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

llvm/include/llvm/Config/llvm-config.h and clang/AST/DeclNodes.inc missing #58260

Open
Leon-Zhang opened this issue Oct 10, 2022 · 5 comments
Open

Comments

@Leon-Zhang
Copy link

Leon-Zhang commented Oct 10, 2022

I have been using cmake gui with following configurations

(LLVM_ENABLE_PROJECTS="clang;lldb;clang-tools-extra")

to generate sln visual studio project file for build, it can compile, but llvm-config.h file is not generated (from llvm/Config/llvm-config.h.cmake);
Also tried to include clang frontend and matcher headers, but gives inc file not found:

Error	C1083	Cannot open include file: 'clang/AST/DeclNodes.inc': No such file or directory
clang\include\clang\AST\ASTFwd.h	21

how to fix this? Thanks.

@Leon-Zhang
Copy link
Author

Leon-Zhang commented Oct 10, 2022

Double checked,
"llvm\include\llvm\Config\llvm-config.h.cmake"
"llvm\include\llvm\Config\abi-breaking.h.cmake"
"llvm\include\llvm\Config\config.h.cmake"

Above 3 cmake files suppose to generate(process by llvm\utils\gn\build\write_cmake_config.py) corresponding header files while they did not as intended.

@Leon-Zhang Leon-Zhang changed the title llvm-config.h missing llvm-config.h and clang/AST/DeclNodes.inc missing Oct 11, 2022
@Leon-Zhang Leon-Zhang changed the title llvm-config.h and clang/AST/DeclNodes.inc missing llvm/include/Config/llvm-config.h and clang/AST/DeclNodes.inc missing Oct 11, 2022
@Leon-Zhang Leon-Zhang changed the title llvm/include/Config/llvm-config.h and clang/AST/DeclNodes.inc missing llvm/include/llvm/Config/llvm-config.h and clang/AST/DeclNodes.inc missing Oct 11, 2022
@Leon-Zhang
Copy link
Author

Leon-Zhang commented Oct 21, 2022

Update: I am able to build using command line mode in console(MINGW64) instead of using visual stduio, seems missing files mentioned above are able to be produced by following command
cmake -DCMAKE_INSTALL_PREFIX=/e/ProgramFiles/llvm -DCMAKE_INSTALL_CONFIG_NAME=Debug -P cmake_install.cmake

But from cmake gui, seems there is no gui interface to execute such command.

@PavelKotov1
Copy link

Hello, dear friends!
I am having similar problem in llvm 16.02:
llvm-config.h header file is missing in the include\Config folder. There is llvm-config.h.cmake file present, but I am very new to cmake and cannot figure out how to produce llvm-config.h using the command from the previous post by Leon-Zhang [on Oct 21, 2022].
Could somebody be so nice and kind and explain how to produce the needed header by giving me detailed possibly step by step instructions.
With kind regards, Pavel Kotov.

@jaydaftari
Copy link

Hello, dear friends! I am having similar problem in llvm 16.02: llvm-config.h header file is missing in the include\Config folder. There is llvm-config.h.cmake file present, but I am very new to cmake and cannot figure out how to produce llvm-config.h using the command from the previous post by Leon-Zhang [on Oct 21, 2022]. Could somebody be so nice and kind and explain how to produce the needed header by giving me detailed possibly step by step instructions. With kind regards, Pavel Kotov.

Hi, Did you get the solution, I am facing the same issue currently.

@Leon-Zhang
Copy link
Author

Leon-Zhang commented Jan 14, 2025

Hello, dear friends! I am having similar problem in llvm 16.02: llvm-config.h header file is missing in the include\Config folder. There is llvm-config.h.cmake file present, but I am very new to cmake and cannot figure out how to produce llvm-config.h using the command from the previous post by Leon-Zhang [on Oct 21, 2022]. Could somebody be so nice and kind and explain how to produce the needed header by giving me detailed possibly step by step instructions. With kind regards, Pavel Kotov.

Just use command line cmake to build, something like
cmake -DCMAKE_INSTALL_PREFIX=/e/ProgramFiles/llvm -DCMAKE_INSTALL_CONFIG_NAME=Debug -P cmake_install.cmake
@PavelKotov1 @jaydaftari

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants