This is an automated email from the ASF dual-hosted git repository.
iwasakims pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/hadoop.git
The following commit(s) were added to refs/heads/trunk by this push:
new d5467d2 HADOOP-16739. Fix native build failure of hadoop-pipes on
CentOS 8.
d5467d2 is described below
commit d5467d299db3dddcbcd2f77a281d5fa82c4a9e4b
Author: Masatake Iwasaki <[email protected]>
AuthorDate: Mon Feb 10 12:55:04 2020 +0900
HADOOP-16739. Fix native build failure of hadoop-pipes on CentOS 8.
---
BUILDING.txt | 41 ++++++++++++++++++++++++++++
hadoop-tools/hadoop-pipes/src/CMakeLists.txt | 22 +++++++++++++++
2 files changed, 63 insertions(+)
diff --git a/BUILDING.txt b/BUILDING.txt
index b647cdd..2af739e 100644
--- a/BUILDING.txt
+++ b/BUILDING.txt
@@ -417,6 +417,47 @@ Building command example:
Note that the command above manually specified the openssl library and include
path. This is necessary at least for Homebrewed OpenSSL.
+
+----------------------------------------------------------------------------------
+
+Building on CentOS 8
+
+----------------------------------------------------------------------------------
+
+
+* Install development tools such as GCC, autotools, OpenJDK and Maven.
+ $ sudo dnf group install 'Development Tools'
+ $ sudo dnf install java-1.8.0-openjdk-devel maven
+
+* Install Protocol Buffers v3.7.1.
+ $ git clone https://github.com/protocolbuffers/protobuf
+ $ cd protobuf
+ $ git checkout v3.7.1
+ $ autoreconf -i
+ $ ./configure --prefix=/usr/local
+ $ make
+ $ sudo make install
+ $ cd ..
+
+* Install libraries provided by CentOS 8.
+ $ sudo dnf install libtirpc-devel zlib-devel lz4-devel bzip2-devel
openssl-devel cyrus-sasl-devel libpmem-devel
+
+* Install optional dependencies (snappy-devel).
+ $ sudo dnf --enablerepo=PowerTools snappy-devel
+
+* Install optional dependencies (libzstd-devel).
+ $ sudo dnf install
https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
+ $ sudo dnf --enablerepo=epel install libzstd-devel
+
+* Install optional dependencies (isa-l).
+ $ sudo dnf --enablerepo=PowerTools install nasm
+ $ git clone https://github.com/intel/isa-l
+ $ cd isa-l/
+ $ ./autogen.sh
+ $ ./configure
+ $ make
+ $ sudo make install
+
----------------------------------------------------------------------------------
Building on Windows
diff --git a/hadoop-tools/hadoop-pipes/src/CMakeLists.txt
b/hadoop-tools/hadoop-pipes/src/CMakeLists.txt
index ff660bf..ce6ee31 100644
--- a/hadoop-tools/hadoop-pipes/src/CMakeLists.txt
+++ b/hadoop-tools/hadoop-pipes/src/CMakeLists.txt
@@ -22,6 +22,25 @@ list(APPEND CMAKE_MODULE_PATH
${CMAKE_SOURCE_DIR}/../../../hadoop-common-project
include(HadoopCommon)
find_package(OpenSSL REQUIRED)
+find_package(PkgConfig QUIET)
+pkg_check_modules(LIBTIRPC libtirpc)
+
+find_path(RPC_INCLUDE_DIRS NAMES rpc/rpc.h)
+
+if (NOT RPC_INCLUDE_DIRS)
+ find_path(TIRPC_INCLUDE_DIRS
+ NAMES netconfig.h
+ PATH_SUFFIXES tirpc
+ HINTS ${LIBTIRPC_INCLUDE_DIRS}
+ )
+
+ find_library(TIRPC_LIBRARIES
+ NAMES tirpc
+ HINTS ${LIBTIRPC_LIBRARY_DIRS}
+ )
+
+ include_directories(${TIRPC_INCLUDE_DIRS})
+endif()
include_directories(
main/native/utils/api
@@ -51,6 +70,9 @@ add_library(hadooputils STATIC
main/native/utils/impl/StringUtils.cc
main/native/utils/impl/SerialUtils.cc
)
+if (NOT RPC_INCLUDE_DIRS AND LIBTIRPC_FOUND)
+ target_link_libraries(hadooputils tirpc)
+endif()
add_library(hadooppipes STATIC
main/native/pipes/impl/HadoopPipes.cc
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]