Blame clingo.spec

231844b
Name:       clingo
725ac12
Version:    5.6.1
ebb0c8e
Release:    %autorelease
231844b
Summary:    A grounder and solver for logic programs
231844b
231844b
License:    MIT
231844b
URL:        https://potassco.org/clingo/
231844b
Source0:    https://github.com/potassco/clingo/archive/v%{version}/%{name}-%{version}.tar.gz
8064cbb
# Disable gcc warning no-class-memaccess, which is intended use in this case
13a2439
Patch0:     clingo.clasp-disable-class-memaccess-warning.patch
231844b
a5e62a7
BuildRequires: bison
a5e62a7
BuildRequires: cmake
a5e62a7
BuildRequires: gcc-c++
a5e62a7
BuildRequires: re2c
231844b
231844b
%description
231844b
Clingo is part of the Potassco project for Answer Set Programming
231844b
(ASP). ASP offers a simple and powerful modeling language to describe
231844b
combinatorial problems as logic programs. The clingo system then takes
231844b
such a logic program and computes answer sets representing solutions
231844b
to the given problem.
231844b
231844b
231844b
%package        devel
231844b
Summary:        Development files for %{name}
231844b
Requires:       %{name}%{?_isa} = %{version}-%{release}
231844b
231844b
%description    devel
231844b
The %{name}-devel package contains libraries and header files for
231844b
developing applications that use %{name}.
231844b
231844b
%package -n lua-%{name}
231844b
Summary:        Lua bindings for Clingo
231844b
Requires:       %{name}%{?_isa} = %{version}-%{release}
231844b
BuildRequires:  lua-devel
231844b
231844b
%description -n lua-%{name}
231844b
Lua bindings for Clingo, a grounder and solver for logic programs.
231844b
231844b
Detailed information (including a User's manual), source code, and pre-compiled
231844b
binaries are available at: http://potassco.org/
231844b
231844b
%package -n python3-%{name}
231844b
Summary:        Python 3 bindings for Clingo
231844b
Requires:       %{name}%{?_isa} = %{version}-%{release}
231844b
BuildRequires:  python3, python3-devel
5f365f3
BuildRequires:  python3-cffi
5f365f3
BuildRequires:  make
231844b
%{?python_provide:%python_provide python3-%{name}}
231844b
231844b
%description -n python3-%{name}
231844b
This module provides functions and classes to work with ground terms and to
231844b
control the instantiation process. In clingo builts, additional functions to
231844b
control and inspect the solving process are available.
5f365f3
231844b
Functions defined in a python script block are callable during the
231844b
instantiation process using @-syntax. The default grounding/solving process can
231844b
be customized if a main function is provided.
231844b
231844b
Detailed information (including a User's manual), source code, and pre-compiled
231844b
binaries are available at: http://potassco.org/
231844b
231844b
231844b
%prep
13a2439
%autosetup -p1
231844b
231844b
231844b
%build
231844b
%cmake \
231844b
  -H. \
231844b
  -Brelease \
231844b
  -DCLINGO_MANAGE_RPATH:BOOL=OFF \
231844b
  -DBUILD_SHARED_LIBS:BOOL=OFF \
231844b
  -DCLINGO_BUILD_APPS:BOOL=ON \
5f365f3
  -DPython_EXECUTABLE=%{__python3} \
231844b
  -DCLINGO_BUILD_SHARED:BOOL=ON \
5f365f3
  -DCLINGO_BUILD_WITH_PYTHON:BOOL=ON \
231844b
  -DLUACLINGO_INSTALL_DIR:PATH=%{lua_libdir}
231844b
231844b
cmake --build release -- %{?_smp_mflags}
231844b
231844b
231844b
%install
231844b
%make_install -C release
231844b
231844b
%files
5f365f3
%doc README.md INSTALL.md
231844b
%license LICENSE.md
5f365f3
%{_libdir}/libclingo.so.4*
231844b
%{_bindir}/*
231844b
231844b
%files devel
231844b
%{_includedir}/*
231844b
%{_libdir}/*.so
231844b
%{_libdir}/cmake/Clingo
231844b
231844b
%files -n lua-%{name}
231844b
%{lua_libdir}/%{name}.so
231844b
231844b
%files -n python3-%{name}
5f365f3
%{python3_sitearch}/%{name}*
231844b
231844b
%changelog
ebb0c8e
%autochangelog