4529a1
Name:		ocaml
aa4861
Version:	3.08.3
817b03
Release: 4
c39241
4529a1
Summary:	Objective Caml compiler and programming environment
cvsextras be41c8
4529a1
Group:		Development/Languages
4529a1
License:	QPL/LGPL
186fbe
URL:		http://www.ocaml.org
aa4861
Source0:	http://caml.inria.fr/distrib/ocaml-3.08/ocaml-3.08.3.tar.bz2
4529a1
Source1:	http://caml.inria.fr/distrib/ocaml-3.08/ocaml-3.08-refman.html.tar.gz
4529a1
Source2:	http://caml.inria.fr/distrib/ocaml-3.08/ocaml-3.08-refman.ps.gz
4529a1
Source3:	http://caml.inria.fr/distrib/ocaml-3.08/ocaml-3.08-refman.info.tar.gz
817b03
Patch0:		ocaml-rpath.patch
817b03
Patch1:		ocaml-user-cflags.patch
817b03
Patch2:		ocaml-num-gcc4.patch
4529a1
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
c5c9c1
BuildRequires:	ncurses-devel, gdbm-devel, xorg-x11-devel
c5c9c1
BuildRequires:	tcl-devel, tk-devel
cvsextras be41c8
BuildRequires:	emacs, perl
4529a1
Requires(post):	/sbin/install-info
aa4861
Requires(preun): /sbin/install-info
cvsextras be41c8
cvsextras be41c8
%description
cvsextras be41c8
Objective Caml is a high-level, strongly-typed, functional and
cvsextras be41c8
object-oriented programming language from the ML family of languages.
cvsextras be41c8
cvsextras be41c8
This package comprises two batch compilers (a fast bytecode compiler
cvsextras be41c8
and an optimizing native-code compiler), an interactive toplevel system,
cvsextras be41c8
parsing tools (Lex,Yacc,Camlp4), a replay debugger, a documentation generator,
cvsextras be41c8
and a comprehensive library.
cvsextras be41c8
cvsextras be41c8
%package -n labltk
cvsextras be41c8
Group:		Development/Languages
cvsextras be41c8
Summary:	Tk bindings for Objective Caml
4529a1
Requires:	ocaml = %{version}-%{release}
cvsextras be41c8
cvsextras be41c8
%description -n labltk
cvsextras be41c8
A library for interfacing Objective Caml with the scripting language
cvsextras be41c8
Tcl/Tk. It include the OCamlBrowser code editor / library browser.
cvsextras be41c8
cvsextras be41c8
%package -n camlp4
cvsextras be41c8
Group:		Development/Languages
4529a1
Summary:	Pre-Processor-Pretty-Printer for OCaml
4529a1
Requires:	ocaml = %{version}-%{release}
cvsextras be41c8
cvsextras be41c8
%description -n camlp4
cvsextras be41c8
Camlp4 is a Pre-Processor-Pretty-Printer for OCaml, parsing a source
cvsextras be41c8
file and printing some result on standard output.
cvsextras be41c8
cvsextras be41c8
%package ocamldoc
cvsextras be41c8
Group:		Development/Languages
cvsextras be41c8
Summary:	Documentation generator for OCaml
4529a1
Requires:	ocaml = %{version}-%{release}
cvsextras be41c8
cvsextras be41c8
%description ocamldoc
cvsextras be41c8
Documentation generator for Objective Caml.
cvsextras be41c8
cvsextras be41c8
%package emacs
cvsextras be41c8
Group:		Development/Languages
cvsextras be41c8
Summary:	Emacs mode for Objective Caml
4529a1
Requires:	ocaml = %{version}-%{release}
cvsextras be41c8
Requires:	emacs
cvsextras be41c8
cvsextras be41c8
%description emacs
cvsextras be41c8
Emacs mode for Objective Caml.
cvsextras be41c8
cvsextras be41c8
%package docs
cvsextras be41c8
Group:		Development/Languages
cvsextras be41c8
Summary:	Documentation for OCaml
4529a1
Requires:	ocaml = %{version}-%{release}
cvsextras be41c8
cvsextras be41c8
%description docs
cvsextras be41c8
Documentation for Objective Caml.
cvsextras be41c8
cvsextras be41c8
%prep
cvsextras be41c8
%setup -q -T -b 0
cvsextras be41c8
%setup -q -T -D -a 1
cvsextras be41c8
%setup -q -T -D -a 3
817b03
%patch0 -p1
817b03
%patch1 -p1 -b .cflags
817b03
%patch2 -p1 -b .x86_32
817b03
cvsextras be41c8
cp %{SOURCE2} refman.ps.gz
cvsextras be41c8
cvsextras be41c8
%build
817b03
CFLAGS="$RPM_OPT_FLAGS" ./configure \
cvsextras be41c8
    -bindir %{_bindir} \
