Initial commit

This commit is contained in:
eabdullin 2024-07-10 15:42:06 +03:00
parent 0633b872e4
commit defa8bc742
10 changed files with 1016 additions and 365 deletions

View File

@ -1 +0,0 @@
1

69
.gitignore vendored
View File

@ -1,68 +1 @@
/libsolv-d49d319.tar.xz
/libsolv-4442b7f.tar.xz
/libsolv-a8e47f1.tar.xz
/libsolv-bcedc98.tar.xz
/libsolv-05baf54.tar.gz
/libsolv-05baf54.tar.xz
/libsolv-f78f5de.tar.xz
/libsolv-6d968f1.tar.xz
/libsolv-2a5c1c4.tar.xz
/libsolv-5bd9589.tar.xz
/libsolv-12af31a.tar.xz
/0.6.8.tar.gz
/libsolv-78c8a55.tar.xz
/78c8a55bc087f45e231276ed5c33c84aed55463c.tar.gz
/850794025c60bf3efe8bd9e402a19cfe83b2fd7b.tar.gz
/99edb54e18f4971f50a359803633f44fdeb08428.tar.gz
/2db517f87a8c0364d28c0fa2590ba034e866a4b8.tar.gz
/libsolv-1f9abfb.tar.gz
/libsolv-0.6.12.tar.gz
/libsolv-0.6.14.tar.gz
/libsolv-0.6.15.tar.gz
/libsolv-0.6.19.tar.gz
/libsolv-0.6.20.tar.gz
/libsolv-0.6.21.tar.gz
/libsolv-0.6.22.tar.gz
/libsolv-0.6.23.tar.gz
/libsolv-0.6.24.tar.gz
/libsolv-0.6.25.tar.gz
/libsolv-0.6.26.tar.gz
/libsolv-2262346.tar.gz
/libsolv-668e249.tar.gz
/libsolv-0.6.27.tar.gz
/libsolv-0.6.28.tar.gz
/libsolv-0.6.29.tar.gz
/libsolv-0.6.30.tar.gz
/libsolv-97b8c0c.tar.gz
/libsolv-ae214a6.tar.gz
/libsolv-8bdcce1.tar.gz
/libsolv-47fbaa2.tar.gz
/libsolv-0.6.31.tar.gz
/libsolv-0.6.32.tar.gz
/libsolv-0.6.33.tar.gz
/libsolv-0.6.34.tar.gz
/libsolv-0.6.35.tar.gz
/libsolv-0.7.0.tar.gz
/libsolv-0.7.1.tar.gz
/libsolv-0.7.2.tar.gz
/libsolv-0.7.3.tar.gz
/libsolv-0.7.4.tar.gz
/libsolv-0.7.5.tar.gz
/libsolv-0.7.6.tar.gz
/libsolv-0.7.7.tar.gz
/libsolv-0.7.8.tar.gz
/libsolv-0.7.10.tar.gz
/libsolv-0.7.11.tar.gz
/libsolv-0.7.12.tar.gz
/libsolv-0.7.14.tar.gz
/libsolv-0.7.15.tar.gz
/libsolv-0.7.17.tar.gz
/libsolv-0.7.19.tar.gz
/libsolv-0.7.20.tar.gz
/libsolv-0.7.21.tar.gz
/libsolv-0.7.22.tar.gz
/libsolv-0.7.24.tar.gz
/libsolv-0.7.25.tar.gz
/libsolv-0.7.27.tar.gz
/libsolv-0.7.28.tar.gz
/libsolv-0.7.29.tar.gz
SOURCES/libsolv-0.7.29.tar.gz

1
.libsolv.metadata Normal file
View File

@ -0,0 +1 @@
0997e5b715ae73efb988d513e5a8ce9a91127eda SOURCES/libsolv-0.7.29.tar.gz

1014
SPECS/libsolv.spec Normal file

File diff suppressed because it is too large Load Diff

1
ci.fmf
View File

@ -1 +0,0 @@
resultsdb-testcase: separate

View File

@ -1,6 +0,0 @@
--- !Policy
product_versions:
- rhel-10
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build./plans/internal/CI-Tier-1.functional}

View File

