You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by as...@apache.org on 2019/11/05 04:29:41 UTC

[qpid-proton] branch master updated (3167d53 -> 5dae7dd)

This is an automated email from the ASF dual-hosted git repository.

astitcher pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/qpid-proton.git.


    from 3167d53  PROTON-2127: Fix FreeBSD build breakage
     new 4a69c9c  PROTON-2126: Fix Python package building on windows - Due to a bug in the combination of CMake and MSbuild failing   to detect cyrus-sasl on windows in the python setup.py was failing   the windows build during 'python setup.py bdist_wheel'
     new 5dae7dd  PROTON-2126: Fix appveyor python usage

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .appveyor.yml      |  8 +++++---
 python/setup.py.in | 27 ++++++++++++++++++---------
 2 files changed, 23 insertions(+), 12 deletions(-)


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org


[qpid-proton] 02/02: PROTON-2126: Fix appveyor python usage

Posted by as...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

astitcher pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/qpid-proton.git

commit 5dae7dd21c61dd08fafbc0aab0fefa00b12f0a94
Author: Jiří Daněk <jd...@redhat.com>
AuthorDate: Mon Nov 4 12:51:49 2019 -0500

    PROTON-2126: Fix appveyor python usage
---
 .appveyor.yml | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/.appveyor.yml b/.appveyor.yml
index 116e881..6379955 100644
--- a/.appveyor.yml
+++ b/.appveyor.yml
@@ -1,6 +1,8 @@
 version: '{branch}.{build}'
 configuration: RelWithDebInfo
 environment:
+  PYTHON: C:\Python35\python.exe
+
   matrix:
     - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
       CMAKE_GENERATOR: Visual Studio 15
@@ -16,8 +18,8 @@ install:
 - vcpkg install jsoncpp:x86-windows
 - vcpkg install jsoncpp:x64-windows
 - vcpkg integrate install
-- pip install --user --upgrade pip
-- pip install --user setuptools tox
+- "%PYTHON% -m pip install --user --upgrade pip"
+- "%PYTHON% -m pip install --user --upgrade setuptools wheel tox"
 cache:
 - C:\ProgramData\chocolatey\bin -> .appveyor.yml
 - C:\ProgramData\chocolatey\lib -> .appveyor.yml
@@ -25,7 +27,7 @@ cache:
 before_build:
 - mkdir BLD
 - cd BLD
-- cmake %VCPKG_INTEGRATION% -G "%CMAKE_GENERATOR%" %QPID_PROTON_CMAKE_ARGS% ..
+- cmake %VCPKG_INTEGRATION% -G "%CMAKE_GENERATOR%" -DPYTHON_EXECUTABLE=%PYTHON% %QPID_PROTON_CMAKE_ARGS% ..
 - cd ..
 build:
   project: BLD/Proton.sln


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org


[qpid-proton] 01/02: PROTON-2126: Fix Python package building on windows - Due to a bug in the combination of CMake and MSbuild failing to detect cyrus-sasl on windows in the python setup.py was failing the windows build during 'python setup.py bdist_wheel'

Posted by as...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

astitcher pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/qpid-proton.git

commit 4a69c9ce2653ece427182f83c113091924eec9a2
Author: Jiří Daněk <jd...@redhat.com>
AuthorDate: Fri Nov 1 17:14:13 2019 -0400

    PROTON-2126: Fix Python package building on windows
    - Due to a bug in the combination of CMake and MSbuild failing
      to detect cyrus-sasl on windows in the python setup.py was failing
      the windows build during 'python setup.py bdist_wheel'
---
 python/setup.py.in | 27 ++++++++++++++++++---------
 1 file changed, 18 insertions(+), 9 deletions(-)

diff --git a/python/setup.py.in b/python/setup.py.in
index c5e1bbb..8d0445c 100644
--- a/python/setup.py.in
+++ b/python/setup.py.in
@@ -159,13 +159,21 @@ class Configure(build_ext):
         # implementations will be used.
         sources.append(os.path.join(proton_src, 'sasl', 'sasl.c'))
         sources.append(os.path.join(proton_src, 'sasl', 'default_sasl.c'))
-        if cc.has_function('sasl_client_done', includes=['sasl/sasl.h'],
-                           libraries=['sasl2']):
-            libraries.append('sasl2')
-            sources.append(os.path.join(proton_src, 'sasl', 'cyrus_sasl.c'))
+
+        # Skip the SASL detection on Windows.
+        # MSbuild scans output of Exec tasks and fails the build if it notices error-like
+        # strings there. This is a known issue with CMake and msbuild, see
+        # * https://github.com/Microsoft/msbuild/issues/2424
+        # * https://cmake.org/pipermail/cmake-developers/2015-October/026775.html
+        if cc.compiler_type!='msvc':
+            if cc.has_function('sasl_client_done', includes=['sasl/sasl.h'], libraries=['sasl2']):
+                libraries.append('sasl2')
+                sources.append(os.path.join(proton_src, 'sasl', 'cyrus_sasl.c'))
+            else:
+                log.warn("Cyrus SASL not installed - only the ANONYMOUS and PLAIN mechanisms will be supported!")
+                sources.append(os.path.join(proton_src, 'sasl', 'cyrus_stub.c'))
         else:
-            log.warn("Cyrus SASL not installed - only the ANONYMOUS and"
-                     " PLAIN mechanisms will be supported!")
+            log.warn("Windows - only the ANONYMOUS and PLAIN mechanisms will be supported!")
             sources.append(os.path.join(proton_src, 'sasl', 'cyrus_stub.c'))
 
         # Hack for Windows/msvc: We need to compile proton as C++, but it seems the only way to
@@ -175,9 +183,10 @@ class Configure(build_ext):
             targets = []
             target_base = os.path.join(self.build_temp, 'srcs')
             try:
-                os.mkdir(target_base)
-            except FileExistsError:
-	            pass
+                # Might need to make intermediate directories use os.makedirs() not os.mkdir()
+                os.makedirs(target_base)
+            except OSError:
+                pass
 
             for f in sources:
                 # We know each file ends in '.c' as we filtered on that above so just add 'pp' to end


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org