Changeset: eaa71cbdc896 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=eaa71cbdc896
Modified Files:
        cmake/monetdb-defines.cmake
        sql/backends/monet5/UDF/pyapi3/CMakeLists.txt
Branch: oscar
Log Message:

Compile and install pyapi on Windows.


diffs (41 lines):

diff --git a/cmake/monetdb-defines.cmake b/cmake/monetdb-defines.cmake
--- a/cmake/monetdb-defines.cmake
+++ b/cmake/monetdb-defines.cmake
@@ -151,6 +151,7 @@ macro(monetdb_macro_variables)
 
   if(PY3INTEGRATION)
     set(HAVE_LIBPY3 "${Python3_NumPy_FOUND}")
+    set(PY3VER "${Python3_VERSION_MINOR}")
   else()
     message(STATUS "Disable Py3integration, because required NumPy is missing")
   endif()
diff --git a/sql/backends/monet5/UDF/pyapi3/CMakeLists.txt 
b/sql/backends/monet5/UDF/pyapi3/CMakeLists.txt
--- a/sql/backends/monet5/UDF/pyapi3/CMakeLists.txt
+++ b/sql/backends/monet5/UDF/pyapi3/CMakeLists.txt
@@ -53,6 +53,10 @@ if(HAVE_LIBPY3)
     monetdb5
     monetdb_config_header)
 
+  target_compile_definitions(pyapi3
+    PRIVATE
+    LIBPYAPI3)
+
   set_target_properties(pyapi3
     PROPERTIES 
     OUTPUT_NAME 
@@ -70,8 +74,14 @@ if(HAVE_LIBPY3)
     INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
 
   if(WIN32)
+    configure_file(pyapi_locatepython3.bat.in
+      ${CMAKE_CURRENT_BINARY_DIR}/pyapi_locatepython3.bat @ONLY)
+
     install(FILES $<TARGET_PDB_FILE:pyapi3> DESTINATION ${LIBDIR}/monetdb5 
OPTIONAL)
-    install(FILES pyapi_locatepython3.bat DESTINATION ${CMAKE_INSTALL_PREFIX})
+    install(FILES
+      ${CMAKE_CURRENT_BINARY_DIR}/pyapi_locatepython3.bat
+      DESTINATION ${CMAKE_INSTALL_PREFIX}
+      COMPONENT server)
   endif()
 endif()
 # vim: set ts=2:sw=2:et
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to