cvsextras be41c8
    -libdir %{_libdir}/ocaml \
0b1d48
    -x11lib %{_prefix}/X11R6/%{_lib} \
cvsextras be41c8
    -mandir %{_mandir}/man1
cvsextras be41c8
make world opt opt.opt
cvsextras be41c8
# %{?_smp_mflags} breaks the build
cvsextras be41c8
(cd emacs; make ocamltags)
cvsextras be41c8
cvsextras be41c8
%install
cvsextras be41c8
rm -rf $RPM_BUILD_ROOT
cvsextras be41c8
%makeinstall BINDIR=$RPM_BUILD_ROOT%{_bindir} LIBDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml MANDIR=$RPM_BUILD_ROOT%{_mandir}
cvsextras be41c8
perl -pi -e "s|^$RPM_BUILD_ROOT||" $RPM_BUILD_ROOT%{_libdir}/ocaml/ld.conf
cvsextras be41c8
(
cvsextras be41c8
    cd emacs;
cvsextras be41c8
    make install BINDIR=$RPM_BUILD_ROOT%{_bindir} EMACSDIR=$RPM_BUILD_ROOT%{_datadir}/emacs/site-lisp
cvsextras be41c8
    make install-ocamltags BINDIR=$RPM_BUILD_ROOT%{_bindir}
cvsextras be41c8
)
cvsextras be41c8
(
cvsextras be41c8
    mkdir -p $RPM_BUILD_ROOT%{_infodir};
cvsextras be41c8
    cd infoman; cp ocaml*.gz $RPM_BUILD_ROOT%{_infodir}
cvsextras be41c8
)
cvsextras be41c8
cvsextras be41c8
%clean
cvsextras be41c8
rm -rf $RPM_BUILD_ROOT
cvsextras be41c8
cvsextras be41c8
%post
cvsextras be41c8
/sbin/install-info \
cvsextras be41c8
    --entry "* ocaml: (ocaml).	 The Objective Caml compiler and programming environment" \
cvsextras be41c8
    --section "Programming Languages" \
cvsextras be41c8
    %{_infodir}/%{name}.info \
cvsextras be41c8
    %{_infodir}/dir 2>/dev/null || :
cvsextras be41c8
cvsextras be41c8
%preun
4529a1
if [ $1 -eq 0 ]; then
cvsextras be41c8
  /sbin/install-info --delete %{_infodir}/%{name}.info %{_infodir}/dir 2>/dev/null || :
