]> jfr.im git - irc/quakenet/qwebirc.git/blobdiff - bin/dependencies_b.py
pixel perfect!
[irc/quakenet/qwebirc.git] / bin / dependencies_b.py
index e5ecda5f4c9837398e9cfe757bfcde7b42b4f9f0..66a26de7e827e5603f10435cbc02a0305e63d767 100644 (file)
@@ -15,6 +15,7 @@ def check_dependencies():
   i = 0\r
   \r
   check_twisted()\r
+  check_zope()\r
   check_win32()\r
   i+=check_json()\r
   i+=check_java()\r
@@ -44,7 +45,7 @@ def check_java():
     warn(specific, "java is not required, but allows qwebirc to compress output,", "making it faster to download.", "you can get java at http://www.java.com/")\r
     \r
   try:\r
-    p = subprocess.Popen(["java", "-version"], stdout=subprocess.PIPE, stderr=subprocess.PIPE)\r
+    p = subprocess.Popen(["java", "-version"], stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=os.name == "nt")\r
     p.communicate()\r
     if p.wait() != 0:\r
       java_warn("something went wrong looking for java.")\r
@@ -60,7 +61,7 @@ def check_hg():
     warn(specific, "mercurial (hg) is not required, but allows qwebirc to save bandwidth by versioning.", "you can get hg at http://www.selenic.com/mercurial/")\r
     \r
   try:\r
-    p = subprocess.Popen(["hg", "id"], stdout=subprocess.PIPE, stderr=subprocess.PIPE)\r
+    p = subprocess.Popen(["hg", "id"], stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=os.name == "nt")\r
     p.communicate()\r
     if p.wait() != 0:\r
       hg_warn("something went wrong looking for mercurial.")\r
@@ -71,6 +72,18 @@ def check_hg():
     \r
   return 0\r
   \r
+def check_zope():\r
+  try:\r
+    from zope.interface import Interface\r
+  except ImportError:\r
+    if sys.platform.startswith("win"):\r
+      fail("qwebirc requires zope interface",\r
+           "see pypi: http://pypi.python.org/pypi/zope.interface")\r
+    else:\r
+      fail("qwebirc requires zope interface.",\r
+           "this should normally come with twisted, but can be downloaded",\r
+           "from pypi: http://pypi.python.org/pypi/zope.interface")\r
+           \r
 def check_twisted():\r
   try:\r
     import twisted\r