[python-fann2] 04/06: Add patch Improve-SWIG-invocation.patch

Christian Kastner ckk at moszumanska.debian.org
Tue Sep 29 19:31:34 UTC 2015


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

ckk pushed a commit to branch master
in repository python-fann2.

commit e6489a3316bf31078ffd7de010422d8bccc9847f
Author: Christian Kastner <ckk at kvr.at>
Date:   Tue Sep 29 13:53:04 2015 +0200

    Add patch Improve-SWIG-invocation.patch
---
 debian/patches/Improve-SWIG-invocation.patch | 35 ++++++++++++++++++++++++++++
 debian/patches/series                        |  1 +
 2 files changed, 36 insertions(+)

diff --git a/debian/patches/Improve-SWIG-invocation.patch b/debian/patches/Improve-SWIG-invocation.patch
new file mode 100644
index 0000000..7c2ceab
--- /dev/null
+++ b/debian/patches/Improve-SWIG-invocation.patch
@@ -0,0 +1,35 @@
+From: Christian Kastner <ckk at kvr.at>
+Date: Tue, 29 Sep 2015 13:40:49 +0200
+Subject: Improve SWIG invocation
+
+Only build the extension in the build target (instead of in all targets but
+sdist), and don't install unnecessary files.
+
+Forwarded: not-needed
+Last-Update: 2015-09-29
+---
+ setup.py | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index b4afbbb..9a96cef 100755
+--- a/setup.py
++++ b/setup.py
+@@ -61,7 +61,7 @@ def build_swig():
+     swig_cmd = [swig_bin, '-c++', '-python', 'fann2/fann2.i']
+     subprocess.Popen(swig_cmd).wait()
+ 
+-if "sdist" not in sys.argv:
++if "build" not in sys.argv:
+     build_swig()
+ 
+ 
+@@ -92,7 +92,7 @@ setup(
+     ],
+     keywords="ANN artificial intelligence FANN2.2.0 bindings".split(' '),
+     zip_safe=False,
+-    include_package_data=True,
++    include_package_data=False,
+     packages=find_packages(),
+     py_modules=['fann2.libfann'],
+     ext_modules=[Extension('fann2._libfann', ['fann2/fann2_wrap.cxx'],
diff --git a/debian/patches/series b/debian/patches/series
index e69de29..759f5ee 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -0,0 +1 @@
+Improve-SWIG-invocation.patch

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



More information about the debian-science-commits mailing list