2017-11-26 23:11:58 -05:00
|
|
|
#!/bin/bash
|
|
|
|
export TEST_BIN_NAME=$1
|
2017-11-27 00:00:14 -05:00
|
|
|
#echo "Building ${TEST_BIN_NAME}"
|
2017-11-26 23:11:58 -05:00
|
|
|
shift 1
|
|
|
|
export BUILD_COMMAND=$@
|
2017-11-27 00:00:14 -05:00
|
|
|
#echo "Build command: ${BUILD_COMMAND}"
|
|
|
|
eval ${BUILD_COMMAND} >/dev/null 2>/dev/null
|
2017-11-26 23:22:29 -05:00
|
|
|
|
2017-11-26 23:11:58 -05:00
|
|
|
if [ $? -eq 0 ]; then
|
2017-11-26 23:22:29 -05:00
|
|
|
echo -ne "#!/bin/bash\nexit 1;" > ${TEST_BIN_NAME}
|
|
|
|
else
|
|
|
|
echo -ne "#!/bin/bash\nexit 0;" > ${TEST_BIN_NAME}
|
2017-11-26 23:11:58 -05:00
|
|
|
fi
|
|
|
|
chmod u+x ${TEST_BIN_NAME}
|
|
|
|
exit 0;
|
|
|
|
|