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
diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in
index 10e5bdd..7137a68 100644
--- a/Examples/test-suite/errors/Makefile.in
+++ b/Examples/test-suite/errors/Makefile.in
@@ -45,6 +45,11 @@
 # 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 @@
 # 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:
diff --git a/Examples/test-suite/errors/cpp_extra_brackets.i b/Examples/test-suite/errors/cpp_extra_brackets.i
index 32cf7f7..81fdb29 100644
--- a/Examples/test-suite/errors/cpp_extra_brackets.i
+++ b/Examples/test-suite/errors/cpp_extra_brackets.i
@@ -1,4 +1,4 @@
-%module cpp_extra_brackets
+%module xxx
 
 // Extra brackets was segfaulting in SWIG-3.0.0
 struct ABC {
diff --git a/Examples/test-suite/errors/cpp_extra_brackets2.i b/Examples/test-suite/errors/cpp_extra_brackets2.i
index 17a5d59..194dea4 100644
--- a/Examples/test-suite/errors/cpp_extra_brackets2.i
+++ b/Examples/test-suite/errors/cpp_extra_brackets2.i
@@ -1,4 +1,4 @@
-%module cpp_extra_brackets
+%module xxx
 
 // Extra brackets was segfaulting in SWIG-3.0.0
 struct ABC {
diff --git a/Examples/test-suite/errors/cpp_invalid_qualifiers.i b/Examples/test-suite/errors/cpp_invalid_qualifiers.i
index fd3b363..d0723df 100644
--- a/Examples/test-suite/errors/cpp_invalid_qualifiers.i
+++ b/Examples/test-suite/errors/cpp_invalid_qualifiers.i
@@ -1,4 +1,4 @@
-%module cpp_invalid_qualifiers
+%module xxx
 
 // Constructors, destructors and static methods cannot have qualifiers
 struct A {
diff --git a/Examples/test-suite/errors/cpp_invalid_template.i b/Examples/test-suite/errors/cpp_invalid_template.i
index ea0d7be..45ad739 100644
--- a/Examples/test-suite/errors/cpp_invalid_template.i
+++ b/Examples/test-suite/errors/cpp_invalid_template.i
@@ -1,4 +1,4 @@
-%module cpp_invalid_scope
+%module xxx
 
 %template(abc) SSS::AAA<int>;
 
diff --git a/Examples/test-suite/errors/cpp_namespace_template_bad.i b/Examples/test-suite/errors/cpp_namespace_template_bad.i
index 5c42d6d..f41918f 100644
--- a/Examples/test-suite/errors/cpp_namespace_template_bad.i
+++ b/Examples/test-suite/errors/cpp_namespace_template_bad.i
@@ -1,4 +1,4 @@
-%module namespace_template
+%module xxx
 
 namespace test {
   template<typename T> T max(T a, T b) { return (a > b) ? a : b; }
diff --git a/Examples/test-suite/errors/cpp_nested_namespace_alias.i b/Examples/test-suite/errors/cpp_nested_namespace_alias.i
index b7cbceb..058d344 100644
--- a/Examples/test-suite/errors/cpp_nested_namespace_alias.i
+++ b/Examples/test-suite/errors/cpp_nested_namespace_alias.i
@@ -1,4 +1,4 @@
-%module cpp_nested_namespace_alias
+%module xxx
 
 // C++17 nested namespaces
 
diff --git a/Examples/test-suite/errors/cpp_recursive_typedef.i b/Examples/test-suite/errors/cpp_recursive_typedef.i
index 3d65a88..82d9f7a 100644
--- a/Examples/test-suite/errors/cpp_recursive_typedef.i
+++ b/Examples/test-suite/errors/cpp_recursive_typedef.i
@@ -1,4 +1,4 @@
-%module cpp_recursive_typedef
+%module xxx
 
 typedef std::set<pds> pds;
 
diff --git a/Examples/test-suite/errors/cpp_refqualifier.i b/Examples/test-suite/errors/cpp_refqualifier.i
index afd6632..3980a81 100644
--- a/Examples/test-suite/errors/cpp_refqualifier.i
+++ b/Examples/test-suite/errors/cpp_refqualifier.i
@@ -1,4 +1,4 @@
-%module cpp_refqualifier
+%module xxx
 
 %ignore Host::h_ignored;
 %ignore Host::i_ignored() &&;
diff --git a/Examples/test-suite/errors/cpp_shared_ptr.i b/Examples/test-suite/errors/cpp_shared_ptr.i
index edbd0cf..bdcd30f 100644
--- a/Examples/test-suite/errors/cpp_shared_ptr.i
+++ b/Examples/test-suite/errors/cpp_shared_ptr.i
@@ -1,4 +1,4 @@
-%module cpp_shared_ptr
+%module xxx
 
 %include <boost_shared_ptr.i>
 
diff --git a/Examples/test-suite/errors/cpp_template_duplicate_names.i b/Examples/test-suite/errors/cpp_template_duplicate_names.i
index 67f21d7..9607696 100644
--- a/Examples/test-suite/errors/cpp_template_duplicate_names.i
+++ b/Examples/test-suite/errors/cpp_template_duplicate_names.i
@@ -1,4 +1,4 @@
-%module cpp_template_duplicate_names
+%module xxx
 
 // From test-suite/template_class_reuse.i test
 
diff --git a/Examples/test-suite/errors/cpp_template_friend.i b/Examples/test-suite/errors/cpp_template_friend.i
index c9d1c9d..3b8d85e 100644
--- a/Examples/test-suite/errors/cpp_template_friend.i
+++ b/Examples/test-suite/errors/cpp_template_friend.i
@@ -1,4 +1,4 @@
-%module cpp_template_friend
+%module xxx
 
 template<typename T> T template_friend1(T);
 template<typename T> T template_friend1(T);
diff --git a/Examples/test-suite/errors/pp_missing_file.i b/Examples/test-suite/errors/pp_missing_file.i
index 5e3f0ea..366f159 100644
--- a/Examples/test-suite/errors/pp_missing_file.i
+++ b/Examples/test-suite/errors/pp_missing_file.i
@@ -1,3 +1,3 @@
-%module test
+%module xxx
 
 %include "missing_filename.i"