1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00
samba-mirror/third_party/heimdal/tools/fixgcov-source-paths.sh
Stefan Metzmacher 7055827b8f HEIMDAL: move code from source4/heimdal* to third_party/heimdal*
This makes it clearer that we always want to do heimdal changes
via the lorikeet-heimdal repository.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Joseph Sutton <josephsutton@catalyst.net.nz>

Autobuild-User(master): Joseph Sutton <jsutton@samba.org>
Autobuild-Date(master): Wed Jan 19 21:41:59 UTC 2022 on sn-devel-184
2022-01-19 21:41:59 +00:00

19 lines
471 B
Bash
Executable File

#!/bin/sh
find ${1:-.} -name '*.gcov' -print | while read f; do
case "$f" in
*/.libs/*) continue;;
*) true;;
esac
echo FIX $f
f_basename=${f%%.gcno\#\#*}.c
f_basename=${f_basename##*/}
head -1 "$f" | grep 'Source:/' > /dev/null && continue
#bname=$(head -1 "$f" | grep 'Source:/' | cut -d: -f4)
dname=$(echo "$f"|cut -d'#' -f1|sed -e 's,/[^/]*$,/,')
ex "$f" <<EOF
1,1 s,:Source:.*$,:Source:${dname}${f_basename},
wq!
EOF
done