# Build options: # # --with termite # The termite distributed programming system is currently broken %define dirname gambc-v4_6_0-devel %define termite_rev 080714_2216 Name: gambit-c Version: 4.6.0 Release: 1%{?dist} Summary: Scheme programming system Group: Development/Languages License: ASL 2.0 or LGPLv2 URL: http://www.iro.umontreal.ca/~gambit Source0: http://www.iro.umontreal.ca/~gambit/download/gambit/v4.6/source/%{dirname}.tgz %if %{?_with_termite:1}%{!?_with_termite:0} Source1: http://termite.googlecode.com/files/termite%{termite_rev}.tar.gz %else Provides: gambit-c-termite = %{version}-%{release} Obsoletes: gambit-c-termite < %{version}-%{release} %endif Source2: gambit-init.el Patch0: gambc-v4_2_8-modtime.patch BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) BuildRequires: emacs Requires: gcc %description Gambit-C includes a Scheme interpreter and a Scheme compiler which can be used to build standalone executables. Because the compiler generates portable C code it is fairly easy to port to any platform with a decent C compiler. The Gambit-C system conforms to the R4RS, R5RS and IEEE Scheme standards. The full numeric tower is implemented, including: infinite precision integers (bignums), rationals, inexact reals (floating point numbers), and complex numbers. %package doc Summary: Documentation for %{name} Group: Documentation BuildArch: noarch Requires: %{name} = %{version}-%{release} Requires(post): info Requires(preun): info %if %{?_with_termite:0}%{!?_with_termite:1} Provides: gambit-c-termite-doc = %{version}-%{release} Obsoletes: gambit-c-termite-doc < %{version}-%{release} %endif %description doc Gambit-C includes a Scheme interpreter and a Scheme compiler which can be used to build standalone executables. Because the compiler generates portable C code it is fairly easy to port to any platform with a decent C compiler. This package contains the Gambit-C user manual in HTML and PDF formats. %if %{?_with_termite:1}%{!?_with_termite:0} %package termite Summary: Termite distributed programming system Group: Development/Languages URL: http://www.toute.ca/ Requires: %{name} = %{version}-%{release} %description termite Termite is an Erlang-like distributed programming system written in Scheme. %package termite-doc Summary: Examples for the Termite distributed programming system Group: Documentation Requires: %{name}-termite = %{version}-%{release} %description termite-doc Termite is an Erlang-like distributed programming system written in Scheme. This package contains examples and benchmarks for Termite. %endif %package -n emacs-gambit Summary: Gambit-C editing mode for Emacs Group: Applications/Editors BuildArch: noarch Requires: emacs(bin) >= %{_emacs_version} %description -n emacs-gambit An Emacs mode for editing Gambit-C Scheme source code. %package -n emacs-gambit-el Summary: Elisp source file for emacs-gambit Group: Applications/Editors BuildArch: noarch Requires: emacs-gambit = %{version}-%{release} %description -n emacs-gambit-el Elisp source file for the Gambit-C editing mode for Emacs. %prep %if %{?_with_termite:1}%{!?_with_termite:0} %setup -q -n %{dirname} -a1 %else %setup -q -n %{dirname} %endif %patch0 -p1 -b .modtime #find . -name '*.scm' | xargs chmod 0644 #find examples -name '*.scm' | xargs sed -i 's|/usr/local/Gambit-C|/usr|g' touch -r doc/gambit-c.info-2{,.tstamp} iconv -f iso88591 -t utf8 doc/gambit-c.info-2 -o doc/gambit-c.info-2.utf8 touch -r doc/gambit-c.info-2{,.utf8} mv doc/gambit-c.info-2{.utf8,} #sed -i "s|\xE9|\xC3\xA9|g" doc/gambit-c.info-2 # Permission fixes chmod -x lib/{mem.c,setup.h} %build %configure --enable-single-host \ --enable-gcc-opts \ --bindir=%{_libdir}/%{name}/bin \ --libdir=%{_libdir}/%{name} make %{?_smp_mflags} # Compile emacs module (cd misc && emacs -batch -f batch-byte-compile gambit.el) %check make check %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT%{_bindir} for i in gsc gsi do ln -sf ../%{_lib}/%{name}/bin/$i $RPM_BUILD_ROOT%{_bindir}/$i done cat > $RPM_BUILD_ROOT%{_bindir}/gsix </dev/null || : %preun doc if [ $1 -eq 0 ]; then /sbin/install-info --delete %{_infodir}/%{name}.info %{_infodir}/dir 2>/dev/null || : fi %files %defattr(-,root,root,-) %doc LGPL.txt LICENSE-2.0.txt README %if %{?_with_termite:1}%{!?_with_termite:0} %exclude %{_bindir}/tsi %endif %{_bindir}/* %{_includedir}/*.h %{_mandir}/man1/gsi.* %if %{?_with_termite:1}%{!?_with_termite:0} %exclude %{_libdir}/%{name}/*/lib/termite %endif %{_libdir}/%{name} %{_libdir}/*.a %if %{?_with_termite:1}%{!?_with_termite:0} %files termite %defattr(-,root,root,-) %doc termite-doc/* %{_bindir}/tsi %{_libdir}/%{name}/v%{version}/lib/termite %endif %files -n emacs-gambit %defattr(-,root,root,-) %doc LGPL.txt LICENSE-2.0.txt %{_emacs_sitelispdir}/*.elc %{_emacs_sitestartdir}/gambit-init.el %files -n emacs-gambit-el %defattr(-,root,root,-) %{_emacs_sitelispdir}/*.el %files doc %defattr(-,root,root,-) %doc doc/gambit-c.html doc/gambit-c.pdf # don't package examples until makefiles are fixed # examples %{_infodir}/* %if %{?_with_termite:1}%{!?_with_termite:0} %files termite-doc %defattr(-,root,root,-) %doc termite-more-docs/* %endif %changelog * Mon Jul 12 2010 Michel Salim - 4.6.0-1 - Update to 4.6.0 - Bundle license text with independent Emacs subpackage * Fri Jul 24 2009 Fedora Release Engineering - 4.3.2-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild * Tue Feb 24 2009 Fedora Release Engineering - 4.3.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild * Wed Jan 28 2009 Michel Salim - 4.3.2-2 - If termite packages are disabled, the corresponding gambit-c packages Provides: and Obsoletes: them * Fri Dec 19 2008 Michel Salim - 4.3.2-1 - Update to 4.3.2 * Tue Oct 14 2008 Michel Salim - 4.2.9-1 - Update to 4.2.9 - Disable Termite for now; still broken - When built on EL-5, depend directly on emacs binary rather than emacs(bin) * Mon Jul 14 2008 Michel Salim - 4.2.8-6 - Put include files and libraries in standard paths * Thu Jun 19 2008 Michel Salim - 4.2.8-5 - Package Termite as a module instead of bundling a custom Gambit-C with it * Thu Jun 19 2008 Michel Salim - 4.2.8-4 - Permission fixes for Termite subpackage * Wed Jun 18 2008 Michel Salim - 4.2.8-3 - Bundle Termite as a subpackage * Sat Jun 7 2008 Michel Salim - 4.2.8-2 - Rename six symlink to avoid clash with existing six package * Mon Jun 2 2008 Michel Salim - 4.2.8-1 - Update to 4.2.8 - Rename to gambit-c * Fri Dec 28 2007 Gerard Milmeister - 4.1.2-1 - new release 4.1.2 * Sat Apr 14 2007 Gerard Milmeister - 4.0-1.b22 - new version 4.0b22 * Sun Oct 15 2006 Gerard Milmeister - 4.0-1.b20 - new version 4.0b20 * Sat Feb 4 2006 Gerard Milmeister - 4.0-1.b17 - new version 4.0b17 * Mon Nov 7 2005 Gerard Milmeister - 4.0-1.b15 - New Version 4.0b15 * Fri Aug 12 2005 Gerard Milmeister - 4.0-1.b14 - First Fedora release