 +}
 +
 +NINJA_BASE = """\
-+# Rules run in subdirectories but expect to be able to reach out to
-+# builddir, so use an absolute path.
-+builddir = %(cwd)s/ninja/
++builddir = $root/ninja
 +
 +cc = gcc
 +cxx = g++

+    print >>master_ninja, 'subninja', ninja
+
+  if all_outputs:
+    print >>master_ninja, 'build all: phony ' + ' '.join(all_outputs)
+
+  master_ninja.close()
+  OverPrint('done.\n')

+
+rule stamp
+  description = STAMP $out
+  command = touch $out
+
+""" % {
