summaryrefslogtreecommitdiff
path: root/tools/linux_packaging/noderun
blob: 3519c516a833dcc1e57a28a267a3e291b93429bd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh

BASE=$(readlink -f $0)
BASE=$(dirname $BASE) # up one
BASE=$(dirname $BASE) # up one more
BASE=$(dirname $BASE) # up again

if mount | grep --silent vmshare ; then
    sudo mount -t vboxsf vmshare $HOME/vmshare
fi

NPROCS=`grep -c processor /proc/cpuinfo`

cd $BASE || exit 1
svn update || exit 1
scons SYSLIBS=1 --config=force -j$NPROCS || exit 1
cd tools/linux_packaging || exit 1
./build --public --strip some || exit 1
./package --public --singlearch || exit 1
file=`ls -t *.tar`
echo "Copying $file to shared folder ..."
sudo cp $file $HOME/vmshare || exit 1

exit 0