summaryrefslogtreecommitdiff
path: root/devel/ocaml-classes/files/patch-Makefile
blob: 677e1b22db4a01e83d47f2df5febe35e2bdd8caa (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
--- Makefile.orig	Thu Apr 18 20:39:26 2002
+++ Makefile	Fri Sep 20 21:16:25 2002
@@ -1,10 +1,11 @@
 #Adjust this directory for installation
-LIBDIR=`ocamlc -where`
+LIBDIR=$(PREFIX)/lib/ocaml/site-lib/classes
 COMPILER=ocamlc -c
 LIBRARIAN=ocamlc -a
 OPTCOMP=ocamlopt -c
 OPTLIB=ocamlopt -a
-INSTALL=cp
+INSTALL=install -o root -g wheel -m 644
+INSTALLDIR=install -d -o root -g wheel -m 755
 
 OBJECTS=obuffer.cmo	ohashtbl.cmo	oqueue.cmo	ostack.cmo \
 	omap.cmo	oset.cmo	ostream.cmo	omapping.cmo
@@ -43,12 +44,15 @@
 	@$(MAKE) real-install LIBDIR=$(LIBDIR)
 
 real-install:
+	$(INSTALLDIR) $(LIBDIR)
 	$(INSTALL) stdclass.cma *.cmi *.mli $(LIBDIR)
 	if test -f stdclass.cmxa; \
 	then $(INSTALL) stdclass.cmxa stdclass.a *.cmx $(LIBDIR); fi
+	if test -f META; \
+	then $(INSTALL) META $(LIBDIR); fi
 
 clean:
-	rm -f *.cm* *.o *.a *~ #*
+	rm -f *.cm* *.o *.a *~
 
 depend:
 	ocamldep *.ml *.mli > .depend