aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMatthias Maennich <maennich@google.com>2020-09-23 14:35:10 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2020-09-23 14:35:10 +0000
commite87e5828f5ca1b0733d2bb63b89cb00571641e43 (patch)
treed3ee2626dd77b2e294c79559639cc3745e3a4fd7 /tests
parent62652afc4e5266d028e3d86b3201e0d284ffab62 (diff)
parentbdb1bc80b90c3fde34e8b0b2b6ddae5d44914979 (diff)
downloadplatform_external_elfutils-e87e5828f5ca1b0733d2bb63b89cb00571641e43.tar.gz
platform_external_elfutils-e87e5828f5ca1b0733d2bb63b89cb00571641e43.tar.bz2
platform_external_elfutils-e87e5828f5ca1b0733d2bb63b89cb00571641e43.zip
Merge "Merge tag 'elfutils-0.181' into master"
Diffstat (limited to 'tests')
-rw-r--r--tests/ChangeLog74
-rw-r--r--tests/Makefile.am19
-rw-r--r--tests/asm-tst1.c2
-rw-r--r--tests/asm-tst2.c2
-rw-r--r--tests/asm-tst3.c2
-rw-r--r--tests/asm-tst4.c2
-rw-r--r--tests/asm-tst5.c2
-rw-r--r--tests/asm-tst6.c2
-rw-r--r--tests/asm-tst7.c2
-rw-r--r--tests/asm-tst8.c2
-rw-r--r--tests/asm-tst9.c2
-rwxr-xr-xtests/coverage.sh2
-rwxr-xr-xtests/run-ar.sh2
-rwxr-xr-xtests/run-backtrace-core-aarch64.sh2
-rwxr-xr-xtests/run-backtrace-core-i386.sh2
-rwxr-xr-xtests/run-backtrace-core-ppc.sh2
-rwxr-xr-xtests/run-backtrace-core-s390.sh2
-rwxr-xr-xtests/run-backtrace-core-s390x.sh2
-rwxr-xr-xtests/run-backtrace-core-sparc.sh2
-rwxr-xr-xtests/run-backtrace-core-x32.sh2
-rwxr-xr-xtests/run-backtrace-core-x86_64.sh2
-rwxr-xr-xtests/run-backtrace-data.sh2
-rwxr-xr-xtests/run-backtrace-demangle.sh2
-rwxr-xr-xtests/run-backtrace-dwarf.sh2
-rwxr-xr-xtests/run-backtrace-fp-core-aarch64.sh2
-rwxr-xr-xtests/run-backtrace-fp-core-i386.sh2
-rwxr-xr-xtests/run-backtrace-fp-core-ppc64le.sh2
-rwxr-xr-xtests/run-backtrace-fp-core-x86_64.sh2
-rwxr-xr-xtests/run-backtrace-native-biarch.sh2
-rwxr-xr-xtests/run-backtrace-native-core-biarch.sh2
-rwxr-xr-xtests/run-backtrace-native-core.sh2
-rwxr-xr-xtests/run-backtrace-native.sh2
-rwxr-xr-xtests/run-debuginfod-find.sh8
-rwxr-xr-xtests/run-deleted.sh2
-rwxr-xr-xtests/run-dwelf_elf_e_machine_string.sh2
-rwxr-xr-xtests/run-large-elf-file.sh2
-rwxr-xr-xtests/run-lfs-symbols.sh2
-rwxr-xr-xtests/run-linkmap-cut.sh2
-rwxr-xr-xtests/run-readelf-frames.sh173
-rwxr-xr-xtests/run-readelf-n.sh31
-rwxr-xr-xtests/run-test-includes.sh26
-rwxr-xr-xtests/testfile-gnu-property-note-aarch64.bz2bin0 -> 1952 bytes
42 files changed, 362 insertions, 39 deletions
diff --git a/tests/ChangeLog b/tests/ChangeLog
index 99f9da9d..5f2b1449 100644
--- a/tests/ChangeLog
+++ b/tests/ChangeLog
@@ -1,3 +1,77 @@
+2020-09-03 Mark Wielaard <mark@klomp.org>
+
+ * run-readelf-frames.sh: New test.
+ * Makefile.am (TESTS): Add run-readelf-frames.sh.
+ (EXTRA_DIST): Likewise.
+
+2020-09-03 Mark Wielaard <mark@klomp.org>
+
+ * testfile-gnu-property-note-aarch64.bz2: New file.
+ * run-readelf-n.sh: Handle testfile-gnu-property-note-aarch64.
+ * Makefile.am (EXTRA_DIST): Add
+ testfile-gnu-property-note-aarch64.bz2.
+
+2020-07-19 Mark Wielaard <mark@klomp.org>
+
+ * asm-tst1.c: Include libebl.h after libasm.h.
+ * asm-tst2.c: Likewise.
+ * asm-tst3.c: Likewise.
+ * asm-tst4.c: Likewise.
+ * asm-tst5.c: Likewise.
+ * asm-tst6.c: Likewise.
+ * asm-tst7.c: Likewise.
+ * asm-tst8.c: Likewise.
+ * asm-tst9.c: Likewise.
+
+2020-07-05 Mark Wielaard <mark@klomp.org>
+
+ * run-test-includes.sh: New test.
+ * Makefile.am (TESTS): Add run-test-includes.sh.
+ (EXTRA_DIST): Likewise.
+
+2020-07-03 Alice Zhang <alizhang@redhat.com>
+
+ * run-debuginfod-find.sh: Add scheme free url testcase.
+
+2020-06-19 Mark Wielaard <mark@klomp.org>
+
+ * Makefile.am (TESTS): Don't add run-debuginfod-find.sh when
+ DUMMY_LIBDEBUGINFOD.
+
+2020-06-16 Mark Wielaard <mark@klomp.org>
+
+ * coverage.sh: Use /usr/bin/env bash.
+ * run-ar.sh: Likewise.
+ * run-backtrace-core-aarch64.sh: Likewise.
+ * run-backtrace-core-i386.sh: Likewise.
+ * run-backtrace-core-ppc.sh: Likewise.
+ * run-backtrace-core-s390.sh: Likewise.
+ * run-backtrace-core-s390x.sh: Likewise.
+ * run-backtrace-core-sparc.sh: Likewise.
+ * run-backtrace-core-x32.sh: Likewise.
+ * run-backtrace-core-x86_64.sh: Likewise.
+ * run-backtrace-data.sh: Likewise.
+ * run-backtrace-demangle.sh: Likewise.
+ * run-backtrace-dwarf.sh: Likewise.
+ * run-backtrace-fp-core-aarch64.sh: Likewise.
+ * run-backtrace-fp-core-i386.sh: Likewise.
+ * run-backtrace-fp-core-ppc64le.sh: Likewise.
+ * run-backtrace-fp-core-x86_64.sh: Likewise.
+ * run-backtrace-native-biarch.sh: Likewise.
+ * run-backtrace-native-core-biarch.sh: Likewise.
+ * run-backtrace-native-core.sh: Likewise.
+ * run-backtrace-native.sh: Likewise.
+ * run-debuginfod-find.sh: Likewise.
+ * run-deleted.sh: Likewise.
+ * run-dwelf_elf_e_machine_string.sh: Likewise.
+ * run-large-elf-file.sh: Likewise.
+ * run-lfs-symbols.sh: Likewise.
+ * run-linkmap-cut.sh: Likewise.
+
+2020-06-11 Mark Wielaard <mark@klomp.org>
+
+ * Makefile.am (nlist-test): Add GCOV flags when necessary.
+
2020-06-06 Mark Wielaard <mark@klomp.org>
* testfilesyms32.bz2: New test file.
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 7db7db16..4629ce64 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -80,13 +80,19 @@ backtrace-child-biarch$(EXEEXT): backtrace-child.c
$(AM_LDFLAGS) $(LDFLAGS) $(backtrace_child_LDFLAGS) \
-o $@ $<
+if GCOV
+GCOV_FLAGS=-fprofile-arcs -ftest-coverage
+else
+GCOV_FLAGS=
+endif
+
# test_nlist checks its own symbol table, and expects various symbols
# to be in the order as specified in the source file. Explicitly set
# minimal CFLAGS
test-nlist$(EXEEXT): test-nlist.c
$(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
$(AM_CPPFLAGS) $(CPPFLAGS) \
- $(test_nlist_CFLAGS) $(test_nlist_LDADD) -o $@ $<
+ $(test_nlist_CFLAGS) $(GCOV_FLAGS) -o $@ $< $(test_nlist_LDADD)
TESTS = run-arextract.sh run-arsymtest.sh run-ar.sh newfile test-nlist \
update1 update2 update3 update4 \
@@ -119,6 +125,7 @@ TESTS = run-arextract.sh run-arsymtest.sh run-ar.sh newfile test-nlist \
run-readelf-test4.sh run-readelf-twofiles.sh \
run-readelf-macro.sh run-readelf-loc.sh run-readelf-ranges.sh \
run-readelf-aranges.sh run-readelf-line.sh run-readelf-z.sh \
+ run-readelf-frames.sh \
run-readelf-n.sh \
run-native-test.sh run-bug1-test.sh \
run-debuglink.sh run-debugaltlink.sh run-buildid.sh \
@@ -178,7 +185,7 @@ TESTS = run-arextract.sh run-arsymtest.sh run-ar.sh newfile test-nlist \
run-elfclassify.sh run-elfclassify-self.sh \
run-disasm-riscv64.sh \
run-pt_gnu_prop-tests.sh \
- run-getphdrnum.sh
+ run-getphdrnum.sh run-test-includes.sh
if !BIARCH
export ELFUTILS_DISABLE_BIARCH = 1
@@ -204,8 +211,11 @@ endif
if DEBUGINFOD
check_PROGRAMS += debuginfod_build_id_find
+# With the dummy delegation doesn't work
+if !DUMMY_LIBDEBUGINFOD
TESTS += run-debuginfod-find.sh
endif
+endif
EXTRA_DIST = run-arextract.sh run-arsymtest.sh run-ar.sh \
run-show-die-info.sh run-get-files.sh run-get-lines.sh \
@@ -304,12 +314,14 @@ EXTRA_DIST = run-arextract.sh run-arsymtest.sh run-ar.sh \
testfile-dwzstr.bz2 testfile-dwzstr.multi.bz2 \
run-readelf-addr.sh run-readelf-str.sh \
run-readelf-types.sh \
+ run-readelf-frames.sh \
run-readelf-n.sh \
testfile-gnu-property-note.bz2 testfile-gnu-property-note.o.bz2 \
testfile_gnu_props.32le.o.bz2 \
testfile_gnu_props.64le.o.bz2 \
testfile_gnu_props.32be.o.bz2 \
testfile_gnu_props.64be.o.bz2 \
+ testfile-gnu-property-note-aarch64.bz2 \
run-allfcts-multi.sh \
test-offset-loop.bz2 test-offset-loop.alt.bz2 \
run-prelink-addr-test.sh \
@@ -496,7 +508,8 @@ EXTRA_DIST = run-arextract.sh run-arsymtest.sh run-ar.sh \
debuginfod-tars/pacman-sources/hello.c \
run-pt_gnu_prop-tests.sh \
testfile_pt_gnu_prop.bz2 testfile_pt_gnu_prop32.bz2 \
- run-getphdrnum.sh testfile-phdrs.elf.bz2
+ run-getphdrnum.sh testfile-phdrs.elf.bz2 \
+ run-test-includes.sh
if USE_VALGRIND
diff --git a/tests/asm-tst1.c b/tests/asm-tst1.c
index cdf2a921..d03a4361 100644
--- a/tests/asm-tst1.c
+++ b/tests/asm-tst1.c
@@ -20,8 +20,8 @@
#endif
#include <fcntl.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <string.h>
diff --git a/tests/asm-tst2.c b/tests/asm-tst2.c
index 9e88b70c..e65a9d2f 100644
--- a/tests/asm-tst2.c
+++ b/tests/asm-tst2.c
@@ -20,8 +20,8 @@
#endif
#include <fcntl.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <string.h>
diff --git a/tests/asm-tst3.c b/tests/asm-tst3.c
index 39c1d90c..e45fa16a 100644
--- a/tests/asm-tst3.c
+++ b/tests/asm-tst3.c
@@ -20,8 +20,8 @@
#endif
#include <fcntl.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <string.h>
diff --git a/tests/asm-tst4.c b/tests/asm-tst4.c
index 5114938b..1a05bfcc 100644
--- a/tests/asm-tst4.c
+++ b/tests/asm-tst4.c
@@ -20,8 +20,8 @@
#endif
#include <fcntl.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/tests/asm-tst5.c b/tests/asm-tst5.c
index dcb852f8..256873f0 100644
--- a/tests/asm-tst5.c
+++ b/tests/asm-tst5.c
@@ -20,8 +20,8 @@
#endif
#include <fcntl.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/tests/asm-tst6.c b/tests/asm-tst6.c
index 829cd90c..4a665ed0 100644
--- a/tests/asm-tst6.c
+++ b/tests/asm-tst6.c
@@ -19,8 +19,8 @@
# include <config.h>
#endif
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/tests/asm-tst7.c b/tests/asm-tst7.c
index 90179769..87c21485 100644
--- a/tests/asm-tst7.c
+++ b/tests/asm-tst7.c
@@ -21,8 +21,8 @@
#include <fcntl.h>
#include <inttypes.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <unistd.h>
diff --git a/tests/asm-tst8.c b/tests/asm-tst8.c
index a65509fe..7dbac10f 100644
--- a/tests/asm-tst8.c
+++ b/tests/asm-tst8.c
@@ -21,8 +21,8 @@
#include <fcntl.h>
#include <inttypes.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <unistd.h>
diff --git a/tests/asm-tst9.c b/tests/asm-tst9.c
index 681e872d..6bec3f6e 100644
--- a/tests/asm-tst9.c
+++ b/tests/asm-tst9.c
@@ -21,8 +21,8 @@
#include <fcntl.h>
#include <inttypes.h>
-#include ELFUTILS_HEADER(ebl)
#include ELFUTILS_HEADER(asm)
+#include ELFUTILS_HEADER(ebl)
#include <libelf.h>
#include <stdio.h>
#include <string.h>
diff --git a/tests/coverage.sh b/tests/coverage.sh
index 01d292cc..448d43ba 100755
--- a/tests/coverage.sh
+++ b/tests/coverage.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
if [ "x$1" = "x-v" ]; then
verbose=yes
diff --git a/tests/run-ar.sh b/tests/run-ar.sh
index fb9394d5..656f1d1a 100755
--- a/tests/run-ar.sh
+++ b/tests/run-ar.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2017 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-aarch64.sh b/tests/run-backtrace-core-aarch64.sh
index a29a6613..41221d36 100755
--- a/tests/run-backtrace-core-aarch64.sh
+++ b/tests/run-backtrace-core-aarch64.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-i386.sh b/tests/run-backtrace-core-i386.sh
index 7294ec3d..c497f4aa 100755
--- a/tests/run-backtrace-core-i386.sh
+++ b/tests/run-backtrace-core-i386.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-ppc.sh b/tests/run-backtrace-core-ppc.sh
index 555ac352..1a51046c 100755
--- a/tests/run-backtrace-core-ppc.sh
+++ b/tests/run-backtrace-core-ppc.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-s390.sh b/tests/run-backtrace-core-s390.sh
index d3b6dc9c..ce3afb93 100755
--- a/tests/run-backtrace-core-s390.sh
+++ b/tests/run-backtrace-core-s390.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-s390x.sh b/tests/run-backtrace-core-s390x.sh
index c3e236d4..39450c14 100755
--- a/tests/run-backtrace-core-s390x.sh
+++ b/tests/run-backtrace-core-s390x.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-sparc.sh b/tests/run-backtrace-core-sparc.sh
index 60399baa..2f39e745 100755
--- a/tests/run-backtrace-core-sparc.sh
+++ b/tests/run-backtrace-core-sparc.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2015 Oracle, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-x32.sh b/tests/run-backtrace-core-x32.sh
index 2ad76bcf..e6144b35 100755
--- a/tests/run-backtrace-core-x32.sh
+++ b/tests/run-backtrace-core-x32.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) H.J. Lu <hjl.tools@gmail.com>, 2015.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-core-x86_64.sh b/tests/run-backtrace-core-x86_64.sh
index d00cd6d6..49248015 100755
--- a/tests/run-backtrace-core-x86_64.sh
+++ b/tests/run-backtrace-core-x86_64.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-data.sh b/tests/run-backtrace-data.sh
index 3062c304..f67a43ef 100755
--- a/tests/run-backtrace-data.sh
+++ b/tests/run-backtrace-data.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-demangle.sh b/tests/run-backtrace-demangle.sh
index 2d253240..403a4852 100755
--- a/tests/run-backtrace-demangle.sh
+++ b/tests/run-backtrace-demangle.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2014, 2015 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-dwarf.sh b/tests/run-backtrace-dwarf.sh
index 8834048a..7ed795d8 100755
--- a/tests/run-backtrace-dwarf.sh
+++ b/tests/run-backtrace-dwarf.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-fp-core-aarch64.sh b/tests/run-backtrace-fp-core-aarch64.sh
index fda88d37..397e3c3a 100755
--- a/tests/run-backtrace-fp-core-aarch64.sh
+++ b/tests/run-backtrace-fp-core-aarch64.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2017 The Qt Company
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-fp-core-i386.sh b/tests/run-backtrace-fp-core-i386.sh
index c58ff532..43f859fe 100755
--- a/tests/run-backtrace-fp-core-i386.sh
+++ b/tests/run-backtrace-fp-core-i386.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2017 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-fp-core-ppc64le.sh b/tests/run-backtrace-fp-core-ppc64le.sh
index 326ca342..345b8dbe 100755
--- a/tests/run-backtrace-fp-core-ppc64le.sh
+++ b/tests/run-backtrace-fp-core-ppc64le.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2017 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-fp-core-x86_64.sh b/tests/run-backtrace-fp-core-x86_64.sh
index 348eb183..12f44c4b 100755
--- a/tests/run-backtrace-fp-core-x86_64.sh
+++ b/tests/run-backtrace-fp-core-x86_64.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2017 The Qt Company
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-native-biarch.sh b/tests/run-backtrace-native-biarch.sh
index 2afe38a5..92869830 100755
--- a/tests/run-backtrace-native-biarch.sh
+++ b/tests/run-backtrace-native-biarch.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013, 2015 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-native-core-biarch.sh b/tests/run-backtrace-native-core-biarch.sh
index 02552ce9..23274257 100755
--- a/tests/run-backtrace-native-core-biarch.sh
+++ b/tests/run-backtrace-native-core-biarch.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013, 2015 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-native-core.sh b/tests/run-backtrace-native-core.sh
index cb025a56..db95895f 100755
--- a/tests/run-backtrace-native-core.sh
+++ b/tests/run-backtrace-native-core.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-backtrace-native.sh b/tests/run-backtrace-native.sh
index ddae345d..823c4117 100755
--- a/tests/run-backtrace-native.sh
+++ b/tests/run-backtrace-native.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2013 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-debuginfod-find.sh b/tests/run-debuginfod-find.sh
index 7faad331..730bb0e1 100755
--- a/tests/run-debuginfod-find.sh
+++ b/tests/run-debuginfod-find.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/usr/bin/env bash
#
# Copyright (C) 2019-2020 Red Hat, Inc.
# This file is part of elfutils.
@@ -413,6 +413,12 @@ testrun ${abs_top_builddir}/debuginfod/debuginfod-find debuginfo $BUILDID && fal
export DEBUGINFOD_URLS=http://127.0.0.1:$PORT2
testrun ${abs_top_builddir}/debuginfod/debuginfod-find debuginfo $BUILDID
+# test again with scheme free url
+export DEBUGINFOD_URLS=127.0.0.1:$PORT1
+rm -rf $DEBUGINFOD_CACHE_PATH
+testrun ${abs_top_builddir}/debuginfod/debuginfod-find debuginfo $BUILDID && false || true
+export DEBUGINFOD_URLS=127.0.0.1:$PORT2
+testrun ${abs_top_builddir}/debuginfod/debuginfod-find debuginfo $BUILDID
# test parallel queries in client
export DEBUGINFOD_CACHE_PATH=${PWD}/.client_cache3
diff --git a/tests/run-deleted.sh b/tests/run-deleted.sh
index 0f647621..a1ec1ecf 100755
--- a/tests/run-deleted.sh
+++ b/tests/run-deleted.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2014 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-dwelf_elf_e_machine_string.sh b/tests/run-dwelf_elf_e_machine_string.sh
index ba6d0e63..658f229f 100755
--- a/tests/run-dwelf_elf_e_machine_string.sh
+++ b/tests/run-dwelf_elf_e_machine_string.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Test to make sure all EM values in elf.h are recognized
# Copyright (C) 2019 Red Hat, Inc.
# This file is part of elfutils.
diff --git a/tests/run-large-elf-file.sh b/tests/run-large-elf-file.sh
index cbe30615..667d24d8 100755
--- a/tests/run-large-elf-file.sh
+++ b/tests/run-large-elf-file.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2019 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-lfs-symbols.sh b/tests/run-lfs-symbols.sh
index b65391b6..7398e7f4 100755
--- a/tests/run-lfs-symbols.sh
+++ b/tests/run-lfs-symbols.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2015 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-linkmap-cut.sh b/tests/run-linkmap-cut.sh
index de2bc7cc..053b96dc 100755
--- a/tests/run-linkmap-cut.sh
+++ b/tests/run-linkmap-cut.sh
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /usr/bin/env bash
# Copyright (C) 2014 Red Hat, Inc.
# This file is part of elfutils.
#
diff --git a/tests/run-readelf-frames.sh b/tests/run-readelf-frames.sh
new file mode 100755
index 00000000..f0429d19
--- /dev/null
+++ b/tests/run-readelf-frames.sh
@@ -0,0 +1,173 @@
+#! /bin/sh
+# Copyright (C) 2020 Red Hat, Inc.
+# This file is part of elfutils.
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# elfutils is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+. $srcdir/test-subr.sh
+
+# See run-readelf-n.sh
+testfiles testfile-gnu-property-note-aarch64
+
+testrun_compare ${abs_top_builddir}/src/readelf --debug-dump=frames testfile-gnu-property-note-aarch64 <<\EOF
+
+Call frame search table section [17] '.eh_frame_hdr':
+ version: 1
+ eh_frame_ptr_enc: 0x1b (sdata4 pcrel)
+ fde_count_enc: 0x3 (udata4)
+ table_enc: 0x3b (sdata4 datarel)
+ eh_frame_ptr: 0x44 (offset: 0x758)
+ fde_count: 7
+ Table:
+ 0xfffffe70 (offset: 0x580) -> 0x5c fde=[ 14]
+ 0xfffffea0 (offset: 0x5b0) -> 0x70 fde=[ 28]
+ 0xfffffee0 (offset: 0x5f0) -> 0x84 fde=[ 3c]
+ 0xffffff20 (offset: 0x630) -> 0xac fde=[ 64]
+ 0xffffff28 (offset: 0x638) -> 0xc0 fde=[ 78]
+ 0xffffff40 (offset: 0x650) -> 0xd8 fde=[ 90]
+ 0xffffffc0 (offset: 0x6d0) -> 0x110 fde=[ c8]
+
+Call frame information section [18] '.eh_frame' at offset 0x758:
+
+ [ 0] CIE length=16
+ CIE_id: 0
+ version: 1
+ augmentation: "zR"
+ code_alignment_factor: 4
+ data_alignment_factor: -8
+ return_address_register: 30
+ Augmentation data: 0x1b (FDE address encoding: sdata4 pcrel)
+
+ Program:
+ def_cfa r31 (sp) at offset 0
+
+ [ 14] FDE length=16 cie=[ 0]
+ CIE_pointer: 24
+ initial_location: 0x0000000000400580 (offset: 0x580)
+ address_range: 0x30 (end offset: 0x5b0)
+
+ Program:
+ nop
+ nop
+ nop
+
+ [ 28] FDE length=16 cie=[ 0]
+ CIE_pointer: 44
+ initial_location: 0x00000000004005b0 (offset: 0x5b0)
+ address_range: 0x3c (end offset: 0x5ec)
+
+ Program:
+ nop
+ nop
+ nop
+
+ [ 3c] FDE length=36 cie=[ 0]
+ CIE_pointer: 64
+ initial_location: 0x00000000004005f0 (offset: 0x5f0)
+ address_range: 0x38 (end offset: 0x628)
+
+ Program:
+ advance_loc 1 to 0x5f4
+ AARCH64_negate_ra_state
+ advance_loc 1 to 0x5f8
+ def_cfa_offset 32
+ offset r29 (x29) at cfa-32
+ offset r30 (x30) at cfa-24
+ advance_loc 2 to 0x600
+ offset r19 (x19) at cfa-16
+ advance_loc 8 to 0x620
+ restore r30 (x30)
+ restore r29 (x29)
+ restore r19 (x19)
+ def_cfa_offset 0
+ advance_loc 1 to 0x624
+ AARCH64_negate_ra_state
+ nop
+ nop
+ nop
+
+ [ 64] FDE length=16 cie=[ 0]
+ CIE_pointer: 104
+ initial_location: 0x0000000000400630 (offset: 0x630)
+ address_range: 0x8 (end offset: 0x638)
+
+ Program:
+ nop
+ nop
+ nop
+
+ [ 78] FDE length=20 cie=[ 0]
+ CIE_pointer: 124
+ initial_location: 0x0000000000400638 (offset: 0x638)
+ address_range: 0xc (end offset: 0x644)
+
+ Program:
+ nop
+ nop
+ nop
+ nop
+ nop
+ nop
+ nop
+
+ [ 90] FDE length=52 cie=[ 0]
+ CIE_pointer: 148
+ initial_location: 0x0000000000400650 (offset: 0x650)
+ address_range: 0x80 (end offset: 0x6d0)
+
+ Program:
+ advance_loc 1 to 0x654
+ AARCH64_negate_ra_state
+ advance_loc 1 to 0x658
+ def_cfa_offset 64
+ offset r29 (x29) at cfa-64
+ offset r30 (x30) at cfa-56
+ advance_loc 2 to 0x660
+ offset r19 (x19) at cfa-48
+ offset r20 (x20) at cfa-40
+ advance_loc 3 to 0x66c
+ offset r21 (x21) at cfa-32
+ offset r22 (x22) at cfa-24
+ advance_loc 5 to 0x680
+ offset r23 (x23) at cfa-16
+ offset r24 (x24) at cfa-8
+ advance_loc 18 to 0x6c8
+ restore r30 (x30)
+ restore r29 (x29)
+ restore r23 (x23)
+ restore r24 (x24)
+ restore r21 (x21)
+ restore r22 (x22)
+ restore r19 (x19)
+ restore r20 (x20)
+ def_cfa_offset 0
+ advance_loc 1 to 0x6cc
+ AARCH64_negate_ra_state
+ nop
+ nop
+
+ [ c8] FDE length=16 cie=[ 0]
+ CIE_pointer: 204
+ initial_location: 0x00000000004006d0 (offset: 0x6d0)
+ address_range: 0x8 (end offset: 0x6d8)
+
+ Program:
+ nop
+ nop
+ nop
+
+ [ dc] Zero terminator
+EOF
+
+exit 0
diff --git a/tests/run-readelf-n.sh b/tests/run-readelf-n.sh
index cc7d7f66..4c98fd82 100755
--- a/tests/run-readelf-n.sh
+++ b/tests/run-readelf-n.sh
@@ -226,3 +226,34 @@ Note section [ 4] '.note.gnu.property' of 56 bytes at offset 0x40:
GNU 8 GNU_PROPERTY_TYPE_0
NO_COPY_ON_PROTECTION
EOF
+
+# - testfile-gnu-property-note.c
+# int
+# main ()
+# {
+# return 0;
+# }
+#
+# gcc -mbranch-protection=standard -c testfile-gnu-property-note.c
+# gcc -o testfile-gnu-property-note-aarch64 testfile-gnu-property-note.o
+# eu-strip --remove-section=.gnu.build.attributes \
+# testfile-gnu-property-note-aarch64
+
+testfiles testfile-gnu-property-note-aarch64
+testrun_compare ${abs_top_builddir}/src/readelf -n testfile-gnu-property-note-aarch64 << EOF
+
+Note section [ 2] '.note.gnu.property' of 32 bytes at offset 0x2c8:
+ Owner Data size Type
+ GNU 16 GNU_PROPERTY_TYPE_0
+ AARCH64 FEATURE_1_AND: 00000003 BTI PAC
+
+Note section [ 3] '.note.gnu.build-id' of 36 bytes at offset 0x2e8:
+ Owner Data size Type
+ GNU 20 GNU_BUILD_ID
+ Build ID: af82d6df6f3b396487e3e27a826ca9cbbbecbe5f
+
+Note section [ 4] '.note.ABI-tag' of 32 bytes at offset 0x30c:
+ Owner Data size Type
+ GNU 16 GNU_ABI_TAG
+ OS: Linux, ABI: 3.7.0
+EOF
diff --git a/tests/run-test-includes.sh b/tests/run-test-includes.sh
new file mode 100755
index 00000000..b0ccdd9b
--- /dev/null
+++ b/tests/run-test-includes.sh
@@ -0,0 +1,26 @@
+# All public include headers should be usable "standalone".
+
+. $srcdir/test-subr.sh
+
+echo '#include "libelf.h"' \
+ | gcc -c -o /dev/null -I ${abs_srcdir}/../libelf -xc -
+echo '#include "gelf.h"' \
+ | gcc -c -o /dev/null -I ${abs_srcdir}/../libelf -xc -
+
+echo '#include "dwarf.h"' \
+ | gcc -c -o /dev/null -I ${abs_srcdir}/../libelf \
+ -I ${abs_srcdir}/../libdw -xc -
+echo '#include "libdw.h"' \
+ | gcc -c -o /dev/null -I ${abs_srcdir}/../libelf \
+ -I ${abs_srcdir}/../libdw -xc -
+
+echo '#include "libdwfl.h"' \
+ | gcc -c -o /dev/null -I ${abs_srcdir}/../libelf \
+ -I ${abs_srcdir}/../libdw -I ${abs_srcdir}/../libdwfl -xc -
+echo '#include "libdwelf.h"' \
+ | gcc -c -o /dev/null -I ${abs_srcdir}/../libelf \
+ -I ${abs_srcdir}/../libdw -I ${abs_srcdir}/../libdwelf -xc -
+
+echo '#include "libasm.h"' \
+ | gcc -c -o /dev/null -I ${abs_srcdir}/../libelf \
+ -I ${abs_srcdir}/../libasm -xc -
diff --git a/tests/testfile-gnu-property-note-aarch64.bz2 b/tests/testfile-gnu-property-note-aarch64.bz2
new file mode 100755
index 00000000..2fe37b19
--- /dev/null
+++ b/tests/testfile-gnu-property-note-aarch64.bz2
Binary files differ