lwip/travis.sh

53 lines
1007 B
Bash
Raw Normal View History

2018-10-12 18:09:22 +00:00
#!/bin/bash
cd contrib/ports/unix/check
#build and run unit tests
make clean all
ERR=$?
if [ $ERR != 0 ]; then
echo "unittests build failed"
exit 33
fi
2018-10-13 09:06:00 +00:00
# Build test using make, this tests the Makefile toolchain
make check -j 4
2018-10-13 09:06:00 +00:00
# Build example_app using cmake, this tests the CMake toolchain
cd ../../../../
2018-10-13 09:06:00 +00:00
# Copy lwipcfg for example app
2018-10-14 07:44:12 +00:00
cp contrib/examples/example_app/lwipcfg.h.travis contrib/examples/example_app/lwipcfg.h
2018-10-13 09:06:00 +00:00
# Generate CMake
mkdir build
cd build
/usr/local/bin/cmake .. -G Ninja
2018-10-13 09:06:00 +00:00
# Build CMake
ERR=$?
if [ $ERR != 0 ]; then
echo "cmake GENERATE failed"
exit 33
fi
/usr/local/bin/cmake --build .
ERR=$?
if [ $ERR != 0 ]; then
echo "cmake build failed"
exit 33
fi
/usr/local/bin/cmake --build . --target lwipdocs
ERR=$?
if [ $ERR != 0 ]; then
echo "lwIP documentation failed"
exit 33
fi
cd ..
cd contrib/ports/unix/example_app
./iteropts.sh
ERR=$?
if [ $ERR != 0 ]; then
echo "lwIP iteropts test failed"
exit 33
fi