Merge branch 'experimental'
authorDimitrios Eftaxiopoulos <eftaxi12@otenet.gr>
Fri, 14 Sep 2012 23:40:09 +0000 (02:40 +0300)
committerDimitrios Eftaxiopoulos <eftaxi12@otenet.gr>
Fri, 14 Sep 2012 23:40:09 +0000 (02:40 +0300)
Conflicts:
debian/changelog
debian/control
debian/libmgl-fltk5.symbols
debian/libmgl-qt5.symbols
debian/libmgl-wx5.symbols
debian/libmgl5.symbols
debian/patches/series
debian/patches/texinfo-Makefile.patch
debian/patches/texinfo-png-Makefile.patch
debian/source/options
lang/numpy.i.in
texinfo/Makefile.am
texinfo/Makefile.in

1  2 
debian/changelog.orig
debian/control.orig
debian/patches/series.orig
debian/source/options.orig
lang/numpy.i.in.orig
texinfo/mathgl_en.texi
texinfo/mathgl_ru.texi
texinfo/mgl_en.texi
texinfo/mgl_ru.texi

index 0000000000000000000000000000000000000000,0000000000000000000000000000000000000000..4dc213e76311f137d61f8a71d87064f5012bb27c
new file mode 100644 (file)
--- /dev/null
--- /dev/null
@@@ -1,0 -1,0 +1,435 @@@
++<<<<<<< HEAD
++mathgl (1.11.2-14) unstable; urgency=low
++
++  * Make several libmgl-wx5 related symbols optional in order to fix FTBFS on
++    several arches.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Thu, 10 May 2012 22:19:03 +0300
++
++mathgl (1.11.2-13) unstable; urgency=low
++
++  * Make several libmgl-qt5 related symbols optional in order to fix FTBFS on 
++    several arches.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Thu, 10 May 2012 19:12:22 +0300
++
++mathgl (1.11.2-12) unstable; urgency=low
++
++  * Make more libmgl5 related symbols optional in order to fix FTBFS on several
++    arches.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Thu, 10 May 2012 16:09:18 +0300
++
++mathgl (1.11.2-11) unstable; urgency=low
++
++  * Update symbols files in order to fix FTBFS (Closes: #671964) 
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Tue, 08 May 2012 20:18:59 +0300
++
++mathgl (1.11.2-10) unstable; urgency=low
++
++  * Replace octave3.2-headers with liboctave-dev in Build-Depends in
++    debian/control (Closes: #666753).
++  * Add zlib1g (>= 1.2.6) to Depends of libmgl5 to deal with a symbol export 
++    problem in earlier versions of mgl, which is not being seen by 
++    debhelper's shlib expansion (spotted by D. Haley).
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Fri, 6 Apr 2012 18:03:00 +0300
++
++mathgl (1.11.2-9) unstable; urgency=low
++
++  * Add patches that fix conflicting pointer type issues in files
++    mgl/mgl_eps.cpp and mgl/mgl_export.cpp (Closes: #661292).
++  * Change dependency of python-mathgl package from python-numpy to 
++    python-numpy-abi9.
++  * Update Debian Policy to 3.9.3.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sun, 26 Feb 2012 09:23:00 +0200
++
++mathgl (1.11.2-8) unstable; urgency=low
++
++  * Team upload
++  * Build only against libhdf5-dev (transition 1.8.6 => 1.8.8)
++
++ -- Sylvestre Ledru <sylvestre@debian.org>  Wed, 18 Jan 2012 19:29:33 +0100
++
++mathgl (1.11.2-7) unstable; urgency=low
++
++  * Fix FTBFS for sparc64.
++  * Ammend symbols files for alpha.
++  * Make libmgl-dev package dependent on libmgl-*5 packages (Closes: #646923).
++  * Create new texinfo-png-Makefile.patch in the place of 
++    createpngdirectory.patch.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Mon, 2 Jan 2012 18:32:00 +0200
++=======
++mathgl (2.0.3-1) unstable; urgency=low
++
++  * New upstream release.
++  * Add mpi-default-dev to build dependencies.
++  * Add patch for lang/setup.py.in to enable python to read directory tree 
++    written in utf-8 (not ascii) encoding. 
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Tue, 11 Sep 2012 21:19:08 +0300
++
++mathgl (2.0-1) experimental; urgency=low
++
++  * Add udav manpage.
++  * Add descriptions for the two patches. 
++  * Strip debian revision numbers from symbols in symbols files.
++  * New upstream release.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Wed, 18 Apr 2012 17:17:00 +0200
++
++mathgl (2~rc2+svn403-1) experimental; urgency=low
++
++  * Updated source from svn repository.
++  * Replace octave3.2-headers with liboctave-dev in build deps.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sun, 8 Apr 2012 20:49:00 +0200
++
++mathgl (2~rc2+svn400-1) experimental; urgency=low
++
++  * Updated source from svn repository.
++  * Fix installation of manpages for mglview, mglvonv and mgl.
++  * Rename mathgl-doc binary to mathgl-doc-en.
++  * Update symbols for libmgl-glut6.
++  * Fix installation directory in doc-base file mathgl-doc-en.
++  * Fix library package names to reflect soname.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sun, 1 Apr 2012 04:04:00 +0200
++
++mathgl (2~rc2+svn387-1) experimental; urgency=low
++
++  * Updated source from svn repository.
++  * Fix installation directory of python module and files.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Tue, 27 Mar 2012 17:29:00 +0200
++
++mathgl (2~rc2+svn383-1) experimental; urgency=low
++
++  * Updated source from svn repository.
++  * Add udav, libmgl-glut and mathgl-doc packages.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Mon, 26 Mar 2012 15:35:00 +0200
++
++mathgl (2~rc2-1) experimental; urgency=low
++
++  * Updated source from svn repository.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Tue, 6 Mar 2012 17:22:00 +0200
++
++mathgl (2~rc1-4) unreleased; urgency=low
++
++  * Fix symbols FTBFS on armhf.
++  * Make build dependency on libhdf5-dev only.
++  * Make python-mathgl depend on python-numpy-abi9.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Wed, 22 Feb 2012 19:39:00 +0200
++
++mathgl (2~rc1-3) experimental; urgency=low
++
++  * Fix symbols FTBFS, related to libmgl-wnd6, on several arches.
++  * Make libmgl-dev dependent on libmgl-wnd6.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Wed, 4 Jan 2012 20:16:00 +0200
++
++mathgl (2~rc1-2) experimental; urgency=low
++
++  * Correct typo in mathgl description in debian/control (Closes: #644863).
++  * Try to fix symbols FTBFS on several arches.   
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Wed, 4 Jan 2012 15:30:00 +0200
++
++mathgl (2~rc1-1) experimental; urgency=low
++
++  * New experimental upstream release (Closes: #632468).
++  * No documentation debian packages provided.   
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Wed, 28 Sep 2011 11:30:00 +0300
++>>>>>>> experimental
++
++mathgl (1.11.2-6) unstable; urgency=low
++
++  * Fix FTBFS for sparc (Closes: #642654).  
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Mon, 26 Sep 2011 16:23:12 +0300
++
++mathgl (1.11.2-5) unstable; urgency=low
++
++  * Resolve differences for all non-optional symbols, in symbols files for ia64,
++    sparc and sh4 architectures (Closes: #642654).
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Mon, 26 Sep 2011 10:25:00 +0300
++
++mathgl (1.11.2-4) unstable; urgency=low
++
++  * Add python-numpy to Depnds of python-mathgl in debian/control and add
++    dh_numpy in binary-arch in debian/rules (Closes: #641793).
++<<<<<<< HEAD
++  * Ammend symbols files for ia64, sparc and sh4 architectures (Closes: 642654).
++=======
++  * Ammend symbols files for ia64, sparc and sh4 architectures (Closes: #642654).
++>>>>>>> experimental
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sat, 24 Sep 2011 23:16:00 +0300
++
++mathgl (1.11.2-3) unstable; urgency=low
++
++  * Replace libfltk-dev with libfltk1.3-dev | libfltk-dev in debian/control 
++    Build-Depends (Closes: #638834).
++  * Ammend symbols files for s390x architecture (Closes: #639492).
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Wed, 7 Sep 2011 06:04:00 +0300
++
++mathgl (1.11.2-2) unstable; urgency=low
++
++  * Add debian/source/options file in order to avoid the generation of unneeded debian-
++    changes patch, due to the creation of extra file config.log during build.
++  * Ammend symbols files.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Thu, 18 Aug 2011 20:48:00 +0300
++
++mathgl (1.11.2-1) unstable; urgency=low
++
++  * Incorporate changes due to the last two NMU's.
++  * New upstream version.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Tue, 28 Jun 2011 17:01:00 +0200
++
++mathgl (1.11.1.1-2.2) unstable; urgency=low
++
++  * Non-maintainer upload (closes: #610777).
++  * debian/libmgl-qt5.symbols: _ZN10QByteArrayD1Ev is needed on sparc and
++    ia64, so add it as optional.
++  * debian/libmgl-wx5.symbols: three destructors known to be undefined on
++    armel/armhf are also not defined on ia64 or sparc, so mark these as
++    optional also.  Destructors of foreign classes are not part of the
++    library ABI, so it's fine to ignore these.
++
++ -- Steve Langasek <vorlon@debian.org>  Sun, 19 Jun 2011 07:57:43 +0000
++
++mathgl (1.11.1.1-2.1) unstable; urgency=low
++
++  * Non-maintainer upload.
++  * Fix library symbols files (closes: #610777):
++    - debian/libmgl-qt5.symbols: drop _ZN10QByteArrayD2Ev, which is not
++      present on *any* architecture anymore.
++    - debian/libmgl-fltk5.symbols: _ZN9Fl_PixmapC2EPKPKc is not present on
++      ia64 or sparc and never has been.
++    - debian/libmgl5.symbols:
++      + _ZN7mglFuncD1Ev is present on all architectures, drop the
++        architecture list (fixing the 'kfeebsd' typo that caused a build
++        failure on kfreebsd-amd64).
++      + _ZNSt15basic_stringbufIcSt11char_traitsIcESaIcEED2Ev,
++        _ZN8u3dLightD2Ev: symbols not seen on *any* archs, drop.
++      + Drop 18 symbols whose exclusion list included all 15 architectures
++        that have been tested.
++      + Other symbols that are template instantiations are now marked as
++        optional symbols instead of tagged with an arch list, since they are
++        not part of the ABI and will come and go based on the compiler
++        version used, *not* just on the architecture.
++      + If there are 8 or more architectures in the arch qualifier, invert
++        it.  In some cases this reveals that certain symbols are actually
++        64-bit specific - so infer that not-yet-tested 32-bit archs follow
++        the pattern.
++    - debian/*.symbols: any symbols marked for armel should also be marked
++      for armhf.
++  * debian/rules: clean the dependency_libs out of .la files at build
++    time, per Policy 10.2.  Closes: #620629.
++
++ -- Steve Langasek <vorlon@debian.org>  Sat, 18 Jun 2011 07:33:55 +0000
++
++mathgl (1.11.1.1-3) unreleased; urgency=low
++
++  * Further attempt to fix symbol breakages
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sun, 29 May 2011 19:41:00 +0200
++
++mathgl (1.11.1.1-2) unstable; urgency=low
++
++  * Try to fix libmgl5 related symbols breakage on all arches
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sun, 22 May 2011 20:50:00 +0200
++
++mathgl (1.11.1.1-1) unstable; urgency=low
++
++  * New upstream version
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Tue, 26 Apr 2011 01:15:00 +0200
++
++mathgl (1.11.0.1-9) unreleased; urgency=low
++
++  * Again try to fix build failure due to broken symbols for several architectures
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sat, 2 Apr 2011 02:05:00 +0200
++
++mathgl (1.11.0.1-8) unstable; urgency=low
++
++  * Try to fix build failure due to broken symbols for several architectures
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Thu, 24 Mar 2011 23:56:00 +0200
++
++mathgl (1.11.0.1-7) unstable; urgency=low
++
++  * Create patch for the removal of the texinfo/mgl_ru.info-* files
++  * Update symbols files (Closes: #618235)
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Mon, 14 Mar 2011 00:10:00 +0200
++
++mathgl (1.11.0.1-6) unstable; urgency=low
++
++  * Try to fix build failure due to broken symbols for sparc64
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sat, 5 Mar 2011 21:27:00 +0200
++
++mathgl (1.11.0.1-5) unstable; urgency=low
++
++  * Try to fix build failure due to broken symbols for armel and s390
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Fri, 25 Feb 2011 21:30:00 +0200
++
++mathgl (1.11.0.1-4) unstable; urgency=low
++
++  * Create mixed symbols files for amd64 and i386 with tagged symbols 
++    (Closes: #610777)
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sat, 19 Feb 2011 23:10:00 +0200
++
++mathgl (1.11.0.1-3) unstable; urgency=low
++
++  * Upload in unstable
++  * Change symbols files for pbuilder --distribution unstable (Closes: #610777)
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sat, 12 Feb 2011 22:14:00 +0200
++
++mathgl (1.11.0.1-2) experimental; urgency=low
++
++  * Update symbols files for pbuilder --distribution experimental.
++  * Remove createpngdirectory.patch from series.
++  * Apply patch for FTBFS on i386 (Closes: #607539).
++  * Add Replaces tags for old mathgl-doc package in debian/control.
++  * Various improvements in the debian/rules file.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Mon, 17 Jan 2011 21:43:00 +0200
++
++mathgl (1.11.0.1-1) experimental; urgency=low
++
++  * Correct debian/copyright file.
++  * Create proper patches for the changes in the source tree.
++  * Add new package for Russian documentation.
++  * New upstream release (Closes: #603004).
++  * Correct several spelling mistakes in manpages and in lang/numpy.i
++  * Create symbols files for libraries.
++  * Register documentation to doc-base.
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sun, 12 Dec 2010 19:13:00 +0200
++
++mathgl (1.10.2.1-2) unstable; urgency=low
++
++  * Make .png pictures visible from the html documentation.
++  * Add python support (Closes: #541481).
++
++ -- Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>  Sun, 11 Sep 2010 12:37:00 +0200
++      
++mathgl (1.10.2.1-1) unstable; urgency=low
++
++  [ D Eftaxiopoulos ]
++  * Update to Debian Policy 3.9.1
++  * Put myself and D. Haley to the maintainers list.
++  * Comment out parallel-build-png.patch in the debian/patches/series file
++    since it seems to apply to a texinfo/Makefile.am file that is not 
++    included in the source tree.
++  * Append package quilt to the build-depends list for the source in the 
++    debian/control file, in order to fix a lintian error.
++  * Reinstate debian/source/format file with content '3.0 (quilt)'.
++  * Fix Lintian warnings related to manpages.
++
++  [ D Haley ]
++  * New upstream release 1.10.2.1 (Closes: #562743).
++
++  [ Salvatore Bonaccorso ]
++  * New Maintainer (Closes: #564422). Set Maintainer to Debian Science
++    Maintainers <debian-science-maintainers@lists.alioth.debian.org>.
++  * Convert to '3.0 (quilt)' package source format. Drop quilt framework for
++    packaging. 
++  * debian/control: 
++    - Change Vcs-Browser and Vcs-Git to the debian-science git repository.
++    - Change Section for source package to 'science' as per debian-science
++      group policy.
++    - Set DM-Upload-Allowed field to yes.
++  * Add myself to Uploaders.
++
++  [ Sylvestre Ledru ]
++  * Missing dependency against automake added.
++
++ -- Sylvestre Ledru <sylvestre@debian.org>  Sun, 15 Aug 2010 21:45:47 +0200
++
++mathgl (1.9-3) unstable; urgency=low
++
++  * QA upload.
++  * Properly orphan the package (see #564422), set maintainer to QA.
++  * Bump Standards-Version to 3.8.4, no changes needed.
++  * Add debian/README.source, pointing to quilt doc.
++  * Bump build-deps on octave from 3.0 to 3.2 (Closes: #574025).
++
++ -- Stefano Zacchiroli <zack@debian.org>  Fri, 26 Mar 2010 14:06:08 +0100
++
++mathgl (1.9-2) unstable; urgency=low
++
++  * Fix FTBFS. Closes: #545882.
++  * Update Standards-Version to 3.8.3.
++
++ -- Bradley Smith <bradsmith@debian.org>  Wed, 09 Sep 2009 22:44:44 +0100
++
++mathgl (1.9-1) unstable; urgency=low
++
++  * New upstream release. Closes: #535503.
++  * QT -> qt in package descriptions. Closes: #534425.
++
++ -- Bradley Smith <bradsmith@debian.org>  Sun, 19 Jul 2009 16:41:41 +0100
++
++mathgl (1.8.1-6) unstable; urgency=low
++
++  * Redo descriptions.
++
++ -- Bradley Smith <bradsmith@debian.org>  Tue, 09 Jun 2009 20:26:42 +0100
++
++mathgl (1.8.1-5) unstable; urgency=low
++
++  * Correct info-dir-section in texinfo/mathgl.texi. Closes: #528893.
++
++ -- Bradley Smith <bradsmith@debian.org>  Wed, 27 May 2009 17:52:50 +0100
++
++mathgl (1.8.1-4) unstable; urgency=low
++
++  * Correct libltdl-dev Build-Depend. Closes: #526426.
++  * Further improve descriptions.
++
++ -- Bradley Smith <bradsmith@debian.org>  Fri, 01 May 2009 12:59:05 +0100
++
++mathgl (1.8.1-3) unstable; urgency=low
++
++  * Tidy up descriptions. Closes: #521830, #521917.
++  * Update Standards-Version to 3.8.1. (No changes).
++  * Fix watch file.
++
++ -- Bradley Smith <bradsmith@debian.org>  Sat, 18 Apr 2009 17:42:59 +0100
++
++mathgl (1.8.1-2) unstable; urgency=low
++
++  * Fix parallel builds. Closes: #519738.
++
++ -- Bradley Smith <bradsmith@debian.org>  Thu, 19 Mar 2009 19:08:37 +0000
++
++mathgl (1.8.1-1) unstable; urgency=low
++
++  * New upstream release. Closes: #518769.
++
++ -- Bradley Smith <bradsmith@debian.org>  Sun, 08 Mar 2009 13:29:33 +0000
++
++mathgl (1.8-1) unstable; urgency=low
++
++  * Initial release. Closes: #510378.
++
++ -- Bradley Smith <bradsmith@debian.org>  Thu, 01 Jan 2009 11:27:32 +0000
index 0000000000000000000000000000000000000000,0000000000000000000000000000000000000000..0466090ebca64b5a4759fcc674ec8af6b03b72a3
new file mode 100644 (file)
--- /dev/null
--- /dev/null
@@@ -1,0 -1,0 +1,179 @@@
++Source: mathgl
++Section: science
++Priority: optional
++Maintainer: Debian Science Maintainers <debian-science-maintainers@lists.alioth.debian.org>
++Uploaders: Dimitrios Eftaxiopoulos <eftaxi12@otenet.gr>, D Haley <mycae@yahoo.com>
++DM-Upload-Allowed: yes
++<<<<<<< HEAD
++Build-Depends: debhelper (>= 7.2.3~), libltdl-dev, libgsl0-dev, freeglut3-dev, 
++ libgl1-mesa-dev | libgl-dev, libpng-dev, libhdf5-dev, gawk, swig,
++ libjpeg-dev, libtiff-dev, libfltk1.3-dev | libfltk-dev, libqt4-dev, libwxgtk2.8-dev, 
++ texinfo, texi2html, texlive, texlive-generic-recommended, liboctave-dev,
++ libgif-dev, autoconf, automake, python, python-dev, python-numpy, python-support,
++ libhdf4-dev, chrpath
++=======
++Build-Depends: debhelper (>= 7.2.3~), libltdl-dev, libgsl0-dev, freeglut3-dev,
++ libgl1-mesa-dev | libgl-dev, libpng-dev, libhdf5-dev, swig, cmake, libxft-dev,
++ libjpeg-dev, libtiff-dev, libfltk1.3-dev, libqt4-dev, libwxgtk2.8-dev, 
++ texinfo, texi2html, texlive, texlive-generic-recommended, liboctave-dev,
++ libgif-dev, python, python-dev, python-numpy, python-support, libfontconfig1-dev,
++ libhdf4-dev, chrpath, libxinerama-dev, libxmu-dev, libxi-dev, libhpdf-dev,
++ mpi-default-dev
++>>>>>>> experimental
++Standards-Version: 3.9.3
++Homepage: http://mathgl.sourceforge.net/index.html
++Vcs-Git: git://git.debian.org/debian-science/packages/mathgl.git
++Vcs-Browser: http://git.debian.org/?p=debian-science/packages/mathgl.git
++
++Package: mathgl
++Architecture: any
++Section: libs
++Depends: ${shlibs:Depends}, ${misc:Depends}, libmgl6.0.0 (= ${binary:Version})
++Description: library for scientific graphs. (utilities and examples)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains MathGL utilities and examples.
++
++Package: udav
++Architecture: any
++Section: libs
++Depends: ${shlibs:Depends}, ${misc:Depends}, libmgl6.0.0 (= ${binary:Version})
++Description: library for scientific graphs. (window interface)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the udav window environment based on mathgl.
++
++Package: mathgl-doc-en
++Architecture: all
++Section: doc
++Depends: dpkg (>= 1.15.4) | install-info, ${misc:Depends}
++Replaces: mathgl-doc
++Description: library for scientific graphs. (English documentation)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the MathGL documentation.
++
++Package: libmgl6.0.0
++Architecture: any
++Section: libs
++Depends: ${shlibs:Depends}, ${misc:Depends}, libmgl-data, zlib1g (>= 1.2.6)
++Description: library for scientific graphs. (main runtime library)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the shared object files.
++
++<<<<<<< HEAD
++Package: libmgl-data
++Architecture: all
++Section: misc
++Depends: ${misc:Depends}
++Description: library for scientific graphs. (data files)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the MathGL data files.
++
++Package: libmgl-dev
++Architecture: any
++Section: libdevel
++Depends: libmgl5 (= ${binary:Version}), ${misc:Depends}, 
++ libmgl-fltk5 (= ${binary:Version}), libmgl-qt5 (= ${binary:Version}), 
++ libmgl-wx5 (= ${binary:Version}), libmgl-glut5 (= ${binary:Version}), 
++ libgsl0-dev, libpng-dev, libgl1-mesa-dev | libgl-dev 
++Description: library for scientific graphs. (development files)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the development files.
++
++Package: libmgl-fltk5
++=======
++Package: libmgl-wnd6.0.0
++>>>>>>> experimental
++Architecture: any
++Section: libs
++Depends: ${shlibs:Depends}, ${misc:Depends}, libmgl-data
++Description: library for scientific graphs. (windows runtime library)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the window opening related shared object files.
++
++Package: libmgl-glut6.0.0
++Architecture: any
++Section: libs
++Depends: ${shlibs:Depends}, ${misc:Depends}, libmgl-data
++Description: library for scientific graphs. (glut interface for windows)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the glut interface shared object files for window 
++ opening.
++
++Package: libmgl-data
++Architecture: all
++Section: misc
++Depends: ${misc:Depends}
++Description: library for scientific graphs. (data files)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the MathGL data files.
++
++Package: libmgl-dev
++Architecture: any
++Section: libdevel
++Depends: libmgl6.0.0 (= ${binary:Version}), libmgl-wnd6.0.0 (= ${binary:Version}), 
++ ${misc:Depends}, libgsl0-dev, libgl1-mesa-dev | libgl-dev, libpng-dev
++Description: library for scientific graphs. (development files)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package contains the development files. 
++
++Package: python-mathgl
++Architecture: any
++Section: python
++Depends: ${shlibs:Depends}, ${misc:Depends}, ${python:Depends}, python-numpy-abi9
++Description: library for scientific graphs. (Python module)
++ A free cross-platform library of fast C++ routines for plotting data in up
++ to 3 dimensions. It can export plots to bitmaps and vector EPS, SVG, IDTF
++ files. There are simple window interfaces based on GLUT, FLTK and/or Qt.
++ MathGL can also be used in the console. There are interfaces to a set of
++ languages, such as, C, Fortran, Pascal, Forth, Python, Octave.
++ .
++ This package provides the Python module for mathgl.
index 0000000000000000000000000000000000000000,0000000000000000000000000000000000000000..1167984c3443907e2a22a5eff23fbe938e4352b3
new file mode 100644 (file)
--- /dev/null
--- /dev/null
@@@ -1,0 -1,0 +1,15 @@@
++<<<<<<< HEAD
++texinfo-png-Makefile.patch
++mgl-mgl-eps-cpp.patch
++mgl-mgl-export-cpp.patch
++dircategory-and-direntry-mathgl-en-texi.patch
++dircategory-and-direntry-mathgl-ru-texi.patch
++dircategory-and-direntry-mgl-ru-texi.patch
++dircategory-and-direntry-mgl-en-texi.patch
++correct-spelling-error-in-nympy-i.patch
++texinfo-Makefile.patch
++=======
++lang-CMakeLists-txt.patch
++CMakeLists-txt.patch
++lang-setup-py-in.patch
++>>>>>>> experimental
index 0000000000000000000000000000000000000000,0000000000000000000000000000000000000000..0d9493ad28528c74b75f4c2e303c1121facefc3c
new file mode 100644 (file)
--- /dev/null
--- /dev/null
@@@ -1,0 -1,0 +1,5 @@@
++<<<<<<< HEAD
++ extend-diff-ignore = "(^|/)(config\.log|texinfo/mgl_ru\.info-1|texinfo/mgl_ru\.info-2|Makefile\.in|aclocal\.m4|configure|examples/Makefile\.in|include/Makefile\.in|lang/Makefile\.in|mgl/Makefile\.in|texinfo/Makefile\.in|texinfo/png/Makefile\.in|utils/Makefile\.in|widgets/Makefile\.in)$"
++=======
++ extend-diff-ignore = "(^|/)(install_manifest\.txt|include/mgl/config\.h)$"
++>>>>>>> experimental
index 0000000000000000000000000000000000000000,0000000000000000000000000000000000000000..4f746631d190657fcf60a0c4f19eb9cf39a74704
new file mode 100644 (file)
--- /dev/null
--- /dev/null
@@@ -1,0 -1,0 +1,1638 @@@
++/* -*- C -*-  (not really, but good for syntax highlighting) */
++#ifdef SWIGPYTHON
++
++%{
++#ifndef SWIG_FILE_WITH_INIT
++#  define NO_IMPORT_ARRAY
++#endif
++#include "stdio.h"
++#include <numpy/arrayobject.h>
++%}
++
++/**********************************************************************/
++
++%fragment("NumPy_Backward_Compatibility", "header")
++{
++/* Support older NumPy data type names
++*/
++%#if NDARRAY_VERSION < 0x01000000
++%#define NPY_BOOL          PyArray_BOOL
++%#define NPY_BYTE          PyArray_BYTE
++%#define NPY_UBYTE         PyArray_UBYTE
++%#define NPY_SHORT         PyArray_SHORT
++%#define NPY_USHORT        PyArray_USHORT
++%#define NPY_INT           PyArray_INT
++%#define NPY_UINT          PyArray_UINT
++%#define NPY_LONG          PyArray_LONG
++%#define NPY_ULONG         PyArray_ULONG
++%#define NPY_LONGLONG      PyArray_LONGLONG
++%#define NPY_ULONGLONG     PyArray_ULONGLONG
++%#define NPY_FLOAT         PyArray_FLOAT
++%#define NPY_DOUBLE        PyArray_DOUBLE
++%#define NPY_LONGDOUBLE    PyArray_LONGDOUBLE
++%#define NPY_CFLOAT        PyArray_CFLOAT
++%#define NPY_CDOUBLE       PyArray_CDOUBLE
++%#define NPY_CLONGDOUBLE   PyArray_CLONGDOUBLE
++%#define NPY_OBJECT        PyArray_OBJECT
++%#define NPY_STRING        PyArray_STRING
++%#define NPY_UNICODE       PyArray_UNICODE
++%#define NPY_VOID          PyArray_VOID
++%#define NPY_NTYPES        PyArray_NTYPES
++%#define NPY_NOTYPE        PyArray_NOTYPE
++%#define NPY_CHAR          PyArray_CHAR
++%#define NPY_USERDEF       PyArray_USERDEF
++%#define npy_intp          intp
++
++%#define NPY_MAX_BYTE      MAX_BYTE
++%#define NPY_MIN_BYTE      MIN_BYTE
++%#define NPY_MAX_UBYTE     MAX_UBYTE
++%#define NPY_MAX_SHORT     MAX_SHORT
++%#define NPY_MIN_SHORT     MIN_SHORT
++%#define NPY_MAX_USHORT    MAX_USHORT
++%#define NPY_MAX_INT       MAX_INT
++%#define NPY_MIN_INT       MIN_INT
++%#define NPY_MAX_UINT      MAX_UINT
++%#define NPY_MAX_LONG      MAX_LONG
++%#define NPY_MIN_LONG      MIN_LONG
++%#define NPY_MAX_ULONG     MAX_ULONG
++%#define NPY_MAX_LONGLONG  MAX_LONGLONG
++%#define NPY_MIN_LONGLONG  MIN_LONGLONG
++%#define NPY_MAX_ULONGLONG MAX_ULONGLONG
++%#define NPY_MAX_INTP      MAX_INTP
++%#define NPY_MIN_INTP      MIN_INTP
++
++%#define NPY_FARRAY        FARRAY
++%#define NPY_F_CONTIGUOUS  F_CONTIGUOUS
++%#endif
++}
++
++/**********************************************************************/
++
++/* The following code originally appeared in
++ * enthought/kiva/agg/src/numeric.i written by Eric Jones.  It was
++ * translated from C++ to C by John Hunter.  Bill Spotz has modified
++ * it to fix some minor bugs, upgrade from Numeric to numpy (all
++ * versions), add some comments and functionality, and convert from
++ * direct code insertion to SWIG fragments.
++ */
++
++%fragment("NumPy_Macros", "header")
++{
++/* Macros to extract array attributes.
++ */
++%#define is_array(a)            ((a) && PyArray_Check((PyArrayObject *)a))
++%#define array_type(a)          (int)(PyArray_TYPE(a))
++%#define array_numdims(a)       (((PyArrayObject *)a)->nd)
++%#define array_dimensions(a)    (((PyArrayObject *)a)->dimensions)
++%#define array_size(a,i)        (((PyArrayObject *)a)->dimensions[i])
++%#define array_data(a)          (((PyArrayObject *)a)->data)
++%#define array_is_contiguous(a) (PyArray_ISCONTIGUOUS(a))
++%#define array_is_native(a)     (PyArray_ISNOTSWAPPED(a))
++%#define array_is_fortran(a)    (PyArray_ISFORTRAN(a))
++}
++
++/**********************************************************************/
++
++%fragment("NumPy_Utilities", "header")
++{
++  /* Given a PyObject, return a string describing its type.
++   */
++  char* pytype_string(PyObject* py_obj) {
++    if (py_obj == NULL          ) return "C NULL value";
++    if (py_obj == Py_None       ) return "Python None" ;
++    if (PyCallable_Check(py_obj)) return "callable"    ;
++    if (PyString_Check(  py_obj)) return "string"      ;
++    if (PyInt_Check(     py_obj)) return "int"         ;
++    if (PyFloat_Check(   py_obj)) return "float"       ;
++    if (PyDict_Check(    py_obj)) return "dict"        ;
++    if (PyList_Check(    py_obj)) return "list"        ;
++    if (PyTuple_Check(   py_obj)) return "tuple"       ;
++    if (PyFile_Check(    py_obj)) return "file"        ;
++    if (PyModule_Check(  py_obj)) return "module"      ;
++    if (PyInstance_Check(py_obj)) return "instance"    ;
++
++<<<<<<< HEAD:lang/numpy.i
++    return "unkown type";
++=======
++    return "unknow type";
++>>>>>>> experimental:lang/numpy.i.in
++  }
++
++  /* Given a NumPy typecode, return a string describing the type.
++   */
++  char* typecode_string(int typecode) {
++    static char* type_names[25] = {"bool", "byte", "unsigned byte",
++                                   "short", "unsigned short", "int",
++                                   "unsigned int", "long", "unsigned long",
++                                   "long long", "unsigned long long",
++                                   "float", "double", "long double",
++                                   "complex float", "complex double",
++                                   "complex long double", "object",
++                                   "string", "unicode", "void", "ntypes",
++                                   "notype", "char", "unknown"};
++    return typecode < 24 ? type_names[typecode] : type_names[24];
++  }
++
++  /* Make sure input has correct numpy type.  Allow character and byte
++   * to match.  Also allow int and long to match.  This is deprecated.
++   * You should use PyArray_EquivTypenums() instead.
++   */
++  int type_match(int actual_type, int desired_type) {
++    return PyArray_EquivTypenums(actual_type, desired_type);
++  }
++}
++
++/**********************************************************************/
++
++%fragment("NumPy_Object_to_Array", "header",
++          fragment="NumPy_Backward_Compatibility",
++          fragment="NumPy_Macros",
++          fragment="NumPy_Utilities")
++{
++  /* Given a PyObject pointer, cast it to a PyArrayObject pointer if
++   * legal.  If not, set the python error string appropriately and
++   * return NULL.
++   */
++  PyArrayObject* obj_to_array_no_conversion(PyObject* input, int typecode)
++  {
++    PyArrayObject* ary = NULL;
++    if (is_array(input) && (typecode == NPY_NOTYPE ||
++                            PyArray_EquivTypenums(array_type(input), typecode)))
++    {
++      ary = (PyArrayObject*) input;
++    }
++    else if is_array(input)
++    {
++      char* desired_type = typecode_string(typecode);
++      char* actual_type  = typecode_string(array_type(input));
++      PyErr_Format(PyExc_TypeError,
++                   "Array of type '%s' required.  Array of type '%s' given",
++                   desired_type, actual_type);
++      ary = NULL;
++    }
++    else
++    {
++      char * desired_type = typecode_string(typecode);
++      char * actual_type  = pytype_string(input);
++      PyErr_Format(PyExc_TypeError,
++                   "Array of type '%s' required.  A '%s' was given",
++                   desired_type, actual_type);
++      ary = NULL;
++    }
++    return ary;
++  }
++
++  /* Convert the given PyObject to a NumPy array with the given
++   * typecode.  On success, return a valid PyArrayObject* with the
++   * correct type.  On failure, the python error string will be set and
++   * the routine returns NULL.
++   */
++  PyArrayObject* obj_to_array_allow_conversion(PyObject* input, int typecode,
++                                               int* is_new_object)
++  {
++    PyArrayObject* ary = NULL;
++    PyObject* py_obj;
++    if (is_array(input) && (typecode == NPY_NOTYPE ||
++                            PyArray_EquivTypenums(array_type(input),typecode)))
++    {
++      ary = (PyArrayObject*) input;
++      *is_new_object = 0;
++    }
++    else
++    {
++      py_obj = PyArray_FROMANY(input, typecode, 0, 0, NPY_DEFAULT);
++      /* If NULL, PyArray_FromObject will have set python error value.*/
++      ary = (PyArrayObject*) py_obj;
++      *is_new_object = 1;
++    }
++    return ary;
++  }
++
++  /* Given a PyArrayObject, check to see if it is contiguous.  If so,
++   * return the input pointer and flag it as not a new object.  If it is
++   * not contiguous, create a new PyArrayObject using the original data,
++   * flag it as a new object and return the pointer.
++   */
++  PyArrayObject* make_contiguous(PyArrayObject* ary, int* is_new_object,
++                                 int min_dims, int max_dims)
++  {
++    PyArrayObject* result;
++    if (array_is_contiguous(ary))
++    {
++      result = ary;
++      *is_new_object = 0;
++    }
++    else
++    {
++      result = (PyArrayObject*) PyArray_ContiguousFromObject((PyObject*)ary,
++                                                             array_type(ary),
++                                                             min_dims,
++                                                             max_dims);
++      *is_new_object = 1;
++    }
++    return result;
++  }
++
++  /* Given a PyArrayObject, check to see if it is Fortran-contiguous.
++   * If so, return the input pointer, but do not flag it as not a new
++   * object.  If it is not Fortran-contiguous, create a new
++   * PyArrayObject using the original data, flag it as a new object
++   * and return the pointer.
++   */
++  PyArrayObject* make_fortran(PyArrayObject* ary, int* is_new_object,
++                              int min_dims, int max_dims)
++  {
++    PyArrayObject* result;
++    if (array_is_fortran(ary))
++    {
++      result = ary;
++      *is_new_object = 0;
++    }
++    else
++    {
++      Py_INCREF(ary->descr);
++      result = (PyArrayObject*) PyArray_FromArray(ary, ary->descr, NPY_FORTRAN);
++      *is_new_object = 1;
++    }
++    return result;
++  }
++
++  /* Convert a given PyObject to a contiguous PyArrayObject of the
++   * specified type.  If the input object is not a contiguous
++   * PyArrayObject, a new one will be created and the new object flag
++   * will be set.
++   */
++  PyArrayObject* obj_to_array_contiguous_allow_conversion(PyObject* input,
++                                                          int typecode,
++                                                          int* is_new_object)
++  {
++    int is_new1 = 0;
++    int is_new2 = 0;
++    PyArrayObject* ary2;
++    PyArrayObject* ary1 = obj_to_array_allow_conversion(input, typecode,
++                                                        &is_new1);
++    if (ary1)
++    {
++      ary2 = make_contiguous(ary1, &is_new2, 0, 0);
++      if ( is_new1 && is_new2)
++      {
++        Py_DECREF(ary1);
++      }
++      ary1 = ary2;
++    }
++    *is_new_object = is_new1 || is_new2;
++    return ary1;
++  }
++
++  /* Convert a given PyObject to a Fortran-ordered PyArrayObject of the
++   * specified type.  If the input object is not a Fortran-ordered
++   * PyArrayObject, a new one will be created and the new object flag
++   * will be set.
++   */
++  PyArrayObject* obj_to_array_fortran_allow_conversion(PyObject* input,
++                                                       int typecode,
++                                                       int* is_new_object)
++  {
++    int is_new1 = 0;
++    int is_new2 = 0;
++    PyArrayObject* ary2;
++    PyArrayObject* ary1 = obj_to_array_allow_conversion(input, typecode,
++                                                        &is_new1);
++    if (ary1)
++    {
++      ary2 = make_fortran(ary1, &is_new2, 0, 0);
++      if (is_new1 && is_new2)
++      {
++        Py_DECREF(ary1);
++      }
++      ary1 = ary2;
++    }
++    *is_new_object = is_new1 || is_new2;
++    return ary1;
++  }
++
++} /* end fragment */
++
++
++/**********************************************************************/
++
++%fragment("NumPy_Array_Requirements", "header",
++          fragment="NumPy_Backward_Compatibility",
++          fragment="NumPy_Macros")
++{
++  /* Test whether a python object is contiguous.  If array is
++   * contiguous, return 1.  Otherwise, set the python error string and
++   * return 0.
++   */
++  int require_contiguous(PyArrayObject* ary)
++  {
++    int contiguous = 1;
++    if (!array_is_contiguous(ary))
++    {
++      PyErr_SetString(PyExc_TypeError,
++                      "Array must be contiguous.  A non-contiguous array was given");
++      contiguous = 0;
++    }
++    return contiguous;
++  }
++
++  /* Require that a numpy array is not byte-swapped.  If the array is
++   * not byte-swapped, return 1.  Otherwise, set the python error string
++   * and return 0.
++   */
++  int require_native(PyArrayObject* ary)
++  {
++    int native = 1;
++    if (!array_is_native(ary))
++    {
++      PyErr_SetString(PyExc_TypeError,
++                      "Array must have native byteorder.  "
++                      "A byte-swapped array was given");
++      native = 0;
++    }
++    return native;
++  }
++
++  /* Require the given PyArrayObject to have a specified number of
++   * dimensions.  If the array has the specified number of dimensions,
++   * return 1.  Otherwise, set the python error string and return 0.
++   */
++  int require_dimensions(PyArrayObject* ary, int exact_dimensions)
++  {
++    int success = 1;
++    if (array_numdims(ary) != exact_dimensions)
++    {
++      PyErr_Format(PyExc_TypeError,
++                   "Array must have %d dimensions.  Given array has %d dimensions",
++                   exact_dimensions, array_numdims(ary));
++      success = 0;
++    }
++    return success;
++  }
++
++  /* Require the given PyArrayObject to have one of a list of specified
++   * number of dimensions.  If the array has one of the specified number
++   * of dimensions, return 1.  Otherwise, set the python error string
++   * and return 0.
++   */
++  int require_dimensions_n(PyArrayObject* ary, int* exact_dimensions, int n)
++  {
++    int success = 0;
++    int i;
++    char dims_str[255] = "";
++    char s[255];
++    for (i = 0; i < n && !success; i++)
++    {
++      if (array_numdims(ary) == exact_dimensions[i])
++      {
++        success = 1;
++      }
++    }
++    if (!success)
++    {
++      for (i = 0; i < n-1; i++)
++      {
++        sprintf(s, "%d, ", exact_dimensions[i]);
++        strcat(dims_str,s);
++      }
++      sprintf(s, " or %d", exact_dimensions[n-1]);
++      strcat(dims_str,s);
++      PyErr_Format(PyExc_TypeError,
++                   "Array must have %s dimensions.  Given array has %d dimensions",
++                   dims_str, array_numdims(ary));
++    }
++    return success;
++  }
++
++  /* Require the given PyArrayObject to have a specified shape.  If the
++   * array has the specified shape, return 1.  Otherwise, set the python
++   * error string and return 0.
++   */
++  int require_size(PyArrayObject* ary, npy_intp* size, int n)
++  {
++    int i;
++    int success = 1;
++    int len;
++    char desired_dims[255] = "[";
++    char s[255];
++    char actual_dims[255] = "[";
++    for(i=0; i < n;i++)
++    {
++      if (size[i] != -1 &&  size[i] != array_size(ary,i))
++      {
++        success = 0;
++      }
++    }
++    if (!success)
++    {
++      for (i = 0; i < n; i++)
++      {
++        if (size[i] == -1)
++        {
++          sprintf(s, "*,");
++        }
++        else
++        {
++          sprintf(s, "%ld,", (long int)size[i]);
++        }
++        strcat(desired_dims,s);
++      }
++      len = strlen(desired_dims);
++      desired_dims[len-1] = ']';
++      for (i = 0; i < n; i++)
++      {
++        sprintf(s, "%ld,", (long int)array_size(ary,i));
++        strcat(actual_dims,s);
++      }
++      len = strlen(actual_dims);
++      actual_dims[len-1] = ']';
++      PyErr_Format(PyExc_TypeError,
++                   "Array must have shape of %s.  Given array has shape of %s",
++                   desired_dims, actual_dims);
++    }
++    return success;
++  }
++
++  /* Require the given PyArrayObject to to be FORTRAN ordered.  If the
++   * the PyArrayObject is already FORTRAN ordered, do nothing.  Else,
++   * set the FORTRAN ordering flag and recompute the strides.
++   */
++  int require_fortran(PyArrayObject* ary)
++  {
++    int success = 1;
++    int nd = array_numdims(ary);
++    int i;
++    if (array_is_fortran(ary)) return success;
++    /* Set the FORTRAN ordered flag */
++    ary->flags = NPY_FARRAY;
++    /* Recompute the strides */
++    ary->strides[0] = ary->strides[nd-1];
++    for (i=1; i < nd; ++i)
++      ary->strides[i] = ary->strides[i-1] * array_size(ary,i-1);
++    return success;
++  }
++}
++
++/* Combine all NumPy fragments into one for convenience */
++%fragment("NumPy_Fragments", "header",
++          fragment="NumPy_Backward_Compatibility",
++          fragment="NumPy_Macros",
++          fragment="NumPy_Utilities",
++          fragment="NumPy_Object_to_Array",
++          fragment="NumPy_Array_Requirements") { }
++
++/* End John Hunter translation (with modifications by Bill Spotz)
++ */
++
++/* %numpy_typemaps() macro
++ *
++ * This macro defines a family of 41 typemaps that allow C arguments
++ * of the form
++ *
++ *     (DATA_TYPE IN_ARRAY1[ANY])
++ *     (DATA_TYPE* IN_ARRAY1, DIM_TYPE DIM1)
++ *     (DIM_TYPE DIM1, DATA_TYPE* IN_ARRAY1)
++ *
++ *     (DATA_TYPE IN_ARRAY2[ANY][ANY])
++ *     (DATA_TYPE* IN_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_ARRAY2)
++ *     (DATA_TYPE* IN_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_FARRAY2)
++ *
++ *     (DATA_TYPE IN_ARRAY3[ANY][ANY][ANY])
++ *     (DATA_TYPE* IN_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_ARRAY3)
++ *     (DATA_TYPE* IN_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_FARRAY3)
++ *
++ *     (DATA_TYPE INPLACE_ARRAY1[ANY])
++ *     (DATA_TYPE* INPLACE_ARRAY1, DIM_TYPE DIM1)
++ *     (DIM_TYPE DIM1, DATA_TYPE* INPLACE_ARRAY1)
++ *
++ *     (DATA_TYPE INPLACE_ARRAY2[ANY][ANY])
++ *     (DATA_TYPE* INPLACE_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_ARRAY2)
++ *     (DATA_TYPE* INPLACE_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_FARRAY2)
++ *
++ *     (DATA_TYPE INPLACE_ARRAY3[ANY][ANY][ANY])
++ *     (DATA_TYPE* INPLACE_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* INPLACE_ARRAY3)
++ *     (DATA_TYPE* INPLACE_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++ *     (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* INPLACE_FARRAY3)
++ *
++ *     (DATA_TYPE ARGOUT_ARRAY1[ANY])
++ *     (DATA_TYPE* ARGOUT_ARRAY1, DIM_TYPE DIM1)
++ *     (DIM_TYPE DIM1, DATA_TYPE* ARGOUT_ARRAY1)
++ *
++ *     (DATA_TYPE ARGOUT_ARRAY2[ANY][ANY])
++ *
++ *     (DATA_TYPE ARGOUT_ARRAY3[ANY][ANY][ANY])
++ *
++ *     (DATA_TYPE** ARGOUTVIEW_ARRAY1, DIM_TYPE* DIM1)
++ *     (DIM_TYPE* DIM1, DATA_TYPE** ARGOUTVIEW_ARRAY1)
++ *
++ *     (DATA_TYPE** ARGOUTVIEW_ARRAY2, DIM_TYPE* DIM1, DIM_TYPE* DIM2)
++ *     (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** ARGOUTVIEW_ARRAY2)
++ *     (DATA_TYPE** ARGOUTVIEW_FARRAY2, DIM_TYPE* DIM1, DIM_TYPE* DIM2)
++ *     (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** ARGOUTVIEW_FARRAY2)
++ *
++ *     (DATA_TYPE** ARGOUTVIEW_ARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3)
++ *     (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, DATA_TYPE** ARGOUTVIEW_ARRAY3)
++ *     (DATA_TYPE** ARGOUTVIEW_FARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3)
++ *     (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, DATA_TYPE** ARGOUTVIEW_FARRAY3)
++ *
++ * where "DATA_TYPE" is any type supported by the NumPy module, and
++ * "DIM_TYPE" is any int-like type suitable for specifying dimensions.
++ * The difference between "ARRAY" typemaps and "FARRAY" typemaps is
++ * that the "FARRAY" typemaps expect FORTRAN ordering of
++ * multidimensional arrays.  In python, the dimensions will not need
++ * to be specified (except for the "DATA_TYPE* ARGOUT_ARRAY1"
++ * typemaps).  The IN_ARRAYs can be a numpy array or any sequence that
++ * can be converted to a numpy array of the specified type.  The
++ * INPLACE_ARRAYs must be numpy arrays of the appropriate type.  The
++ * ARGOUT_ARRAYs will be returned as new numpy arrays of the
++ * appropriate type.
++ *
++ * These typemaps can be applied to existing functions using the
++ * %apply directive.  For example:
++ *
++ *     %apply (double* IN_ARRAY1, int DIM1) {(double* series, int length)};
++ *     double prod(double* series, int length);
++ *
++ *     %apply (int DIM1, int DIM2, double* INPLACE_ARRAY2)
++ *           {(int rows, int cols, double* matrix        )};
++ *     void floor(int rows, int cols, double* matrix, double f);
++ *
++ *     %apply (double IN_ARRAY3[ANY][ANY][ANY])
++ *           {(double tensor[2][2][2]         )};
++ *     %apply (double ARGOUT_ARRAY3[ANY][ANY][ANY])
++ *           {(double low[2][2][2]                )};
++ *     %apply (double ARGOUT_ARRAY3[ANY][ANY][ANY])
++ *           {(double upp[2][2][2]                )};
++ *     void luSplit(double tensor[2][2][2],
++ *                  double low[2][2][2],
++ *                  double upp[2][2][2]    );
++ *
++ * or directly with
++ *
++ *     double prod(double* IN_ARRAY1, int DIM1);
++ *
++ *     void floor(int DIM1, int DIM2, double* INPLACE_ARRAY2, double f);
++ *
++ *     void luSplit(double IN_ARRAY3[ANY][ANY][ANY],
++ *                  double ARGOUT_ARRAY3[ANY][ANY][ANY],
++ *                  double ARGOUT_ARRAY3[ANY][ANY][ANY]);
++ */
++
++%define %numpy_typemaps(DATA_TYPE, DATA_TYPECODE, DIM_TYPE)
++
++/************************/
++/* Input Array Typemaps */
++/************************/
++
++/* Typemap suite for (DATA_TYPE IN_ARRAY1[ANY])
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE IN_ARRAY1[ANY])
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE IN_ARRAY1[ANY])
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[1] = { $1_dim0 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 1) ||
++      !require_size(array, size, 1)) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++%typemap(freearg)
++  (DATA_TYPE IN_ARRAY1[ANY])
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DATA_TYPE* IN_ARRAY1, DIM_TYPE DIM1)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* IN_ARRAY1, DIM_TYPE DIM1)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* IN_ARRAY1, DIM_TYPE DIM1)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[1] = { -1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 1) ||
++      !require_size(array, size, 1)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++}
++%typemap(freearg)
++  (DATA_TYPE* IN_ARRAY1, DIM_TYPE DIM1)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DATA_TYPE* IN_ARRAY1)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DATA_TYPE* IN_ARRAY1)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DATA_TYPE* IN_ARRAY1)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[1] = {-1};
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 1) ||
++      !require_size(array, size, 1)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DATA_TYPE*) array_data(array);
++}
++%typemap(freearg)
++  (DIM_TYPE DIM1, DATA_TYPE* IN_ARRAY1)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DATA_TYPE IN_ARRAY2[ANY][ANY])
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE IN_ARRAY2[ANY][ANY])
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE IN_ARRAY2[ANY][ANY])
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[2] = { $1_dim0, $1_dim1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 2) ||
++      !require_size(array, size, 2)) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++%typemap(freearg)
++  (DATA_TYPE IN_ARRAY2[ANY][ANY])
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DATA_TYPE* IN_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* IN_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* IN_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[2] = { -1, -1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 2) ||
++      !require_size(array, size, 2)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++}
++%typemap(freearg)
++  (DATA_TYPE* IN_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_ARRAY2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_ARRAY2)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_ARRAY2)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[2] = { -1, -1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 2) ||
++      !require_size(array, size, 2)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DATA_TYPE*) array_data(array);
++}
++%typemap(freearg)
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_ARRAY2)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DATA_TYPE* IN_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* IN_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* IN_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[2] = { -1, -1 };
++  array = obj_to_array_fortran_allow_conversion($input, DATA_TYPECODE,
++                                                &is_new_object);
++  if (!array || !require_dimensions(array, 2) ||
++      !require_size(array, size, 2) || !require_fortran(array)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++}
++%typemap(freearg)
++  (DATA_TYPE* IN_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_FARRAY2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_FARRAY2)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_FARRAY2)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[2] = { -1, -1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 2) ||
++      !require_size(array, size, 2) || !require_fortran(array)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DATA_TYPE*) array_data(array);
++}
++%typemap(freearg)
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* IN_FARRAY2)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DATA_TYPE IN_ARRAY3[ANY][ANY][ANY])
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE IN_ARRAY3[ANY][ANY][ANY])
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE IN_ARRAY3[ANY][ANY][ANY])
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[3] = { $1_dim0, $1_dim1, $1_dim2 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 3) ||
++      !require_size(array, size, 3)) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++%typemap(freearg)
++  (DATA_TYPE IN_ARRAY3[ANY][ANY][ANY])
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DATA_TYPE* IN_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2,
++ *                    DIM_TYPE DIM3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* IN_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* IN_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[3] = { -1, -1, -1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 3) ||
++      !require_size(array, size, 3)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++  $4 = (DIM_TYPE) array_size(array,2);
++}
++%typemap(freearg)
++  (DATA_TYPE* IN_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3,
++ *                    DATA_TYPE* IN_ARRAY3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_ARRAY3)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_ARRAY3)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[3] = { -1, -1, -1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 3) ||
++      !require_size(array, size, 3)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DIM_TYPE) array_size(array,2);
++  $4 = (DATA_TYPE*) array_data(array);
++}
++%typemap(freearg)
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_ARRAY3)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DATA_TYPE* IN_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2,
++ *                    DIM_TYPE DIM3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* IN_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* IN_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[3] = { -1, -1, -1 };
++  array = obj_to_array_fortran_allow_conversion($input, DATA_TYPECODE,
++                                                &is_new_object);
++  if (!array || !require_dimensions(array, 3) ||
++      !require_size(array, size, 3) | !require_fortran(array)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++  $4 = (DIM_TYPE) array_size(array,2);
++}
++%typemap(freearg)
++  (DATA_TYPE* IN_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3,
++ *                    DATA_TYPE* IN_FARRAY3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_FARRAY3)
++{
++  $1 = is_array($input) || PySequence_Check($input);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_FARRAY3)
++  (PyArrayObject* array=NULL, int is_new_object=0)
++{
++  npy_intp size[3] = { -1, -1, -1 };
++  array = obj_to_array_contiguous_allow_conversion($input, DATA_TYPECODE,
++                                                   &is_new_object);
++  if (!array || !require_dimensions(array, 3) ||
++      !require_size(array, size, 3) || !require_fortran(array)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DIM_TYPE) array_size(array,2);
++  $4 = (DATA_TYPE*) array_data(array);
++}
++%typemap(freearg)
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* IN_FARRAY3)
++{
++  if (is_new_object$argnum && array$argnum)
++    { Py_DECREF(array$argnum); }
++}
++
++/***************************/
++/* In-Place Array Typemaps */
++/***************************/
++
++/* Typemap suite for (DATA_TYPE INPLACE_ARRAY1[ANY])
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE INPLACE_ARRAY1[ANY])
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE INPLACE_ARRAY1[ANY])
++  (PyArrayObject* array=NULL)
++{
++  npy_intp size[1] = { $1_dim0 };
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,1) || !require_size(array, size, 1) ||
++      !require_contiguous(array) || !require_native(array)) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++
++/* Typemap suite for (DATA_TYPE* INPLACE_ARRAY1, DIM_TYPE DIM1)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* INPLACE_ARRAY1, DIM_TYPE DIM1)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* INPLACE_ARRAY1, DIM_TYPE DIM1)
++  (PyArrayObject* array=NULL, int i=1)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,1) || !require_contiguous(array)
++      || !require_native(array)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = 1;
++  for (i=0; i < array_numdims(array); ++i) $2 *= array_size(array,i);
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DATA_TYPE* INPLACE_ARRAY1)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DATA_TYPE* INPLACE_ARRAY1)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DATA_TYPE* INPLACE_ARRAY1)
++  (PyArrayObject* array=NULL, int i=0)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,1) || !require_contiguous(array)
++      || !require_native(array)) SWIG_fail;
++  $1 = 1;
++  for (i=0; i < array_numdims(array); ++i) $1 *= array_size(array,i);
++  $2 = (DATA_TYPE*) array_data(array);
++}
++
++/* Typemap suite for (DATA_TYPE INPLACE_ARRAY2[ANY][ANY])
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE INPLACE_ARRAY2[ANY][ANY])
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE INPLACE_ARRAY2[ANY][ANY])
++  (PyArrayObject* array=NULL)
++{
++  npy_intp size[2] = { $1_dim0, $1_dim1 };
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,2) || !require_size(array, size, 2) ||
++      !require_contiguous(array) || !require_native(array)) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++
++/* Typemap suite for (DATA_TYPE* INPLACE_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* INPLACE_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* INPLACE_ARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,2) || !require_contiguous(array)
++      || !require_native(array)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_ARRAY2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_ARRAY2)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_ARRAY2)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,2) || !require_contiguous(array) ||
++      !require_native(array)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DATA_TYPE*) array_data(array);
++}
++
++/* Typemap suite for (DATA_TYPE* INPLACE_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* INPLACE_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* INPLACE_FARRAY2, DIM_TYPE DIM1, DIM_TYPE DIM2)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,2) || !require_contiguous(array)
++      || !require_native(array) || !require_fortran(array)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_FARRAY2)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_FARRAY2)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DATA_TYPE* INPLACE_FARRAY2)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,2) || !require_contiguous(array) ||
++      !require_native(array) || !require_fortran(array)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DATA_TYPE*) array_data(array);
++}
++
++/* Typemap suite for (DATA_TYPE INPLACE_ARRAY3[ANY][ANY][ANY])
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE INPLACE_ARRAY3[ANY][ANY][ANY])
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE INPLACE_ARRAY3[ANY][ANY][ANY])
++  (PyArrayObject* array=NULL)
++{
++  npy_intp size[3] = { $1_dim0, $1_dim1, $1_dim2 };
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,3) || !require_size(array, size, 3) ||
++      !require_contiguous(array) || !require_native(array)) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++
++/* Typemap suite for (DATA_TYPE* INPLACE_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2,
++ *                    DIM_TYPE DIM3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* INPLACE_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* INPLACE_ARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,3) || !require_contiguous(array) ||
++      !require_native(array)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++  $4 = (DIM_TYPE) array_size(array,2);
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3,
++ *                    DATA_TYPE* INPLACE_ARRAY3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* INPLACE_ARRAY3)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* INPLACE_ARRAY3)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,3) || !require_contiguous(array)
++      || !require_native(array)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DIM_TYPE) array_size(array,2);
++  $4 = (DATA_TYPE*) array_data(array);
++}
++
++/* Typemap suite for (DATA_TYPE* INPLACE_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2,
++ *                    DIM_TYPE DIM3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DATA_TYPE* INPLACE_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* INPLACE_FARRAY3, DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,3) || !require_contiguous(array) ||
++      !require_native(array) || !require_fortran(array)) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++  $2 = (DIM_TYPE) array_size(array,0);
++  $3 = (DIM_TYPE) array_size(array,1);
++  $4 = (DIM_TYPE) array_size(array,2);
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3,
++ *                    DATA_TYPE* INPLACE_FARRAY3)
++ */
++%typecheck(SWIG_TYPECHECK_DOUBLE_ARRAY,
++           fragment="NumPy_Macros")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* INPLACE_FARRAY3)
++{
++  $1 = is_array($input) && PyArray_EquivTypenums(array_type($input),
++                                                 DATA_TYPECODE);
++}
++%typemap(in,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DIM_TYPE DIM2, DIM_TYPE DIM3, DATA_TYPE* INPLACE_FARRAY3)
++  (PyArrayObject* array=NULL)
++{
++  array = obj_to_array_no_conversion($input, DATA_TYPECODE);
++  if (!array || !require_dimensions(array,3) || !require_contiguous(array)
++      || !require_native(array) || !require_fortran(array)) SWIG_fail;
++  $1 = (DIM_TYPE) array_size(array,0);
++  $2 = (DIM_TYPE) array_size(array,1);
++  $3 = (DIM_TYPE) array_size(array,2);
++  $4 = (DATA_TYPE*) array_data(array);
++}
++
++/*************************/
++/* Argout Array Typemaps */
++/*************************/
++
++/* Typemap suite for (DATA_TYPE ARGOUT_ARRAY1[ANY])
++ */
++%typemap(in,numinputs=0,
++         fragment="NumPy_Backward_Compatibility,NumPy_Macros")
++  (DATA_TYPE ARGOUT_ARRAY1[ANY])
++  (PyObject * array = NULL)
++{
++  npy_intp dims[1] = { $1_dim0 };
++  array = PyArray_SimpleNew(1, dims, DATA_TYPECODE);
++  if (!array) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++%typemap(argout)
++  (DATA_TYPE ARGOUT_ARRAY1[ANY])
++{
++  $result = SWIG_Python_AppendOutput($result,array$argnum);
++}
++
++/* Typemap suite for (DATA_TYPE* ARGOUT_ARRAY1, DIM_TYPE DIM1)
++ */
++%typemap(in,numinputs=1,
++         fragment="NumPy_Fragments")
++  (DATA_TYPE* ARGOUT_ARRAY1, DIM_TYPE DIM1)
++  (PyObject * array = NULL)
++{
++  npy_intp dims[1];
++  if (!PyInt_Check($input))
++  {
++    char* typestring = pytype_string($input);
++    PyErr_Format(PyExc_TypeError,
++                 "Int dimension expected.  '%s' given.",
++                 typestring);
++    SWIG_fail;
++  }
++  $2 = (DIM_TYPE) PyInt_AsLong($input);
++  dims[0] = (npy_intp) $2;
++  array = PyArray_SimpleNew(1, dims, DATA_TYPECODE);
++  if (!array) SWIG_fail;
++  $1 = (DATA_TYPE*) array_data(array);
++}
++%typemap(argout)
++  (DATA_TYPE* ARGOUT_ARRAY1, DIM_TYPE DIM1)
++{
++  $result = SWIG_Python_AppendOutput($result,array$argnum);
++}
++
++/* Typemap suite for (DIM_TYPE DIM1, DATA_TYPE* ARGOUT_ARRAY1)
++ */
++%typemap(in,numinputs=1,
++         fragment="NumPy_Fragments")
++  (DIM_TYPE DIM1, DATA_TYPE* ARGOUT_ARRAY1)
++  (PyObject * array = NULL)
++{
++  npy_intp dims[1];
++  if (!PyInt_Check($input))
++  {
++    char* typestring = pytype_string($input);
++    PyErr_Format(PyExc_TypeError,
++                 "Int dimension expected.  '%s' given.",
++                 typestring);
++    SWIG_fail;
++  }
++  $1 = (DIM_TYPE) PyInt_AsLong($input);
++  dims[0] = (npy_intp) $1;
++  array = PyArray_SimpleNew(1, dims, DATA_TYPECODE);
++  if (!array) SWIG_fail;
++  $2 = (DATA_TYPE*) array_data(array);
++}
++%typemap(argout)
++  (DIM_TYPE DIM1, DATA_TYPE* ARGOUT_ARRAY1)
++{
++  $result = SWIG_Python_AppendOutput($result,array$argnum);
++}
++
++/* Typemap suite for (DATA_TYPE ARGOUT_ARRAY2[ANY][ANY])
++ */
++%typemap(in,numinputs=0,
++         fragment="NumPy_Backward_Compatibility,NumPy_Macros")
++  (DATA_TYPE ARGOUT_ARRAY2[ANY][ANY])
++  (PyObject * array = NULL)
++{
++  npy_intp dims[2] = { $1_dim0, $1_dim1 };
++  array = PyArray_SimpleNew(2, dims, DATA_TYPECODE);
++  if (!array) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++%typemap(argout)
++  (DATA_TYPE ARGOUT_ARRAY2[ANY][ANY])
++{
++  $result = SWIG_Python_AppendOutput($result,array$argnum);
++}
++
++/* Typemap suite for (DATA_TYPE ARGOUT_ARRAY3[ANY][ANY][ANY])
++ */
++%typemap(in,numinputs=0,
++         fragment="NumPy_Backward_Compatibility,NumPy_Macros")
++  (DATA_TYPE ARGOUT_ARRAY3[ANY][ANY][ANY])
++  (PyObject * array = NULL)
++{
++  npy_intp dims[3] = { $1_dim0, $1_dim1, $1_dim2 };
++  array = PyArray_SimpleNew(3, dims, DATA_TYPECODE);
++  if (!array) SWIG_fail;
++  $1 = ($1_ltype) array_data(array);
++}
++%typemap(argout)
++  (DATA_TYPE ARGOUT_ARRAY3[ANY][ANY][ANY])
++{
++  $result = SWIG_Python_AppendOutput($result,array$argnum);
++}
++
++/*****************************/
++/* Argoutview Array Typemaps */
++/*****************************/
++
++/* Typemap suite for (DATA_TYPE** ARGOUTVIEW_ARRAY1, DIM_TYPE* DIM1)
++ */
++%typemap(in,numinputs=0)
++  (DATA_TYPE** ARGOUTVIEW_ARRAY1, DIM_TYPE* DIM1    )
++  (DATA_TYPE*  data_temp        , DIM_TYPE  dim_temp)
++{
++  $1 = &data_temp;
++  $2 = &dim_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility")
++  (DATA_TYPE** ARGOUTVIEW_ARRAY1, DIM_TYPE* DIM1)
++{
++  npy_intp dims[1] = { *$2 };
++  PyObject * array = PyArray_SimpleNewFromData(1, dims, DATA_TYPECODE, (void*)(*$1));
++  if (!array) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,array);
++}
++
++/* Typemap suite for (DIM_TYPE* DIM1, DATA_TYPE** ARGOUTVIEW_ARRAY1)
++ */
++%typemap(in,numinputs=0)
++  (DIM_TYPE* DIM1    , DATA_TYPE** ARGOUTVIEW_ARRAY1)
++  (DIM_TYPE  dim_temp, DATA_TYPE*  data_temp        )
++{
++  $1 = &dim_temp;
++  $2 = &data_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility")
++  (DIM_TYPE* DIM1, DATA_TYPE** ARGOUTVIEW_ARRAY1)
++{
++  npy_intp dims[1] = { *$1 };
++  PyObject * array = PyArray_SimpleNewFromData(1, dims, DATA_TYPECODE, (void*)(*$2));
++  if (!array) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,array);
++}
++
++/* Typemap suite for (DATA_TYPE** ARGOUTVIEW_ARRAY2, DIM_TYPE* DIM1, DIM_TYPE* DIM2)
++ */
++%typemap(in,numinputs=0)
++  (DATA_TYPE** ARGOUTVIEW_ARRAY2, DIM_TYPE* DIM1     , DIM_TYPE* DIM2     )
++  (DATA_TYPE*  data_temp        , DIM_TYPE  dim1_temp, DIM_TYPE  dim2_temp)
++{
++  $1 = &data_temp;
++  $2 = &dim1_temp;
++  $3 = &dim2_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility")
++  (DATA_TYPE** ARGOUTVIEW_ARRAY2, DIM_TYPE* DIM1, DIM_TYPE* DIM2)
++{
++  npy_intp dims[2] = { *$2, *$3 };
++  PyObject * array = PyArray_SimpleNewFromData(2, dims, DATA_TYPECODE, (void*)(*$1));
++  if (!array) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,array);
++}
++
++/* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** ARGOUTVIEW_ARRAY2)
++ */
++%typemap(in,numinputs=0)
++  (DIM_TYPE* DIM1     , DIM_TYPE* DIM2     , DATA_TYPE** ARGOUTVIEW_ARRAY2)
++  (DIM_TYPE  dim1_temp, DIM_TYPE  dim2_temp, DATA_TYPE*  data_temp        )
++{
++  $1 = &dim1_temp;
++  $2 = &dim2_temp;
++  $3 = &data_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility")
++  (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** ARGOUTVIEW_ARRAY2)
++{
++  npy_intp dims[2] = { *$1, *$2 };
++  PyObject * array = PyArray_SimpleNewFromData(2, dims, DATA_TYPECODE, (void*)(*$3));
++  if (!array) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,array);
++}
++
++/* Typemap suite for (DATA_TYPE** ARGOUTVIEW_FARRAY2, DIM_TYPE* DIM1, DIM_TYPE* DIM2)
++ */
++%typemap(in,numinputs=0)
++  (DATA_TYPE** ARGOUTVIEW_FARRAY2, DIM_TYPE* DIM1     , DIM_TYPE* DIM2     )
++  (DATA_TYPE*  data_temp        , DIM_TYPE  dim1_temp, DIM_TYPE  dim2_temp)
++{
++  $1 = &data_temp;
++  $2 = &dim1_temp;
++  $3 = &dim2_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility,NumPy_Array_Requirements")
++  (DATA_TYPE** ARGOUTVIEW_FARRAY2, DIM_TYPE* DIM1, DIM_TYPE* DIM2)
++{
++  npy_intp dims[2] = { *$2, *$3 };
++  PyObject * obj = PyArray_SimpleNewFromData(2, dims, DATA_TYPECODE, (void*)(*$1));
++  PyArrayObject * array = (PyArrayObject*) obj;
++  if (!array || !require_fortran(array)) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,obj);
++}
++
++/* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** ARGOUTVIEW_FARRAY2)
++ */
++%typemap(in,numinputs=0)
++  (DIM_TYPE* DIM1     , DIM_TYPE* DIM2     , DATA_TYPE** ARGOUTVIEW_FARRAY2)
++  (DIM_TYPE  dim1_temp, DIM_TYPE  dim2_temp, DATA_TYPE*  data_temp        )
++{
++  $1 = &dim1_temp;
++  $2 = &dim2_temp;
++  $3 = &data_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility,NumPy_Array_Requirements")
++  (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** ARGOUTVIEW_FARRAY2)
++{
++  npy_intp dims[2] = { *$1, *$2 };
++  PyObject * obj = PyArray_SimpleNewFromData(2, dims, DATA_TYPECODE, (void*)(*$3));
++  PyArrayObject * array = (PyArrayObject*) obj;
++  if (!array || !require_fortran(array)) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,obj);
++}
++
++/* Typemap suite for (DATA_TYPE** ARGOUTVIEW_ARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2,
++                      DIM_TYPE* DIM3)
++ */
++%typemap(in,numinputs=0)
++  (DATA_TYPE** ARGOUTVIEW_ARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3)
++  (DATA_TYPE* data_temp, DIM_TYPE dim1_temp, DIM_TYPE dim2_temp, DIM_TYPE dim3_temp)
++{
++  $1 = &data_temp;
++  $2 = &dim1_temp;
++  $3 = &dim2_temp;
++  $4 = &dim3_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility")
++  (DATA_TYPE** ARGOUTVIEW_ARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3)
++{
++  npy_intp dims[3] = { *$2, *$3, *$4 };
++  PyObject * array = PyArray_SimpleNewFromData(3, dims, DATA_TYPECODE, (void*)(*$1));
++  if (!array) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,array);
++}
++
++/* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3,
++                      DATA_TYPE** ARGOUTVIEW_ARRAY3)
++ */
++%typemap(in,numinputs=0)
++  (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, DATA_TYPE** ARGOUTVIEW_ARRAY3)
++  (DIM_TYPE dim1_temp, DIM_TYPE dim2_temp, DIM_TYPE dim3_temp, DATA_TYPE* data_temp)
++{
++  $1 = &dim1_temp;
++  $2 = &dim2_temp;
++  $3 = &dim3_temp;
++  $4 = &data_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility")
++  (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, DATA_TYPE** ARGOUTVIEW_ARRAY3)
++{
++  npy_intp dims[3] = { *$1, *$2, *$3 };
++  PyObject * array = PyArray_SimpleNewFromData(3, dims, DATA_TYPECODE, (void*)(*$3));
++  if (!array) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,array);
++}
++
++/* Typemap suite for (DATA_TYPE** ARGOUTVIEW_FARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2,
++                      DIM_TYPE* DIM3)
++ */
++%typemap(in,numinputs=0)
++  (DATA_TYPE** ARGOUTVIEW_FARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3)
++  (DATA_TYPE* data_temp, DIM_TYPE dim1_temp, DIM_TYPE dim2_temp, DIM_TYPE dim3_temp)
++{
++  $1 = &data_temp;
++  $2 = &dim1_temp;
++  $3 = &dim2_temp;
++  $4 = &dim3_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility,NumPy_Array_Requirements")
++  (DATA_TYPE** ARGOUTVIEW_FARRAY3, DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3)
++{
++  npy_intp dims[3] = { *$2, *$3, *$4 };
++  PyObject * obj = PyArray_SimpleNewFromData(3, dims, DATA_TYPECODE, (void*)(*$1));
++  PyArrayObject * array = (PyArrayObject*) obj;
++  if (!array || require_fortran(array)) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,obj);
++}
++
++/* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3,
++                      DATA_TYPE** ARGOUTVIEW_FARRAY3)
++ */
++%typemap(in,numinputs=0)
++  (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, DATA_TYPE** ARGOUTVIEW_FARRAY3)
++  (DIM_TYPE dim1_temp, DIM_TYPE dim2_temp, DIM_TYPE dim3_temp, DATA_TYPE* data_temp)
++{
++  $1 = &dim1_temp;
++  $2 = &dim2_temp;
++  $3 = &dim3_temp;
++  $4 = &data_temp;
++}
++%typemap(argout,
++         fragment="NumPy_Backward_Compatibility,NumPy_Array_Requirements")
++  (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, DATA_TYPE** ARGOUTVIEW_FARRAY3)
++{
++  npy_intp dims[3] = { *$1, *$2, *$3 };
++  PyObject * obj = PyArray_SimpleNewFromData(3, dims, DATA_TYPECODE, (void*)(*$3));
++  PyArrayObject * array = (PyArrayObject*) obj;
++  if (!array || require_fortran(array)) SWIG_fail;
++  $result = SWIG_Python_AppendOutput($result,obj);
++}
++
++%enddef    /* %numpy_typemaps() macro */
++/* *************************************************************** */
++
++/* Concrete instances of the %numpy_typemaps() macro: Each invocation
++ * below applies all of the typemaps above to the specified data type.
++ */
++%numpy_typemaps(signed char       , NPY_BYTE     , int)
++%numpy_typemaps(unsigned char     , NPY_UBYTE    , int)
++%numpy_typemaps(short             , NPY_SHORT    , int)
++%numpy_typemaps(unsigned short    , NPY_USHORT   , int)
++%numpy_typemaps(int               , NPY_INT      , int)
++%numpy_typemaps(unsigned int      , NPY_UINT     , int)
++%numpy_typemaps(long              , NPY_LONG     , int)
++%numpy_typemaps(unsigned long     , NPY_ULONG    , int)
++%numpy_typemaps(long long         , NPY_LONGLONG , int)
++%numpy_typemaps(unsigned long long, NPY_ULONGLONG, int)
++%numpy_typemaps(float             , NPY_FLOAT    , int)
++%numpy_typemaps(double            , NPY_DOUBLE   , int)
++
++/* ***************************************************************
++ * The follow macro expansion does not work, because C++ bool is 4
++ * bytes and NPY_BOOL is 1 byte
++ *
++ *    %numpy_typemaps(bool, NPY_BOOL, int)
++ */
++
++/* ***************************************************************
++ * On my Mac, I get the following warning for this macro expansion:
++ * 'swig/python detected a memory leak of type 'long double *', no destructor found.'
++ *
++ *    %numpy_typemaps(long double, NPY_LONGDOUBLE, int)
++ */
++
++/* ***************************************************************
++ * Swig complains about a syntax error for the following macro
++ * expansions:
++ *
++ *    %numpy_typemaps(complex float,  NPY_CFLOAT , int)
++ *
++ *    %numpy_typemaps(complex double, NPY_CDOUBLE, int)
++ *
++ *    %numpy_typemaps(complex long double, NPY_CLONGDOUBLE, int)
++ */
++
++#endif /* SWIGPYTHON */
Simple merge
Simple merge
Simple merge
Simple merge