[pypy-svn] r78868 - pypy/trunk/pypy/translator/c
arigo at codespeak.net
arigo at codespeak.net
Mon Nov 8 13:54:40 CET 2010
Author: arigo
Date: Mon Nov 8 13:54:38 2010
New Revision: 78868
Modified:
pypy/trunk/pypy/translator/c/genc.py
Log:
Better support in the Makefile for Ctrl-C during make,
not leaving empty files behind.
Modified: pypy/trunk/pypy/translator/c/genc.py
==============================================================================
--- pypy/trunk/pypy/translator/c/genc.py (original)
+++ pypy/trunk/pypy/translator/c/genc.py Mon Nov 8 13:54:38 2010
@@ -623,9 +623,15 @@
mk.definition('OBJECTS', '$(ASMLBLFILES) gcmaptable.s')
mk.rule('%.s', '%.c', '$(CC) $(CFLAGS) $(CFLAGSEXTRA) -frandom-seed=$< -o $@ -S $< $(INCLUDEDIRS)')
mk.rule('%.lbl.s %.gcmap', '%.s',
- python + '$(PYPYDIR)/translator/c/gcc/trackgcroot.py -m$(PYPY_MAIN_FUNCTION) -t $< > $*.gcmap')
+ [python +
+ '$(PYPYDIR)/translator/c/gcc/trackgcroot.py '
+ '-m$(PYPY_MAIN_FUNCTION) -t $< > $*.gctmp',
+ 'mv $*.gctmp $*.gcmap'])
mk.rule('gcmaptable.s', '$(GCMAPFILES)',
- python + '$(PYPYDIR)/translator/c/gcc/trackgcroot.py $(GCMAPFILES) > $@')
+ [python +
+ '$(PYPYDIR)/translator/c/gcc/trackgcroot.py '
+ '$(GCMAPFILES) > $@.tmp',
+ 'mv $@.tmp $@'])
mk.rule('.PRECIOUS', '%.s', "# don't remove .s files if Ctrl-C'ed")
else:
More information about the Pypy-commit
mailing list