mirror of
https://github.com/brl/mutter.git
synced 2024-11-22 16:10:41 -05:00
d6af73ba68
On systems that have undergone the /usr merge, /bin/bash and /usr/bin/bash can be used interchangeably, but on systems where /bin and /usr/bin are separate (such as Debian 11 or older), bash was traditionally in /bin and there is no bash in /usr/bin. Resolves: https://gitlab.gnome.org/GNOME/mutter/-/issues/2385 Signed-off-by: Simon McVittie <smcv@debian.org> Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2900>
39 lines
879 B
Bash
Executable File
39 lines
879 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# We need a coverity token to fetch the tarball
|
|
if [ -x $COVERITY_TOKEN ]
|
|
then
|
|
echo "No coverity token. Run this job from a protected branch."
|
|
exit -1
|
|
fi
|
|
|
|
mkdir -p coverity
|
|
|
|
# Download and check MD5 first
|
|
curl https://scan.coverity.com/download/linux64 \
|
|
--data "token=$COVERITY_TOKEN&project=mutter&md5=1" \
|
|
--output /tmp/coverity_tool.md5
|
|
|
|
diff /tmp/coverity_tool.md5 coverity/coverity_tool.md5 >/dev/null 2>&1
|
|
|
|
if [ $? -eq 0 -a -d coverity/cov-analysis* ]
|
|
then
|
|
echo "Coverity tarball is up-to-date"
|
|
exit 0
|
|
fi
|
|
|
|
# Download and extract coverity tarball
|
|
curl https://scan.coverity.com/download/linux64 \
|
|
--data "token=$COVERITY_TOKEN&project=mutter" \
|
|
--output /tmp/coverity_tool.tgz
|
|
|
|
rm -rf ./coverity/cov-analysis*
|
|
|
|
tar zxf /tmp/coverity_tool.tgz -C coverity/
|
|
if [ $? -eq 0 ]
|
|
then
|
|
mv /tmp/coverity_tool.md5 coverity/
|
|
fi
|
|
|
|
rm /tmp/coverity_tool.tgz
|