cvsextras be41c8
fi
cvsextras be41c8
cvsextras be41c8
%files
cvsextras be41c8
%defattr(-,root,root,-)
cvsextras be41c8
%{_bindir}/*
cvsextras be41c8
%{_mandir}/man1/*
cvsextras be41c8
%{_mandir}/man3/*
cvsextras be41c8
%{_libdir}/ocaml
cvsextras be41c8
%{_infodir}/*
cvsextras be41c8
%exclude %{_bindir}/camlp4*
cvsextras be41c8
%exclude %{_bindir}/mkcamlp4
cvsextras be41c8
%exclude %{_bindir}/ocpp
cvsextras be41c8
%exclude %{_bindir}/labltk
cvsextras be41c8
%exclude %{_bindir}/ocamltags
cvsextras be41c8
%exclude %{_bindir}/ocamlbrowser
cvsextras be41c8
%exclude %{_bindir}/ocamldoc*
cvsextras be41c8
%exclude %{_libdir}/ocaml/camlp4
cvsextras be41c8
%exclude %{_libdir}/ocaml/labltk
cvsextras be41c8
%exclude %{_libdir}/ocaml/ocamldoc
cvsextras be41c8
%exclude %{_mandir}/man1/camlp4*
cvsextras be41c8
%exclude %{_mandir}/man1/mkcamlp4*
cvsextras be41c8
%exclude %{_libdir}/ocaml/stublibs/dlllabltk.so
cvsextras be41c8
%exclude %{_libdir}/ocaml/stublibs/dlltkanim.so
cvsextras be41c8
%doc README LICENSE Changes
cvsextras be41c8
cvsextras be41c8
%files -n labltk
cvsextras be41c8
%defattr(-,root,root,-)
cvsextras be41c8
%{_bindir}/labltk
cvsextras be41c8
%{_bindir}/ocamlbrowser
cvsextras be41c8
%{_libdir}/ocaml/labltk
cvsextras be41c8
%{_libdir}/ocaml/stublibs/dlllabltk.so
cvsextras be41c8
%{_libdir}/ocaml/stublibs/dlltkanim.so
cvsextras be41c8
%doc otherlibs/labltk/examples_labltk
cvsextras be41c8
%doc otherlibs/labltk/examples_camltk
cvsextras be41c8
cvsextras be41c8
%files -n camlp4
cvsextras be41c8
%defattr(-,root,root,-)
cvsextras be41c8
%{_bindir}/camlp4*
cvsextras be41c8
%{_bindir}/mkcamlp4
cvsextras be41c8
%{_bindir}/ocpp
cvsextras be41c8
%{_libdir}/ocaml/camlp4
cvsextras be41c8
%{_mandir}/man1/camlp4*
cvsextras be41c8
%{_mandir}/man1/mkcamlp4*
cvsextras be41c8
cvsextras be41c8
%files ocamldoc
cvsextras be41c8
%defattr(-,root,root,-)
cvsextras be41c8
%{_bindir}/ocamldoc*
cvsextras be41c8
%{_libdir}/ocaml/ocamldoc
cvsextras be41c8
%doc ocamldoc/Changes.txt
cvsextras be41c8
cvsextras be41c8
%files docs
cvsextras be41c8
%defattr(-,root,root,-)
cvsextras be41c8
%doc refman.ps.gz htmlman
cvsextras be41c8
cvsextras be41c8
%files emacs
cvsextras be41c8
%defattr(-,root,root,-)
cvsextras be41c8
%{_datadir}/emacs/site-lisp/*
cvsextras be41c8
%{_bindir}/ocamltags
cvsextras be41c8
%doc emacs/README
cvsextras be41c8
cvsextras be41c8
%changelog
817b03
* Mon May 9 2005 Toshio Kuratomi <toshio-tiki-lounge.com> - 3.08.3-4
817b03
- Fix for gcc4 and the 32 bit assembly in otherlibs/num.
817b03
- Fix to allow compilation with RPM_OPT_FLAG defined -O level.
817b03
d95206
* Sun May 22 2005 Jeremy Katz <katzj@redhat.com> - 3.08.3-3
d95206
- rebuild on all arches
d95206
c39241
* Fri Apr  7 2005 Michael Schwendt <mschwendt[AT]users.sf.net>
c39241
- rebuilt
c39241
aa4861
* Sat Mar 26 2005 Gerard Milmeister <gemi@bluewin.ch> - 3.08.3-1
aa4861
- New Version 3.08.3
aa4861
c5c9c1
* Sat Feb 12 2005 Gerard Milmeister <gemi@bluewin.ch> - 0:3.08.2-2
c5c9c1
- Added patch for removing rpath from shared libs
c5c9c1
186fbe
* Sat Feb 12 2005 Gerard Milmeister <gemi@bluewin.ch> - 0:3.08.2-1
186fbe
- New Version 3.08.2
186fbe
0b1d48
* Thu Dec 30 2004 Thorsten Leemhuis <fedora[AT]leemhuis[DOT]info> - 0:3.07-6
4529a1
- add -x11lib %%{_prefix}/X11R6/%%{_lib} to configure; fixes labltk build
0b1d48
  on x86_64
0b1d48
cvsextras be41c8
* Tue Dec  2 2003 Gerard Milmeister <gemi@bluewin.ch> - 0:3.07-0.fdr.5
cvsextras be41c8
- ocamldoc -> ocaml-ocamldoc
cvsextras be41c8
- ocaml-doc -> ocaml-docs
cvsextras be41c8
cvsextras be41c8
* Fri Nov 28 2003 Gerard Milmeister <gemi@bluewin.ch> - 0:3.07-0.fdr.4
cvsextras be41c8
- Make separate packages for labltk, camlp4, ocamldoc, emacs and documentation
cvsextras be41c8
cvsextras be41c8
* Thu Nov 27 2003 Gerard Milmeister <gemi@bluewin.ch> - 0:3.07-0.fdr.2
cvsextras be41c8
- Changed license tag
cvsextras be41c8
- Register info files
cvsextras be41c8
- Honor RPM_OPT_FLAGS
cvsextras be41c8
- New Patch
cvsextras be41c8
cvsextras be41c8
* Fri Oct 31 2003 Gerard Milmeister <gemi@bluewin.ch> - 0:3.07-0.fdr.1
cvsextras be41c8
- First Fedora release
cvsextras be41c8
cvsextras be41c8
* Mon Oct 13 2003 Axel Thimm <Axel.Thimm@physik.fu-berlin.de>
cvsextras be41c8
- Updated to 3.07.
cvsextras be41c8
cvsextras be41c8
* Wed Apr  9 2003 Axel Thimm <Axel.Thimm@physik.fu-berlin.de>
cvsextras be41c8
- Rebuilt for Red Hat 9.
cvsextras be41c8
cvsextras be41c8
* Tue Nov 26 2002 Axel Thimm <Axel.Thimm@physik.fu-berlin.de>
cvsextras be41c8
- Added %{_mandir}/mano/* entry