Allwmake 1.2 KB
Newer Older
1
#!/bin/sh
2 3 4 5
cd ${0%/*} || exit 1                                # Run from this directory
export WM_CONTINUE_ON_ERROR=true                    # Optional unit
. ${WM_PROJECT_DIR:?}/wmake/scripts/AllwmakeParseArguments
. ${WM_PROJECT_DIR:?}/wmake/scripts/paraviewFunctions # CMake, PV functions
6
# -----------------------------------------------------------------------------
7

8 9 10 11 12 13 14
warnIncomplete()
{
    echo
    echo "    WARNING: incomplete build of ParaView plugin: $@"
    echo
}

Mark Olesen's avatar
Mark Olesen committed
15 16 17 18
if have_pvplugin_support
then
(
    wmakeLibPv foamPv
19 20 21
    wmakeLibPv blockMeshReader/library
    wmakeLibPv foamReader/library

22
    unset cmakeOpts cmakeType
23

Mark Olesen's avatar
Mark Olesen committed
24
    if [ "$targetType" != objects ]
25
    then
26 27 28 29 30 31 32 33 34 35 36 37 38
        case "$PARAVIEW_API" in
        (5.[0-6])
            cmakeType="cmakePv"
            ;;
        (*)
            # cmakeType="cmakePvInstall"
            warnIncomplete "(unknown/unsupported version: $PARAVIEW_API)"
            ;;
        esac
    fi

    if [ -n "$cmakeType" ]
    then
39 40
        "$cmakeType" $PWD/blockMeshReader "$cmakeOpts" || warnIncomplete "blockMesh"
        "$cmakeType" $PWD/foamReader "$cmakeOpts" || warnIncomplete "OpenFOAM"
41
    fi
Mark Olesen's avatar
Mark Olesen committed
42 43
)
fi
44

45
#------------------------------------------------------------------------------