From: Barry Warsaw Date: Thu, 7 Apr 2011 14:40:36 +0000 (-0400) Subject: Refinement by Stefan Krah (see issue 11715, msg133194) to exit early if the X-Git-Tag: v3.2.1b1~167^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=88e194513e60853f7074d8f0fbca75d987a7a124;p=thirdparty%2FPython%2Fcpython.git Refinement by Stefan Krah (see issue 11715, msg133194) to exit early if the dpkg-architecture command is not found on $PATH. This should fix the failures on FreeBSD and Solaris, which do not create the target file via I/O redirection if the command isn't found (unlike Linux and OS X which do). --- diff --git a/setup.py b/setup.py index 29a002fa3916..1e15b7ae9cec 100644 --- a/setup.py +++ b/setup.py @@ -342,6 +342,8 @@ class PyBuildExt(build_ext): def add_multiarch_paths(self): # Debian/Ubuntu multiarch support. # https://wiki.ubuntu.com/MultiarchSpec + if not find_executable('dpkg-architecture'): + return tmpfile = os.path.join(self.build_temp, 'multiarch') if not os.path.exists(self.build_temp): os.makedirs(self.build_temp)