Sophie

Sophie

distrib > Mageia > 1 > i586 > media > core-updates-src > by-pkgid > b850e5c583858315953a44a2c2fc9494 > files > 38

blender-2.49b-11.1.mga1.src.rpm

#!/bin/sh
#
# A wrapper script for Blender
#

# In case user's home directory doesn't contain ~/.blender, copy it
# from ${BLENDER_LIBDIR}/blender

export BLENDER_LIBDIR=SPECDEFINED

if [ ! -d ~/.blender ]; then
    install -d ~/.blender
    ln -sf /usr/share/locale ~/.blender
    ln -sf ${BLENDER_LIBDIR}/blender/.Blanguages ~/.blender
    ln -sf ${BLENDER_LIBDIR}/blender/.bfont.ttf ~/.blender
    cp -a ${BLENDER_LIBDIR}/blender/VERSION ~/.blender

    install -d ~/.blender/plugins/sequence
    install -d ~/.blender/plugins/texture
    if [ -d ${BLENDER_LIBDIR}/blender/bpydata ]; then
        cp -a ${BLENDER_LIBDIR}/blender/bpydata ~/.blender
       ln -sf ${BLENDER_LIBDIR}/blender/bpydata/config/* ~/.blender/bpydata/config/
    fi
    install -d ~/.blender/scripts
    ln -sf ${BLENDER_LIBDIR}/blender/scripts/* ~/.blender/scripts/
fi

# 
# In case the user's ~/.blender came from older versions, some files 
# should be reinstalled.
#

if [ $(cat ~/.blender/VERSION) != $(cat ${BLENDER_LIBDIR}/blender/VERSION) -o ${BLENDER_LIBDIR}/blender/scripts -nt ~/.blender/scripts ]; then
    if [ -d ${BLENDER_LIBDIR}/blender/bpydata ]; then
        cp -a ${BLENDER_LIBDIR}/blender/bpydata ~/.blender
    fi
    ln -sf ${BLENDER_LIBDIR}/blender/scripts/* ~/.blender/scripts/
    cp -a ${BLENDER_LIBDIR}/blender/VERSION ~/.blender
fi

TEMP=${TMP}

if [ "x${TEMP}" == x ]; then
    TEMP=${TMPDIR}
fi

export TEMP