view nodejs/run.sh @ 1094:613a7caa9bd6

Dynamic link libmbfly.so against nodejs plugin
author Thinker K.F. Li <thinker@codemud.net>
date Sat, 04 Dec 2010 12:40:04 +0800
parents 652199a55802
children bced6fe39856
line wrap: on
line source

#!/bin/sh

ABS=`realpath $0`
if [ -z "$SRCDIR" ]; then
    SRCDIR=`dirname $ABS`/..
fi
if [ -z "$BUILDDIR" ]; then
    BUILDDIR=`dirname $ABS`/..
fi

NODE_PATH=${BUILDDIR}/nodejs/objs/default:${SRCDIR}/nodejs:$NODE_PATH
export NODE_PATH

LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${BUILDDIR}/src/.libs/
export LD_LIBRARY_PATH

DIR=`dirname $1`
FNAME=`basename $1`

cd $DIR; node $FNAME