@ -1,277 +0,0 @@
%global libname solv
%bcond_without python_bindings
%bcond_without perl_bindings
%bcond_without ruby_bindings
# Creates special prefixed pseudo-packages from appdata metadata
%bcond_without appdata
# Creates special prefixed "group:", "category:" pseudo-packages
%bcond_without comps
%bcond_without conda
# For rich dependencies
%bcond_without complex_deps
%bcond_without helix_repo
%bcond_without suse_repo
%bcond_without debian_repo
%bcond_without arch_repo
# For handling deb + rpm at the same time
%bcond_without multi_semantics
%if %{defined rhel}
%bcond_with zchunk
%else
%bcond_without zchunk
%endif
%bcond_without zstd
%define __cmake_switch(b:) %[%{expand:%%{?with_%{-b*}}} ? "ON" : "OFF"]
Name: lib%{libname}
Version: 0.7.29
Release: %autorelease
Summary: Package dependency solver
License: BSD-3-Clause
URL: https://github.com/openSUSE/libsolv
Source: %{url}/archive/%{version}/%{name}-%{version}.tar.gz
# Downstream-only, RHEL-41048
Patch0: 0001-Add-support-for-computing-hashes-using-OpenSSL.patch
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: ninja-build
BuildRequires: pkgconfig(rpm)
BuildRequires: zlib-devel
# -DWITH_LIBXML2=ON
BuildRequires: libxml2-devel
# -DWITH_OPENSSL=ON
BuildRequires: pkgconfig(openssl)
# -DENABLE_LZMA_COMPRESSION=ON
BuildRequires: xz-devel
# -DENABLE_BZIP2_COMPRESSION=ON
BuildRequires: bzip2-devel
%if %{with zstd}
# -DENABLE_ZSTD_COMPRESSION=ON
BuildRequires: libzstd-devel
%endif
%if %{with zchunk}
# -DENABLE_ZCHUNK_COMPRESSION=ON
BuildRequires: pkgconfig(zck)
%endif
%description
A free package dependency solver using a satisfiability algorithm. The
library is based on two major, but independent, blocks:
- Using a dictionary approach to store and retrieve package
and dependency information.
- Using satisfiability, a well known and researched topic, for
resolving package dependencies.
%package devel
Summary: Development files for %{name}
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: rpm-devel%{?_isa}
%description devel
Development files for %{name}.
%package tools-base
Summary: Utilities used by libzypp to manage .solv files
Requires: %{name}%{?_isa} = %{version}-%{release}
Provides: libsolv-tools:%{_bindir}/repo2solv
%description tools-base
This subpackage contains utilities used by libzypp to manage solv files.
%package tools
Summary: Package dependency solver tools
Requires: %{name}%{?_isa} = %{version}-%{release}
# repo2solv dependencies. Used as execl()
Requires: /usr/bin/find
Requires: libsolv-tools-base = %{version}-%{release}
%description tools
Package dependency solver tools.
%package demo
Summary: Applications demoing the %{name} library
Requires: %{name}%{?_isa} = %{version}-%{release}
# solv dependencies. Used as execlp() and system()
Requires: /usr/bin/curl
Requires: /usr/bin/gpg2
%description demo
Applications demoing the %{name} library.
%if %{with perl_bindings}
%package -n perl-%{libname}
Summary: Perl bindings for the %{name} library
BuildRequires: swig
BuildRequires: perl-devel
BuildRequires: perl-generators
Requires: %{name}%{?_isa} = %{version}-%{release}
%description -n perl-%{libname}
Perl bindings for the %{name} library.
%endif
%if %{with ruby_bindings}
%package -n ruby-%{libname}
Summary: Ruby bindings for the %{name} library
BuildRequires: swig
BuildRequires: ruby-devel
Requires: %{name}%{?_isa} = %{version}-%{release}
%description -n ruby-%{libname}
Ruby bindings for the %{name} library.
%endif
%if %{with python_bindings}
%package -n python3-%{libname}
Summary: Python bindings for the %{name} library
%{?python_provide:%python_provide python3-%{libname}}
BuildRequires: swig
BuildRequires: python3-devel
Requires: %{name}%{?_isa} = %{version}-%{release}
%description -n python3-%{libname}
Python bindings for the %{name} library.
Python 3 version.
%endif
%prep
%autosetup -p1
# Prune unbundled cryptography sources, RHEL-41048.
rm src/{md5,sha1,sha2}.{c,h}
%build
%cmake -GNinja \
-DFEDORA=1 \
-DENABLE_RPMDB=ON \
-DENABLE_RPMDB_BYRPMHEADER=ON \
-DENABLE_RPMDB_LIBRPM=ON \
-DENABLE_RPMPKG_LIBRPM=ON \
-DENABLE_RPMMD=ON \
-DENABLE_COMPS=%{__cmake_switch -b comps} \
-DENABLE_APPDATA=%{__cmake_switch -b appdata} \
-DUSE_VENDORDIRS=ON \
-DWITH_LIBXML2=ON \
-DWITH_OPENSSL=ON \
-DENABLE_LZMA_COMPRESSION=ON \
-DENABLE_BZIP2_COMPRESSION=ON \
-DENABLE_ZSTD_COMPRESSION=%{__cmake_switch -b zstd} \
-DENABLE_ZCHUNK_COMPRESSION=%{__cmake_switch -b zchunk} \
%if %{with zchunk}
-DWITH_SYSTEM_ZCHUNK=ON \
%endif
-DENABLE_HELIXREPO=%{__cmake_switch -b helix_repo} \
-DENABLE_SUSEREPO=%{__cmake_switch -b suse_repo} \
-DENABLE_DEBIAN=%{__cmake_switch -b debian_repo} \
-DENABLE_ARCHREPO=%{__cmake_switch -b arch_repo} \
-DMULTI_SEMANTICS=%{__cmake_switch -b multi_semantics} \
-DENABLE_COMPLEX_DEPS=%{__cmake_switch -b complex_deps} \
-DENABLE_CONDA=%{__cmake_switch -b conda} \
-DENABLE_PERL=%{__cmake_switch -b perl_bindings} \
-DENABLE_RUBY=%{__cmake_switch -b ruby_bindings} \
-DENABLE_PYTHON=%{__cmake_switch -b python_bindings} \
%if %{with python_bindings}
-DPYTHON_EXECUTABLE=%{python3} \
%endif
%{nil}
%cmake_build
%install
%cmake_install
%check
%ctest
# Python smoke test (not tested in %%ctest):
export PYTHONPATH=%{buildroot}%{python3_sitearch}
export LD_LIBRARY_PATH=%{buildroot}%{_libdir}
%python3 -c 'import solv'
%files
%license LICENSE*
%doc README
%{_libdir}/%{name}.so.*
%{_libdir}/%{name}ext.so.*
%files devel
%{_libdir}/%{name}.so
%{_libdir}/%{name}ext.so
%{_includedir}/%{libname}/
%{_libdir}/pkgconfig/%{name}.pc
%{_libdir}/pkgconfig/%{name}ext.pc
# Own directory because we don't want to depend on cmake
%dir %{_datadir}/cmake/Modules/
%{_datadir}/cmake/Modules/FindLibSolv.cmake
%{_mandir}/man3/%{name}*.3*
# Some small macro to list tools with mans
%global solv_tool() \
%{_bindir}/%{1}\
%{_mandir}/man1/%{1}.1*
%files tools-base
%solv_tool repo2solv
%solv_tool rpmdb2solv
%files tools
%solv_tool deltainfoxml2solv
%solv_tool dumpsolv
%solv_tool installcheck
%solv_tool mergesolv
%solv_tool repomdxml2solv
%solv_tool rpmmd2solv
%solv_tool rpms2solv
%solv_tool testsolv
%solv_tool updateinfoxml2solv
%if %{with comps}
%solv_tool comps2solv
%endif
%if %{with appdata}
%solv_tool appdata2solv
%endif
%if %{with debian_repo}
%solv_tool deb2solv
%endif
%if %{with arch_repo}
%solv_tool archpkgs2solv
%solv_tool archrepo2solv
%endif
%if %{with helix_repo}
%solv_tool helix2solv
%endif
%if %{with suse_repo}
%solv_tool susetags2solv
%endif
%if %{with conda}
%{_bindir}/conda2solv
%endif
%files demo
%solv_tool solv
%if %{with perl_bindings}
%files -n perl-%{libname}
%{perl_vendorarch}/%{libname}.pm
%{perl_vendorarch}/%{libname}.so
%endif
%if %{with ruby_bindings}
%files -n ruby-%{libname}
%{ruby_vendorarchdir}/%{libname}.so
%endif
%if %{with python_bindings}
%files -n python3-%{libname}
%{python3_sitearch}/_%{libname}.so
%{python3_sitearch}/%{libname}.py
%{python3_sitearch}/__pycache__/%{libname}.*
%endif
%changelog
%autochangelog

View File

@ -1,11 +0,0 @@
summary: Internal CI-Tier-1 tests plan
discover:
- name: libsolv
how: fmf
filter: 'tag: CI-Tier-1'
url: https://pkgs.devel.redhat.com/git/tests/libsolv
execute:
how: tmt
adjust:
enabled: false
when: distro == centos-stream or distro == fedora

View File

@ -1 +0,0 @@
SHA512 (libsolv-0.7.29.tar.gz) = 5c76a4f2173999a7741ba613368209ee98942a82ca910ab455d19690ddade06d69a791406495a4bd50988c032fc6aa94b613fb00d54e1a5d36d6db1e8912599c