Implementation of following functionality
[platform/upstream/iotivity.git] / resource / csdk / connectivity / build / arduino / build.sh
1 #!/bin/sh
2 if echo $1 | grep -q -i "make"
3 then
4 cd ../lib/libcoap-4.1.1/
5 make -f makefile_arduino.mak PLATFORM=$2 ARDUINO_DIR=$4
6 cd ../../build/arduino
7 make PLATFORM=$2 TRANSPORT=$3 ARDUINO_DIR=$4 APP_NAME=$5
8 else
9 cd ../lib/libcoap-4.1.1/
10 make $1 -f makefile_arduino.mak PLATFORM=$2 ARDUINO_DIR=$4
11 cd ../../build/arduino/
12 make $1 PLATFORM=$2 TRANSPORT=$3 ARDUINO_DIR=$4 APP_NAME=$5
13 fi