%global debug_package %{nil} %if 0%{?fedora} >= 35 %bcond_without guile30 %else %bcond_with guile30 %endif # This is a temporary work-around until the fixes for # https://github.com/rpm-software-management/rpm/issues/1765 land in # Fedora. %global __brp_strip /bin/true %global srcname filesystem Name: guile-%{srcname} Version: 0.2.0 Release: 1%{?dist} Summary: File name manipulation in Guile License: LGPLv3 URL: https://gitlab.com/lilyp/guile-filesystem Source0: https://gitlab.com/lilyp/guile-filesystem/-/archive/%{version}/guile-filesystem-%{version}.tar.bz2 BuildRequires: autoconf BuildRequires: automake BuildRequires: /usr/bin/make BuildRequires: /usr/bin/makeinfo %global _description %{expand: (ice-9 filesystem) provides a set of utilities to deal with the filesystem beyond what POSIX mandates, from manipulating file names to actually creating files and directories.} %description %_description %package -n guile22-%{srcname} Summary: File name manipulation in Guile BuildRequires: guile22-devel Requires: guile22 %description -n guile22-%{srcname} %_description %if %{with guile30} %package -n guile30-%{srcname} Summary: File name manipulation in Guile BuildRequires: guile30-devel Requires: guile30 %description -n guile30-%{srcname} %_description %endif %package doc Summary: Documentation for guile-filesystem %description doc Documentation for guile-filesystem. %prep %setup -qc mv %{name}-%{version} guile22 %if %{with guile30} cp -a guile22 guile30 %endif %build pushd guile22 autoreconf -vif GUILE=/usr/bin/guile2.2 export GUILE GUILD=/usr/bin/guild2.2 export GUILD GUILE_EFFECTIVE_VERSION=2.2 export GUILE_EFFECTIVE_VERSION %configure %make_build popd %if %{with guile30} pushd guile30 autoreconf -vif GUILE=/usr/bin/guile3.0 export GUILE GUILD=/usr/bin/guild3.0 export GUILD GUILE_EFFECTIVE_VERSION=3.0 export GUILE_EFFECTIVE_VERSION %configure %make_build popd %endif %install rm -rf $RPM_BUILD_ROOT pushd guile22 %make_install popd %if %{with guile30} pushd guile30 %make_install popd %endif find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';' %files -n guile22-%{srcname} %license guile22/COPYING %doc guile22/AUTHORS guile22/NEWS guile22/README.org %{_libdir}/guile/2.2/site-ccache/ice-9/%{srcname}.go %{_datadir}/guile/site/2.2/ice-9/%{srcname}.scm %if %{with guile30} %files -n guile30-%{srcname} %license guile30/COPYING %doc guile30/AUTHORS guile30/NEWS guile30/README.org %{_libdir}/guile/3.0/site-ccache/ice-9/%{srcname}.go %{_datadir}/guile/site/3.0/ice-9/%{srcname}.scm %endif %files doc %{_infodir}/*