mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: missing chdir in Allwclean for wallFunctionTable
STYLE: improve consistency in Allwclean scripts
This commit is contained in:
@ -1,7 +1,8 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
cd ${0%/*} || exit 1 # Run from this directory
|
||||||
cd ${0%/*} || exit 1
|
|
||||||
|
|
||||||
wclean libso DPMTurbulenceModels
|
wclean libso DPMTurbulenceModels
|
||||||
wclean
|
wclean
|
||||||
wclean MPPICFoam
|
wclean MPPICFoam
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -8,3 +8,5 @@ wmake $targetType DPMTurbulenceModels
|
|||||||
|
|
||||||
wmake $targetType
|
wmake $targetType
|
||||||
wmake $targetType MPPICFoam
|
wmake $targetType MPPICFoam
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
cd ${0%/*} || exit 1 # run from this directory
|
cd ${0%/*} || exit 1 # Run from this directory
|
||||||
|
|
||||||
wclean libso CompressibleTwoPhaseMixtureTurbulenceModels
|
wclean libso CompressibleTwoPhaseMixtureTurbulenceModels
|
||||||
wclean
|
wclean
|
||||||
|
|||||||
@ -4,5 +4,4 @@ cd ${0%/*} || exit 1 # Run from this directory
|
|||||||
wclean libso helpTypes
|
wclean libso helpTypes
|
||||||
wclean
|
wclean
|
||||||
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -5,7 +5,4 @@ wclean libso foamPv
|
|||||||
PVblockMeshReader/Allwclean
|
PVblockMeshReader/Allwclean
|
||||||
PVFoamReader/Allwclean
|
PVFoamReader/Allwclean
|
||||||
|
|
||||||
# remove dummy directory (see Allwmake)
|
|
||||||
rmdir Make 2>/dev/null
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -24,10 +24,6 @@ case "$major" in
|
|||||||
wmakeLibPv foamPv
|
wmakeLibPv foamPv
|
||||||
PVblockMeshReader/Allwmake $targetType $*
|
PVblockMeshReader/Allwmake $targetType $*
|
||||||
PVFoamReader/Allwmake $targetType $*
|
PVFoamReader/Allwmake $targetType $*
|
||||||
|
|
||||||
# Dummy directory to trigger proper 'wclean all' behaviour
|
|
||||||
# - the Allwclean will otherwise not be used
|
|
||||||
mkdir -p Make
|
|
||||||
)
|
)
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
|
|||||||
@ -1,5 +1,7 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
cd ${0%/*} || exit 1 # Run from this directory
|
||||||
|
|
||||||
wclean libso tabulatedWallFunction
|
wclean libso tabulatedWallFunction
|
||||||
wclean
|
wclean
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -1,26 +1,23 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
cd ${0%/*} || exit 1 # Run from this directory
|
cd ${0%/*} || exit 1 # Run from this directory
|
||||||
|
|
||||||
# Define how an mpi-versioned library is created
|
# Clean an mpi-versioned library
|
||||||
# clean the qualified directory
|
|
||||||
wcleanMpiLib()
|
wcleanMpiLib()
|
||||||
{
|
{
|
||||||
for libName
|
case "$WM_MPLIB" in (*MPI*)
|
||||||
do
|
|
||||||
(
|
(
|
||||||
WM_OPTIONS="$WM_OPTIONS$WM_MPLIB"
|
WM_OPTIONS="$WM_OPTIONS$WM_MPLIB"
|
||||||
|
for libName
|
||||||
|
do
|
||||||
wclean $libName
|
wclean $libName
|
||||||
)
|
|
||||||
done
|
done
|
||||||
|
)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
wclean dummy
|
wclean dummy
|
||||||
|
wcleanMpiLib mpi
|
||||||
case "$WM_MPLIB" in
|
|
||||||
*MPI*)
|
|
||||||
wcleanMpiLib mpi
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -1,44 +1,26 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
cd ${0%/*} || exit 1 # Run from this directory
|
cd ${0%/*} || exit 1 # Run from this directory
|
||||||
|
|
||||||
# get SCOTCH_VERSION, SCOTCH_ARCH_PATH
|
# Clean an mpi-versioned library
|
||||||
if settings=`$WM_PROJECT_DIR/bin/foamEtcFile config.sh/scotch`
|
|
||||||
then
|
|
||||||
. $settings
|
|
||||||
echo " using SCOTCH_ARCH_PATH=$SCOTCH_ARCH_PATH"
|
|
||||||
else
|
|
||||||
echo
|
|
||||||
echo " Error: no config.sh/scotch settings"
|
|
||||||
echo
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
# Define how to clean an mpi-versioned library
|
|
||||||
wcleanMpiLib()
|
wcleanMpiLib()
|
||||||
{
|
{
|
||||||
for libName
|
case "$WM_MPLIB" in (*MPI*)
|
||||||
do
|
|
||||||
(
|
(
|
||||||
WM_OPTIONS="$WM_OPTIONS$WM_MPLIB"
|
WM_OPTIONS="$WM_OPTIONS$WM_MPLIB"
|
||||||
|
for libName
|
||||||
|
do
|
||||||
wclean $libName
|
wclean $libName
|
||||||
)
|
|
||||||
done
|
done
|
||||||
|
)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
if [ -n "$SCOTCH_ARCH_PATH" ]
|
|
||||||
then
|
|
||||||
wclean scotchDecomp
|
|
||||||
|
|
||||||
if [ -d "$FOAM_LIBBIN/$FOAM_MPI" ]
|
|
||||||
then
|
|
||||||
wcleanMpiLib ptscotchDecomp
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo " skipping scotchDecomp (ptscotchDecomp)"
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
wclean scotchDecomp
|
||||||
wclean metisDecomp
|
wclean metisDecomp
|
||||||
wclean decompositionMethods
|
wclean decompositionMethods
|
||||||
wclean decompose
|
wclean decompose
|
||||||
|
wcleanMpiLib ptscotchDecomp
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -1,11 +1,10 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
cd ${0%/*} || exit 1 # Run from this directory
|
cd ${0%/*} || exit 1 # Run from this directory
|
||||||
makeType=${1:-libso}
|
|
||||||
|
|
||||||
wclean $makeType regionModel
|
wclean libso regionModel
|
||||||
wclean $makeType pyrolysisModels
|
wclean libso pyrolysisModels
|
||||||
wclean $makeType surfaceFilmModels
|
wclean libso surfaceFilmModels
|
||||||
wclean $makeType thermalBaffleModels
|
wclean libso thermalBaffleModels
|
||||||
wclean $makeType regionCoupling
|
wclean libso regionCoupling
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
13
wmake/wclean
13
wmake/wclean
@ -128,8 +128,8 @@ then
|
|||||||
}
|
}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Print command
|
# Print command, trim off leading './' for readability
|
||||||
echo "$Script $targetType${targetType:+ }${dir:-.}"
|
echo "$Script $targetType${targetType:+ }${dir#./}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
@ -152,19 +152,18 @@ then
|
|||||||
echo "Removing empty directories..."
|
echo "Removing empty directories..."
|
||||||
|
|
||||||
# Get sub-directories avoiding particular directories
|
# Get sub-directories avoiding particular directories
|
||||||
for dir in $(find . -mindepth 1 -maxdepth 1 \
|
for d in $(find . -mindepth 1 -maxdepth 1 \
|
||||||
-name .git -prune -o -type d -print)
|
-name .git -prune -o -type d -print)
|
||||||
do
|
do
|
||||||
echo " searching: $dir"
|
echo " searching: ${d#./}"
|
||||||
find $dir -depth -empty -type d -delete -print
|
find $d -depth -empty -type d -delete -print
|
||||||
done
|
done
|
||||||
|
|
||||||
# Second pass: clean up object directories with WM_PROJECT_DIR that don't
|
# Second pass: clean up object directories with WM_PROJECT_DIR that don't
|
||||||
# have respective source code folders, along with the respective binaries
|
# have respective source code folders, along with the respective binaries
|
||||||
|
|
||||||
if [ "$(expandPath $PWD)" = "$WM_PROJECT_DIR" ]
|
if [ "$(expandPath $PWD)" = "$WM_PROJECT_DIR" ]
|
||||||
then
|
then
|
||||||
objectsDir=$(findObjectDir $PWD) || exit 1 # Fatal
|
objectsDir=$(findObjectDir $PWD 2>/dev/null) || exit 1 # Fatal
|
||||||
|
|
||||||
if [ -d "$objectsDir" ]
|
if [ -d "$objectsDir" ]
|
||||||
then
|
then
|
||||||
|
|||||||
Reference in New Issue
Block a user