make install
popd >/dev/null
+rsync -a ../build/debian/tmp/ debian/tmp/
+cp ../build/bcusdk-0.0.5/debian/changelog debian/
+cp ../build/bcusdk-0.0.5/debian/copyright debian/
+
#!/bin/bash
set -e
-# TODO: should be replaced by a mbuild environment variable
-project_dir="$HOME/projects"
-
# Quelle: https://www.meintechblog.de/2014/06/knx-eib-gateway-in-fhem-einbinden/
# $CONFIGURE_OPTS may be set by cross compile environment
PTH_OPTS="--with-mctx-mth=sjlj --with-mctx-dsp=ssjlj --with-mctx-stk=sas"
fi
-wget --no-check-certificate http://www.auto.tuwien.ac.at/~mkoegler/pth/pthsem_2.0.8.tar.gz
-tar xf pthsem_2.0.8.tar.gz
+tar xf Downloads/pthsem_2.0.8.tar.gz
pushd pthsem-2.0.8 >/dev/null
- ./configure --prefix=$project_dir/debian/tmp/usr $PTH_OPTS $CONFIGURE_OPTS
+ ./configure --prefix=$HOME/build/debian/tmp/usr $PTH_OPTS $CONFIGURE_OPTS
make
popd >/dev/null
-wget --no-check-certificate http://www.auto.tuwien.ac.at/~mkoegler/eib/bcusdk_0.0.5.tar.gz
-tar xf bcusdk_0.0.5.tar.gz
-cp ~/projects/eibd/configure bcusdk-0.0.5/
+tar xf Downloads/bcusdk_0.0.5.tar.gz
+cp eibd/configure bcusdk-0.0.5/
pushd bcusdk-0.0.5
- ./configure --with-pth=subdir:$HOME/build/pthsem-2.0.8 --without-pth-test --enable-onlyeibd --enable-eibnetip --enable-eibnetiptunnel --enable-eibnetipserver --enable-tpuarts --prefix=$project_dir/debian/tmp/usr $CONFIGURE_OPTS
+ ./configure --with-pth=subdir:$HOME/build/pthsem-2.0.8 --without-pth-test --enable-onlyeibd --enable-eibnetip --enable-eibnetiptunnel --enable-eibnetipserver --enable-tpuarts --prefix=$HOME/build/debian/tmp/usr $CONFIGURE_OPTS
popd >/dev/null
# override package version
echo "version=0.0.5" >> debian/setenv.sh
+mkdir -p Downloads
+cd Downloads
+
+if [ ! -f pthsem_2.0.8.tar.gz ]
+then
+ wget --no-check-certificate http://www.auto.tuwien.ac.at/~mkoegler/pth/pthsem_2.0.8.tar.gz
+fi
+if [ ! -f bcusdk_0.0.5.tar.gz ]
+then
+ wget --no-check-certificate http://www.auto.tuwien.ac.at/~mkoegler/eib/bcusdk_0.0.5.tar.gz
+fi
+