Skip to content

Conversation

@MaskRay
Copy link
Owner

@MaskRay MaskRay commented Jan 22, 2019

Notably, delete SYSTEM_CLANG which downloads prebuilt clang+llvm archives from releases.llvm.org

@MaskRay
Copy link
Owner Author

MaskRay commented Jan 22, 2019

This does not work currently. I must have missed something:

% cmake -H. -Bbuild -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_COMPILER=~/llvm/Stable/bin/clang++ -DCMAKE_PREFIX_PATH="$LLVM/Release;$LLVM/Release/tools/clang;$LLVM;$LLVM/tools/clang"
-- Could NOT find Clang (missing: Clang_LIBRARY Clang_INCLUDE_DIR LLVM_INCLUDE_DIR LLVM_BUILD_INCLUDE_DIR) (found suitable version "8.0.0", minimum required is "7.0.0")
-- Configuring done
CMake Error at CMakeLists.txt:12 (add_executable):
  Target "ccls" links to target "Clang::Clang" but the target was not found.
  Perhaps a find_package() call is missing for an IMPORTED target, or an
  ALIAS target is missing?


CMake Error at CMakeLists.txt:12 (add_executable):
  Target "ccls" links to target "Clang::Clang" but the target was not found.
  Perhaps a find_package() call is missing for an IMPORTED target, or an
  ALIAS target is missing?

@DaanDeMeyer I'm sorry to bother you but would you like to help?

@DaanDeMeyer
Copy link
Contributor

DaanDeMeyer commented Jan 22, 2019

Your changes work for me (Arch Linux, clang+llvm packages installed). Most likely your CMAKE_PREFIX_PATH isn't entirely correct.

Make sure the lib and bin folders with the clang libraries and binaries are in a direct subdirectory of any directory in CMAKE_PREFIX_PATH

@MaskRay MaskRay force-pushed the master branch 2 times, most recently from 8b3d5a4 to c245b40 Compare January 23, 2019 01:54
@MaskRay MaskRay force-pushed the cmake branch 4 times, most recently from c040493 to ad98bf2 Compare January 23, 2019 02:53
@MaskRay MaskRay changed the title Simplify cmake cmake: delete SYSTEM_CLANG and auto-download mechanism Jan 23, 2019
@MaskRay MaskRay merged commit a5f600a into master Jan 23, 2019
@MaskRay MaskRay deleted the cmake branch January 25, 2019 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants