2019-04-25 16:38:52 +00:00
|
|
|
%define basen black-hole-solver
|
|
|
|
%define libname_orig lib%{basen}
|
|
|
|
%define major 1
|
|
|
|
%define libname lib%{basen}%{major}
|
|
|
|
%define develname lib%{basen}-devel
|
|
|
|
|
|
|
|
Name: %{basen}
|
2020-11-09 16:18:39 +00:00
|
|
|
Version: 1.10.1
|
2021-01-26 01:11:35 +00:00
|
|
|
Release: 2%{?dist}
|
2019-04-25 16:38:52 +00:00
|
|
|
# The entire source code is MIT except xxHash-0.6.5/ which is BSD
|
|
|
|
License: MIT and BSD
|
|
|
|
Source0: https://fc-solve.shlomifish.org/downloads/fc-solve/%{basen}-%{version}.tar.xz
|
|
|
|
URL: https://www.shlomifish.org/open-source/projects/black-hole-solitaire-solver/
|
|
|
|
Requires: %{libname}%{?_isa} = %version-%release
|
|
|
|
Summary: The Black Hole Solitaire Solver Executable
|
|
|
|
BuildRequires: cmake
|
|
|
|
BuildRequires: gcc
|
|
|
|
BuildRequires: gcc-c++
|
|
|
|
BuildRequires: glibc-devel
|
|
|
|
BuildRequires: perl(Carp)
|
|
|
|
BuildRequires: perl(Cwd)
|
|
|
|
BuildRequires: perl(Data::Dumper)
|
|
|
|
BuildRequires: perl(Dir::Manifest)
|
|
|
|
BuildRequires: perl(Env::Path)
|
|
|
|
BuildRequires: perl(File::Path)
|
|
|
|
BuildRequires: perl(File::Spec)
|
|
|
|
BuildRequires: perl(Inline)
|
|
|
|
BuildRequires: perl(Inline::C)
|
|
|
|
BuildRequires: perl(List::MoreUtils)
|
|
|
|
BuildRequires: perl(Path::Tiny)
|
|
|
|
BuildRequires: perl(Test::Differences)
|
|
|
|
BuildRequires: perl(Test::More)
|
|
|
|
BuildRequires: perl(Test::RunValgrind)
|
2020-11-09 16:18:39 +00:00
|
|
|
BuildRequires: perl(Test::Some)
|
2019-04-25 16:38:52 +00:00
|
|
|
BuildRequires: perl(Test::Trap)
|
|
|
|
BuildRequires: perl(autodie)
|
|
|
|
BuildRequires: perl(base)
|
|
|
|
BuildRequires: perl(lib)
|
|
|
|
BuildRequires: perl(strict)
|
|
|
|
BuildRequires: perl(warnings)
|
|
|
|
BuildRequires: perl-devel
|
|
|
|
BuildRequires: python3
|
2019-12-18 08:58:57 +00:00
|
|
|
BuildRequires: rinutils-devel
|
2019-04-25 16:38:52 +00:00
|
|
|
BuildRequires: valgrind
|
|
|
|
BuildRequires: xxhash-devel
|
|
|
|
|
|
|
|
%description
|
|
|
|
This is a solver, written in C, to solve the Solitaire variants “Golf”,
|
|
|
|
“Black Hole” and “All in a Row”. It provides a portable C library, and
|
|
|
|
a command line application that after being fed with a layout will emit the
|
|
|
|
cards to move.
|
|
|
|
|
|
|
|
%files
|
|
|
|
%license COPYING
|
2019-05-23 10:36:40 +00:00
|
|
|
%doc NEWS.asciidoc README.md
|
2019-04-25 16:38:52 +00:00
|
|
|
%_bindir/black-hole-solve
|
|
|
|
%{_mandir}/man6/black-hole-solve.6.*
|
|
|
|
|
|
|
|
#--------------------------------------------------------------------
|
|
|
|
|
|
|
|
%package -n %{libname}
|
|
|
|
Summary: The Black Hole Solver dynamic libraries
|
|
|
|
|
|
|
|
%description -n %{libname}
|
|
|
|
Contains the Black Hole Solver libraries that are used by some programs.
|
|
|
|
|
|
|
|
This package is mandatory for the Black Hole Solver executable too.
|
|
|
|
|
|
|
|
%files -n %{libname}
|
|
|
|
%{_libdir}/libblack_hole_solver.so.%{major}{,.*}
|
|
|
|
|
|
|
|
#--------------------------------------------------------------------
|
|
|
|
|
|
|
|
%package -n %{develname}
|
|
|
|
Summary: The Black Hole Solitaire development tools
|
|
|
|
Requires: %{libname}%{?_isa} = %version-%release
|
|
|
|
Provides: %{name}-devel = %{version}-%{release}
|
|
|
|
|
|
|
|
%description -n %{develname}
|
|
|
|
Development tools for the Black Hole Solitaire Solver.
|
|
|
|
|
|
|
|
%files -n %{develname}
|
|
|
|
%_includedir/black-hole-solver/*.h
|
|
|
|
%{_libdir}/pkgconfig/*.pc
|
|
|
|
%{_libdir}/libblack_hole_solver.so
|
|
|
|
|
|
|
|
#--------------------------------------------------------------------
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
|
|
|
|
|
|
|
%build
|
|
|
|
# The game limit flags are recommended by the PySolFC README.
|
2019-05-08 20:42:00 +00:00
|
|
|
%cmake -DLOCALE_INSTALL_DIR=%{_datadir}/locale -DLIB_INSTALL_DIR=%{_libdir} -DBUILD_STATIC_LIBRARY= -DDISABLE_APPLYING_RPATH=TRUE -DUSE_SYSTEM_XHASH=TRUE
|
2020-07-28 05:41:24 +00:00
|
|
|
%cmake_build
|
2019-04-25 16:38:52 +00:00
|
|
|
|
|
|
|
%check
|
|
|
|
%ifarch %arm
|
|
|
|
# valgrind suppression not working without glibc-debuginfo breaks it
|
2020-07-28 05:41:24 +00:00
|
|
|
%__rm -f t/valgrind.t
|
2019-04-25 16:38:52 +00:00
|
|
|
%endif
|
2020-07-28 05:41:24 +00:00
|
|
|
%__rm -f t/clang-format.t
|
|
|
|
%__rm -f t/perltidy.t
|
2019-04-25 16:38:52 +00:00
|
|
|
# fails due to build containing binaries
|
2020-07-28 05:41:24 +00:00
|
|
|
%__rm -f t/style-trailing-space.t
|
2019-04-25 16:38:52 +00:00
|
|
|
# %%make_build test
|
2020-07-28 05:41:24 +00:00
|
|
|
src="`pwd`"
|
|
|
|
cd "%{__cmake_builddir}"
|
|
|
|
perl "$src"/run-tests.pl
|
2019-04-25 16:38:52 +00:00
|
|
|
|
|
|
|
%install
|
2020-07-28 05:41:24 +00:00
|
|
|
%{cmake_install}
|
|
|
|
%__rm -f %{buildroot}/%{_libdir}/*.a
|
2019-04-25 16:38:52 +00:00
|
|
|
|
|
|
|
%changelog
|
2021-01-26 01:11:35 +00:00
|
|
|
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.10.1-2
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
|
|
|
|
2020-11-09 16:18:39 +00:00
|
|
|
* Mon Nov 09 2020 Shlomi Fish <shlomif@shlomifish.org> 1.10.1-1
|
|
|
|
- New version; add BR on Test::Some.
|
|
|
|
|
2020-07-28 05:41:24 +00:00
|
|
|
* Tue Jul 28 2020 Shlomi Fish <shlomif@shlomifish.org> 1.8.0-3
|
|
|
|
- Convert to the new cmake rpm macros
|
|
|
|
|
2020-07-27 13:11:11 +00:00
|
|
|
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.8.0-2
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
|
|
|
|
2020-07-28 05:41:24 +00:00
|
|
|
* Sun Jun 28 2020 Shlomi Fish <shlomif@shlomifish.org> 1.8.0-1
|
2020-06-28 20:08:26 +00:00
|
|
|
- New upstream version.
|
|
|
|
|
2020-01-28 13:02:45 +00:00
|
|
|
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-2
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
|
|
|
|
2019-07-24 19:21:24 +00:00
|
|
|
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.0-2
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
|
|
|
|
2019-04-25 16:38:52 +00:00
|
|
|
* Wed Apr 24 2019 Shlomi Fish <shlomif@cpan.org> 0.20.0-1
|
|
|
|
- Initial Fedora package based on the Mageia one.
|