You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by mm...@apache.org on 2021/02/12 17:30:27 UTC
[pulsar] branch master updated: Add missing python 3.9 paths in
CmakeLists.txt (#9574)
This is an automated email from the ASF dual-hosted git repository.
mmerli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar.git
The following commit(s) were added to refs/heads/master by this push:
new e930868 Add missing python 3.9 paths in CmakeLists.txt (#9574)
e930868 is described below
commit e930868cb9000a6b90539db483eddaaed305c6a1
Author: Ali Ahmed <al...@gmail.com>
AuthorDate: Fri Feb 12 09:29:50 2021 -0800
Add missing python 3.9 paths in CmakeLists.txt (#9574)
---
pulsar-client-cpp/CMakeLists.txt | 2 +-
pulsar-client-cpp/python/CMakeLists.txt | 39 +++++++++++++++++++++++----------
2 files changed, 28 insertions(+), 13 deletions(-)
diff --git a/pulsar-client-cpp/CMakeLists.txt b/pulsar-client-cpp/CMakeLists.txt
index 580bf74..3fe63e0 100644
--- a/pulsar-client-cpp/CMakeLists.txt
+++ b/pulsar-client-cpp/CMakeLists.txt
@@ -201,7 +201,7 @@ if (BUILD_PYTHON_WRAPPER)
list(GET PYTHONLIBS_VERSION_NO_LIST 1 PYTHONLIBS_VERSION_MINOR)
set(BOOST_PYTHON_NAME_POSTFIX ${PYTHONLIBS_VERSION_MAJOR}${PYTHONLIBS_VERSION_MINOR})
# For python3 the lib name is boost_python3
- set(BOOST_PYTHON_NAME_LIST python36;python37;python38;python3;python3-mt;python-py${BOOST_PYTHON_NAME_POSTFIX};python${BOOST_PYTHON_NAME_POSTFIX}-mt;python${BOOST_PYTHON_NAME_POSTFIX})
+ set(BOOST_PYTHON_NAME_LIST python36;python37;python38;python39;python3;python3-mt;python-py${BOOST_PYTHON_NAME_POSTFIX};python${BOOST_PYTHON_NAME_POSTFIX}-mt;python${BOOST_PYTHON_NAME_POSTFIX})
else ()
# Regular boost_python
set(BOOST_PYTHON_NAME_LIST python;python-mt;python-py27;python27-mt;python27)
diff --git a/pulsar-client-cpp/python/CMakeLists.txt b/pulsar-client-cpp/python/CMakeLists.txt
index 985aaf8..2607ab3 100644
--- a/pulsar-client-cpp/python/CMakeLists.txt
+++ b/pulsar-client-cpp/python/CMakeLists.txt
@@ -19,14 +19,20 @@
INCLUDE_DIRECTORIES("${Boost_INCLUDE_DIRS}" "${PYTHON_INCLUDE_DIRS}")
-ADD_LIBRARY(_pulsar SHARED src/pulsar.cc src/producer.cc src/consumer.cc
- src/config.cc src/enums.cc src/client.cc
- src/message.cc src/authentication.cc
- src/reader.cc src/schema.cc)
+ADD_LIBRARY(_pulsar SHARED src/pulsar.cc
+ src/producer.cc
+ src/consumer.cc
+ src/config.cc
+ src/enums.cc
+ src/client.cc
+ src/message.cc
+ src/authentication.cc
+ src/reader.cc
+ src/schema.cc)
+
SET(CMAKE_SHARED_LIBRARY_PREFIX )
SET(CMAKE_SHARED_LIBRARY_SUFFIX .so)
-
if (NOT APPLE AND NOT MSVC)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS_PYTHON}")
endif()
@@ -48,18 +54,27 @@ if (NOT DEFINED ${Boost_PYTHON38-MT_LIBRARY})
set(Boost_PYTHON38-MT_LIBRARY ${Boost_PYTHON38_LIBRARY})
endif()
+if (NOT DEFINED ${Boost_PYTHON39-MT_LIBRARY})
+ set(Boost_PYTHON39-MT_LIBRARY ${Boost_PYTHON39_LIBRARY})
+endif()
+
# Try all possible boost-python variable namings
-set(PYTHON_WRAPPER_LIBS ${Boost_PYTHON_LIBRARY} ${Boost_PYTHON3_LIBRARY}
- ${Boost_PYTHON27-MT_LIBRARY} ${Boost_PYTHON37-MT_LIBRARY}
- ${Boost_PYTHON34_LIBRARY} ${Boost_PYTHON35_LIBRARY}
- ${Boost_PYTHON36_LIBRARY} ${Boost_PYTHON38_LIBRARY}
+set(PYTHON_WRAPPER_LIBS ${Boost_PYTHON_LIBRARY}
+ ${Boost_PYTHON3_LIBRARY}
+ ${Boost_PYTHON27-MT_LIBRARY}
+ ${Boost_PYTHON37-MT_LIBRARY}
+ ${Boost_PYTHON34_LIBRARY}
+ ${Boost_PYTHON35_LIBRARY}
+ ${Boost_PYTHON36_LIBRARY}
+ ${Boost_PYTHON38_LIBRARY}
${Boost_PYTHON39_LIBRARY})
if (APPLE)
set(PYTHON_WRAPPER_LIBS ${PYTHON_WRAPPER_LIBS}
- ${Boost_PYTHON27-MT_LIBRARY_RELEASE}
- ${Boost_PYTHON37-MT_LIBRARY_RELEASE}
- ${Boost_PYTHON38-MT_LIBRARY_RELEASE})
+ ${Boost_PYTHON27-MT_LIBRARY_RELEASE}
+ ${Boost_PYTHON37-MT_LIBRARY_RELEASE}
+ ${Boost_PYTHON38-MT_LIBRARY_RELEASE}
+ ${Boost_PYTHON39-MT_LIBRARY_RELEASE})
endif()
message(STATUS "Using Boost Python libs: ${PYTHON_WRAPPER_LIBS}")