Index: /issm/trunk-jpl/src/modules/EnumToString/EnumToString.cpp
===================================================================
--- /issm/trunk-jpl/src/modules/EnumToString/EnumToString.cpp	(revision 13033)
+++ /issm/trunk-jpl/src/modules/EnumToString/EnumToString.cpp	(revision 13034)
@@ -5,13 +5,14 @@
 #include "./EnumToString.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+WRAPPER(EnumToString){
 
 	char    *name    = NULL;
 	int      enum_in;
 
-	/*checks on arguments on the matlab side: */
-	if(nrhs!=NRHS){
-		EnumToStringUsage(); _error2_("usage. See above");
-	}
+	/*Boot module: */
+	MODULEBOOT();
+
+	/*checks on arguments: */
+	CHECKARGUMENTS(NLHS,NRHS,&EnumToStringUsage);
 
 	/*Fetch inputs: */
@@ -23,4 +24,7 @@
 	/* output: */
 	WriteData(NAME,name);
+
+	/*end module: */
+	MODULEEND();
 }
 
Index: /issm/trunk-jpl/src/modules/EnumToString/EnumToString.h
===================================================================
--- /issm/trunk-jpl/src/modules/EnumToString/EnumToString.h	(revision 13033)
+++ /issm/trunk-jpl/src/modules/EnumToString/EnumToString.h	(revision 13034)
@@ -6,7 +6,16 @@
 #define _ENUMTOSTRING_H
 
-/* local prototypes: */
-void EnumToStringUsage(void);
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#else
+#error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
+#endif
 
+/*Very important definition in case we are compiling a python module!: needs to come before header files inclusion*/
+#ifdef _HAVE_PYTHON_
+#define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
+#endif
+
+/*Header files: */
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
@@ -15,9 +24,17 @@
 #include "../../c/issm-binding.h"
     
+#ifdef _HAVE_MATLAB_MODULES_
 /* serial input macros: */
 #define ENUMIN (mxArray*)prhs[0]
-
 /* serial output macros: */
 #define NAME (mxArray**)&plhs[0]
+#endif
+
+#ifdef _HAVE_PYTHON_MODULES_
+/* serial input macros: */
+#define ENUMIN PyTuple_GetItem(args,0)
+/* serial output macros: */
+#define NAME output,0
+#endif
 
 /* serial arg counts: */
@@ -30,3 +47,6 @@
 #define __FUNCT__  "EnumToString"
 
+/* local prototypes: */
+void EnumToStringUsage(void);
+
 #endif  /* _TEST_H */
Index: /issm/trunk-jpl/src/modules/StringToEnum/StringToEnum.cpp
===================================================================
--- /issm/trunk-jpl/src/modules/StringToEnum/StringToEnum.cpp	(revision 13033)
+++ /issm/trunk-jpl/src/modules/StringToEnum/StringToEnum.cpp	(revision 13034)
@@ -5,13 +5,14 @@
 #include "./StringToEnum.h"
 
-void mexFunction( int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]){
+WRAPPER(StringToEnum){
 
 	char    *name    = NULL;
 	int      enum_out;
 
-	/*checks on arguments on the matlab side: */
-	if(nrhs!=NRHS){
-		StringToEnumUsage(); _error2_("usage. See above");
-	}
+	/*Boot module: */
+	MODULEBOOT();
+
+	/*checks on arguments: */
+	CHECKARGUMENTS(NLHS,NRHS,&StringToEnumUsage);
 
 	/*Fetch inputs: */
@@ -23,4 +24,7 @@
 	/* output: */
 	WriteData(ENUMOUT,enum_out);
+
+	/*end module: */
+	MODULEEND();
 }
 
Index: /issm/trunk-jpl/src/modules/StringToEnum/StringToEnum.h
===================================================================
--- /issm/trunk-jpl/src/modules/StringToEnum/StringToEnum.h	(revision 13033)
+++ /issm/trunk-jpl/src/modules/StringToEnum/StringToEnum.h	(revision 13034)
@@ -6,7 +6,16 @@
 #define _STRINGTOENUM_H
 
-/* local prototypes: */
-void StringToEnumUsage(void);
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#else
+#error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
+#endif
 
+/*Very important definition in case we are compiling a python module!: needs to come before header files inclusion*/
+#ifdef _HAVE_PYTHON_
+#define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
+#endif
+
+/*Header files: */
 #include "../../c/include/globals.h"
 #include "../../c/modules/modules.h"
@@ -15,9 +24,17 @@
 #include "../../c/issm-binding.h"
     
+#ifdef _HAVE_MATLAB_MODULES_
 /* serial input macros: */
 #define NAME (mxArray*)prhs[0]
-
 /* serial output macros: */
 #define ENUMOUT (mxArray**)&plhs[0]
+#endif
+
+#ifdef _HAVE_PYTHON_MODULES_
+/* serial input macros: */
+#define NAME PyTuple_GetItem(args,0)
+/* serial output macros: */
+#define ENUMOUT output,0
+#endif
 
 /* serial arg counts: */
@@ -30,3 +47,6 @@
 #define __FUNCT__  "StringToEnum"
 
+/* local prototypes: */
+void StringToEnumUsage(void);
+
 #endif  /* _TEST_H */
