caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] Patch to ocaml-3.01-2 RPM spec file
@ 2001-03-20 16:35 David Fox
  2001-03-20 17:45 ` David Fox
  0 siblings, 1 reply; 2+ messages in thread
From: David Fox @ 2001-03-20 16:35 UTC (permalink / raw)
  To: caml-list

I thought I would contribute these changes to the latest ocaml RPM
SPEC file because I had to rebuild it anyway to get the right paths
for the emacs site lisp files.  The emacs patch just adds a line to
the Makefile to byte compile caml-font.el.

--- ocaml-3.01-2.spec	Thu Mar  8 06:28:56 2001
+++ ocaml-3.01-3.spec	Tue Mar 20 08:25:03 2001
@@ -1,16 +1,18 @@
 Name: ocaml
 Version: 3.01
-Release: 2
+Release: 3
 Summary: The Objective Caml compiler and programming environment
 Source0: ftp://ftp.inria.fr/lang/caml-light/ocaml-3.01.tar.gz
 Source1: ftp://ftp.inria.fr/lang/caml-light/ocaml-3.01-refman.html.tar.gz
 Source2: ftp://ftp.inria.fr/lang/caml-light/ocaml-3.01-refman.ps.gz
 Source3: ftp://ftp.inria.fr/lang/caml-light/ocaml-3.01-refman.info.tar.gz
+Patch: ocaml-3.01-emacs.patch
 Copyright: Open Source
 Group: Development/Languages
 BuildRoot: /var/tmp/ocaml-buildroot
 Vendor: INRIA Rocquencourt
 URL: http://caml.inria.fr/
+BuildRequires: XFree86-devel gpm-devel ncurses-devel tcl tk emacs
 
 %description
 Objective Caml is a high-level, strongly-typed, functional and
@@ -24,27 +26,28 @@
 %setup -T -b 0
 %setup -T -D -a 1
 %setup -T -D -a 3
+%patch -p1
 cp ../../SOURCES/ocaml-3.01-refman.ps.gz refman.ps.gz
 
 %build
-./configure -bindir /usr/bin -libdir /usr/lib/ocaml -mandir /usr/man/man1
+./configure -bindir %{_bindir} -libdir %{_libdir}/ocaml -mandir %{_mandir}/man1
 make world opt ocamlc.opt ocamlopt.opt
 
 %install
-rm -rf ${RPM_BUILD_ROOT}/usr/lib/ocaml
-make install BINDIR=${RPM_BUILD_ROOT}/usr/bin LIBDIR=${RPM_BUILD_ROOT}/usr/lib/ocaml MANDIR=${RPM_BUILD_ROOT}/usr/man/man1
-(cd emacs; make install BINDIR=${RPM_BUILD_ROOT}/usr/bin EMACSDIR=${RPM_BUILD_ROOT}/usr/lib/emacs/site-lisp)
-(mkdir -p ${RPM_BUILD_ROOT}/usr/info; cd infoman; cp ocaml*.gz ${RPM_BUILD_ROOT}/usr/info)
+rm -rf %{buildroot}%{_libdir}/ocaml
+make install BINDIR=%{buildroot}%{_bindir} LIBDIR=%{buildroot}%{_libdir}/ocaml MANDIR=%{buildroot}%{_mandir}/man1
+(cd emacs; make install BINDIR=%{buildroot}%{_bindir} EMACSDIR=%{buildroot}%{_datadir}/emacs/site-lisp)
+(mkdir -p %{buildroot}%{_infodir}; cd infoman; cp ocaml*.gz %{buildroot}%{_infodir})
 
 # Disable build root strip policy, executables generated by ocamlc -custom
 # MUST NOT BE STRIPPED
 %define __spec_install_post /usr/lib/rpm/brp-compress
 
 %files
-/usr/bin/*
-/usr/man/man1/*
-/usr/lib/ocaml
-/usr/lib/emacs/site-lisp/*
-/usr/info/*
+%{_bindir}/*
+%{_mandir}/man1/*
+%{_libdir}/ocaml
+%{_datadir}/emacs/site-lisp/*
+%{_infodir}/*
 
 %doc refman.ps.gz htmlman

-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Caml-list] Patch to ocaml-3.01-2 RPM spec file
  2001-03-20 16:35 [Caml-list] Patch to ocaml-3.01-2 RPM spec file David Fox
@ 2001-03-20 17:45 ` David Fox
  0 siblings, 0 replies; 2+ messages in thread
From: David Fox @ 2001-03-20 17:45 UTC (permalink / raw)
  To: caml-list

Oops, I didn't include the patch to emacs/Makefile:

--- ocaml-3.01/emacs/Makefile~	Wed Nov 17 10:57:32 1999
+++ ocaml-3.01/emacs/Makefile	Tue Mar 20 08:19:32 2001
@@ -19,6 +19,7 @@
 COMPILECMD=(progn \
               (setq load-path (cons "." load-path)) \
               (byte-compile-file "caml.el") \
+              (byte-compile-file "caml-font.el") \
               (byte-compile-file "inf-caml.el") \
               (byte-compile-file "camldebug.el"))
 

I do not compile the caml-hilit.el file because I seem to recall that
hilit mode is obsolete.  It has also been pointed out to me that the
following line should be inserted into the spec file directly after
the %files line:

  %defattr(-, root, root)

this sets the ownership of all the installed files to root.root,
necessary if the binary RPM was built by a regular user.
-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2001-03-20 17:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-03-20 16:35 [Caml-list] Patch to ocaml-3.01-2 RPM spec file David Fox
2001-03-20 17:45 ` David Fox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).