Patchwork [1,of,5,stable,osx-packaging,v2] hghave: add check for bdist_mpkg

login
register
mail settings
Submitter Augie Fackler
Date April 27, 2016, 3:45 p.m.
Message ID <1d2e15aa68f73659a3f4.1461771951@augie-macbookair2.roam.corp.google.com>
Download mbox | patch
Permalink /patch/14804/
State Superseded
Commit d78e00e4be7cd32ae972188daf823c4443f5a62d
Headers show

Comments

Augie Fackler - April 27, 2016, 3:45 p.m.
# HG changeset patch
# User Augie Fackler <augie@google.com>
# Date 1461038158 14400
#      Mon Apr 18 23:55:58 2016 -0400
# Branch stable
# Node ID 1d2e15aa68f73659a3f45907e2e035c5a3dc053b
# Parent  87d4a6c5567e81386b8c2209d95060d5bf72e064
hghave: add check for bdist_mpkg

Patch

diff --git a/tests/hghave.py b/tests/hghave.py
--- a/tests/hghave.py
+++ b/tests/hghave.py
@@ -456,6 +456,14 @@  def has_aix():
 def has_osx():
     return sys.platform == 'darwin'
 
+@check("bdistmpkg", "bdist_mpkg Python Package")
+def has_bdistmpkg():
+    try:
+        import bdist_mpkg.script_bdist_mpkg
+        return True
+    except ImportError:
+        return False
+
 @check("docker", "docker support")
 def has_docker():
     pat = r'A self-sufficient runtime for'