2010-02-11 03:22:59 +00:00
|
|
|
%global opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0)
|
2011-07-11 21:31:14 +00:00
|
|
|
%global ocaml_destdir %{_libdir}/ocaml
|
2014-02-26 14:35:57 +00:00
|
|
|
%if !%{opt}
|
2010-02-11 03:22:59 +00:00
|
|
|
%global debug_package %{nil}
|
2014-02-26 14:35:57 +00:00
|
|
|
%endif
|
2011-01-21 15:54:18 +00:00
|
|
|
|
2009-08-08 02:52:26 +00:00
|
|
|
Name: ocaml-ocamlgraph
|
2014-04-21 22:00:50 +00:00
|
|
|
Version: 1.8.5
|
2014-06-07 15:43:45 +00:00
|
|
|
Release: 2%{?dist}
|
2009-08-08 02:52:26 +00:00
|
|
|
Summary: OCaml library for arc and node graphs
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2009-08-08 02:52:26 +00:00
|
|
|
License: LGPLv2 with exceptions
|
|
|
|
URL: http://ocamlgraph.lri.fr/
|
2014-04-21 22:00:50 +00:00
|
|
|
Source0: http://ocamlgraph.lri.fr/download/ocamlgraph-%{version}.tar.gz
|
2009-08-08 02:52:26 +00:00
|
|
|
Source1: ocamlgraph-test.result
|
2014-02-26 14:35:57 +00:00
|
|
|
# When building the byte variant, do not try to install artifacts that were
|
|
|
|
# not built.
|
2014-04-21 22:00:50 +00:00
|
|
|
Patch0: ocamlgraph-1.8.5-byte-install.patch
|
2010-02-11 03:22:59 +00:00
|
|
|
|
2011-07-11 21:31:14 +00:00
|
|
|
BuildRequires: libart_lgpl-devel
|
|
|
|
BuildRequires: libgnomecanvas-devel
|
|
|
|
BuildRequires: ocaml
|
2014-02-26 14:35:57 +00:00
|
|
|
BuildRequires: ocaml-findlib
|
2008-12-05 13:23:18 +00:00
|
|
|
BuildRequires: ocaml-lablgtk-devel
|
2011-07-11 21:31:14 +00:00
|
|
|
BuildRequires: ocaml-ocamldoc
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2011-07-11 21:31:14 +00:00
|
|
|
%global __requires_exclude ocaml\\\(Sig\\\)
|
2014-02-26 14:35:57 +00:00
|
|
|
%global libname %(sed -e 's/^ocaml-//' <<< %{name})
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
%description
|
|
|
|
Ocamlgraph provides several different implementations of graph data
|
|
|
|
structures. It also provides implementations for a number of classical
|
|
|
|
graph algorithms like Kruskal's algorithm for MSTs, topological
|
|
|
|
ordering of DAGs, Dijkstra's shortest paths algorithm, and
|
|
|
|
Ford-Fulkerson's maximal-flow algorithm to name a few. The algorithms
|
|
|
|
and data structures are written functorially for maximal
|
|
|
|
reusability. Also has input and output capability for Graph Modeling
|
|
|
|
Language file format and Dot and Neato graphviz (graph visualization)
|
|
|
|
tools.
|
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2009-08-08 02:52:26 +00:00
|
|
|
%package devel
|
|
|
|
Summary: Development files for %{name}
|
2014-02-26 14:35:57 +00:00
|
|
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2009-08-08 02:52:26 +00:00
|
|
|
%description devel
|
2008-08-23 20:48:48 +00:00
|
|
|
The %{name}-devel package contains libraries and signature files for
|
|
|
|
developing applications that use %{name}.
|
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2014-02-26 14:35:57 +00:00
|
|
|
%package tools
|
|
|
|
Summary: Graph editing tools for %{name}
|
|
|
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
|
|
%description tools
|
|
|
|
The %{name}-tools package contains graph editing tools for use with
|
|
|
|
%{name}.
|
|
|
|
|
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
%prep
|
2014-04-21 22:00:50 +00:00
|
|
|
%setup -q -n %{libname}-%{version}
|
2014-02-26 14:35:57 +00:00
|
|
|
%if ! %opt
|
2011-07-11 21:31:14 +00:00
|
|
|
%patch0
|
2014-02-26 14:35:57 +00:00
|
|
|
%endif
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2011-07-11 21:31:14 +00:00
|
|
|
cp -p %{SOURCE1} .
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2011-07-11 21:31:14 +00:00
|
|
|
# Remove spurious executable bits
|
|
|
|
find . -name '*.ml*' -perm /0111 | xargs chmod a-x
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2013-05-14 19:43:27 +00:00
|
|
|
# Fix encoding
|
|
|
|
for fil in CHANGES COPYING CREDITS; do
|
|
|
|
iconv -f latin1 -t utf-8 $fil > $fil.utf8
|
|
|
|
touch -r $fil $fil.utf8
|
|
|
|
mv -f $fil.utf8 $fil
|
|
|
|
done
|
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
%build
|
2011-07-11 21:31:14 +00:00
|
|
|
%configure
|
2008-08-23 20:48:48 +00:00
|
|
|
|
|
|
|
%if %opt
|
2013-09-14 13:22:53 +00:00
|
|
|
%global opt_option OCAMLBEST=opt OCAMLOPT='ocamlopt.opt -g'
|
2008-08-23 20:48:48 +00:00
|
|
|
%else
|
2010-02-11 03:22:59 +00:00
|
|
|
%global opt_option OCAMLBEST=byte OCAMLC=ocamlc
|
2008-08-23 20:48:48 +00:00
|
|
|
%endif
|
2009-10-08 13:07:40 +00:00
|
|
|
make depend
|
2008-08-23 20:48:48 +00:00
|
|
|
make %{opt_option}
|
|
|
|
make doc
|
|
|
|
|
|
|
|
%check
|
2008-11-20 16:49:18 +00:00
|
|
|
make --no-print-directory check >& test
|
2011-07-11 21:31:14 +00:00
|
|
|
diff -u test ocamlgraph-test.result
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
%install
|
|
|
|
mkdir -p %{buildroot}%{ocaml_destdir}
|
|
|
|
make OCAMLFIND_DESTDIR=%{buildroot}%{ocaml_destdir} install-findlib
|
2014-02-26 14:35:57 +00:00
|
|
|
%if %opt
|
|
|
|
install -m 0755 -p graph.cmxs %{buildroot}%{ocaml_destdir}/%{libname}
|
|
|
|
%endif
|
2008-08-23 20:48:48 +00:00
|
|
|
|
2013-08-06 15:12:38 +00:00
|
|
|
# Include all code and examples in the docs
|
|
|
|
mkdir -p dox-devel/examples
|
|
|
|
mkdir -p dox-devel/API
|
|
|
|
cp -p examples/*.ml dox-devel/examples
|
|
|
|
cp -p doc/* dox-devel/API
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2014-02-26 14:35:57 +00:00
|
|
|
# Install the graph editing tools
|
|
|
|
mkdir -p %{buildroot}%{_bindir}
|
|
|
|
%if %opt
|
|
|
|
install -m 0755 -p editor/editor.opt %{buildroot}/%{_bindir}/ocaml-graph-editor
|
|
|
|
install -m 0755 -p dgraph/dgraph.opt %{buildroot}%{_bindir}/ocaml-graph-viewer
|
|
|
|
install -m 0755 -p view_graph/viewgraph.opt \
|
|
|
|
%{buildroot}%{_bindir}/ocaml-viewgraph
|
|
|
|
%else
|
|
|
|
install -m 0755 -p editor/editor.byte %{buildroot}/%{_bindir}/ocaml-graph-editor
|
|
|
|
install -m 0755 -p dgraph/dgraph.byte %{buildroot}%{_bindir}/ocaml-graph-viewer
|
|
|
|
install -m 0755 -p view_graph/viewgraph.byte \
|
|
|
|
%{buildroot}%{_bindir}/ocaml-viewgraph
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
%files
|
2013-08-06 15:12:38 +00:00
|
|
|
%doc COPYING CREDITS FAQ LICENSE
|
2014-02-26 14:35:57 +00:00
|
|
|
%{ocaml_destdir}/%{libname}/
|
2008-08-23 20:48:48 +00:00
|
|
|
%if %opt
|
|
|
|
%exclude %{ocaml_destdir}/*/*.a
|
|
|
|
%exclude %{ocaml_destdir}/*/*.cmxa
|
|
|
|
%exclude %{ocaml_destdir}/*/*.cmx
|
2010-02-11 03:22:59 +00:00
|
|
|
%exclude %{ocaml_destdir}/*/*.o
|
2008-08-23 20:48:48 +00:00
|
|
|
%endif
|
|
|
|
%exclude %{ocaml_destdir}/*/*.mli
|
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
%files devel
|
2013-08-06 15:12:38 +00:00
|
|
|
%doc CHANGES README dox-devel/*
|
2008-08-23 20:48:48 +00:00
|
|
|
%if %opt
|
|
|
|
%{ocaml_destdir}/*/*.a
|
|
|
|
%{ocaml_destdir}/*/*.cmxa
|
|
|
|
%{ocaml_destdir}/*/*.cmx
|
2010-02-11 03:22:59 +00:00
|
|
|
%{ocaml_destdir}/*/*.o
|
2008-08-23 20:48:48 +00:00
|
|
|
%endif
|
|
|
|
%{ocaml_destdir}/*/*.mli
|
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2014-02-26 14:35:57 +00:00
|
|
|
%files tools
|
|
|
|
%{_bindir}/*
|
|
|
|
|
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
%changelog
|
2014-06-07 15:43:45 +00:00
|
|
|
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.5-2
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
|
|
|
|
2014-04-21 22:00:50 +00:00
|
|
|
* Mon Apr 21 2014 Jerry James <loganjerry@gmail.com> - 1.8.5-1
|
|
|
|
- New upstream release
|
|
|
|
|
2014-04-15 12:41:23 +00:00
|
|
|
* Tue Apr 15 2014 Richard W.M. Jones <rjones@redhat.com> - 1.8.4-2
|
|
|
|
- Remove ocaml_arches macro (RHBZ#1087794).
|
|
|
|
|
2014-02-26 14:35:57 +00:00
|
|
|
* Wed Feb 26 2014 Jerry James <loganjerry@gmail.com> - 1.8.4-1
|
|
|
|
- New upstream release, 1.8.4+dev, where the "+dev" refers to a bug fix
|
|
|
|
that was applied immediately after the 1.8.4 release
|
|
|
|
- Drop upstreamed patch
|
|
|
|
- Install graph.cmxs and enable the -debuginfo subpackage
|
|
|
|
- Update expected test results
|
|
|
|
- BR ocaml-findlib only, not ocaml-findlib-devel
|
|
|
|
- Install graph editing tools into -tools subpackage
|
|
|
|
- Fix the bytecode build
|
|
|
|
|
2013-10-02 13:16:11 +00:00
|
|
|
* Wed Oct 02 2013 Richard W.M. Jones <rjones@redhat.com> - 1.8.3-5
|
|
|
|
- Rebuild for ocaml-lablgtk 2.18.
|
|
|
|
|
2013-09-14 13:22:53 +00:00
|
|
|
* Sat Sep 14 2013 Richard W.M. Jones <rjones@redhat.com> - 1.8.3-4
|
|
|
|
- Rebuild for OCaml 4.01.0.
|
|
|
|
|
2013-08-06 15:12:38 +00:00
|
|
|
* Tue Aug 6 2013 Jerry James <loganjerry@gmail.com> - 1.8.3-3
|
|
|
|
- Adapt to Rawhide unversioned docdir change (bz 994002)
|
|
|
|
|
2013-08-03 14:57:58 +00:00
|
|
|
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.3-2
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
|
|
|
|
2013-05-14 19:43:27 +00:00
|
|
|
* Tue May 14 2013 Jerry James <loganjerry@gmail.com> - 1.8.3-1
|
|
|
|
- New upstream release
|
|
|
|
|
2013-02-14 09:01:00 +00:00
|
|
|
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.2-3
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
|
|
|
|
2012-10-17 15:31:56 +00:00
|
|
|
* Wed Oct 17 2012 Jerry James <loganjerry@gmail.com> - 1.8.2-2
|
|
|
|
- Rebuild for OCaml 4.00.1.
|
|
|
|
|
2012-07-30 22:51:03 +00:00
|
|
|
* Mon Jul 30 2012 Jerry James <loganjerry@gmail.com> - 1.8.2-1
|
|
|
|
- New upstream release
|
|
|
|
|
2012-07-20 06:05:09 +00:00
|
|
|
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.1-4
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
|
|
|
|
2012-06-11 08:26:28 +00:00
|
|
|
* Mon Jun 11 2012 Richard W.M. Jones <rjones@redhat.com> - 1.8.1-3
|
|
|
|
- Rebuild for OCaml 4.00.0.
|
|
|
|
|
2012-01-08 00:50:55 +00:00
|
|
|
* Sat Jan 7 2012 Jerry James <loganjerry@gmail.com> - 1.8.1-2
|
|
|
|
- Rebuild for OCaml 3.12.1
|
|
|
|
|
2011-10-28 16:57:20 +00:00
|
|
|
* Tue Oct 25 2011 Jerry James <loganjerry@gmail.com> - 1.8.1-1
|
|
|
|
- New upstream release
|
|
|
|
|
2011-07-11 21:31:14 +00:00
|
|
|
* Mon Jul 11 2011 Jerry James <loganjerry@gmail.com> - 1.7-1
|
|
|
|
- New upstream release
|
|
|
|
- Drop unnecessary spec file elements (BuildRoot, etc.)
|
|
|
|
- Drop dependency generation workaround for Fedora 12 and earlier
|
|
|
|
- Remove spurious executable bits on source files
|
|
|
|
- Replace the definition of __ocaml_requires_opts to "-i Sig", which removes
|
|
|
|
the legitimate Requires: ocaml(GtkSignal), with __requires_exclude.
|
|
|
|
|
2011-02-09 01:59:27 +00:00
|
|
|
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.6-3
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
|
|
|
|
2011-01-21 15:54:18 +00:00
|
|
|
* Fri Jan 21 2011 Richard W.M. Jones <rjones@redhat.com> - 1.6-2
|
|
|
|
- Ignore ocaml(Sig) symbol.
|
|
|
|
|
2011-01-10 13:35:00 +00:00
|
|
|
* Mon Jan 10 2011 Richard W.M. Jones <rjones@redhat.com> - 1.6-1
|
|
|
|
- New upstream version 1.6.
|
|
|
|
- Rebuild for OCaml 3.12.
|
|
|
|
- Remove obsolete patches and add patch to fix install-findlib rule.
|
|
|
|
|
2010-02-11 03:22:59 +00:00
|
|
|
* Wed Feb 10 2010 Alan Dunn <amdunn@gmail.com> - 1.3-3
|
|
|
|
- Include files (including .cmo files) and install more files that are
|
|
|
|
needed by other applications (eg: Frama-C) that depend on
|
|
|
|
ocaml-ocamlgraph
|
|
|
|
- define -> global
|
|
|
|
- Update for new dependency generator in F13
|
|
|
|
|
2009-12-30 13:51:16 +00:00
|
|
|
* Wed Dec 30 2009 Richard W.M. Jones <rjones@redhat.com> - 1.3-2
|
|
|
|
- Rebuild for OCaml 3.11.2.
|
|
|
|
|
2009-10-08 13:07:40 +00:00
|
|
|
* Thu Oct 8 2009 Richard W.M. Jones <rjones@redhat.com> - 1.3-1
|
|
|
|
- New upstream release 1.3.
|
|
|
|
- A slightly different viewGraph-related patch is required for this release.
|
|
|
|
|
2009-08-08 02:52:26 +00:00
|
|
|
* Fri Aug 07 2009 Alan Dunn <amdunn@gmail.com> - 1.1-1
|
|
|
|
- New upstream release 1.1.
|
|
|
|
- Makefile patch updated (still not incorporated upstream).
|
|
|
|
|
2009-07-25 20:00:48 +00:00
|
|
|
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0-6
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
|
|
|
|
|
2009-05-23 09:02:55 +00:00
|
|
|
* Sat May 23 2009 Richard W.M. Jones <rjones@redhat.com> - 1.0-5
|
|
|
|
- Rebuild for OCaml 3.11.1
|
|
|
|
|
2009-04-16 09:06:11 +00:00
|
|
|
* Thu Apr 16 2009 S390x secondary arch maintainer <fedora-s390x@lists.fedoraproject.org>
|
|
|
|
- ExcludeArch sparc64, s390, s390x as we don't have OCaml on those archs
|
|
|
|
(added sparc64 per request from the sparc maintainer)
|
|
|
|
|
2009-02-26 07:19:11 +00:00
|
|
|
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0-4
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
|
|
|
|
2008-12-05 13:31:36 +00:00
|
|
|
* Fri Dec 5 2008 Richard W.M. Jones <rjones@redhat.com> - 1.0-3
|
2008-12-05 13:23:18 +00:00
|
|
|
- Rebuild for OCaml 3.11.0.
|
|
|
|
- Requires lablgtk2.
|
2008-12-05 13:31:36 +00:00
|
|
|
- Pull in gtk / libgnomecanvas too.
|
2008-12-05 13:23:18 +00:00
|
|
|
|
2008-11-20 16:49:18 +00:00
|
|
|
* Thu Nov 20 2008 Richard W.M. Jones <rjones@redhat.com> - 1.0-1
|
|
|
|
- New upstream release 1.0.
|
|
|
|
- Patch0 removed - now upstream.
|
|
|
|
- Added a patch to fix documentation problem.
|
|
|
|
- Run tests with 'make --no-print-directory'.
|
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
* Wed Aug 13 2008 Alan Dunn <amdunn@gmail.com> 0.99c-2
|
|
|
|
- Incorporates changes suggested during review:
|
|
|
|
- License information was incorrect
|
|
|
|
- rpmlint error now properly justified
|
2008-11-20 16:49:18 +00:00
|
|
|
|
2008-08-23 20:48:48 +00:00
|
|
|
* Thu Aug 07 2008 Alan Dunn <amdunn@gmail.com> 0.99c-1
|
|
|
|
- Initial Fedora RPM release.
|