67b7f62a8f
The content of this branch was automatically imported from Fedora ELN with the following as its source: https://src.fedoraproject.org/rpms/automake#7640c908710e39b9fae6e1bccb181337759cabfc
34 lines
749 B
Bash
Executable File
34 lines
749 B
Bash
Executable File
#!/bin/bash
|
|
|
|
die() { echo >&2 "$@"; exit 1; }
|
|
|
|
lines=`git status --porcelain | grep -v ^?? | wc -l`
|
|
test "$lines" != "0" && die "stash the git changes"
|
|
|
|
if test -d config; then
|
|
cd config
|
|
git pull
|
|
cd ..
|
|
else
|
|
git clone git://git.savannah.gnu.org/config.git
|
|
fi
|
|
|
|
|
|
cp config/config.guess .
|
|
cp config/config.sub .
|
|
|
|
lines=`git status --porcelain config.guess config.sub | wc -l`
|
|
if test "$lines" = "0"; then
|
|
echo "no upstream change"
|
|
exit 0
|
|
fi
|
|
|
|
make -C config check || die "make check failed"
|
|
|
|
rpmdev-bumpspec automake.spec \
|
|
-c "update config.{guess,sub} to gnuconfig git HEAD" \
|
|
|| die "can not bump spec"
|
|
|
|
git add -f config.sub config.guess automake.spec
|
|
git commit -m "gnuconfig: sync with upstream git" --no-verify
|