[Pkg-ocaml-maint-commits] [SCM] ocaml-r packaging branch, master, updated. upstream/0.1-1-g2c10f8a

Guillaume Yziquel guillaume.yziquel at citycable.ch
Wed Oct 14 21:51:41 UTC 2009


The following commit has been merged in the master branch:
commit 2c10f8aac56f56cb45d007f6eec37c1b68ccd359
Author: Guillaume Yziquel <guillaume.yziquel at citycable.ch>
Date:   Wed Oct 14 23:50:28 2009 +0200

    Initial debian packaging.

diff --git a/debian/META b/debian/META
new file mode 100644
index 0000000..73d757e
--- /dev/null
+++ b/debian/META
@@ -0,0 +1,6 @@
+name="R"
+version="0.1"
+description="R bindings for OCaml"
+archive(byte)="r.cma rmath.cma"
+archive(native)="r.cmxa rmath.cmxa"
+
diff --git a/debian/README.source b/debian/README.source
new file mode 100644
index 0000000..bb9337a
--- /dev/null
+++ b/debian/README.source
@@ -0,0 +1,14 @@
+Building ocaml-csv for Debian
+-----------------------------
+
+This source package uses quilt to apply and remove its patches. Please
+refer to `/usr/share/doc/quilt/README.source' for information about
+how to use quilt for source packages.
+
+The quilt series is generated from the Git repository, using TopGit
+(from the `topgit' Debian package). This process is documented in
+`/usr/share/doc/topgit/HOWTO-tg2quilt.gz'.
+
+The branch layout is those described in the aforementioned document.
+
+ -- Guillaume Yziquel <guillaume.yziquel at citycable.ch>  Sat, 10 Oct 2009 14:30:33 +0200
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..780a66e
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+ocaml-r (0.1-1) UNRELEASED; urgency=low
+
+  * Initial release (Closes: #542857)
+
+ -- Guillaume Yziquel <guillaume.yziquel at citycable.ch>  Fri, 21 Aug 2009 19:15:18 +0200
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..7f8f011
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+7
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..79a4c17
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,36 @@
+Source: ocaml-r
+Section: ocaml
+Priority: optional
+Maintainer: "Debian OCaml Maintainers" <debian-ocaml-maint at lists.debian.org>
+Uploaders: Guillaume Yziquel <guillaume.yziquel at citycable.ch>
+DM-Upload-Allowed: yes
+Build-Depends: quilt,
+ cdbs (>= 0.4.52),
+ debhelper (>= 7),
+ dh-ocaml (>= 0.9),
+ ocaml-nox (>=3.11),
+ camlp4 (>=3.11),
+ ocaml-findlib,
+ camlp4-extra,
+ r-base-core
+Standards-Version: 3.8.3
+Homepage: http://home.gna.org/ocaml-r/
+Vcs-Browser: http://git.debian.org/?p=pkg-ocaml-maint/packages/ocaml-r.git
+Vcs-Git: git://git.debian.org/git/pkg-ocaml-maint/packages/ocaml-r.git
+
+Package: libr-ocaml-dev
+Architecture: any
+Depends: r-base-core,
+ ${ocaml:Depends},
+ ${shlibs:Depends},
+ ${misc:Depends}
+Provides: ${ocaml:Provides}
+Recommends: ocaml-findlib
+Description: OCaml bindings for the R interpreter
+ OCaml-R provides OCaml bindings to the R math library and
+ the R library usable to embed R in your application.
+ .
+ OCaml-R is still in development. Most of the R math library
+ functions are available. With the embedded R, it is already
+ possible to evaluate R code, create R variables and exchange
+ basic data between embedded R and OCaml sides. 
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..010004a
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,20 @@
+Format-Specification: http://wiki.debian.org/Proposals/CopyrightFormat
+Upstream-Name: OCaml-R
+Upstream-Maintainer: Maxence Guesdon <maxence.guesdon at inria.fr>
+Upstream-Source: http://home.gna.org/ocaml-r/
+Packaged-By: Guillaume Yziquel <guillaume.yziquel at citycable.ch>
+Packaged-Date: Thu, 02 Jun 2009 17:13:41 +0100
+Upstream-author: Maxence Guesdon <maxence.guesdon at inria.fr>
+Original-Source-Location: http://home.gna.org/ocaml-r/
+
+Files: *
+Copyright: (C) 2008 Institut National de Recherche en Informatique et en Automatique. All rights reserved. <maxence.guesdon at inria.fr>
+License: GPL-3
+ On Debian GNU/Linux systems, the complete text of the GNU Lesser General
+ Public License can be found in `/usr/share/common-licenses/GPL-3'.
+
+Files: debian/*
+Copyright: (C) Copyright 2009 Guillaume Yziquel <guillaume.yziquel at citycable.ch>
+License: GPL-3
+ On Debian GNU/Linux systems, the complete text of the GNU General
+ Public License can be found in `/usr/share/common-licenses/GPL-3'.
diff --git a/debian/gbp.conf b/debian/gbp.conf
new file mode 100644
index 0000000..cec628c
--- /dev/null
+++ b/debian/gbp.conf
@@ -0,0 +1,2 @@
+[DEFAULT]
+pristine-tar = True
diff --git a/debian/libr-ocaml-dev.dirs.in b/debian/libr-ocaml-dev.dirs.in
new file mode 100644
index 0000000..ad86960
--- /dev/null
+++ b/debian/libr-ocaml-dev.dirs.in
@@ -0,0 +1 @@
+ at OCamlStdlibDir@/R/
diff --git a/debian/libr-ocaml-dev.install.in b/debian/libr-ocaml-dev.install.in
new file mode 100644
index 0000000..71e3ece
--- /dev/null
+++ b/debian/libr-ocaml-dev.install.in
@@ -0,0 +1,8 @@
+src/*.mli             @OCamlStdlibDir@/R
+src/*.cmi             @OCamlStdlibDir@/R
+src/*.cma             @OCamlStdlibDir@/R
+src/*.so              @OCamlStdlibDir@/R
+OPT: src/*.a          @OCamlStdlibDir@/R
+OPT: src/*.cmx        @OCamlStdlibDir@/R
+OPT: src/*.cmxa       @OCamlStdlibDir@/R
+debian/META           @OCamlStdlibDir@/R
diff --git a/debian/patches/fPIC.diff b/debian/patches/fPIC.diff
new file mode 100644
index 0000000..f12b01f
--- /dev/null
+++ b/debian/patches/fPIC.diff
@@ -0,0 +1,16 @@
+From: Guillaume Yziquel <guillaume.yziquel at citycable.ch>
+Subject: [PATCH] Using -fPIC to compile shared stubs on amd64.
+
+Index: ocaml-r-0.1/master.Makefile.in
+===================================================================
+--- ocaml-r-0.1.orig/master.Makefile.in	2009-08-25 16:53:08.000000000 +0200
++++ ocaml-r-0.1/master.Makefile.in	2009-08-25 17:00:33.000000000 +0200
+@@ -101,7 +101,7 @@
+ 	$(OCAMLOPT) $(OCAMLPP) $(COMPFLAGS) -c $<
+ 
+ %.o: %.c
+-	$(OCAMLOPT) $(COMPFLAGS) -c $<
++	$(OCAMLOPT) $(COMPFLAGS) -ccopt -fPIC -c $<
+ 
+ %.ml:%.mll
+ 	$(OCAMLLEX) $<
diff --git a/debian/patches/new-build-system.diff b/debian/patches/new-build-system.diff
new file mode 100644
index 0000000..2497d84
--- /dev/null
+++ b/debian/patches/new-build-system.diff
@@ -0,0 +1,58 @@
+From: Guillaume Yziquel <guillaume.yziquel at citycable.ch>
+Subject: [PATCH] Replacing build system by a more direct one.
+
+Index: ocaml-r-0.1/src/Makefile
+===================================================================
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -69,21 +69,35 @@
+ 
+ all: byte opt
+ 
+-$(LIB): $(LIB_CMIFILES) $(LIB_CMXFILES) $(LIB_COBJ_FILES)
+-	$(OCAMLMKLIB) -o `basename $@ .cmxa` $(LINKFLAGS) \
+-	$(LIB_COBJ_FILES) $(LIB_CMXFILES)
+-
+-$(LIB_BYTE): $(LIB_CMIFILES) $(LIB_CMOFILES) $(LIB_COBJ_FILES)
+-	$(OCAMLMKLIB) -custom -o `basename $@ .cma` $(LINKFLAGS_BYTE) \
+-	$(LIB_COBJ_FILES) $(LIB_CMOFILES)
+-
+-$(LIBMATH): $(LIBMATH_CMIFILES) $(LIBMATH_CMXFILES) $(LIBMATH_COBJ_FILES)
+-	$(OCAMLMKLIB) -o `basename $@ .cmxa` $(LINKFLAGS_MATH) \
+-	$(LIBMATH_COBJ_FILES) $(LIBMATH_CMXFILES)
+-
+-$(LIBMATH_BYTE): $(LIBMATH_CMIFILES) $(LIBMATH_CMOFILES) $(LIBMATH_COBJ_FILES)
+-	$(OCAMLMKLIB) -custom -o `basename $@ .cma` $(LINKFLAGS_MATH_BYTE) \
+-	$(LIBMATH_COBJ_FILES) $(LIBMATH_CMOFILES)
++r.cma: dllr_base_stubs.so dllr_data_stubs.so rdevices.cmo rdevices.cmi r.cmo r.cmi
++	ocamlc -a -dllpath /usr/lib/R/lib -dllib dllr_base_stubs.so -dllib dllr_data_stubs.so -dllib libR.so -o r.cma rdevices.cmo r.cmo
++
++r.cmxa: dllr_base_stubs.so dllr_data_stubs.so rdevices.cmx rdevices.cmi r.cmx r.cmi
++	ocamlopt -a -ccopt -L/usr/lib/R/lib -cclib -lr_base_stubs -cclib -lr_data_stubs -cclib -lR -o r.cmxa rdevices.cmx r.cmx
++
++rmath.cma: dllr_math_stubs.so rmath.cmo rmath.cmi
++	ocamlc -a -dllib dllr_math_stubs.so -dllib libRmath.so -o rmath.cma rmath.cmo
++
++rmath.cmxa: dllr_math_stubs.so rmath.cmx rmath.cmi
++	ocamlopt -a -cclib -lr_math_stubs -cclib -lRmath -o rmath.cmxa rmath.cmx
++
++dllr_base_stubs.so: libr_base_stubs.a r_base.o
++	ocamlmklib -o r_base_stubs r_base.o
++
++dllr_data_stubs.so: libr_data_stubs.a r_data.o
++	ocamlmklib -o r_data_stubs r_data.o
++
++dllr_math_stubs.so: libr_math_stubs.a r_math.o
++	ocamlmklib -o r_math_stubs r_math.o
++
++libr_base_stubs.a: r_base.o
++	ar rcs libr_base_stubs.a r_base.o
++
++libr_data_stubs.a: r_data.o
++	ar rcs libr_data_stubs.a r_data.o
++
++libr_math_stubs.a: r_math.o
++	ar rcs libr_math_stubs.a r_math.o
+ 
+ $(PA_R): pa_ocamlr.ml
+ 	$(OCAMLC) -I +camlp4 -I +camlp4/Camlp4Parsers -c -pp camlp4of.opt $<
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..7f1fce4
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,2 @@
+fPIC.diff
+new-build-system.diff
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..f7bbb8d
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,52 @@
+#!/usr/bin/make -f
+# debian/rules for pgocaml package
+# Copyright (C) 2009 Guillaume Yziquel <guillaume.yziquel at citycable.ch>
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
+# MA 02110-1301, USA.
+
+include /usr/share/cdbs/1/rules/ocaml.mk
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/rules/patchsys-quilt.mk
+include /usr/share/cdbs/1/class/autotools.mk
+
+PACKAGE := ocaml-r
+DESTDIR := $(CURDIR)/debian/$(PACKAGE)
+
+PACKAGE_DEV := libr-ocaml-dev
+DESTDIR_DEV := $(CURDIR)/debian/$(PACKAGE_DEV)
+
+OCAMLDOC_PLUGINSDIR := $(DESTDIR)/$(shell ocamldoc -customdir)
+
+DEB_MAKE_CLEAN_TARGET    := distclean
+
+DEB_MAKE_BUILD_TARGET    := depend all doc
+
+DEB_MAKE_INSTALL_TARGET  := install                                      \
+                            DESTDIR='$(DESTDIR)'                         \
+                            OCAMLDOC_PLUGINSDIR='$(OCAMLDOC_PLUGINSDIR)'
+
+DEB_CONFIGURE_EXTRA_FLAGS = --prefix=/usr --datadir=/usr/share/ocaml-r   \
+                            --mandir=/usr/share/man                      \
+                            --libdir=$(OCAML_STDLIB_DIR)/R
+
+OCAML_OCAMLDOC_PACKAGES = libr-ocaml-dev
+OCAML_OCAMLDOC_OCAMLFIND_FLAGS =
+
+redo-patches::
+	rm -f debian/patches/*
+	git format-patch -N -o debian/patches master...patch-queue | \
+	  sed -e 's%debian/patches/%%' > debian/patches/series
+
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..5d58d5f
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,2 @@
+version=3
+http://download.gna.org/ocaml-r/ocaml-r_([\d\.]*)\.tar.gz

-- 
ocaml-r packaging



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