[Pkg-ocaml-maint-commits] r4593 - in /trunk/packages/ocaml/trunk/debian: changelog patches/00list patches/camlrun_shared.dpatch

zack at users.alioth.debian.org zack at users.alioth.debian.org
Fri Sep 28 14:56:32 UTC 2007


Author: zack
Date: Fri Sep 28 14:56:32 2007
New Revision: 4593

URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/?sc=1&rev=4593
Log:
* add patch camlrun_shared, which ships an alternative version of the
  camlrun library (called "camlrun_shared") made of PIC objects

Added:
    trunk/packages/ocaml/trunk/debian/patches/camlrun_shared.dpatch   (with props)
Modified:
    trunk/packages/ocaml/trunk/debian/changelog
    trunk/packages/ocaml/trunk/debian/patches/00list

Modified: trunk/packages/ocaml/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/ocaml/trunk/debian/changelog?rev=4593&op=diff
==============================================================================
--- trunk/packages/ocaml/trunk/debian/changelog (original)
+++ trunk/packages/ocaml/trunk/debian/changelog Fri Sep 28 14:56:32 2007
@@ -4,11 +4,15 @@
   * Suggest "tarballs" instead of "upstream" in the policy as directory name
     for storing upstream sources since it is more standard.
 
+  [ Stefano Zacchiroli ]
+  * add patch camlrun_shared, which ships an alternative version of the
+    camlrun library (called "camlrun_shared") made of PIC objects
+
   [ Sylvain Le Gall ]
   * ... fixes in cdbs class for ocamldoc generation ... (TODO: still to be
     checked) [ entry added by Zack ]
 
- -- Stefano Zacchiroli <zack at debian.org>  Fri, 28 Sep 2007 15:50:37 +0200
+ -- Stefano Zacchiroli <zack at debian.org>  Fri, 28 Sep 2007 16:49:23 +0200
 
 ocaml (3.10.0-8) unstable; urgency=low
 

Modified: trunk/packages/ocaml/trunk/debian/patches/00list
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/ocaml/trunk/debian/patches/00list?rev=4593&op=diff
==============================================================================
--- trunk/packages/ocaml/trunk/debian/patches/00list (original)
+++ trunk/packages/ocaml/trunk/debian/patches/00list Fri Sep 28 14:56:32 2007
@@ -10,3 +10,4 @@
 install_ocamlbuild.dpatch
 arm_ccheckbound_typo.dpatch
 not-native-no-aspp
+camlrun_shared.dpatch

Added: trunk/packages/ocaml/trunk/debian/patches/camlrun_shared.dpatch
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/ocaml/trunk/debian/patches/camlrun_shared.dpatch?rev=4593&op=file
==============================================================================
--- trunk/packages/ocaml/trunk/debian/patches/camlrun_shared.dpatch (added)
+++ trunk/packages/ocaml/trunk/debian/patches/camlrun_shared.dpatch Fri Sep 28 14:56:32 2007
@@ -1,0 +1,74 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## camlrun_shared.dpatch by Stefano Zacchiroli <zack at debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: build and ship an alternative version of the libcamlrun.a library
+## DP: (called libcamlrun_shared.so) which is made of PIC objects
+
+ at DPATCH@
+diff -urNad trunk~/byterun/Makefile trunk/byterun/Makefile
+--- trunk~/byterun/Makefile	2007-02-23 10:29:45.000000000 +0100
++++ trunk/byterun/Makefile	2007-09-28 16:01:36.000000000 +0200
+@@ -28,6 +28,7 @@
+   dynlink.o unix.o
+ 
+ DOBJS=$(OBJS:.o=.d.o) instrtrace.d.o
++PICOBJS=$(OBJS:.o=.pic.o)
+ 
+ PRIMS=alloc.c array.c compare.c extern.c floats.c gc_ctrl.c hash.c \
+   intern.c interp.c ints.c io.c lexing.c md5.c meta.c obj.c parsing.c \
+@@ -39,6 +40,10 @@
+ 
+ all: ocamlrun$(EXE) ld.conf
+ 
++ifeq ($(SUPPORTS_SHARED_LIBRARIES),true)
++all: libcamlrun_shared.so
++endif
++
+ ocamlrun$(EXE): libcamlrun.a prims.o
+ 	$(BYTECC) $(BYTECCCOMPOPTS) $(BYTECCLINKOPTS) -o ocamlrun$(EXE) \
+ 	          prims.o libcamlrun.a $(BYTECCLIBS)
+@@ -50,6 +55,9 @@
+ install:
+ 	cp ocamlrun$(EXE) $(BINDIR)/ocamlrun$(EXE)
+ 	cp libcamlrun.a $(LIBDIR)/libcamlrun.a
++ifeq ($(SUPPORTS_SHARED_LIBRARIES),true)
++	cp libcamlrun_shared.so $(LIBDIR)/libcamlrun_shared.so
++endif
+ 	cd $(LIBDIR); $(RANLIB) libcamlrun.a
+ 	if test -d $(LIBDIR)/caml; then : ; else mkdir $(LIBDIR)/caml; fi
+ 	for i in $(PUBLIC_INCLUDES); do \
+@@ -69,8 +77,12 @@
+ 	ar rc libcamlrund.a $(DOBJS)
+ 	$(RANLIB) libcamlrund.a
+ 
++libcamlrun_shared.so: $(PICOBJS)
++	gcc -shared -o $@ $^
++
+ clean:
+ 	rm -f ocamlrun$(EXE) ocamlrund$(EXE) *.o lib*.a
++	rm -f lib*.so
+ 	rm -f primitives prims.c opnames.h jumptbl.h ld.conf
+ 	rm -f version.h
+ 
+@@ -105,6 +117,7 @@
+ 	echo "#define OCAML_VERSION \"`head -1 ../VERSION`\"" >version.h
+ 
+ .SUFFIXES: .d.o
++.SUFFIXES: .pic.o
+ 
+ .c.d.o:
+ 	@ if test -f $*.o; then mv $*.o $*.f.o; else :; fi
+@@ -112,6 +125,12 @@
+ 	mv $*.o $*.d.o
+ 	@ if test -f $*.f.o; then mv $*.f.o $*.o; else :; fi
+ 
++.c.pic.o:
++	@ if test -f $*.o; then mv $*.o $*.f.o; else :; fi
++	$(CC) $(CFLAGS) $(SHAREDCCCOMPOPTS) -c $<
++	mv $*.o $*.pic.o
++	@ if test -f $*.f.o; then mv $*.f.o $*.o; else :; fi
++
+ depend : prims.c opnames.h jumptbl.h version.h
+ 	-gcc -MM $(BYTECCCOMPOPTS) *.c > .depend
+ 	-gcc -MM $(BYTECCCOMPOPTS) -DDEBUG *.c | sed -e 's/\.o/.d.o/' >> .depend

Propchange: trunk/packages/ocaml/trunk/debian/patches/camlrun_shared.dpatch
------------------------------------------------------------------------------
    svn:executable = *




More information about the Pkg-ocaml-maint-commits mailing list