rhel)
VENDOR_RELEASE="$release"
;;
+ debian)
+ VENDOR_RELEASE="$release"
+ ;;
ubuntu)
VENDOR_RELEASE="$release"
if [[ "x$VENDOR_RELEASE" == 'x12.04' ]]; then
assert_file 'Makefile' 'configure did not produce a Makefile'
}
+function run_make_maintainer_clean_if_possible ()
+{
+ if [ -f 'Makefile' ]; then
+ make_maintainer_clean
+ fi
+}
+
function run_autoreconf_if_required ()
{
if [ ! -x 'configure' ]; then
;;
'clang-analyzer')
;;
- 'test-*')
+ test-*)
;;
- 'valgrind-*')
+ valgrind-*)
;;
- 'gdb-*')
+ gdb-*)
;;
'dist')
;;
*)
- die "Unknown MAKE_TARGET option: $1"
+ echo "Matched default"
+ return 1
;;
esac
+
+ return 0
}
function bootstrap ()
# If we are running inside of Jenkins, we want to only run some of the possible tests
if $jenkins_build_environment; then
check_make_target $target
+ ret=$?
+ if [ $ret -ne 0 ]; then
+ die "Unknown MAKE_TARGET option: $target"
+ fi
fi
+ local snapshot_run=false
+
case $target in
'self')
self_test
;;
'snapshot')
make_for_snapshot
+ snapshot_run=true
;;
'rpm')
make_rpm
make_target "$target"
;;
esac
+
+ if $jenkins_build_environment; then
+ if ! $snapshot_run; then
+ run_make_maintainer_clean_if_possible
+ fi
+ fi
+
done
}
# We don't want Jenkins overriding other variables, so we NULL them.
if [ -z "$MAKE_TARGET" ]; then
if $jenkins_build_environment; then
- MAKE_TARGET='jenkins'
+ if [[ -n "$label" ]]; then
+ check_make_target $label
+ if [ $? -eq 0 ]; then
+ MAKE_TARGET="$label"
+ fi
+ fi
+
+ if [ -z "$MAKE_TARGET" ]; then
+ MAKE_TARGET='jenkins'
+ fi
fi
fi