diff --git a/Allwmake b/Allwmake index 514b42e321..4886868523 100755 --- a/Allwmake +++ b/Allwmake @@ -68,19 +68,34 @@ src/Allwmake $targetType $* # OpenFOAM applications applications/Allwmake $targetType $* +#------------------------------------------------------------------------------ +# Additional components -# Additional components/modules case "$FOAM_MODULE_PREFIX" in (false | none) echo ======================================== echo "OpenFOAM modules disabled (prefix=${FOAM_MODULE_PREFIX})" + echo "Can be built separately:" + echo + echo " ./Allwmake-modules -prefix=..." + echo + echo ======================================== echo ;; (*) # Use wmake -all instead of Allwmake to allow for overrides ( cd "$WM_PROJECT_DIR/modules" 2>/dev/null && wmake -all ) + + echo ======================================== + echo "The optional plugins can be built separately:" + echo + echo " ./Allwmake-plugins -prefix=..." + echo + echo ======================================== + echo esac +#------------------------------------------------------------------------------ # Count files in given directory. Ignore "Test-*" binaries. _foamCountDirEntries() { diff --git a/Allwmake-modules b/Allwmake-modules new file mode 100755 index 0000000000..4a9dc1e022 --- /dev/null +++ b/Allwmake-modules @@ -0,0 +1,37 @@ +#!/bin/sh +# Run from OPENFOAM top-level directory only +cd "${0%/*}" || exit +wmake -check-dir "$WM_PROJECT_DIR" 2>/dev/null || { + echo "Error (${0##*/}) : not located in \$WM_PROJECT_DIR" + echo " Check your OpenFOAM environment and installation" + exit 1 +} +if [ -f "$WM_PROJECT_DIR"/wmake/scripts/AllwmakeParseArguments ] +then . "$WM_PROJECT_DIR"/wmake/scripts/AllwmakeParseArguments -no-recursion "$@" || \ + echo "Argument parse error" +else + echo "Error (${0##*/}) : WM_PROJECT_DIR appears to be incorrect" + echo " Check your OpenFOAM environment and installation" + exit 1 +fi + +#------------------------------------------------------------------------------ +# Additional components + +case "$FOAM_MODULE_PREFIX" in +(false | none) + echo ======================================== + echo "OpenFOAM modules disabled (prefix=${FOAM_MODULE_PREFIX})" + echo "Can be built separately:" + echo + echo " ./Allwmake-modules -prefix=..." + echo + echo ======================================== + echo + ;; +(*) + # Use wmake -all instead of Allwmake to allow for overrides + ( cd "$WM_PROJECT_DIR/modules" 2>/dev/null && wmake -all ) +esac + +#------------------------------------------------------------------------------ diff --git a/Allwmake-plugins b/Allwmake-plugins new file mode 100755 index 0000000000..c5aa93794c --- /dev/null +++ b/Allwmake-plugins @@ -0,0 +1,37 @@ +#!/bin/sh +# Run from OPENFOAM top-level directory only +cd "${0%/*}" || exit +wmake -check-dir "$WM_PROJECT_DIR" 2>/dev/null || { + echo "Error (${0##*/}) : not located in \$WM_PROJECT_DIR" + echo " Check your OpenFOAM environment and installation" + exit 1 +} +if [ -f "$WM_PROJECT_DIR"/wmake/scripts/AllwmakeParseArguments ] +then . "$WM_PROJECT_DIR"/wmake/scripts/AllwmakeParseArguments -no-recursion "$@" || \ + echo "Argument parse error" +else + echo "Error (${0##*/}) : WM_PROJECT_DIR appears to be incorrect" + echo " Check your OpenFOAM environment and installation" + exit 1 +fi + +#------------------------------------------------------------------------------ +# Additional components + +case "$FOAM_MODULE_PREFIX" in +(false | none) + echo ======================================== + echo "OpenFOAM plugins disabled (prefix=${FOAM_MODULE_PREFIX})" + echo "Can be built separately:" + echo + echo " ./Allwmake-plugins -prefix=..." + echo + echo ======================================== + echo + ;; +(*) + # Use wmake -all instead of Allwmake to allow for overrides + ( cd "$WM_PROJECT_DIR/plugins" 2>/dev/null && wmake -all ) +esac + +#------------------------------------------------------------------------------