Skip to content

Commit

Permalink
ARROW-17368: [C++] Add support for installing utilities (apache#13832)
Browse files Browse the repository at this point in the history
Authored-by: Sutou Kouhei <[email protected]>
Signed-off-by: Sutou Kouhei <[email protected]>
  • Loading branch information
kou authored and zagto committed Oct 7, 2022
1 parent 3dda4e5 commit a46c8f7
Show file tree
Hide file tree
Showing 5 changed files with 74 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cpp/src/arrow/ipc/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ if(ARROW_BUILD_UTILITIES OR ARROW_BUILD_INTEGRATION)
target_link_libraries(arrow-file-to-stream ${ARROW_UTIL_LIB})
add_executable(arrow-stream-to-file stream_to_file.cc)
target_link_libraries(arrow-stream-to-file ${ARROW_UTIL_LIB})
if(ARROW_BUILD_UTILITIES)
install(TARGETS arrow-file-to-stream arrow-stream-to-file ${INSTALL_IS_OPTIONAL}
DESTINATION ${CMAKE_INSTALL_BINDIR})
endif()

if(ARROW_BUILD_INTEGRATION)
add_dependencies(arrow-integration arrow-file-to-stream)
Expand Down
26 changes: 26 additions & 0 deletions dev/tasks/linux-packages/apache-arrow/debian/control.in
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,19 @@ Description: Apache Arrow is a data processing library for analysis
.
This package provides C++ library files.

Package: arrow-tools
Section: utils
Architecture: any
Multi-Arch: same
Pre-Depends: ${misc:Pre-Depends}
Depends:
${misc:Depends},
${shlibs:Depends},
libarrow1000 (= ${binary:Version})
Description: Apache Arrow is a data processing library for analysis
.
This package provides tools.

Package: libarrow-cuda1000
Section: libs
Architecture: @CUDA_ARCHITECTURE@
Expand Down Expand Up @@ -310,6 +323,19 @@ Description: Apache Parquet is a columnar storage format
.
This package provides C++ library files to process Apache Parquet format.

Package: parquet-tools
Section: utils
Architecture: any
Multi-Arch: same
Pre-Depends: ${misc:Pre-Depends}
Depends:
${misc:Depends},
${shlibs:Depends},
libparquet1000 (= ${binary:Version})
Description: Apache Parquet is a columnar storage format
.
This package provides tools.

Package: libparquet-dev
Section: libdevel
Architecture: any
Expand Down
2 changes: 2 additions & 0 deletions dev/tasks/linux-packages/apache-arrow/debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ override_dh_auto_configure:
--builddirectory=cpp_build \
--buildsystem=cmake+ninja \
-- \
-DARROW_BUILD_UTILITIES=ON \
-DARROW_COMPUTE=ON \
-DARROW_CSV=ON \
-DARROW_CUDA=$${ARROW_CUDA} \
Expand Down Expand Up @@ -60,6 +61,7 @@ override_dh_auto_configure:
-DCMAKE_BUILD_TYPE=$(BUILD_TYPE) \
-DCMAKE_UNITY_BUILD=ON \
-DCUDAToolkit_ROOT=/usr \
-DPARQUET_BUILD_EXECUTABLES=ON \
-DPARQUET_REQUIRE_ENCRYPTION=ON \
-DPythonInterp_FIND_VERSION=ON \
-DPythonInterp_FIND_VERSION_MAJOR=3
Expand Down
30 changes: 30 additions & 0 deletions dev/tasks/linux-packages/apache-arrow/yum/arrow.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ Apache Arrow is a data processing library for analysis.
cpp_build_type=release
cd cpp
%arrow_cmake \
-DARROW_BUILD_UTILITIES=ON \
-DARROW_CSV=ON \
-DARROW_DATASET=ON \
%if %{use_flight}
Expand Down Expand Up @@ -188,6 +189,7 @@ cd cpp
-DARROW_WITH_ZLIB=ON \
-DARROW_WITH_ZSTD=ON \
-DCMAKE_BUILD_TYPE=$cpp_build_type \
-DPARQUET_BUILD_EXECUTABLES=ON \
-DPARQUET_REQUIRE_ENCRYPTION=ON \
%if %{use_python}
-DPythonInterp_FIND_VERSION=ON \
Expand Down Expand Up @@ -263,6 +265,20 @@ This package contains the libraries for Apache Arrow C++.
%license LICENSE.txt NOTICE.txt
%{_libdir}/libarrow.so.*

%package tools
Summary: Tools for Apache Arrow C++
License: Apache-2.0
Requires: %{name}%{major_version}-libs = %{version}-%{release}

%description tools
Tools for Apache Arrow C++.

%files tools
%defattr(-,root,root,-)
%doc README.md
%license LICENSE.txt NOTICE.txt
%{_bindir}/arrow-*

%package devel
Summary: Libraries and header files for Apache Arrow C++
License: Apache-2.0
Expand Down Expand Up @@ -633,6 +649,20 @@ This package contains the libraries for Apache Parquet C++.
%license LICENSE.txt NOTICE.txt
%{_libdir}/libparquet.so.*

%package -n parquet-tools
Summary: Tools for Apache Parquet C++
License: Apache-2.0
Requires: parquet%{major_version}-libs = %{version}-%{release}

%description -n parquet-tools
Tools for Apache Parquet C++.

%files -n parquet-tools
%defattr(-,root,root,-)
%doc README.md
%license LICENSE.txt NOTICE.txt
%{_bindir}/parquet-*

%package -n parquet-devel
Summary: Libraries and header files for Apache Parquet C++
License: Apache-2.0
Expand Down
12 changes: 12 additions & 0 deletions dev/tasks/tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -585,6 +585,7 @@ tasks:
- .dsc
- .orig.tar.gz
artifacts:
- arrow-tools_{no_rc_version}-1_[a-z0-9]+.deb
{% if architecture == "amd64" %}
- apache-arrow-apt-source_{no_rc_version}-1.debian.tar.xz
- apache-arrow-apt-source_{no_rc_version}-1.dsc
Expand Down Expand Up @@ -648,6 +649,7 @@ tasks:
- libparquet-glib1000_{no_rc_version}-1_[a-z0-9]+.deb
- libparquet1000-dbgsym_{no_rc_version}-1_[a-z0-9]+.d?deb
- libparquet1000_{no_rc_version}-1_[a-z0-9]+.deb
- parquet-tools_{no_rc_version}-1_[a-z0-9]+.deb
{% if architecture == "amd64" %}
- gir1.2-arrow-cuda-1.0_{no_rc_version}-1_[a-z0-9]+.deb
- gir1.2-plasma-1.0_{no_rc_version}-1_[a-z0-9]+.deb
Expand Down Expand Up @@ -756,6 +758,11 @@ tasks:
{% endif %}
{% if architecture == "amd64" %}
- arrow-{no_rc_version}-1.[a-z0-9]+.src.rpm
{% endif %}
- arrow-tools-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
- arrow-tools-debuginfo-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
{% if not is_rhel7_based %}
- arrow-tools-debugsource-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
{% endif %}
{% if not is_rhel7_based and architecture == "amd64" %}
- gandiva-devel-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
Expand All @@ -777,6 +784,11 @@ tasks:
- parquet[0-9]+-libs-debuginfo-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
{% endif %}
- parquet[0-9]+-libs-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
- parquet-tools-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
- parquet-tools-debuginfo-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
{% if not is_rhel7_based %}
- parquet-tools-debugsource-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
{% endif %}
- plasma-devel-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
- plasma-glib-devel-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
- plasma-glib-doc-{no_rc_version}-1.[a-z0-9]+.[a-z0-9_]+.rpm
Expand Down

0 comments on commit a46c8f7

Please sign in to comment.