Blob Blame History Raw
%global gauche_main_version 0.9

%global snapshot_date 20120403
%global git_revision  f7d3f802f3750
%global alphatag      %{snapshot_date}git%{git_revision}

Name:           gauche-gtk
Epoch:          1
Version:        0.6
Release:        0.10.%{alphatag}%{?dist}
Summary:        Gauche extension module to use GTK

%if 0%{?rhel}
Group:          Development/Languages
%endif
License:        BSD
URL:            http://practical-scheme.net/
# no stable release yet
# git clone git://github.com/shirok/Gauche-gtk2.git
# (cd Gauche-gtk2 && git archive --format=tar \
#  --prefix=%%{name}-%%{version}/ %%{git_revision} \
# | xz ) > %%{name}-%%{version}-%%{git_revision}.tar.xz
Source0:        %{name}-%{version}-%{git_revision}.tar.xz

%if 0%{?el5}
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%endif

BuildRequires:  gauche-devel
BuildRequires:  gtk2-devel
BuildRequires:  gtkglext-devel
BuildRequires:  libX11-devel
BuildRequires:  libXt-devel
BuildRequires:  libICE-devel
BuildRequires:  autoconf
# used in test
BuildRequires:  gauche-gl
BuildRequires:  Xvfb xauth

Requires:       gauche-gl

# To match gauche
ExcludeArch:    ppc64


%description
Gauche extension module to use GTK.


%package devel
Summary:        Development files for %{name}
%if 0%{?rhel}
Group:          Development/Languages
%endif
Requires:       %{name} = %{epoch}:%{version}-%{release}

%description devel
Development files for %{name}.


%prep
%setup -q
autoconf


%build
%configure --enable-gtkgl --enable-glgd --enable-glgd-pango
make stubs
make %{?_smp_mflags} OPTFLAGS=


%install
%if 0%{?el5}
rm -rf $RPM_BUILD_ROOT
%endif
mkdir -p $RPM_BUILD_ROOT`gauche-config --syslibdir`
mkdir -p $RPM_BUILD_ROOT`gauche-config --sysarchdir`
make install DESTDIR=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -name '*.so' -exec chmod 0755 '{}' ';'
chmod -c 644 */*.c # for debuginfo


%check
# 'make check' does not set return code properly, but
# outputs to test.log
xvfb-run -a -w 1 make check
# Gtk test currently fails.
# four known failures reported upstream; fail if more failures occur
# https://github.com/shirok/Gauche-gtk2/issues/2
[ $(grep " ==> ERROR: GOT " src/test.log | wc -l) -le 4 ]


%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root,-)
%doc COPYING README VERSION examples
%{_libdir}/gauche-%{gauche_main_version}/site/*/*.so
%{_datadir}/gauche-%{gauche_main_version}/site/lib/.packages/Gauche-gtk2.gpd
%{_datadir}/gauche-%{gauche_main_version}/site/lib/gtk.scm
%{_datadir}/gauche-%{gauche_main_version}/site/lib/gtk
%{_datadir}/gauche-%{gauche_main_version}/site/lib/h2s


%files devel
%{_libdir}/gauche-%{gauche_main_version}/site/include/*


%changelog
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:0.6-0.10.20120403gitf7d3f802f3750
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild

* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:0.6-0.9.20120403gitf7d3f802f3750
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild

* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:0.6-0.8.20120403gitf7d3f802f3750
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild

* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:0.6-0.7.20120403gitf7d3f802f3750
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Sun May 13 2012 Michel Salim <salimma@fedoraproject.org> - 1:0.6-0.6.20120403gitf7d3f802f3750
- Correct the path to test log

* Sun May 13 2012 Michel Salim <salimma@fedoraproject.org> - 1:0.6-0.5.20120403gitf7d3f802f3750
- Rebuild for Gauche 0.9.3.x
- Update to latest snapshot
- Enable graphical tests
- Spec clean-ups

* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:0.6-0.4.20110725git598828842a339
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Thu Sep 22 2011 Michel Salim <salimma@fedoraproject.org> - 1:0.6-0.3.20110725git598828842a339
- Include Epoch field in -devel subpackage's dependence on main package

* Fri Sep 16 2011 Michel Salim <salimma@fedoraproject.org> - 1:0.6-0.2.20110725git598828842a339
- add Epoch field for upgrade path from mislabeled 0.9 release

* Thu Sep 15 2011 Michel Salim <salimma@fedoraproject.org> - 0.6-0.1.20110725git598828842a339
- Updated Git snapshot
- Fix version numbering
- Put header in -devel subpackage
- Fix overlapping directory ownerships
- Enable tests

* Mon Feb 14 2011 Gerard Milmeister <gemi@bluewin.ch> - 0.9-1.git20110214
- New release to match Gauche 0.9

* Sat Aug  1 2009 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-21
- fix for gtk 2.17

* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-20
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Sat Jun 20 2009 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-19
- updated for gauche 0.8.14

* Thu Feb 14 2008 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-17
- rebuild for gauche 0.8.13

* Mon Aug 20 2007 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-16
- fix include problem

* Mon Aug 20 2007 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-15
- fix gtk problem

* Sat Aug 18 2007 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-14
- exclude arch ppc64, depends on non-existing ppc64 gauche

* Sat Aug 18 2007 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-13
- rebuild for gauche 0.8.11

* Fri Apr 20 2007 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-12
- rebuild for gauche 0.8.10

* Thu Feb 22 2007 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-11
- added fix for using opt flags

* Thu Jan 18 2007 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-10
- rebuild for gauche 0.8.9

* Mon Nov 13 2006 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-9
- rebuilt for gauche 0.8.8

* Mon Aug 28 2006 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-8
- Rebuild for FE6

* Fri May  5 2006 Gerard Milmeister <gemi@bluewin.ch> - 0.4.1-7
- Added include flags for freetype
- Added -fPIC flag 

* Wed Feb 23 2005 Gerard Milmeister <gemi@bluewin.ch> - 0:0.4.1-1
- New Version 0.4.1

* Fri Mar 19 2004 Gerard Milmeister <gemi@bluewin.ch> - 0:0.4-0.fdr.1
- New Version 0.4

* Fri Mar 19 2004 Gerard Milmeister <gemi@bluewin.ch> - 0:0.3.2-0.fdr.1
- New Version 0.3.2

* Mon Nov 10 2003 Gerard Milmeister <gemi@bluewin.ch> - 0:0.3.1-0.fdr.1
- First Fedora release