Use CLANG_INCLUDE_DIRS for clang include dir

Authored by buschinski on Oct 4 2018, 6:17 PM.

Description

Use CLANG_INCLUDE_DIRS for clang include dir

Summary:
Use CLANG_INCLUDE_DIRS for clang include dir instead of manually building it.

This fixes the error:
kdevplatform.shell: Could not load plugin "kdevclangsupport" , it reported the error: "The clang builtin include path \"/usr/lib64/llvm/7/lib64/clang/7.0.0/include\" is invalid (missing cpuid.h header).\nTry setting the KDEV_CLANG_BUILTIN_DIR environment variable manually to fix this.\nSee also: https://bugs.kde.org/show_bug.cgi?id=393779" Disabling the plugin now.

As CMake with CLANG_INCLUDE_DIRS already tests if this folder is present, it should work across all distros.

CCBUG: 393779

Reviewers: KDevelop, kfunk

Reviewed By: KDevelop, kfunk

Subscribers: mwolff, aaronpuchert, brauch, kossebau, kfunk, arrowd, kdevelop-devel

Tags: KDevelop

Differential Revision: https://phabricator.kde.org/D15895

Details