Extract the prepared testsuite to the standalone subpackage so it can be run outside of the buildroot
This commit is contained in:
parent
239038b1a4
commit
8671500d5f
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
Name: mariadb-connector-c
|
Name: mariadb-connector-c
|
||||||
Version: 3.1.3
|
Version: 3.1.3
|
||||||
Release: 1%{?with_debug:.debug}%{?dist}
|
Release: 2%{?with_debug:.debug}%{?dist}
|
||||||
Summary: The MariaDB Native Client library (C driver)
|
Summary: The MariaDB Native Client library (C driver)
|
||||||
License: LGPLv2+
|
License: LGPLv2+
|
||||||
Source: https://downloads.mariadb.org/interstitial/connector-c-%{version}/mariadb-connector-c-%{version}-src.tar.gz
|
Source: https://downloads.mariadb.org/interstitial/connector-c-%{version}/mariadb-connector-c-%{version}-src.tar.gz
|
||||||
@ -12,6 +12,8 @@ Source3: client.cnf
|
|||||||
Url: http://mariadb.org/
|
Url: http://mariadb.org/
|
||||||
# More information: https://mariadb.com/kb/en/mariadb/building-connectorc-from-source/
|
# More information: https://mariadb.com/kb/en/mariadb/building-connectorc-from-source/
|
||||||
|
|
||||||
|
Patch1: testsuite.patch
|
||||||
|
|
||||||
Requires: %{_sysconfdir}/my.cnf
|
Requires: %{_sysconfdir}/my.cnf
|
||||||
BuildRequires: zlib-devel cmake openssl-devel gcc-c++
|
BuildRequires: zlib-devel cmake openssl-devel gcc-c++
|
||||||
# Remote-IO plugin
|
# Remote-IO plugin
|
||||||
@ -37,6 +39,19 @@ Contains everything needed to build against libmariadb.so >=3 client library.
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
%package test
|
||||||
|
Summary: Testsuite files for mariadb-connector-c
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
Requires: cmake
|
||||||
|
Recommends: mariadb-server
|
||||||
|
|
||||||
|
%description test
|
||||||
|
Testsuite files for mariadb-connector-c.
|
||||||
|
Contains binaries and a prepared CMake ctest file.
|
||||||
|
Requires running MariaDB / MySQL server with create database "test".
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
%package config
|
%package config
|
||||||
Summary: Configuration files for packages that use /etc/my.cnf as a configuration file
|
Summary: Configuration files for packages that use /etc/my.cnf as a configuration file
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
@ -52,6 +67,7 @@ and require this package, so the /etc/my.cnf file is present.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{name}-%{version}-src
|
%setup -q -n %{name}-%{version}-src
|
||||||
|
%patch1 -p1
|
||||||
|
|
||||||
# Remove unsused parts
|
# Remove unsused parts
|
||||||
rm -r win zlib win-iconv examples
|
rm -r win zlib win-iconv examples
|
||||||
@ -176,6 +192,13 @@ popd
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
%files test
|
||||||
|
%dir %{_datadir}/%{name}
|
||||||
|
%{_datadir}/%{name}/*
|
||||||
|
%{_libdir}/libcctap.so
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Opened issues on the upstream tracker:
|
# Opened issues on the upstream tracker:
|
||||||
# https://jira.mariadb.org/browse/CONC-293
|
# https://jira.mariadb.org/browse/CONC-293
|
||||||
# DESCRIPTION: add mysql_config and mariadb_config man page
|
# DESCRIPTION: add mysql_config and mariadb_config man page
|
||||||
@ -203,6 +226,9 @@ popd
|
|||||||
# Currently, one of the tests - 'ps_bugs' - is failing
|
# Currently, one of the tests - 'ps_bugs' - is failing
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Aug 19 2019 Michal Schorm <mschorm@redhat.com> - 3.1.3-2
|
||||||
|
- Extract the prepared testsuite to the standalone subpackage so it can be run outside of the buildroot
|
||||||
|
|
||||||
* Fri Aug 02 2019 Michal Schorm <mschorm@redhat.com> - 3.1.3-1
|
* Fri Aug 02 2019 Michal Schorm <mschorm@redhat.com> - 3.1.3-1
|
||||||
- Rebase to 3.1.3 version
|
- Rebase to 3.1.3 version
|
||||||
- Patch upstreamed
|
- Patch upstreamed
|
||||||
|
10
testsuite.patch
Normal file
10
testsuite.patch
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
--- mariadb-connector-c-3.1.3-src/unittest/libmariadb/CMakeLists.txt 2019-07-25 10:03:48.000000000 -0400
|
||||||
|
+++ mariadb-connector-c-3.1.3-src/unittest/libmariadb/CMakeLists.txt_patched 2019-08-19 17:02:26.317247605 -0400
|
||||||
|
@@ -71,3 +71,7 @@ FOREACH(API_TEST ${MANUAL_TESTS})
|
||||||
|
ADD_EXECUTABLE(${API_TEST} ${API_TEST}.c)
|
||||||
|
TARGET_LINK_LIBRARIES(${API_TEST} cctap ma_getopt mariadbclient)
|
||||||
|
ENDFOREACH()
|
||||||
|
+
|
||||||
|
+INSTALL(TARGETS ${API_TESTS} DESTINATION ${SHAREDIR}/mariadb-connector-c/tests COMPONENT Tests)
|
||||||
|
+INSTALL(FILES ${CC_SOURCE_DIR}/unittest/mytap/libcctap.so PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE DESTINATION ${INSTALL_LIBDIR} COMPONENT Tests)
|
||||||
|
+INSTALL(FILES ${CC_SOURCE_DIR}/unittest/libmariadb/CTestTestfile.cmake DESTINATION ${SHAREDIR}/mariadb-connector-c/tests COMPONENT Tests)
|
Loading…
Reference in New Issue
Block a user