diff options
author | Paulo Neves <ptsneves@gmail.com> | 2022-06-14 17:11:02 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-07-01 12:37:52 +0100 |
commit | 53f0ee8d420008efa7408b1a83c42f7d5438f06a (patch) | |
tree | a43ee843978a20bf5de843302ea32f20ce5545a8 /meta-selftest/recipes-test | |
parent | 82589b5936df1b0ad55ebd5961f3943d33f8bacc (diff) | |
download | poky-53f0ee8d420008efa7408b1a83c42f7d5438f06a.tar.gz |
oeqa/selftest: Add test for shebang overflow
Make sure we do not stage any executable with a bigger shebang
than 128. Fixes [1]
[1] https://bugzilla.yoctoproject.org/show_bug.cgi?id=11053
(From OE-Core rev: 280f68528c93b5ffab888c99190accf59e807a3f)
Signed-off-by: Paulo Neves <ptsneves@gmail.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta-selftest/recipes-test')
-rw-r--r-- | meta-selftest/recipes-test/sysroot-test/sysroot-shebang-test_1.0.bb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/meta-selftest/recipes-test/sysroot-test/sysroot-shebang-test_1.0.bb b/meta-selftest/recipes-test/sysroot-test/sysroot-shebang-test_1.0.bb new file mode 100644 index 0000000000..6c834be897 --- /dev/null +++ b/meta-selftest/recipes-test/sysroot-test/sysroot-shebang-test_1.0.bb | |||
@@ -0,0 +1,12 @@ | |||
1 | SUMMARY = "Check that shebang does not exceed 128 characters" | ||
2 | LICENSE = "CLOSED" | ||
3 | INHIBIT_DEFAULT_DEPS = "1" | ||
4 | |||
5 | EXCLUDE_FROM_WORLD = "1" | ||
6 | do_install() { | ||
7 | install -d ${D}${bindir} | ||
8 | echo '#!BiM3cnVd1Amtv6PG+FynrQiVMbZnX5ELgF21q3EkuB+44JEGWtq8TvBJ7EGidfVs3eR3wVOUbLnjYDlKUWcm7YC/ute7f+KDHbwxziRUSUBZAUqgjiQdfQ0HnxajI0ozbM863E9JV9k13yZKYfh9/zR77Y6Dl4Dd3zOWS75LSpkAXV' > ${D}${bindir}/max-shebang | ||
9 | chmod 755 ${D}${bindir}/max-shebang | ||
10 | } | ||
11 | |||
12 | BBCLASSEXTEND = "native" | ||