Skip to content

Commit

Permalink
[llvm]Fix build error on x64-windows. (#6631)
Browse files Browse the repository at this point in the history
  • Loading branch information
JackBoosY authored and Rastaban committed May 29, 2019
1 parent 2144587 commit 93ceb1a
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ports/llvm/CONTROL
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Source: llvm
Version: 7.0.0-2
Version: 7.0.0-3
Description: The LLVM Compiler Infrastructure
Build-Depends: atlmfc (windows)
16 changes: 16 additions & 0 deletions ports/llvm/fix-build-error.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
diff --git a/tools/clang/tools/libclang/CMakeLists.txt b/tools/clang/tools/libclang/CMakeLists.txt
index e539c83..09c1ea3 100644
--- a/tools/clang/tools/libclang/CMakeLists.txt
+++ b/tools/clang/tools/libclang/CMakeLists.txt
@@ -56,10 +56,7 @@ if (TARGET clangTidyPlugin)
endif()
endif ()

-find_library(DL_LIBRARY_PATH dl)
-if (DL_LIBRARY_PATH)
- list(APPEND LIBS dl)
-endif()
+list(APPEND LIBS "${DL_LIBRARY_PATH}")

option(LIBCLANG_BUILD_STATIC
"Build libclang as a static library (in addition to a shared one)" OFF)
4 changes: 3 additions & 1 deletion ports/llvm/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ endif()

vcpkg_apply_patches(
SOURCE_PATH ${SOURCE_PATH}
PATCHES ${CMAKE_CURRENT_LIST_DIR}/install-cmake-modules-to-share.patch
PATCHES
install-cmake-modules-to-share.patch
fix-build-error.patch
)

vcpkg_find_acquire_program(PYTHON3)
Expand Down

0 comments on commit 93ceb1a

Please sign in to comment.