The errors testcases use -module to obtain a unique module name
Fixes parallel make where each invocation of swig was writing and deleting the same file resulting in lots of the newly introduced warning messages: On exit, could not delete file xxx.py: No such file or directory
This commit is contained in:
parent
2cf075558c
commit
0d76eb3b56
13 changed files with 19 additions and 14 deletions
|
|
@ -45,6 +45,11 @@ include $(srcdir)/../common.mk
|
|||
# whatever we do here.
|
||||
$(DOXYGEN_ERROR_TEST_CASES): SWIGOPT += -doxygen
|
||||
|
||||
# Unique module names are obtained from the .i file name (required for parallel make).
|
||||
# Note: -module overrides %module in the .i file.
|
||||
MODULE_OPTION=-module $*
|
||||
nomodule.ctest: MODULE_OPTION =
|
||||
|
||||
# Portable dos2unix / todos for stripping CR
|
||||
TODOS = tr -d '\r'
|
||||
#TODOS = sed -e 's/\r$$//' # On Mac OS X behaves as if written 's/r$$//'
|
||||
|
|
@ -55,12 +60,12 @@ STRIP_SRCDIR = sed -e 's|\\|/|g' -e 's|^$(SRCDIR)||'
|
|||
# Rules for the different types of tests
|
||||
%.cpptest:
|
||||
echo "$(ACTION)ing errors testcase $*"
|
||||
-$(SWIGINVOKE) -c++ -python -Wall -Fstandard $(SWIGOPT) $(SRCDIR)$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT)
|
||||
-$(SWIGINVOKE) -c++ -python -Wall -Fstandard $(MODULE_OPTION) $(SWIGOPT) $(SRCDIR)$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT)
|
||||
$(COMPILETOOL) diff -c $(SRCDIR)$*.stderr $*.$(ERROR_EXT)
|
||||
|
||||
%.ctest:
|
||||
echo "$(ACTION)ing errors testcase $*"
|
||||
-$(SWIGINVOKE) -python -Wall -Fstandard $(SWIGOPT) $(SRCDIR)$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT)
|
||||
-$(SWIGINVOKE) -python -Wall -Fstandard $(MODULE_OPTION) $(SWIGOPT) $(SRCDIR)$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT)
|
||||
$(COMPILETOOL) diff -c $(SRCDIR)$*.stderr $*.$(ERROR_EXT)
|
||||
|
||||
%.clean:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue