2012-07-02 19:50:14 +02:00
|
|
|
#!/bin/bash
|
2012-09-08 18:40:47 +02:00
|
|
|
|
|
|
|
# this script downloads and builds the democlient
|
|
|
|
# syntax:
|
|
|
|
# ./build 1.56
|
|
|
|
|
|
|
|
# cppcheck lib folder
|
|
|
|
cppchecklib=cppcheck-$1/lib
|
|
|
|
|
2012-09-28 20:25:46 +02:00
|
|
|
echo Downloading...
|
2012-09-08 18:40:47 +02:00
|
|
|
wget https://downloads.sourceforge.net/project/cppcheck/cppcheck/$1/cppcheck-$1.tar.bz2
|
|
|
|
|
2012-09-28 20:25:46 +02:00
|
|
|
echo Unpacking...
|
2012-09-08 18:40:47 +02:00
|
|
|
tar xjvf cppcheck-$1.tar.bz2
|
|
|
|
rm cppcheck-$1.tar.bz2
|
|
|
|
rm cppcheck-$1/Changelog
|
|
|
|
|
2012-09-28 20:25:46 +02:00
|
|
|
echo Building...
|
2012-09-08 18:40:47 +02:00
|
|
|
g++ -O2 -o democlient-$1.cgi -I$cppchecklib cppcheck-$1/democlient/democlient.cpp $cppchecklib/*.cpp
|
|
|
|
|
2012-09-28 20:25:46 +02:00
|
|
|
echo Copy cgi to webspace...
|
2012-09-08 18:40:47 +02:00
|
|
|
cp democlient-$1.cgi /home/project-web/cppcheck/cgi-bin/democlient.cgi
|
2012-07-02 19:50:14 +02:00
|
|
|
chmod +rx /home/project-web/cppcheck/cgi-bin/democlient.cgi
|
2012-09-08 18:40:47 +02:00
|
|
|
|
|
|
|
echo Done!
|