You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by we...@apache.org on 2017/07/09 04:37:25 UTC

arrow git commit: ARROW-1193: [C++] Support pkg-config for arrow_python.so

Repository: arrow
Updated Branches:
  refs/heads/master 3309d1268 -> b6b876c52


ARROW-1193: [C++] Support pkg-config for arrow_python.so

I want it to create a Ruby library that integrates Python via Apache Arrow object in the same process.
[pycall](https://rubygems.org/gems/pycall) gem provides a feature to use Python objects in Ruby script in the same process. In this situation, we can change Apache Arrow data between Ruby and Python as Ruby/Python object instead of writing/reading Apache Arrow objects.

Author: Kouhei Sutou <ko...@clear-code.com>

Closes #821 from kou/cpp-python-support-pkg-config and squashes the following commits:

12979fca [Kouhei Sutou] [C++] Don't link libpython
f473e667 [Kouhei Sutou] [C++] Support pkg-config for arrow_python.so


Project: http://git-wip-us.apache.org/repos/asf/arrow/repo
Commit: http://git-wip-us.apache.org/repos/asf/arrow/commit/b6b876c5
Tree: http://git-wip-us.apache.org/repos/asf/arrow/tree/b6b876c5
Diff: http://git-wip-us.apache.org/repos/asf/arrow/diff/b6b876c5

Branch: refs/heads/master
Commit: b6b876c52effa11e623fda464c3230fb9f4f26d3
Parents: 3309d12
Author: Kouhei Sutou <ko...@clear-code.com>
Authored: Sun Jul 9 00:37:21 2017 -0400
Committer: Wes McKinney <we...@twosigma.com>
Committed: Sun Jul 9 00:37:21 2017 -0400

----------------------------------------------------------------------
 cpp/src/arrow/python/CMakeLists.txt     |  8 ++++++++
 cpp/src/arrow/python/arrow-python.pc.in | 27 +++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/arrow/blob/b6b876c5/cpp/src/arrow/python/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/cpp/src/arrow/python/CMakeLists.txt b/cpp/src/arrow/python/CMakeLists.txt
index bc2a815..d5e980b 100644
--- a/cpp/src/arrow/python/CMakeLists.txt
+++ b/cpp/src/arrow/python/CMakeLists.txt
@@ -95,6 +95,14 @@ install(FILES
   type_traits.h
   DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/arrow/python")
 
+# pkg-config support
+configure_file(arrow-python.pc.in
+  "${CMAKE_CURRENT_BINARY_DIR}/arrow-python.pc"
+  @ONLY)
+install(
+  FILES "${CMAKE_CURRENT_BINARY_DIR}/arrow-python.pc"
+  DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig/")
+
 if (ARROW_BUILD_TESTS)
   ADD_ARROW_TEST(python-test
     STATIC_LINK_LIBS "${ARROW_PYTHON_TEST_LINK_LIBS}")

http://git-wip-us.apache.org/repos/asf/arrow/blob/b6b876c5/cpp/src/arrow/python/arrow-python.pc.in
----------------------------------------------------------------------
diff --git a/cpp/src/arrow/python/arrow-python.pc.in b/cpp/src/arrow/python/arrow-python.pc.in
new file mode 100644
index 0000000..11e33c5
--- /dev/null
+++ b/cpp/src/arrow/python/arrow-python.pc.in
@@ -0,0 +1,27 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+prefix=@CMAKE_INSTALL_PREFIX@
+libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
+includedir=${prefix}/include
+
+Name: Apache Arrow Python
+Description: Python integration library for Apache Arrow
+Version: @ARROW_VERSION@
+Requires: arrow
+Libs: -L${libdir} -larrow_python
+Cflags: -I${includedir} -I@PYTHON_INCLUDE_DIRS@