Skip to content
Browse files

create phony rules for all binaries

  • Loading branch information...
1 parent 449b620 commit 356f31abb92c87b3fa32700d3b44e49f1321cdb2 @martine martine committed
Showing with 3 additions and 5 deletions.
  1. +3 −5 configure.py
View
8 configure.py
@@ -97,7 +97,9 @@ def cxx(name, **kwargs):
return n.build(built(name + objext), 'cxx', src(name + '.cc'), **kwargs)
def binary(name):
if platform in ('mingw', 'windows'):
- return name + '.exe'
+ exe = name + '.exe'
+ n.build(name, 'phony', exe)
+ return exe
return name
n.variable('builddir', 'build')
@@ -277,8 +279,6 @@ def shell_escape(str):
objs = cxx('ninja')
ninja = n.build(binary('ninja'), 'link', objs, implicit=ninja_lib,
variables=[('libs', libs)])
-if 'ninja' not in ninja:
- n.build('ninja', 'phony', ninja)
n.newline()
all_targets += ninja
@@ -334,8 +334,6 @@ def shell_escape(str):
ninja_test = n.build(binary('ninja_test'), 'link', objs, implicit=ninja_lib,
variables=[('ldflags', test_ldflags),
('libs', test_libs)])
-if 'ninja_test' not in ninja_test:
- n.build('ninja_test', 'phony', ninja_test)
n.newline()
all_targets += ninja_test

0 comments on commit 356f31a

Please sign in to comment.
Something went wrong with that request. Please try again.