Author: Stella Laurenzo
Date: 2020-12-31T00:11:39-08:00
New Revision: a16c00a7033df6863f3ecd77a9809790f8db286b

URL: 
https://github.com/llvm/llvm-project/commit/a16c00a7033df6863f3ecd77a9809790f8db286b
DIFF: 
https://github.com/llvm/llvm-project/commit/a16c00a7033df6863f3ecd77a9809790f8db286b.diff

LOG: [mlir][python] Fix python extension building on windows.

Added: 
    

Modified: 
    mlir/cmake/modules/AddMLIRPythonExtension.cmake

Removed: 
    


################################################################################
diff  --git a/mlir/cmake/modules/AddMLIRPythonExtension.cmake 
b/mlir/cmake/modules/AddMLIRPythonExtension.cmake
index eaba5214b5a8..290b4a23aa31 100644
--- a/mlir/cmake/modules/AddMLIRPythonExtension.cmake
+++ b/mlir/cmake/modules/AddMLIRPythonExtension.cmake
@@ -44,6 +44,10 @@ function(add_mlir_python_extension libname extname)
     "${pybind11_INCLUDE_DIR}"
   )
 
+  target_link_directories(${libname} PRIVATE
+    "${Python3_LIBRARY_DIRS}"
+  )
+
   # The extension itself must be compiled with RTTI and exceptions enabled.
   # Also, some warning classes triggered by pybind11 are disabled.
   target_compile_options(${libname} PRIVATE


        
_______________________________________________
llvm-branch-commits mailing list
llvm-branch-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

Reply via email to