#!/bin/shset -eusrcdir="${0%/*}"(cd "${srcdir}"echo "m4_define(VERSION_NUMBER, [$(git describe --tags --abbrev=0)+git])" > version.m4autoreconf -i --warnings obsolete)[ -n "${NOCONFIGURE:-}" ] && exitcase "${1:-}" inrpm)# configure with the same flags as when building an RPMexec rpmbuild -D '_topdir tmp/rpmbuild' -D 'make_build #' \--build-in-place -bc tools/cockpit.spec ;;*)exec "${srcdir}/configure" "$@" ;;esac