Code: Select all
grep -q BOOST_HAS <BasicMessage.h || (sed 's:#include <boost/make_shared.hpp>:#ifdef BOOST_HAS_RVALUE_REFS\
#undef BOOST_HAS_RVALUE_REFS\
#include <boost/make_shared.hpp>\
#define BOOST_HAS_RVALUE_REFS\
#else\
#include <boost/make_shared.hpp>\
#endif:' <BasicMessage.h >bmh && cp bmh BasicMessage.h && rm bmh)
This is what I see in the Build tab of Output View:
Code: Select all
MESSAGE: Entering directory `/home/plong/workspace/SimpleAmqpClient'
/bin/sh -f './SimpleAmqpClient.sh'
----------Building project:[ SimpleAmqpClient - Debug ]----------
Executing Pre Build commands ...
./SimpleAmqpClient.sh: line 4: unexpected EOF while looking for matching `''
./SimpleAmqpClient.sh: line 10: syntax error: unexpected end of file
0 errors, 0 warnings
Code: Select all
echo Executing Pre Build commands ...
cd src/SimpleAmqpClient
grep -q BOOST_HAS <BasicMessage.h || (sed 's:#include <boost/make_shared.hpp>:#ifdef BOOST_HAS_RVALUE_REFS\
cd ../..
mkdir build; cd build
cmake -DCMAKE_TOOLCHAIN_FILE=~/Toolchain-z3.cmake -DBOOST_ROOT=$WRKSPC/boost -DRabbitmqc_DIR=$WRKSPC/rabbitmq-c/target ..
echo Done
make
Any idea how I can specify a multiline command without resorting to putting it in a file and referencing the file from a Pre Build command (I hate that)?