kou commented on PR #41395:
URL: https://github.com/apache/arrow/pull/41395#issuecomment-2080101740
```diff
diff --git a/dev/tasks/linux-packages/apache-arrow/yum/arrow.spec.in
b/dev/tasks/linux-packages/apache-arrow/yum/arrow.spec.in
index 3ede1814b8..258759a1ec 100644
--- a/dev/tasks/linux-packages/apache-arrow/yum/arrow.spec.in
+++ b/dev/tasks/linux-packages/apache-arrow/yum/arrow.spec.in
@@ -25,19 +25,8 @@
%define _rhel %{?rhel:%{rhel}}%{!?rhel:0}
%define is_rhel (%{_rhel} != 0)
-%define is_centos_7 (%{_rhel} == 7 && !%{is_amazon_linux})
-
%define major_version %(echo @VERSION@ | grep -o '^[0-9]*')
-%define boost_version %( \
- if [ %{_rhel} -eq 7 ]; then \
- echo 169; \
- fi)
-%define cmake_version %( \
- if [ %{_rhel} -eq 7 ]; then \
- echo 3; \
- fi)
-
%define lz4_requirement %( \
if [ %{_amzn} -eq 0 ]; then \
echo ">= 1.8.0"; \
@@ -55,31 +44,17 @@
%define arrow_cmake_install DESTDIR="%{buildroot}" make -C
%{arrow_cmake_builddir} install
%endif
-%if %{is_centos_7}
-%define gcc_package devtoolset-11-gcc
-%else
-%define gcc_package gcc
-%endif
-
-%define use_flight (%{_rhel} >= 8 || %{_amzn} >= 2023)
-%define use_gandiva (%{_rhel} >= 8 || %{_amzn} >= 2023)
-%define use_gcs (%{_rhel} >= 8)
%define use_gflags (!%{is_amazon_linux})
## TODO: Enable this when glog stopped depending on gflags-devel.
# %%define use_glog (%%{_rhel} <= 8)
%define use_glog 0
-%define use_mimalloc (%{_rhel} >= 8)
# TODO: Enable this. This works on local but is fragile on GitHub Actions
and
# Travis CI.
# %%define use_s3 (%%{_rhel} >= 8)
%define use_s3 0
-%define use_vala (%{_rhel} >= 8 || %{is_amazon_linux})
%define have_grpc (%{_amzn} >= 2023)
-%define have_lz4_libs (%{_rhel} >= 8 || %{_amzn} >= 2023)
%define have_rapidjson (%{_rhel} != 8)
-%define have_re2 (%{_rhel} >= 8 || %{_amzn} >= 2023)
-%define have_thrift (%{_rhel} >= 8)
%define have_utf8proc (%{_rhel} >= 9 || %{_amzn} >= 2023)
%define enable_glib_doc (%{_rhel} >= 9 || %{is_amazon_linux})
@@ -94,16 +69,14 @@ URL: https://arrow.apache.org/
Source0:
https://dist.apache.org/repos/dist/release/@PACKAGE@/@PACKAGE@-%{version}/apache-@PACKAGE@-%{version}.tar.gz
BuildRequires: bison
-BuildRequires: boost%{boost_version}-devel
+BuildRequires: boost-devel
BuildRequires: brotli-devel
BuildRequires: bzip2-devel
-%if %{use_flight}
BuildRequires: c-ares-devel
-%endif
-BuildRequires: cmake%{cmake_version}
+BuildRequires: cmake
BuildRequires: curl-devel
BuildRequires: flex
-BuildRequires: %{gcc_package}-c++
+BuildRequires: gcc-c++
%if %{use_gflags}
BuildRequires: gflags-devel
%endif
@@ -115,38 +88,27 @@ BuildRequires: glog-devel
BuildRequires: grpc-devel
BuildRequires: grpc-plugins
%endif
-%if %{use_gcs}
BuildRequires: json-devel
-%endif
BuildRequires: libzstd-devel
+BuildRequires: llvm-devel
BuildRequires: lz4-devel %{lz4_requirement}
+BuildRequires: ncurses-devel
BuildRequires: ninja-build
BuildRequires: openssl-devel
BuildRequires: pkgconfig
%if %{have_rapidjson}
BuildRequires: rapidjson-devel
%endif
-%if %{have_re2}
BuildRequires: re2-devel
-%endif
BuildRequires: snappy-devel
-%if %{have_thrift}
BuildRequires: thrift-devel
-%endif
%if %{have_utf8proc}
BuildRequires: utf8proc-devel
%endif
BuildRequires: zlib-devel
-%if %{use_gandiva}
-BuildRequires: llvm-devel
-BuildRequires: ncurses-devel
-%endif
-
BuildRequires: gobject-introspection-devel
-%if %{use_vala}
BuildRequires: vala
-%endif
%description
Apache Arrow is a data processing library for analysis.
@@ -161,21 +123,13 @@ cd cpp
-DARROW_BUILD_UTILITIES=ON \
-DARROW_CSV=ON \
-DARROW_DATASET=ON \
-%if %{use_flight}
-DARROW_FLIGHT=ON \
-DARROW_FLIGHT_SQL=ON \
-%endif
-%if %{use_gandiva}
-DARROW_GANDIVA=ON \
-%endif
-%if %{use_gcs}
-DARROW_GCS=ON \
-%endif
-DARROW_HDFS=ON \
-DARROW_JSON=ON \
-%if %{use_mimalloc}
-DARROW_MIMALLOC=ON \
-%endif
-DARROW_ORC=ON \
-DARROW_PACKAGE_KIND=rpm \
-DARROW_PARQUET=ON \
@@ -200,12 +154,7 @@ cd c_glib
%if %{_amzn} >= 2023
# Do nothing
%else
- %if %{is_centos_7}
- # Meson 0.62.0 or later requires Python 3.7 or later.
- pip3 install 'meson<0.62.0'
- %else
- pip3 install meson
- %endif
+ pip3 install meson
%endif
%if %{enable_glib_doc}
pip3 install gi-docgen
@@ -219,9 +168,7 @@ meson setup build \
%if %{enable_glib_doc}
-Ddoc=true \
%endif
-%if %{use_vala}
-Dvapi=true
-%endif
LD_LIBRARY_PATH=$PWD/../cpp/%{arrow_cmake_builddir}/$cpp_build_type \
meson compile -C build %{?_smp_mflags}
@@ -242,11 +189,7 @@ cd -
%package -n %{name}%{major_version}-libs
Summary: Runtime libraries for Apache Arrow C++
License: Apache-2.0
-%if %{have_lz4_libs}
Requires: lz4-libs %{lz4_requirement}
-%else
-Requires: lz4 %{lz4_requirement}
-%endif
%description -n %{name}%{major_version}-libs
This package contains the libraries for Apache Arrow C++.
@@ -278,18 +221,14 @@ Requires: %{name}%{major_version}-libs =
%{version}-%{release}
Requires: brotli-devel
Requires: bzip2-devel
Requires: curl-devel
-%if %{use_gcs}
Requires: json-devel
-%endif
Requires: libzstd-devel
Requires: lz4-devel %{lz4_requirement}
Requires: openssl-devel
%if %{have_rapidjson}
Requires: rapidjson-devel
%endif
-%if %{have_re2}
Requires: re2-devel
-%endif
Requires: snappy-devel
%if %{have_utf8proc}
Requires: utf8proc-devel
@@ -308,9 +247,7 @@ Libraries and header files for Apache Arrow C++.
%{_includedir}/arrow/
%exclude %{_includedir}/arrow/acero/
%exclude %{_includedir}/arrow/dataset/
-%if %{use_flight}
%exclude %{_includedir}/arrow/flight/
-%endif
%{_libdir}/cmake/Arrow/
%{_libdir}/libarrow.a
%{_libdir}/libarrow.so
@@ -390,7 +327,6 @@ Libraries and header files for Apache Arrow dataset.
%{_libdir}/libarrow_dataset.so
%{_libdir}/pkgconfig/arrow-dataset.pc
-%if %{use_flight}
%package -n %{name}%{major_version}-flight-libs
Summary: C++ library for fast data transport.
License: Apache-2.0
@@ -462,9 +398,7 @@ Libraries and header files for Apache Arrow Flight SQL.
%{_libdir}/libarrow_flight_sql.a
%{_libdir}/libarrow_flight_sql.so
%{_libdir}/pkgconfig/arrow-flight-sql.pc
-%endif
-%if %{use_gandiva}
%package -n gandiva%{major_version}-libs
Summary: C++ library for compiling and evaluating expressions on Apache
Arrow data.
License: Apache-2.0
@@ -498,7 +432,6 @@ Libraries and header files for Gandiva.
%{_libdir}/libgandiva.a
%{_libdir}/libgandiva.so
%{_libdir}/pkgconfig/gandiva.pc
-%endif
%package -n parquet%{major_version}-libs
Summary: Runtime libraries for Apache Parquet C++
@@ -580,9 +513,7 @@ Libraries and header files for Apache Arrow GLib.
%license LICENSE.txt NOTICE.txt
%{_datadir}/arrow-glib/example/
%{_datadir}/gir-1.0/Arrow-*.gir
-%if %{use_vala}
%{_datadir}/vala/vapi/arrow-glib.*
-%endif
%{_includedir}/arrow-glib/
%{_libdir}/libarrow-glib.a
%{_libdir}/libarrow-glib.so
@@ -637,9 +568,7 @@ Libraries and header files for Apache Arrow Dataset GLib.
%doc README.md
%license LICENSE.txt NOTICE.txt
%{_datadir}/gir-1.0/ArrowDataset-*.gir
-%if %{use_vala}
%{_datadir}/vala/vapi/arrow-dataset-glib.*
-%endif
%{_includedir}/arrow-dataset-glib/
%{_libdir}/libarrow-dataset-glib.a
%{_libdir}/libarrow-dataset-glib.so
@@ -660,7 +589,6 @@ Documentation for Apache Arrow dataset GLib.
%{_docdir}/arrow-dataset-glib/
%endif
-%if %{use_flight}
%package -n %{name}%{major_version}-flight-glib-libs
Summary: Runtime libraries for Apache Arrow Flight GLib
License: Apache-2.0
@@ -692,9 +620,7 @@ Libraries and header files for Apache Arrow Flight GLib.
%doc README.md
%license LICENSE.txt NOTICE.txt
%{_datadir}/gir-1.0/ArrowFlight-*.gir
-%if %{use_vala}
%{_datadir}/vala/vapi/arrow-flight-glib.*
-%endif
%{_includedir}/arrow-flight-glib/
%{_libdir}/libarrow-flight-glib.a
%{_libdir}/libarrow-flight-glib.so
@@ -746,9 +672,7 @@ Libraries and header files for Apache Arrow Flight SQL
GLib.
%doc README.md
%license LICENSE.txt NOTICE.txt
%{_datadir}/gir-1.0/ArrowFlightSQL-*.gir
-%if %{use_vala}
%{_datadir}/vala/vapi/arrow-flight-sql-glib.*
-%endif
%{_includedir}/arrow-flight-sql-glib/
%{_libdir}/libarrow-flight-sql-glib.a
%{_libdir}/libarrow-flight-sql-glib.so
@@ -765,12 +689,10 @@ Documentation for Apache Arrow Flight SQL GLib.
%defattr(-,root,root,-)
%doc README.md
%license LICENSE.txt NOTICE.txt
- %if %{enable_glib_doc}
+%if %{enable_glib_doc}
%{_docdir}/arrow-flight-sql-glib/
- %endif
%endif
-%if %{use_gandiva}
%package -n gandiva%{major_version}-glib-libs
Summary: Runtime libraries for Gandiva GLib
License: Apache-2.0
@@ -802,9 +724,7 @@ Libraries and header files for Gandiva GLib.
%doc README.md
%license LICENSE.txt NOTICE.txt
%{_datadir}/gir-1.0/Gandiva-*.gir
-%if %{use_vala}
%{_datadir}/vala/vapi/gandiva-glib.*
-%endif
%{_includedir}/gandiva-glib/
%{_libdir}/libgandiva-glib.a
%{_libdir}/libgandiva-glib.so
@@ -821,9 +741,8 @@ Documentation for Gandiva GLib.
%defattr(-,root,root,-)
%doc README.md
%license LICENSE.txt NOTICE.txt
- %if %{enable_glib_doc}
+%if %{enable_glib_doc}
%{_docdir}/gandiva-glib/
- %endif
%endif
%package -n parquet%{major_version}-glib-libs
@@ -857,9 +776,7 @@ Libraries and header files for Apache Parquet GLib.
%doc README.md
%license LICENSE.txt NOTICE.txt
%{_datadir}/gir-1.0/Parquet-*.gir
-%if %{use_vala}
%{_datadir}/vala/vapi/parquet-glib.*
-%endif
%{_includedir}/parquet-glib/
%{_libdir}/libparquet-glib.a
%{_libdir}/libparquet-glib.so
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]