Skip to content

Commit

Permalink
add FreeBSD support for detetecting libclang
Browse files Browse the repository at this point in the history
  • Loading branch information
monwarez committed Jul 27, 2017
1 parent 6463774 commit 211a73f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cpp/ycm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,8 @@ if ( EXTERNAL_LIBCLANG_PATH OR USE_SYSTEM_LIBCLANG )
endif()
# On Debian-based systems, llvm installs into /usr/lib/llvm-x.y.
file( GLOB SYS_LLVM_PATHS "/usr/lib/llvm*/lib" )
# On FreeBSD , llvm install into /usr/local/llvm-xy
file ( GLOB FREEBSD_LLVM_PATHS "/usr/local/llvm*/lib")
# Need TEMP because find_library does not work with an option variable
# On Debian-based systems only a symlink to libclang.so.1 is created
find_library( TEMP
Expand All @@ -290,6 +292,7 @@ if ( EXTERNAL_LIBCLANG_PATH OR USE_SYSTEM_LIBCLANG )
/usr/lib
/usr/lib/llvm
${SYS_LLVM_PATHS}
${FREEBSD_LLVM_PATHS}
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib
/Library/Developer/CommandLineTools/usr/lib )
set( EXTERNAL_LIBCLANG_PATH ${TEMP} )
Expand Down

0 comments on commit 211a73f

Please sign in to comment.