# HG changeset patch # User Adrian Buehlmann # Date 2015-05-14 09:04:35 # Node ID c1a9e31bec0f943eb547c7fcc13d4902218c4758 # Parent 637a15a8a4c15c1ccdd5928ea1eefe9d49d8b0f2 setup: move osutil_ldflags logic to before extmodules definition diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -484,6 +484,11 @@ pymodules = [] common_depends = ['mercurial/util.h'] +osutil_ldflags = [] + +if sys.platform == 'darwin': + osutil_ldflags += ['-framework', 'ApplicationServices'] + extmodules = [ Extension('mercurial.base85', ['mercurial/base85.c'], depends=common_depends), @@ -500,11 +505,6 @@ extmodules = [ depends=common_depends), ] -osutil_ldflags = [] - -if sys.platform == 'darwin': - osutil_ldflags += ['-framework', 'ApplicationServices'] - extmodules.append(Extension('mercurial.osutil', ['mercurial/osutil.c'], extra_link_args=osutil_ldflags, depends=common_depends))