Rev 1583: Fix setup.py run with python2.4. in http://people.samba.org/bzr/jelmer/bzr-svn/trunk
Jelmer Vernooij
jelmer at samba.org
Thu Aug 21 14:01:24 BST 2008
At http://people.samba.org/bzr/jelmer/bzr-svn/trunk
------------------------------------------------------------
revno: 1583
revision-id: jelmer at samba.org-20080821130119-xlduoxq7oa8297q8
parent: jelmer at samba.org-20080821011937-xwau3ghehiqukktx
author: Mark Lee <launchpad-net at lazymalevolence.com>
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Thu 2008-08-21 15:01:19 +0200
message:
Fix setup.py run with python2.4.
modified:
NEWS news-20061231030336-h9fhq245ie0de8bs-1
setup.py setup.py-20060502115218-86950492da22353f
=== modified file 'NEWS'
--- a/NEWS 2008-08-09 03:04:16 +0000
+++ b/NEWS 2008-08-21 13:01:19 +0000
@@ -1,3 +1,9 @@
+bzr-svn-0.4.11 UNRELEASED
+
+ CHANGES
+
+ * Fix setup.py run with python2.4. (#256804)
+
bzr-svn 0.4.11~rc1 2008-08-08
CHANGES
=== modified file 'setup.py'
--- a/setup.py 2008-08-10 05:08:11 +0000
+++ b/setup.py 2008-08-21 13:01:19 +0000
@@ -29,13 +29,14 @@
"""Encapsulate exit status of apr-config execution"""
def __init__(self, msg, cmd, arg, status, val):
self.message = msg % (cmd, val)
- super(CommandException, self).__init__(self.message)
+ Exception.__init__(self, self.message)
self.cmd = cmd
self.arg = arg
self.status = status
def not_found(self):
return os.WIFEXITED(self.status) and os.WEXITSTATUS(self.status) == 127
+
def run_cmd(cmd, arg):
"""Run specified command with given arguments, handling status"""
f = os.popen("'%s' %s" % (cmd, arg))
@@ -56,6 +57,7 @@
raise CommandException("%s terminated abnormally (%d)",
cmd, arg, status, status)
+
def apr_config(arg):
apr_config_cmd = os.getenv("APR_CONFIG")
if apr_config_cmd is None:
@@ -76,6 +78,7 @@
res = run_cmd(apr_config_cmd, arg)
return res
+
def apr_build_data():
"""Determine the APR header file location."""
includedir = apr_config("--includedir")
@@ -84,6 +87,7 @@
ldflags = filter(lambda x: x != "", apr_config("--link-ld").split(" "))
return (includedir, ldflags)
+
def svn_build_data():
"""Determine the Subversion header file location."""
if "SVN_HEADER_PATH" in os.environ and "SVN_LIBRARY_PATH" in os.environ:
@@ -172,6 +176,7 @@
kwargs["define_macros"] = [("WIN32", None)]
return Extension("bzrlib.plugins.svn.%s" % name, *args, **kwargs)
+
# On Windows, we install the apr binaries too.
class install_lib_with_dlls(install_lib):
def _get_dlls(self):
More information about the bazaar-commits
mailing list