[med-svn] [Git][med-team/python-parasail][master] 5 commits: New upstream version 1.2.3

Nilesh Patra gitlab at salsa.debian.org
Sun Dec 20 12:30:07 GMT 2020



Nilesh Patra pushed to branch master at Debian Med / python-parasail


Commits:
8959e602 by Nilesh Patra at 2020-12-20T17:57:02+05:30
New upstream version 1.2.3
- - - - -
60d364d9 by Nilesh Patra at 2020-12-20T17:57:02+05:30
routine-update: New upstream version

- - - - -
d33512ca by Nilesh Patra at 2020-12-20T17:57:03+05:30
Update upstream source from tag 'upstream/1.2.3'

Update to upstream version '1.2.3'
with Debian dir d9f06bca221e6cee60836b8d02995799c3dce5f6
- - - - -
d211d60e by Nilesh Patra at 2020-12-20T17:57:08+05:30
Trim trailing whitespace.

Changes-By: lintian-brush
Fixes: lintian: trailing-whitespace
See-also: https://lintian.debian.org/tags/trailing-whitespace.html

- - - - -
cf20900d by Nilesh Patra at 2020-12-20T17:57:09+05:30
routine-update: Ready to upload to unstable

- - - - -


5 changed files:

- CHANGELOG.rst
- debian/changelog
- debian/rules
- parasail/__init__.py
- setup.py


Changes:

=====================================
CHANGELOG.rst
=====================================
@@ -10,6 +10,11 @@ Unreleased_
 -----------
 The Unreleased section will be empty for tagged releases. Unreleased functionality appears in the develop branch.
 
+-------------------
+1.2.3_ - 2020-12-16
+-------------------
+- Fix #57 Install error with parasail v1.2.2
+
 -------------------
 1.2.2_ - 2020-12-01
 -------------------
@@ -153,7 +158,8 @@ The Unreleased section will be empty for tagged releases. Unreleased functionali
 -------------------
 First tagged release. The 'master' branch always represents the latest stable code. Tagged releases correspond to pypi releases.
 
-.. _Unreleased: https://github.com/jeffdaily/parasail-python/compare/v1.2.2...master
+.. _Unreleased: https://github.com/jeffdaily/parasail-python/compare/v1.2.3...master
+.. _1.2.3:   https://github.com/jeffdaily/parasail-python/compare/v1.2.2...v1.2.3
 .. _1.2.2:   https://github.com/jeffdaily/parasail-python/compare/v1.2.1...v1.2.2
 .. _1.2.1:   https://github.com/jeffdaily/parasail-python/compare/v1.2...v1.2.1
 .. _1.2:     https://github.com/jeffdaily/parasail-python/compare/v1.1.20...v1.2


=====================================
debian/changelog
=====================================
@@ -1,3 +1,9 @@
+python-parasail (1.2.3-1) unstable; urgency=medium
+
+  * New upstream version
+
+ -- Nilesh Patra <npatra974 at gmail.com>  Sun, 20 Dec 2020 17:57:09 +0530
+
 python-parasail (1.2.2-2) unstable; urgency=medium
 
   * Cleanup d/rules


=====================================
debian/rules
=====================================
@@ -7,4 +7,3 @@
 
 %:
 	dh $@ --with python3 --buildsystem=pybuild
-


=====================================
parasail/__init__.py
=====================================
@@ -6,7 +6,7 @@ import sys
 
 import numpy
 
-__version__ = "1.2.2"
+__version__ = "1.2.3"
 __title__ = "parasail"
 __description__ = "pairwise sequence alignment library"
 __uri__ = "https://github.com/jeffdaily/parasail-python"


=====================================
setup.py
=====================================
@@ -186,8 +186,11 @@ def run_autoreconf(root):
                 all_good = False
     return all_good
 
-def build_autotools():
-    print("Building autotools")
+def build_autotools(patch_m4=False):
+    if patch_m4:
+        print("Building autotools with patched m4")
+    else:
+        print("Building autotools")
     save_cwd = os.getcwd()
     top = os.path.join(os.getcwd(), 'autotools')
     if not os.path.exists(top):
@@ -218,7 +221,9 @@ def build_autotools():
                     break
             else:
                 # we failed all the attempts - deal with the consequences.
-                raise RuntimeError("All attempts to download {} have failed".format(tarball))
+                print("All attempts to download {} have failed".format(tarball))
+                os.chdir(save_cwd)
+                return False
         if os.path.exists(tdir):
             print("{} already exists! Using existing sources.".format(tdir))
         else:
@@ -228,14 +233,31 @@ def build_autotools():
             print("{} already exists! Skipping build.".format(binary))
         else:
             os.chdir(os.path.join(top,tdir))
+            CPPFLAGS=""
+            if tool == 'm4' and patch_m4:
+                CPPFLAGS="CPPFLAGS=-D_IO_IN_BACKUP=0x100"
+                for filename in ['lib/freading.c', 'lib/fseeko.c', 'lib/fpurge.c', 'lib/freadahead.c', 'lib/fflush.c']:
+                    with open(filename, "r") as source:
+                        lines = source.readlines()
+                    newlines = [line.replace('_IO_ftrylockfile','_IO_EOF_SEEN') for line in lines]
+                    if lines == newlines:
+                        print("{} skipped".format(filename))
+                    else:
+                        with open(filename, "w") as source:
+                            for line in newlines:
+                                source.write(line)
+                        print("{} patched".format(filename))
             print("configuring {}".format(tool))
+            print("running ./configure --prefix={} {}".format(top,CPPFLAGS))
             proc = subprocess.Popen([
-                './configure', '--prefix={}'.format(top)
+                './configure', '--prefix={}'.format(top), '{}'.format(CPPFLAGS)
                 ], stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
             stdout,stderr = proc.communicate()
             if 0 != proc.returncode:
                 print(stdout)
-                raise RuntimeError("configure of {} failed".format(tool))
+                print("configure of {} failed".format(tool))
+                os.chdir(save_cwd)
+                return False
             print("making and installing {}".format(tool))
             proc = subprocess.Popen([
                 'make', '-j', str(cpu_count()), 'install'
@@ -243,8 +265,11 @@ def build_autotools():
             stdout,stderr = proc.communicate()
             if 0 != proc.returncode:
                 print(stdout)
-                raise RuntimeError("make of {} failed".format(tool))
+                print("make of {} failed".format(tool))
+                os.chdir(save_cwd)
+                return False
     os.chdir(save_cwd)
+    return True
 
 # Download, unzip, configure, and make parasail C library from github.
 # Attempt to skip steps that may have already completed.
@@ -302,7 +327,9 @@ def build_parasail(libname):
             if platform.system() == "Darwin" and 'M4' not in os.environ:
                 os.environ['M4'] = '/usr/bin/m4'
             print("PATH={}".format(os.environ['PATH']))
-            build_autotools()
+            if not build_autotools():
+                if not build_autotools(True):
+                    raise RuntimeError("building autotools failed")
             if not run_autoreconf(root):
                 raise RuntimeError("autoreconf -fi failed")
     root = find_file('configure', parasail_root)



View it on GitLab: https://salsa.debian.org/med-team/python-parasail/-/compare/5307951d08cc6c3af499b0fca7af88138401b584...cf20900dc5db4ac861093981f7338780f364fc29

-- 
View it on GitLab: https://salsa.debian.org/med-team/python-parasail/-/compare/5307951d08cc6c3af499b0fca7af88138401b584...cf20900dc5db4ac861093981f7338780f364fc29
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20201220/0560e5fd/attachment-0001.html>


More information about the debian-med-commit mailing list