diff --git a/Cantera/src/ct2ctml.cpp b/Cantera/src/ct2ctml.cpp index 3aa3a569f..443d500ea 100644 --- a/Cantera/src/ct2ctml.cpp +++ b/Cantera/src/ct2ctml.cpp @@ -151,7 +151,8 @@ namespace ctml { // then clean up by deleting the temporary Python file. #ifndef DEBUG_PATHS #ifdef WIN32 - cmd = "cmd /C rm " + path; + //cmd = "cmd /C rm " + path; + remove(path.c_str()) ; #else cmd = "rm -f " + path; try { diff --git a/Cantera/src/misc.cpp b/Cantera/src/misc.cpp index 239cdddf1..e7076292c 100755 --- a/Cantera/src/misc.cpp +++ b/Cantera/src/misc.cpp @@ -29,6 +29,10 @@ #undef DEBUG_PATHS #include +#ifdef WIN32 +#include +#include +#endif using namespace std; namespace Cantera { @@ -214,6 +218,11 @@ namespace Cantera { // so it is replaced by: path = findInputFile(file); // +#ifdef WIN32 + // RFB: For Windows make the path POSIX compliant so code looking for directory + // separators is simpler. Just look for '/' not both '/' and '\\' + replace_if( path.begin(), path.end(), bind2nd( equal_to(), '\\'), '/' ) ; +#endif string ff = path; if (app()->xmlfiles.find(path)