%{!?with_x:%undefine with_tk}
%define p4ver 3.06
-%define sver 3.09
+%define sver 3.12
Summary: The Objective Caml compiler and programming environment
-Summary(pl.UTF-8): Kompilator OCamla (Objective Caml) oraz środowisko programistyczne
+Summary(pl.UTF-8): Kompilator OCamla (Objective Caml) oraz środowisko programistyczne
Name: ocaml
-Version: 3.09.3
-Release: 1
+Version: 3.12.1
+Release: 15
Epoch: 1
License: distributable
-Vendor: Group of implementors <caml-light@inria.fr>
Group: Development/Languages
Source0: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{version}.tar.bz2
-# Source0-md5: 8b3744efd0d51b82d55b61d0e2bf0e2b
+# Source0-md5: 227a3daaedb150bf5037a3db01f5bf42
Source1: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{sver}-refman.html.tar.gz
-# Source1-md5: b25eb211bf91bcaa536b12d12731ceec
+# Source1-md5: 93cd91f525441eb7e94cc49b9b64bab0
Source2: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{sver}-refman.ps.gz
-# Source2-md5: 598bb8e86329afe1ae374385b2e177e7
-Source3: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-manual.html.tar.gz
-# Source3-md5: 21370bae4e7f6435b38aeb21db7ce8bb
-Source4: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-manual.dvi.gz
-# Source4-md5: 035915d1a530aa7ec9b194d9a7d258eb
-Source5: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-tutorial.html.tar.gz
-# Source5-md5: 96d8eb4ca5abd58c9a280ba59f73b192
-Source6: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-tutorial.dvi.gz
-# Source6-md5: fcd87c235109364242a0c9ccf176dff8
-Source7: http://www.ocaml.info/ocaml_sources/pure-fun-1.0.6.tar.bz2
-# Source7-md5: 94eac3fa1ac51b8ada344b04839cb43c
-Source8: http://www.ocaml.info/ocaml_sources/ds-contrib.tar.gz
-# Source8-md5: 77fa1da7375dea1393cc0b6cd802d7e1
-Source9: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{sver}-refman.info.tar.gz
-# Source9-md5: 280160b1fc7c8513074c3fda0446de29
-Patch0: %{name}-build.patch
-Patch1: %{name}-db3.patch
-Patch2: %{name}-objinfo.patch
-Patch3: %{name}-tk85support.patch
-Patch4: %{name}-CFLAGS.patch
-Patch5: %{name}-as_needed.patch
+# Source2-md5: a9c17db6ffd400c5ea00c6d51cbf56bf
+Source3: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{sver}-refman.info.tar.gz
+# Source3-md5: 8cf24c4f69c6f9c9f9cc1edb9b18f6cb
+Source4: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-manual.html.tar.gz
+# Source4-md5: 21370bae4e7f6435b38aeb21db7ce8bb
+Source5: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-manual.dvi.gz
+# Source5-md5: 035915d1a530aa7ec9b194d9a7d258eb
+Source6: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-tutorial.html.tar.gz
+# Source6-md5: 96d8eb4ca5abd58c9a280ba59f73b192
+Source7: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-tutorial.dvi.gz
+# Source7-md5: fcd87c235109364242a0c9ccf176dff8
+Source8: http://www.ocaml.info/ocaml_sources/pure-fun-1.0.6.tar.bz2
+# Source8-md5: 94eac3fa1ac51b8ada344b04839cb43c
+Source9: http://www.ocaml.info/ocaml_sources/ds-contrib.tar.gz
+# Source9-md5: 77fa1da7375dea1393cc0b6cd802d7e1
+Patch0: %{name}-db3.patch
+Patch1: %{name}-CFLAGS.patch
+Patch2: %{name}-as_needed.patch
+Patch3: %{name}-gas.patch
URL: http://caml.inria.fr/
BuildRequires: db-devel >= 4.1
%{?with_tk:BuildRequires: tk-devel}
%{?with_x:BuildRequires: xorg-lib-libX11-devel}
%if %{with emacs}
BuildRequires: sed >= 4.0
-BuildRequires: xemacs
-BuildRequires: xemacs-common
-BuildRequires: xemacs-fsf-compat-pkg
+BuildRequires: emacs
+BuildRequires: emacs-common
%endif
Requires: %{name}-runtime = %{epoch}:%{version}-%{release}
Provides: ocaml-ocamldoc
%package runtime
Summary: Runtime system for OCaml
-Summary(pl.UTF-8): Środowisko uruchomieniowe dla OCamla
+Summary(pl.UTF-8): Środowisko uruchomieniowe dla OCamla
Group: Libraries
%description runtime
%package lib-source
Summary: Sources of OCaml standard library
-Summary(pl.UTF-8): Źródła biblioteki standardowej OCamla
+Summary(pl.UTF-8): Źródła biblioteki standardowej OCamla
Group: Development/Languages
Requires: %{name} = %{epoch}:%{version}-%{release}
%package doc-html
Summary: HTML documentation for OCaml
-Summary(pl.UTF-8): Dokumentacja dla OCamla w formacie HTML
+Summary(pl.UTF-8): Dokumentacja dla OCamla w formacie HTML
Group: Development/Tools
%description doc-html
%package doc-ps
Summary: PostScript documentation for OCaml
-Summary(pl.UTF-8): Dokumentacja dla OCamla w formacie PostScript
+Summary(pl.UTF-8): Dokumentacja dla OCamla w formacie PostScript
Group: Development/Tools
%description doc-ps
%package doc-info
Summary: Info documentation for OCaml
-Summary(pl.UTF-8): Dokumentacja info dla OCamla
+Summary(pl.UTF-8): Dokumentacja info dla OCamla
Group: Development/Tools
%description doc-info
%package emacs
Summary: Emacs mode for OCaml
-Summary(pl.UTF-8): Tryb OCamla dla Emacsa
+Summary(pl.UTF-8): Tryb OCamla dla Emacsa
Group: Development/Tools
Requires: %{name} = %{epoch}:%{version}-%{release}
%package labltk
Summary: Runtime for LablTk library
-Summary(pl.UTF-8): Środowisko uruchomieniowe dla biblioteki LablTk
+Summary(pl.UTF-8): Środowisko uruchomieniowe dla biblioteki LablTk
Group: Libraries
Requires: %{name} = %{epoch}:%{version}-%{release}
%package labltk-devel
Summary: LablTk library for OCaml
-Summary(pl.UTF-8): Biblioteka LablTk dla OCamla
+Summary(pl.UTF-8): Biblioteka LablTk dla OCamla
Group: Development/Libraries
Requires: %{name}-labltk = %{epoch}:%{version}-%{release}
%package x11graphics
Summary: X11 graphic output for OCaml
-Summary(pl.UTF-8): Dostęp do X11 dla OCamla
+Summary(pl.UTF-8): Dostęp do X11 dla OCamla
Group: Development/Libraries
Requires: %{name} = %{epoch}:%{version}-%{release}
%package x11graphics-devel
Summary: X11 graphic output for OCaml
-Summary(pl.UTF-8): Dostęp do X11 dla OCamla
+Summary(pl.UTF-8): Dostęp do X11 dla OCamla
Group: Development/Libraries
Requires: %{name}-x11graphics = %{epoch}:%{version}-%{release}
%package camlp4
Summary: Objective Caml Preprocessor
-Summary(pl.UTF-8): Preprocesor OCamla
+Summary(pl.UTF-8): Preprocesor OCamla
Group: Development/Languages
Requires: %{name} = %{epoch}:%{version}-%{release}
Provides: camlp4 = %{epoch}:%{version}-%{release}
%package camlp4-doc-html
Summary: Objective Caml Preprocessor - HTML documentation
-Summary(pl.UTF-8): Preprocesor OCamla - dokumentacja HTML
+Summary(pl.UTF-8): Preprocesor OCamla - dokumentacja HTML
Group: Development/Languages
%description camlp4-doc-html
%package compiler-objects
Summary: Compiled parts of OCaml compiler
-Summary(pl.UTF-8): Skompilowane części kompilatora OCamla
+Summary(pl.UTF-8): Skompilowane części kompilatora OCamla
Group: Development/Languages
Requires: %{name} = %{epoch}:%{version}-%{release}
Obsoletes: ocaml-devel
%package ocamldoc-devel
Summary: Files needed to develop programs using ocamldoc
-Summary(pl.UTF-8): Pliki potrzebne do tworzenia programów używających ocamldoc
+Summary(pl.UTF-8): Pliki potrzebne do tworzenia programów używających ocamldoc
Group: Development/Languages
Requires: %{name} = %{epoch}:%{version}-%{release}
# maybe we'll want to add some more stuff here?
%package examples
Summary: Example source code for OCaml
-Summary(pl.UTF-8): Przykładowe kody źródłowe w OCamlu
+Summary(pl.UTF-8): Przykładowe kody źródłowe w OCamlu
Group: Development/Languages
Requires: %{name} = %{epoch}:%{version}-%{release}
autorstwa Okasaki'ego, napisane w OCamlu, wraz z dodatkami.
%prep
-%setup -q -a1 -a3 -a5
+%setup -q -a1 -a3 -a4 -a6
mkdir examples
-tar xjf %{SOURCE7} -C examples
-tar xzf %{SOURCE8} -C examples
-tar xzf %{SOURCE9}
+tar xjf %{SOURCE8} -C examples
+tar xzf %{SOURCE9} -C examples
# order mess with docs somewhat
mkdir -p docs/html
mv htmlman docs/html/ocaml
cp %{SOURCE2} docs/ocaml.ps.gz
mv camlp4-%{p4ver}-manual.html docs/html/camlp4
-cp %{SOURCE4} docs/camlp4.ps.gz
+cp %{SOURCE5} docs/camlp4.ps.gz
mv camlp4-%{p4ver}-tutorial.html docs/html/camlp4-tutorial
-cp %{SOURCE6} docs/camlp4-tutorial.ps.gz
+cp %{SOURCE7} docs/camlp4-tutorial.ps.gz
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
-%patch4 -p1
-%patch5 -p1
%build
cp -f /usr/share/automake/config.sub config/gnu
%{__make} -j1 world bootstrap opt.opt CFLAGS="%{rpmcflags} -Wall"
%{__make} -C tools objinfo CFLAGS="%{rpmcflags} -Wall" -j1
+# broken build system
+sed -e 's,LIBDIR,%{_libdir},' camlp4/man/camlp4.1.tpl > camlp4/man/camlp4.1
+
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT{%{_includedir},%{_infodir},%{_examplesdir}/%{name}-{labltk-,}%{version}}
+install -d $RPM_BUILD_ROOT%{_libdir}/%{name}/site-lib
%{__make} install \
BINDIR=$RPM_BUILD_ROOT%{_bindir} \
EOF
%if %{with emacs}
-%{__make} -C emacs DESTDIR=$RPM_BUILD_ROOT install \
- EMACS="`if [ -x %{_bindir}/emacs ]; then echo emacs; \
- else echo xemacs; fi`" \
- EMACSDIR="$RPM_BUILD_ROOT%{_datadir}/emacs/site-lisp"
+%{__make} -C emacs install \
+ DESTDIR=$RPM_BUILD_ROOT \
+ EMACSDIR="$RPM_BUILD_ROOT%{_datadir}/emacs/site-lisp" \
+ EMACS="emacs"
%endif
# symlink .opt versions of compilers (if present)
ln -sf %{_libdir}/%{name}/{scrape,add}labels $RPM_BUILD_ROOT%{_bindir}
# shutup checkfiles
-rm -rf $RPM_BUILD_ROOT%{_mandir}/man3
-rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/labltk/{labltktop,pp}
+%{__rm} -r $RPM_BUILD_ROOT%{_mandir}/man3
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/labltk/{labltktop,pp}
# install info pages
cp -f infoman/*.gz $RPM_BUILD_ROOT%{_infodir}
+# broken build system
+install camlp4/man/camlp4.1 $RPM_BUILD_ROOT%{_mandir}/man1
+for f in camlp4o.1 camlp4r.1 mkcamlp4.1 camlp4o.opt.1 camlp4r.opt.1 ; do
+ echo '.so camlp4.1' >$RPM_BUILD_ROOT%{_mandir}/man1/$f
+done
+
%clean
rm -rf $RPM_BUILD_ROOT
-%post doc-info
-[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
+%post doc-info -p /sbin/postshell
+-/usr/sbin/fix-info-dir -c %{_infodir}
-%postun doc-info
-[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
+%postun doc-info -p /sbin/postshell
+-/usr/sbin/fix-info-dir -c %{_infodir}
%files
%defattr(644,root,root,755)
%doc LICENSE Changes README Upgrading
+%attr(755,root,root) %{_bindir}/addlabels
%attr(755,root,root) %{_bindir}/ocaml*
-%{!?_without_tk:%exclude %{_bindir}/ocamlbrowser}
+%attr(755,root,root) %{_bindir}/scrapelabels
+%{?with_tk:%exclude %{_bindir}/ocamlbrowser}
%exclude %{_bindir}/ocamlrun
-%attr(755,root,root) %{_bindir}/*labels
%{_includedir}/caml
%{_libdir}/%{name}/caml
%{_libdir}/%{name}/threads
%{_libdir}/%{name}/*.o
%{_libdir}/%{name}/*.cm*
%exclude %{_libdir}/%{name}/*graphics*
+%{_libdir}/%{name}/Makefile.config
%{_libdir}/%{name}/ld.conf
%{_libdir}/%{name}/camlheader
%{_libdir}/%{name}/camlheader_ur
+%{_libdir}/%{name}/ocamlbuild
%dir %{_libdir}/%{name}/ocamldoc
%{_libdir}/%{name}/ocamldoc/*.hva
%attr(755,root,root) %{_libdir}/%{name}/expunge
%attr(755,root,root) %{_libdir}/%{name}/extract_crc
-%attr(755,root,root) %{_libdir}/%{name}/*labels
-%{_mandir}/man1/*ocaml*
+%attr(755,root,root) %{_libdir}/%{name}/objinfo_helper
+%{_mandir}/man1/ocaml*
+%exclude %{_mandir}/man1/ocamlrun.1*
%files runtime
%defattr(644,root,root,755)
%attr(755,root,root) %{_bindir}/ocamlrun
%dir %{_libdir}/%{name}
+%dir %{_libdir}/%{name}/site-lib
%dir %{_libdir}/%{name}/stublibs
%attr(755,root,root) %{_libdir}/%{name}/stublibs/dll*.so
%exclude %{_libdir}/%{name}/stublibs/dllgraphics.so
+%attr(755,root,root) %{_libdir}/%{name}/libcamlrun_shared.so
%if %{with tk}
%exclude %{_libdir}/%{name}/stublibs/dlllabltk.so
-%exclude %{_libdir}/%{name}/stublibs/dlltkanim.so
%endif
+%{_mandir}/man1/ocamlrun.1*
%files lib-source
%defattr(644,root,root,755)
%files labltk
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/%{name}/stublibs/dlllabltk.so
-%attr(755,root,root) %{_libdir}/%{name}/stublibs/dlltkanim.so
%files labltk-devel
%defattr(644,root,root,755)
%dir %{_libdir}/%{name}/labltk
%{_libdir}/%{name}/labltk/*.cm*
%{_libdir}/%{name}/labltk/*.a
+%{_libdir}/%{name}/labltk/*.o
%attr(755,root,root) %{_libdir}/%{name}/labltk/tkcompiler
%{_examplesdir}/%{name}-labltk-%{version}
%endif
%files camlp4
%defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/*camlp4*
-%attr(755,root,root) %{_bindir}/ocpp
-# Not installed since 3.05, is it needed?
-#%attr(755,root,root) %{_bindir}/odyl
+%attr(755,root,root) %{_bindir}/camlp4*
+%attr(755,root,root) %{_bindir}/mkcamlp4
%{_libdir}/%{name}/camlp4
-%{_mandir}/man*/*camlp4*
-%{_mandir}/man*/*ocpp*
+%{_mandir}/man1/camlp4*.1*
+%{_mandir}/man1/mkcamlp4.1*
%files camlp4-doc-html
%defattr(644,root,root,755)