[cmor] 141/190: WIP: add python3 support

Alastair McKinstry mckinstry at moszumanska.debian.org
Tue Jul 21 12:54:48 UTC 2015


This is an automated email from the git hooks/post-receive script.

mckinstry pushed a commit to branch debian/master
in repository cmor.

commit 00aa1c8294fe627a8af3c515dd617a95ec1eff17
Author: Alastair McKinstry <mckinstry at debian.org>
Date:   Mon Jun 10 22:15:22 2013 +0100

    WIP: add python3 support
---
 debian/control              | 11 ++++++++++-
 debian/python-cmor.install  |  1 +
 debian/python3-cmor.install |  1 +
 debian/rules                |  9 ++++++---
 4 files changed, 18 insertions(+), 4 deletions(-)

diff --git a/debian/control b/debian/control
index ea01ccc..947b0d7 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: cmor
 Section: utils
 Priority: extra
 Maintainer: Alastair McKinstry <mckinstry at debian.org>
-Build-Depends: debhelper (>= 9), dh-buildinfo, libossp-uuid-dev, libudunits2-dev, libnetcdf-dev, uuid-dev, python-all-dev (>= 2.6.6-3~), python-setuptools (>= 0.6b3), libgfortran3, automake, python-numpy, gfortran
+Build-Depends: debhelper (>= 9), dh-buildinfo, libossp-uuid-dev, libudunits2-dev, libnetcdf-dev, uuid-dev, python-all-dev (>= 2.6.6-3~), python-setuptools (>= 0.6b3), libgfortran3, automake, python-numpy, gfortran, python3-numpy, python3-all-dev, python3-setuptools
 Build-Conflicts: libcmor2
 Standards-Version: 3.9.4
 Homepage:  http://www2-pcmdi.llnl.gov/cmor
@@ -47,3 +47,12 @@ Depends: ${pydeb:Depends}, ${python:Depends}, ${misc:Depends}, ${shlibs:Depends}
 Provides: ${python:Provides}
 Description: python interface to CMOR
  This is a python interface to CMOR, the Climate Model Output Rewriter.
+
+Package: python3-cmor
+Section: python
+Architecture: any
+Multi-Arch: foreign
+Depends: ${py3deb:Depends}, ${python3:Depends}, ${misc:Depends}, ${shlibs:Depends}
+Provides: ${python3:Provides}
+Description: python3 interface to CMOR
+ This is a python3 interface to CMOR, the Climate Model Output Rewriter.
diff --git a/debian/python-cmor.install b/debian/python-cmor.install
new file mode 100644
index 0000000..dbdb301
--- /dev/null
+++ b/debian/python-cmor.install
@@ -0,0 +1 @@
+/usr/lib/python2*
diff --git a/debian/python3-cmor.install b/debian/python3-cmor.install
new file mode 100644
index 0000000..097a7e8
--- /dev/null
+++ b/debian/python3-cmor.install
@@ -0,0 +1 @@
+/usr/lib/python3
diff --git a/debian/rules b/debian/rules
index 31d778d..471dbfd 100755
--- a/debian/rules
+++ b/debian/rules
@@ -14,8 +14,11 @@ export DEB_CFLAGS_MAINT_APPEND
 BUILD_ARCH_OS :-= $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS)
 BUILD_ARCH_CPU := $(shell dpkg-architecture -qDEB_BUILD_ARCH_CPU)
 
+PYVERS:=`pyversions --supported`
+PY3VERS:=`py3versions --supported`
+
 %:
-	dh $@ --with python2 
+	dh $@ --with python2,python3
 
 override_dh_auto_configure:
 	autoreconf -fiv
@@ -37,8 +40,8 @@ endif
 override_dh_auto_install:
 	$(MAKE) install DESTDIR=`pwd`/debian/tmp
 	$(MAKE) install_shlib DESTDIR=`pwd`/debian/tmp
-	for p in `pyversions --supported` ; do \
-		$$p ./setup.py install --prefix=`pwd`/debian/python-cmor/usr ; \
+	for p in $(PYVERS) $(PY3VERS); do \
+		$$p ./setup.py install  --root=$(CURDIR)/debian/tmp --install-layout=deb ; \
 		done
 	dh_numpy
 	dh_install -p libcmor2 libcmor.so.2    $(LIBDIR)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/cmor.git



More information about the debian-science-commits mailing list