[PATCH libinput 3/5] test: allow running the symbols-leak-test.in script directly
Eric Engestrom
eric.engestrom at imgtec.com
Fri Apr 28 11:11:44 UTC 2017
On Wednesday, 2017-04-26 12:20:39 +1000, Peter Hutterer wrote:
> With autotools, we replace the @top_srcdir@ during configure and then run teh
> resulting scripts.
>
> With meson, it's easier to just pass top-srcdir it in as argument.
>
> Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
> ---
> test/symbols-leak-test.in | 11 +++++++++--
> 1 file changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/test/symbols-leak-test.in b/test/symbols-leak-test.in
> index 448ef2f..69861c9 100755
> --- a/test/symbols-leak-test.in
> +++ b/test/symbols-leak-test.in
> @@ -2,6 +2,13 @@
>
> ### simple check for exported symbols
>
> +# Allow running this after the configure.ac replacement or directly with an
> +# argument for the top_srcdir
> +TOP_SRCDIR="@top_srcdir@"
> +if [ "$TOP_SRCDIR" = "@top_srcdir@" ]; then
Isn't that always going to be true?
> + TOP_SRCDIR="$1"
> +fi
> +
> # make bash exit if any command will exit with non-0 return value
> set -e
>
> @@ -9,9 +16,9 @@ set -e
> cd `dirname $0`
>
> diff -a -u \
> - <(cat @top_srcdir@/src/libinput.sym | \
> + <(cat "$TOP_SRCDIR"/src/libinput.sym | \
> grep '^\s\+libinput_.*' | \
> sed -e 's/^\s\+\(.*\);/\1/' | sort) \
> - <(cat @top_srcdir@/src/*.c | \
> + <(cat "$TOP_SRCDIR"/src/*.c | \
> grep LIBINPUT_EXPORT -A 1 | grep '^libinput_.*' | \
> sed -e 's/(.*//' | sort)
> --
> 2.9.3
>
More information about the wayland-devel
mailing list