This is an automated email from the ASF dual-hosted git repository.
kou pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git
The following commit(s) were added to refs/heads/master by this push:
new 739ea77 ARROW-3455: [Gandiva][C++] Support pkg-config for Gandiva
739ea77 is described below
commit 739ea7740fe8713251cf906299acc900275a98f5
Author: Yosuke Shiro <[email protected]>
AuthorDate: Tue Oct 9 13:51:44 2018 +0900
ARROW-3455: [Gandiva][C++] Support pkg-config for Gandiva
Because we can detect whether Gandiva are built or not by pkg-config.
Author: Yosuke Shiro <[email protected]>
Closes #2729 from shiro615/cpp-support-pkg-config-for-gandiva and squashes
the following commits:
881c3b83 <Yosuke Shiro> Use 'Arrow' instead of 'arrow'
874c0cb1 <Yosuke Shiro> Support pkg-config for Gandiva
---
cpp/src/gandiva/CMakeLists.txt | 8 ++++++++
cpp/src/gandiva/gandiva.pc.in | 27 +++++++++++++++++++++++++++
2 files changed, 35 insertions(+)
diff --git a/cpp/src/gandiva/CMakeLists.txt b/cpp/src/gandiva/CMakeLists.txt
index d47a685..1ca9e98 100644
--- a/cpp/src/gandiva/CMakeLists.txt
+++ b/cpp/src/gandiva/CMakeLists.txt
@@ -150,6 +150,14 @@ install(FILES
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
)
+# pkg-config support
+configure_file(gandiva.pc.in
+ "${CMAKE_CURRENT_BINARY_DIR}/gandiva.pc"
+ @ONLY)
+install(
+ FILES "${CMAKE_CURRENT_BINARY_DIR}/gandiva.pc"
+ DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig/")
+
#args: label test-file src-files
add_gandiva_unit_test(bitmap_accumulator_test.cc bitmap_accumulator.cc)
add_gandiva_unit_test(engine_llvm_test.cc engine.cc llvm_types.cc
configuration.cc ${BC_FILE_PATH_CC})
diff --git a/cpp/src/gandiva/gandiva.pc.in b/cpp/src/gandiva/gandiva.pc.in
new file mode 100644
index 0000000..22ff11a
--- /dev/null
+++ b/cpp/src/gandiva/gandiva.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}/@CMAKE_INSTALL_INCLUDEDIR@
+
+Name: Gandiva
+Description: Gandiva is a toolset for compiling and evaluating expressions on
Arrow data.
+Version: @GANDIVA_VERSION@
+Requires: arrow
+Libs: -L${libdir} -lgandiva
+Cflags: -I${includedir}