diff --git a/applications/solvers/multiphase/MPPICInterFoam/Allwmake b/applications/solvers/multiphase/MPPICInterFoam/Allwmake index 6e71a313cc..7b128ad2e6 100755 --- a/applications/solvers/multiphase/MPPICInterFoam/Allwmake +++ b/applications/solvers/multiphase/MPPICInterFoam/Allwmake @@ -3,7 +3,7 @@ cd ${0%/*} || exit 1 # Run from this directory #------------------------------------------------------------------------------ -wmake libso CompressibleTwoPhaseMixtureTurbulenceModels -wmake +wmake $targetType CompressibleTwoPhaseMixtureTurbulenceModels +wmake $targetType #------------------------------------------------------------------------------ diff --git a/applications/solvers/multiphase/interCondensatingEvaporatingFoam/Allwmake b/applications/solvers/multiphase/interCondensatingEvaporatingFoam/Allwmake index e64b0d1285..bb5db1b94f 100755 --- a/applications/solvers/multiphase/interCondensatingEvaporatingFoam/Allwmake +++ b/applications/solvers/multiphase/interCondensatingEvaporatingFoam/Allwmake @@ -1,11 +1,10 @@ #!/bin/sh cd ${0%/*} || exit 1 # Run from this directory -targetType=libso # Preferred library type . $WM_PROJECT_DIR/wmake/scripts/AllwmakeParseArguments #------------------------------------------------------------------------------ wmake $targetType temperaturePhaseChangeTwoPhaseMixtures -wmake +wmake $targetType #------------------------------------------------------------------------------ diff --git a/applications/utilities/mesh/generation/foamyMesh/Allwmake b/applications/utilities/mesh/generation/foamyMesh/Allwmake index 3dc79feaf8..beef89b54a 100755 --- a/applications/utilities/mesh/generation/foamyMesh/Allwmake +++ b/applications/utilities/mesh/generation/foamyMesh/Allwmake @@ -12,8 +12,8 @@ if have_cgal then wmake $targetType conformalVoronoiMesh wmake $targetType conformalVoronoi2DMesh - wmake foamyQuadMesh - wmake foamyHexMesh + wmake $targetType foamyQuadMesh + wmake $targetType foamyHexMesh # wmake foamyHexMeshBackgroundMesh # (cd foamyHexMeshSurfaceSimplify && ./Allwmake) # wmake cellSizeAndAlignmentGrid diff --git a/applications/utilities/parallelProcessing/decomposePar/decomposePar.C b/applications/utilities/parallelProcessing/decomposePar/decomposePar.C index fa0dd946bd..b14da4cca1 100644 --- a/applications/utilities/parallelProcessing/decomposePar/decomposePar.C +++ b/applications/utilities/parallelProcessing/decomposePar/decomposePar.C @@ -356,6 +356,9 @@ int main(int argc, char *argv[]) ) ); + // Give file handler a chance to determine the output directory + const_cast(fileHandler()).setNProcs(nDomains); + if (decomposeFieldsOnly) { // Sanity check on previously decomposed case @@ -395,22 +398,42 @@ int main(int argc, char *argv[]) Info<< "Removing " << nProcs << " existing processor directories" << endl; - fileHandler().rmDir + // Remove existing processors directory + fileNameList dirs ( - runTime.path()/word("processors"), - true // silent (may not have been collated) - ); - - // remove existing processor dirs - // reverse order to avoid gaps if someone interrupts the process - for (label proci = nProcs-1; proci >= 0; --proci) - { - fileName procDir + fileHandler().readDir ( - runTime.path()/(word("processor") + name(proci)) - ); + runTime.path(), + fileName::Type::DIRECTORY + ) + ); + forAllReverse(dirs, diri) + { + const fileName& d = dirs[diri]; - fileHandler().rmDir(procDir); + // Starts with 'processors' + if (d.find("processors") == 0) + { + if (fileHandler().exists(d)) + { + fileHandler().rmDir(d); + } + } + + // Starts with 'processor' + if (d.find("processor") == 0) + { + // Check that integer after processor + fileName num(d.substr(9)); + label proci = -1; + if (Foam::read(num.c_str(), proci)) + { + if (fileHandler().exists(d)) + { + fileHandler().rmDir(d); + } + } + } } procDirsProblem = false; diff --git a/applications/utilities/parallelProcessing/reconstructPar/reconstructPar.C b/applications/utilities/parallelProcessing/reconstructPar/reconstructPar.C index c8ab33cfa2..d807c19223 100644 --- a/applications/utilities/parallelProcessing/reconstructPar/reconstructPar.C +++ b/applications/utilities/parallelProcessing/reconstructPar/reconstructPar.C @@ -216,6 +216,9 @@ int main(int argc, char *argv[]) << exit(FatalError); } + // Warn fileHandler of number of processors + const_cast(fileHandler()).setNProcs(nProcs); + // Create the processor databases PtrList