The spec automaticlly provides the libpq.so which is the same with postgresql-libs package. In public area, it should not find 2 or more packages provide the same lib. So this might break the downstream dependencies which using pkgconfig(libpq). For this reason, we hide the gpdb private libs.
101 lines
3.2 KiB
RPMSpec
101 lines
3.2 KiB
RPMSpec
NAME: gpdb
|
|
Version: 6.17.0
|
|
Release: 4
|
|
Summary: Open Source Greenplum Database
|
|
|
|
License: Apache 2.0
|
|
URL: https://github.com/greenplum-db/gpdb
|
|
Source0: https://github.com/greenplum-db/gpdb/releases/download/%{version}/%{version}-src-full.tar.gz
|
|
Patch0: orca1.patch
|
|
Patch1: orca2.patch
|
|
Patch2: unittest-fix.patch
|
|
Patch3: gpfdist1.patch
|
|
Patch4: gpfdist2.patch
|
|
Patch5: icw.patch
|
|
|
|
BuildRequires: python2-devel python2-pip
|
|
BuildRequires: apr-devel bison bzip2-devel cmake3 flex gcc gcc-c++ krb5-devel libcurl-devel libevent-devel libkadm5 libyaml-devel libxml2-devel libzstd-devel openssl-devel perl-ExtUtils-Embed readline-devel xerces-c-devel zlib-devel
|
|
|
|
Requires: apr apr-util bash bzip2 curl iproute krb5-devel less libcurl libxml2 libyaml net-tools openldap openssh openssh-clients openssh-server openssl perl readline rsync sed tar which zip zlib
|
|
Requires: hostname net-tools iputils
|
|
|
|
%global _privatelibs lib(pq|pgtypes|ecpg_compat|ecpg)\\.so*
|
|
%global __provides_exclude %{_privatelibs}
|
|
|
|
%description
|
|
Greenplum Database - Massively Parallel PostgreSQL for Analytics. An open-source massively parallel data platform for analytics, machine learning and AI.
|
|
|
|
%prep
|
|
%setup -q -n gpdb_src
|
|
%patch0 -p1
|
|
%patch1 -p1
|
|
%patch2 -p1
|
|
%patch3 -p1
|
|
%patch4 -p1
|
|
%patch5 -p1
|
|
# gpdb has extra components that depends on headers and libs to be installed first, so set prefix to a writable path and move it back later.
|
|
./configure --enable-orca --with-gssapi --disable-rpath --prefix=$PWD/greenplum-db-%{version} --with-libxml --with-openssl --enable-cassert --enable-debug --enable-debug-extensions --disable-mapreduce --enable-orafce --without-perl --with-python
|
|
%build
|
|
make %{?_smp_mflags} install
|
|
|
|
%install
|
|
rm -rf $RPM_BUILD_ROOT
|
|
mkdir -p %{buildroot}/usr/local
|
|
cp -rf %{_builddir}/gpdb_src/greenplum-db-%{version} %{buildroot}/usr/local/
|
|
|
|
%check
|
|
# Unit test
|
|
source greenplum-db-%{version}/greenplum_path.sh
|
|
%ifarch x86_64
|
|
make -s unittest-check
|
|
%endif
|
|
# There is a known issue on ARM tests, which is related with mockery framework.
|
|
# Upstream issue: https://github.com/google/cmockery/issues/67
|
|
# For the following test, only the 1 test is failure.
|
|
# So we force to run the test on aarch64 platform.
|
|
%ifarch aarch64
|
|
make -s unitest-check || true
|
|
%endif
|
|
|
|
%if 0%{getenv:FULL_REGRESS}
|
|
# warmup env
|
|
sleep 5
|
|
|
|
# regression test
|
|
TEST_USER=$USER
|
|
|
|
# setup password-less login
|
|
echo "y" | ssh-keygen -f ~/.ssh/id_rsa -P ""
|
|
touch ~/.ssh/authorized_keys
|
|
chmod 600 ~/.ssh/authorized_keys
|
|
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
|
|
export USER=$TEST_USER
|
|
export PGUSER=$TEST_USER
|
|
|
|
# setup gpdb cluster
|
|
ulimit -n 65535
|
|
make -C gpAux/gpdemo cluster
|
|
|
|
# warmup env
|
|
sleep 5
|
|
|
|
source gpAux/gpdemo/gpdemo-env.sh
|
|
|
|
make installcheck-world
|
|
%endif
|
|
|
|
%files
|
|
%dir /usr/local/greenplum-db-%{version}
|
|
/usr/local/greenplum-db-%{version}
|
|
|
|
%changelog
|
|
* Thu Aug 26 2021 bzhaoop <bzhaojyathousandy@gmail.com> - 6.17.0-4
|
|
- Fix multiple provides for forbiding the private libs in public area.
|
|
|
|
* Thu Aug 12 2021 peifengq <qiupf2000@gmail.com> - 6.17.0-3
|
|
- Run full regress conditionally
|
|
|
|
* Wed Aug 11 2021 peifengq <qiupf2000@gmail.com> - 6.17.0-2
|
|
- add test report for 6.17.0, fix tests
|
|
|