2012-01-10 08:46:58 +01:00
#
2012-01-25 12:25:59 +01:00
# spec file for package guile1
2012-01-10 08:46:58 +01:00
#
2020-06-07 09:20:58 +02:00
# Copyright (c) 2020 SUSE LLC
2012-01-10 08:46:58 +01:00
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
2019-09-06 09:35:06 +02:00
# Please submit bugfixes or comments via https://bugs.opensuse.org/
2012-01-10 08:46:58 +01:00
#
2012-03-17 18:18:17 +01:00
2012-01-18 17:17:51 +01:00
%define binpref guile1
2012-01-10 08:46:58 +01:00
Name : guile1
Version : 1.8.8
Release : 0
Summary : GNU's Ubiquitous Intelligent Language for Extension
2019-09-06 09:35:06 +02:00
License : LGPL-2.1-or-later
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2020-06-07 09:20:58 +02:00
URL : https://www.gnu.org/software/guile/
2020-06-08 14:19:53 +02:00
#https://github.com/texmacs/guile/archive/texmacs.zip
2019-11-23 13:36:16 +01:00
Source0 : https://ftp.gnu.org/gnu/guile/guile-%{version} .tar.gz
Source1 : https://ftp.gnu.org/gnu/guile/guile-%{version} .tar.gz.sig
2015-03-15 00:22:40 +01:00
Source2 : %{name} .keyring
2012-01-10 08:46:58 +01:00
Patch1 : guile-64bit.patch
Patch2 : guile-1.6.10-mktemp.patch
Patch3 : guile-popen-test.patch
Patch5 : guile-gcc.patch
2013-03-04 14:54:22 +01:00
Patch6 : guile-automake-1.13.patch
2013-12-18 08:55:59 +01:00
Patch7 : guile-socket-test.patch
2015-03-15 00:22:40 +01:00
# fix failures with texinfo 5.2
Patch8 : guile-texinfo.patch
2016-10-17 16:53:01 +02:00
Patch9 : guile1-CVE-2016-8605.patch
2017-01-17 00:31:54 +01:00
# PATCH-FIX-OPENSUSE (version is obsolete upstream / from 2010)
Patch10 : reproducible.patch
2019-11-23 13:36:16 +01:00
Patch11 : guile1-fix-texinfo-default-utf8.patch
2015-03-15 00:22:40 +01:00
BuildRequires : automake
BuildRequires : gc-devel
BuildRequires : gmp-devel
BuildRequires : libtool
BuildRequires : readline-devel
2012-09-10 12:48:55 +02:00
# Require the library packages, at least current version. The *.so symlinks are in the main package (due to dlopen(), so without the requires, it would be dangling symlinks.
Requires : libguile-srfi-srfi-1-v-3-3 >= %{version}
Requires : libguile-srfi-srfi-13-14-v-3-3 >= %{version}
Requires : libguile-srfi-srfi-4-v-3-3 >= %{version}
Requires : libguile-srfi-srfi-60-v-2-2 >= %{version}
Requires : libguile17 >= %{version}
Requires : libguilereadline-v-17-17 >= %{version}
2015-03-15 00:22:40 +01:00
PreReq : %{install_info_prereq}
# FIXME: use proper Requires(pre/post/preun/...)
PreReq : fileutils
PreReq : sh-utils
Conflicts : slib < 3a5
BuildRoot : %{_tmppath} /%{name} -%{version} -build
%if 0%{?suse_version}
BuildRequires : pkg-config
%else
BuildRequires : pkgconfig
%endif
%if 0%{?suse_version} >= 1230
BuildRequires : makeinfo
%endif
2012-01-10 08:46:58 +01:00
%description
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs.
%package -n libguile17
Summary : GNU's Ubiquitous Intelligent Language for Extension
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2012-01-10 08:46:58 +01:00
%description -n libguile17
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs. This package
contains the shared libraries.
%package -n libguile-srfi-srfi-1-v-3-3
Summary : GNU's Ubiquitous Intelligent Language for Extension
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2012-01-10 08:46:58 +01:00
%description -n libguile-srfi-srfi-1-v-3-3
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs. This package
contains the shared libraries.
%package -n libguile-srfi-srfi-4-v-3-3
Summary : GNU's Ubiquitous Intelligent Language for Extension
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2012-01-10 08:46:58 +01:00
%description -n libguile-srfi-srfi-4-v-3-3
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs. This package
contains the shared libraries.
%package -n libguile-srfi-srfi-13-14-v-3-3
Summary : GNU's Ubiquitous Intelligent Language for Extension
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2012-01-10 08:46:58 +01:00
%description -n libguile-srfi-srfi-13-14-v-3-3
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs. This package
contains the shared libraries.
%package -n libguile-srfi-srfi-60-v-2-2
Summary : GNU's Ubiquitous Intelligent Language for Extension
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2012-01-10 08:46:58 +01:00
%description -n libguile-srfi-srfi-60-v-2-2
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs. This package
contains the shared libraries.
%package -n libguilereadline-v-17-17
Summary : GNU's Ubiquitous Intelligent Language for Extension
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2012-01-10 08:46:58 +01:00
%description -n libguilereadline-v-17-17
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs. This package
contains the shared libraries.
%package -n libguile1-devel
Summary : GNU's Ubiquitous Intelligent Language for Extension
2012-01-25 12:25:59 +01:00
Group : Development/Languages/Scheme
2012-03-17 18:18:17 +01:00
Requires : gmp-devel
Requires : guile1
2012-01-10 08:46:58 +01:00
Requires : libguile-srfi-srfi-1-v-3-3 = %{version} -%{release}
Requires : libguile-srfi-srfi-13-14-v-3-3 = %{version} -%{release}
2012-03-17 18:18:17 +01:00
Requires : libguile-srfi-srfi-4-v-3-3 = %{version} -%{release}
Requires : libguile-srfi-srfi-60-v-2-2 = %{version} -%{release}
2012-01-10 08:46:58 +01:00
Requires : libguile17 = %{version} -%{release}
2012-03-17 18:18:17 +01:00
Requires : libguilereadline-v-17-17 = %{version} -%{release}
Requires : libltdl-devel
Requires : ncurses-devel
Requires : readline-devel
2012-01-10 08:46:58 +01:00
%description -n libguile1-devel
This is Guile, a portable, embeddable Scheme implementation written in
C. Guile provides a machine independent execution platform that can be
linked in as a library when building extensible programs. This package
contains the files necessary to link against the guile libraries.
%prep
%setup -q -n guile-%{version}
%patch1
%patch2
%patch3
%patch5
2013-03-04 14:54:22 +01:00
%patch6 -p1
2013-12-18 08:55:59 +01:00
%patch7 -p1
2015-03-15 00:22:40 +01:00
%patch8 -p1
2016-10-17 16:53:01 +02:00
%patch9 -p1
2017-01-17 00:31:54 +01:00
%patch10 -p1
2019-11-23 13:36:16 +01:00
%patch11
2012-01-10 08:46:58 +01:00
# guile-1.8.1: The code is not so good for -Werror (unused results of write()).
sed -i s/-Werror// configure.in configure
%build
2019-09-06 09:35:06 +02:00
%define _lto_cflags %{nil}
2020-06-08 14:19:53 +02:00
# NOTE: GCC 10 succeeds in rewriting a
#particular tail call into jumps. This avoids stack frames from the
#recursive call which the check relies on. Funnily enough, a comment
#says: "If the code could be inlined, that might cause the test to give
#an incorrect answer." - indeed.
# As a result the guile executable causes a segfault when built with -02
export CFLAGS=" ` e c h o % o p t f l a g s | t r 0 2 0 0 ` "
echo $CFLAGS
2012-01-25 12:25:59 +01:00
sed -i " s : G U I L E _ : G U I L E 1 _ : " guile-config/guile.m4
sed -i " s : g u i l e : g u i l e 1 : " guile-config/guile.m4
2013-06-17 15:37:40 +02:00
# automake 1.13: do not run test simultaneously
find -name Makefile.am | xargs sed -i 's/\(^AUTOMAKE_OPTIONS.*$\)/\1 serial-tests/'
2012-01-10 08:46:58 +01:00
autoreconf -fi
# FIXME: Following files are apparently compiled without RPM_OPT_FLAGS:
# gen-scmconfig.c,c-tokenize.c
2015-03-15 00:22:40 +01:00
%configure \
--disable-static \
--with-pic \
--with-threads \
--program-transform-name=" s : g u i l e : %{binpref} : "
2020-06-08 14:19:53 +02:00
make --trace %{?_smp_mflags}
2012-01-10 08:46:58 +01:00
%check
2015-03-15 00:22:40 +01:00
# 47 of 11930 tests are failing now
make check || :
2012-01-10 08:46:58 +01:00
%install
2015-03-15 00:22:40 +01:00
make DESTDIR=%{buildroot} install %{?_smp_mflags}
2012-01-10 08:46:58 +01:00
mkdir -p %{buildroot} %{_datadir} /guile/site
2012-01-18 17:17:51 +01:00
rm -r %{buildroot} %{_infodir}
# conflict with guile2
2012-01-25 12:25:59 +01:00
mv %{buildroot} %{_datadir} /aclocal/guile{,1}.m4
2012-01-18 17:17:51 +01:00
# use /usr/bin/guile1 instead of /usr/bin/guile
sed -i " s : $ { G U I L E - g u i l e } : $ { G U I L E - g u i l e 1 } : " %{buildroot} %{_datadir} /guile/1.8/scripts/*
2015-03-15 00:22:40 +01:00
sed -i " s : %{_bindir} / g u i l e : %{_bindir} / g u i l e 1 : " %{buildroot} %{_bindir} /guile1-config
2012-01-10 08:46:58 +01:00
2015-03-15 00:22:40 +01:00
%post -n libguile-srfi-srfi-1-v-3-3 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
2015-03-15 00:22:40 +01:00
%postun -n libguile-srfi-srfi-1-v-3-3 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
%files -n libguile-srfi-srfi-1-v-3-3
%defattr (-,root,root)
%{_libdir} /libguile-srfi-srfi-1-v-3.so.3*
2015-03-15 00:22:40 +01:00
%post -n libguile-srfi-srfi-4-v-3-3 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
2015-03-15 00:22:40 +01:00
%postun -n libguile-srfi-srfi-4-v-3-3 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
%files -n libguile-srfi-srfi-4-v-3-3
%defattr (-,root,root)
%{_libdir} /libguile-srfi-srfi-4-v-3.so.3*
2015-03-15 00:22:40 +01:00
%post -n libguile-srfi-srfi-13-14-v-3-3 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
2015-03-15 00:22:40 +01:00
%postun -n libguile-srfi-srfi-13-14-v-3-3 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
%files -n libguile-srfi-srfi-13-14-v-3-3
%defattr (-,root,root)
%{_libdir} /libguile-srfi-srfi-13-14-v-3.so.3*
2015-03-15 00:22:40 +01:00
%post -n libguile-srfi-srfi-60-v-2-2 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
2015-03-15 00:22:40 +01:00
%postun -n libguile-srfi-srfi-60-v-2-2 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
%files -n libguile-srfi-srfi-60-v-2-2
%defattr (-,root,root)
%{_libdir} /libguile-srfi-srfi-60-v-2.so.2*
2015-03-15 00:22:40 +01:00
%post -n libguile17 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
2015-03-15 00:22:40 +01:00
%postun -n libguile17 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
%files -n libguile17
%defattr (-,root,root)
%{_libdir} /libguile.so.17*
2015-03-15 00:22:40 +01:00
%post -n libguilereadline-v-17-17 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
2015-03-15 00:22:40 +01:00
%postun -n libguilereadline-v-17-17 -p /sbin/ldconfig
2012-01-10 08:46:58 +01:00
%files -n libguilereadline-v-17-17
%defattr (-,root,root)
%{_libdir} /libguilereadline-v-17.so.17*
%pre
# Remove obsolete files (< SuSE Linux 10.2)
2015-03-15 00:22:40 +01:00
rm -f var/adm/SuSEconfig/md5%{_datadir} /guile/*/slibcat
2012-01-10 08:46:58 +01:00
rm -f usr/share/guile/site/slibcat.SuSEconfig
%files
%defattr (-,root,root)
2019-09-06 09:35:06 +02:00
%doc ABOUT-NLS AUTHORS ChangeLog* GUILE-VERSION HACKING
%doc NEWS README THANKS
%license LICENSE COPYING*
2012-01-10 08:46:58 +01:00
%{_bindir} /*
2012-01-18 17:17:51 +01:00
%dir %{_datadir} /guile
%{_datadir} /guile/1.8
%dir %{_datadir} /guile/site
%{_mandir} /man1/%{binpref} .1.gz
2012-08-02 11:10:57 +02:00
# please leave *.so files here [bnc#772490]
%{_libdir} /libguile*.so
2012-01-10 08:46:58 +01:00
%files -n libguile1-devel
%defattr (-,root,root)
%{_includedir} /*
%{_libdir} /libguile*.la
%{_libdir} /pkgconfig/*
2012-01-25 12:25:59 +01:00
%{_datadir} /aclocal/guile1.m4
2012-01-10 08:46:58 +01:00
%changelog