Compare commits
285 Commits
master
...
f37-riscv6
Author | SHA1 | Date | |
---|---|---|---|
4ee607d3a9 | |||
|
c75ea5b05f | ||
|
fa344eeb9c | ||
|
a55206c420 | ||
|
0190aaeb50 | ||
|
794d4708ef | ||
|
4cf5153ba7 | ||
|
2a644cdee4 | ||
|
278aadbc36 | ||
|
6af1867f17 | ||
|
d9744eac07 | ||
|
6aaecc9f93 | ||
|
f271cd9920 | ||
|
1f57bcbc2c | ||
|
6a039d67f0 | ||
|
e305a8053a | ||
|
f0bfd1e41e | ||
|
67f8a8d11a | ||
|
75736750e6 | ||
|
b464395c19 | ||
|
2e205722fd | ||
|
e0ddeb63a3 | ||
|
098cf0d690 | ||
|
3de80672fa | ||
|
d4466f7406 | ||
|
eceb178173 | ||
|
c2186bc772 | ||
|
8b1a765248 | ||
|
8ee18a899b | ||
|
14685185f1 | ||
|
d5f69acf32 | ||
|
6cdacc7a72 | ||
|
c712a9f799 | ||
|
1301bfec6a | ||
|
ac454f15f0 | ||
|
c9b3e0dcfe | ||
|
d6d59a73a8 | ||
|
43a0cd19e4 | ||
|
1b6c8e58c5 | ||
|
4f1eb1f73a | ||
|
41efc42594 | ||
|
5b4731b0ac | ||
|
21338bea37 | ||
|
9cdecda9e3 | ||
|
8c2f473929 | ||
|
8e76478b1d | ||
|
a6710fda16 | ||
|
4852d3d782 | ||
|
86fbdc98e6 | ||
|
dfa29772c3 | ||
|
7cf2a96973 | ||
|
f7e1805543 | ||
|
449fc20654 | ||
|
557b866dd0 | ||
|
9816f99346 | ||
|
a6ef977e8b | ||
|
efff188861 | ||
|
244433eec3 | ||
|
c53c5783da | ||
|
b097ccc79b | ||
|
a40c58d2d4 | ||
|
ffabcb06f2 | ||
|
550ef1b763 | ||
|
c34a9f5bc5 | ||
|
a14426ce95 | ||
|
ee78766bff | ||
|
0000a56eab | ||
|
1e262d15b3 | ||
|
b4ba4e0d3c | ||
|
ec8f2b145d | ||
|
15b34fde9c | ||
|
7c94cb66cc | ||
|
0c278a5d73 | ||
|
0e6be40a3c | ||
|
77a92a7119 | ||
|
d83b796c87 | ||
|
ce231f4bd9 | ||
|
c7d76e06c2 | ||
|
c99cca3ac4 | ||
|
3bf68f34bb | ||
|
14b9ff320e | ||
|
9fd7a9a7dc | ||
|
ddf58cca97 | ||
|
cfbdb08f28 | ||
|
5faade2ad7 | ||
|
92c34892f6 | ||
|
18219884f1 | ||
|
ee53f9336e | ||
|
7add09b73e | ||
|
7f58204567 | ||
|
0bd26e8615 | ||
|
3f7c00bf57 | ||
|
7bc94a3f7c | ||
|
0c5b1fec47 | ||
|
ab631794b6 | ||
|
8477e1751d | ||
|
825be9a6a2 | ||
|
f1b2a85f11 | ||
|
f25c7c2336 | ||
|
efe8b5622b | ||
|
c27947f871 | ||
|
37b5de8c9b | ||
|
5f79645f58 | ||
|
da3ba09492 | ||
|
c62bd663ec | ||
|
ee93527317 | ||
|
0aa5d1ce55 | ||
|
a99d618d38 | ||
|
92cb681581 | ||
|
fe496281b3 | ||
|
9d82370d42 | ||
|
ba44d58e22 | ||
|
29d70de971 | ||
|
1d5918a750 | ||
|
5e4c738a8f | ||
|
be3e1af704 | ||
|
ced3a24210 | ||
|
7a0769e513 | ||
|
5d4d27dda9 | ||
|
6d69597433 | ||
|
438dd33afc | ||
|
c76d8664da | ||
|
75a23fb883 | ||
|
71f8485e39 | ||
|
4af05b1261 | ||
|
0394c1d928 | ||
|
8155573258 | ||
|
dd22b2eaf4 | ||
|
80ffabd2a3 | ||
|
8adc17e68b | ||
|
5bbd4f5f31 | ||
|
a978ea49fa | ||
|
dfddf61cdd | ||
|
76947e83c2 | ||
|
14c8067c11 | ||
|
a9360e73d9 | ||
|
f1a1007e43 | ||
|
96f1a8a19f | ||
|
55304ea386 | ||
|
524ebdae25 | ||
|
993873ad36 | ||
|
1c617b1ec0 | ||
|
45b479d2d6 | ||
|
81adad3f31 | ||
|
a9f3f30da4 | ||
|
394bd0083f | ||
|
689a7f6f54 | ||
|
e5cf20e0a3 | ||
|
9e62aa8ed8 | ||
|
99c1127a11 | ||
|
1622358fc1 | ||
|
60b4b4fa76 | ||
|
604b1841b5 | ||
|
7d1af348fb | ||
|
62f4dedb91 | ||
|
985cb77f4c | ||
|
1d6e1bf892 | ||
|
296c2a76fb | ||
|
90e03be330 | ||
|
d57da4f976 | ||
|
c910f2212a | ||
|
4a7311622e | ||
|
60c8169066 | ||
|
1720e01afe | ||
|
891fad1c0c | ||
|
a35ca900df | ||
|
92c8279fc3 | ||
|
2cfdfdf4f4 | ||
|
ebf96c4e2b | ||
|
7c61286322 | ||
|
3a4181e531 | ||
|
df15f450f0 | ||
|
1874eab6f1 | ||
|
8b182011da | ||
|
d119c7a74a | ||
|
3bac683d82 | ||
|
f470483cbf | ||
|
5509907436 | ||
|
1032ac3725 | ||
|
4a3a6f104e | ||
|
8e0683cc13 | ||
|
409120aa01 | ||
|
d7a90f1991 | ||
|
46640ca3dc | ||
|
e1bd496eeb | ||
|
dc5d2731d4 | ||
|
ec71c316e1 | ||
|
44aadc55ff | ||
|
841b371c4b | ||
|
252b28fa8e | ||
|
2662d34233 | ||
|
432e8594c3 | ||
|
a057c0a359 | ||
|
ebfb417770 | ||
|
62931e922e | ||
|
24fe187a8d | ||
|
3e0594350d | ||
|
3ed514a41c | ||
|
ea02dafc1f | ||
|
b333964fd5 | ||
|
62e7074ffd | ||
|
5b0e474e77 | ||
|
3cff478cb4 | ||
|
33cfa7d0eb | ||
|
c0eabbb63f | ||
|
e6e8317766 | ||
|
34a622f99e | ||
|
5b5750dca2 | ||
|
2b20a13c51 | ||
|
a87d8021be | ||
|
a707c7d43e | ||
|
440266bff3 | ||
|
70bb1086ca | ||
|
b2d7c66572 | ||
|
d69789a4b8 | ||
|
5515ddd6c9 | ||
|
d94f0f89ce | ||
|
ad2a3b8d06 | ||
|
5a05a4d64e | ||
|
a305baad65 | ||
|
087486d90e | ||
|
353a681587 | ||
|
397174a269 | ||
|
d9c1db450f | ||
|
057676c5e3 | ||
|
16d8c4b5fe | ||
|
1c15fe568b | ||
|
43a0359804 | ||
|
6e6cadfea2 | ||
|
932b17dd34 | ||
|
3ab9323c0b | ||
|
b034a2c7c1 | ||
|
afb29d7d9f | ||
|
229003f625 | ||
|
8840f2fcb9 | ||
|
6fd2366132 | ||
|
9f46ccb4ce | ||
|
c4f24c4ee5 | ||
|
225ffdc722 | ||
|
459acd6cb6 | ||
|
ec93f17ffa | ||
|
dcdc0af39b | ||
|
dcc513660a | ||
|
82024ae45f | ||
|
25d4740c92 | ||
|
ba9486d50e | ||
|
b1078c0c21 | ||
|
fd8169aaee | ||
|
46ef9ab08d | ||
|
1a0dc72791 | ||
|
1defc985fc | ||
|
5770b9a0d8 | ||
|
09d5b50939 | ||
|
cb98e5f903 | ||
|
5d051cb7a7 | ||
|
f7f58a9fb9 | ||
|
e8f56c0bdb | ||
|
1fa49e66f8 | ||
|
eb569a62e1 | ||
|
2b9645b749 | ||
|
dba13c4fd1 | ||
|
4c77fc39e7 | ||
|
30290e7bd6 | ||
|
3317ae10db | ||
|
b22155004c | ||
|
23baf8b1d3 | ||
|
3755b69778 | ||
|
980573dc2e | ||
|
476968a31a | ||
|
8997d89f3d | ||
|
9c95399d00 | ||
|
27da4aee96 | ||
|
df1c169d82 | ||
|
9f8f0cdd01 | ||
|
d97bf868e7 | ||
|
fff201eb4f | ||
|
046883693b | ||
|
07e0a5ab8f | ||
|
59663eb6dc | ||
|
c240981e82 | ||
|
af41c06a9f | ||
|
16503862ea | ||
|
b6d4688b8a | ||
|
4a6b895755 | ||
|
978810c39d |
1
.fmf/version
Normal file
1
.fmf/version
Normal file
@ -0,0 +1 @@
|
|||||||
|
1
|
108
.gitignore
vendored
108
.gitignore
vendored
@ -1,106 +1,2 @@
|
|||||||
/annobin-2.0.tar.xz
|
/annobin-*.tar.xz
|
||||||
/annobin-2.1.tar.xz
|
/annobin-9.51-1.fc34.src.rpm
|
||||||
/annobin-2.2.tar.xz
|
|
||||||
/annobin-2.3.tar.lz
|
|
||||||
/annobin-2.3.tar.xz
|
|
||||||
/annobin-2.4.tar.xz
|
|
||||||
/annobin-2.5.tar.xz
|
|
||||||
/annobin-2.5.1.tar.xz
|
|
||||||
/annobin-3.0.tar.xz
|
|
||||||
/annobin-3.1.tar.xz
|
|
||||||
/annobin-3.2.tar.xz
|
|
||||||
/annobin-3.3.tar.xz
|
|
||||||
/annobin-3.4.tar.xz
|
|
||||||
/annobin-3.5.tar.xz
|
|
||||||
/annobin-3.6.tar.xz
|
|
||||||
/annobin-5.0.tar.xz
|
|
||||||
/annobin-5.1.tar.xz
|
|
||||||
/annobin-5.2.tar.xz
|
|
||||||
/annobin-5.3.tar.xz
|
|
||||||
/annobin-5.4.tar.xz
|
|
||||||
/annobin-5.5.tar.xz
|
|
||||||
/annobin-5.6.tar.xz
|
|
||||||
/annobin-5.7.tar.xz
|
|
||||||
/annobin-5.8.tar.xz
|
|
||||||
/annobin-5.9.tar.xz
|
|
||||||
/annobin-5.10.tar.xz
|
|
||||||
/annobin-5.11.tar.xz
|
|
||||||
/annobin-6.0.tar.xz
|
|
||||||
/annobin-6.1.tar.xz
|
|
||||||
/annobin-6.2.tar.xz
|
|
||||||
/annobin-6.3.tar.xz
|
|
||||||
/annobin-6.4.tar.xz
|
|
||||||
/annobin-6.5.tar.xz
|
|
||||||
/annobin-6.6.tar.xz
|
|
||||||
/annobin-7.0.tar.xz
|
|
||||||
/annobin-7.1.tar.xz
|
|
||||||
/annobin-8.0.tar.xz
|
|
||||||
/annobin-8.1.tar.xz
|
|
||||||
/annobin-8.2.tar.xz
|
|
||||||
/annobin-8.3.tar.xz
|
|
||||||
/annobin-8.4.tar.xz
|
|
||||||
/annobin-8.5.tar.xz
|
|
||||||
/annobin-8.6.tar.xz
|
|
||||||
/annobin-8.7.tar.xz
|
|
||||||
/annobin-8.8.tar.xz
|
|
||||||
/annobin-8.9.tar.xz
|
|
||||||
/annobin-8.10.tar.xz
|
|
||||||
/annobin-8.11.tar.xz
|
|
||||||
/annobin-8.12.tar.xz
|
|
||||||
/annobin-8.13.tar.xz
|
|
||||||
/annobin-8.14.tar.xz
|
|
||||||
/annobin-8.15.tar.xz
|
|
||||||
/annobin-8.16.tar.xz
|
|
||||||
/annobin-8.17.tar.xz
|
|
||||||
/annobin-8.18.tar.xz
|
|
||||||
/annobin-8.19.tar.xz
|
|
||||||
/annobin-8.20.tar.xz
|
|
||||||
/annobin-8.21.tar.xz
|
|
||||||
/annobin-8.22.tar.xz
|
|
||||||
/annobin-8.23.tar.xz
|
|
||||||
/annobin-8.24.tar.xz
|
|
||||||
/annobin-8.25.tar.xz
|
|
||||||
/annobin-8.26.tar.xz
|
|
||||||
/annobin-8.27.tar.xz
|
|
||||||
/annobin-8.29.tar.xz
|
|
||||||
/annobin-8.30.tar.xz
|
|
||||||
/annobin-8.31.tar.xz
|
|
||||||
/annobin-8.32.tar.xz
|
|
||||||
/annobin-8.33.tar.xz
|
|
||||||
/annobin-8.34.tar.xz
|
|
||||||
/annobin-8.35.tar.xz
|
|
||||||
/annobin-8.36.tar.xz
|
|
||||||
/annobin-8.37.tar.xz
|
|
||||||
/annobin-8.38.tar.xz
|
|
||||||
/annobin-8.39.tar.xz
|
|
||||||
/annobin-8.41.tar.xz
|
|
||||||
/annobin-8.44.tar.xz
|
|
||||||
/annobin-8.45.tar.xz
|
|
||||||
/annobin-8.48.tar.xz
|
|
||||||
/annobin-8.49.tar.xz
|
|
||||||
/annobin-8.50.tar.xz
|
|
||||||
/annobin-8.51.tar.xz
|
|
||||||
/annobin-8.52.tar.xz
|
|
||||||
/annobin-8.53.tar.xz
|
|
||||||
/annobin-8.55.tar.xz
|
|
||||||
/annobin-8.56.tar.xz
|
|
||||||
/annobin-8.57.tar.xz
|
|
||||||
/annobin-8.58.tar.xz
|
|
||||||
/annobin-8.59.tar.xz
|
|
||||||
/annobin-8.60.tar.xz
|
|
||||||
/annobin-8.61.tar.xz
|
|
||||||
/annobin-8.62.tar.xz
|
|
||||||
/annobin-8.63.tar.xz
|
|
||||||
/annobin-8.64.tar.xz
|
|
||||||
/annobin-8.65.tar.xz
|
|
||||||
/annobin-8.66.tar.xz
|
|
||||||
/annobin-8.67.tar.xz
|
|
||||||
/annobin-8.68.tar.xz
|
|
||||||
/annobin-8.69.tar.xz
|
|
||||||
/annobin-8.70.tar.xz
|
|
||||||
/annobin-8.71.tar.xz
|
|
||||||
/annobin-8.72.tar.xz
|
|
||||||
/annobin-8.73.tar.xz
|
|
||||||
/annobin-8.74.tar.xz
|
|
||||||
/annobin-8.76.tar.xz
|
|
||||||
/annobin-8.77.tar.xz
|
|
||||||
|
1236
annobin.spec
1236
annobin.spec
File diff suppressed because it is too large
Load Diff
20
gating.yaml
Normal file
20
gating.yaml
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
--- !Policy
|
||||||
|
product_versions:
|
||||||
|
- fedora-*
|
||||||
|
decision_context: bodhi_update_push_stable
|
||||||
|
subject_type: koji_build
|
||||||
|
rules:
|
||||||
|
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}
|
||||||
|
- !PassingTestCaseRule {test_case_name: baseos-qe.koji-build.scratch-build.validation}
|
||||||
|
--- !Policy
|
||||||
|
product_versions:
|
||||||
|
- rhel-8
|
||||||
|
decision_context: osci_compose_gate
|
||||||
|
rules:
|
||||||
|
- !PassingTestCaseRule {test_case_name: baseos-ci.brew-build.tier1.functional}
|
||||||
|
--- !Policy
|
||||||
|
product_versions:
|
||||||
|
- rhel-9
|
||||||
|
decision_context: osci_compose_gate
|
||||||
|
rules:
|
||||||
|
- !PassingTestCaseRule {test_case_name: baseos-ci.brew-build.tier1.functional}
|
6
plans/ci.fmf
Normal file
6
plans/ci.fmf
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
summary: CI Gating Plan
|
||||||
|
discover:
|
||||||
|
how: fmf
|
||||||
|
directory: tests
|
||||||
|
execute:
|
||||||
|
how: beakerlib
|
2
sources
2
sources
@ -1 +1 @@
|
|||||||
SHA512 (annobin-8.77.tar.xz) = d9d393aa359ab58a24d295dd4108b0255e39cf9210ec99125ce3f3589adff795aba50234817b38134964caa2fc92cf04d6c6e2945ae6cc2e1145033383cc58cb
|
SHA512 (annobin-10.91.tar.xz) = d7c6e77f3e0385dccf1bb3fba4804675a679ec02a192768974ccad22350dcf6858232708189615ee3063da83b0372afca5b66d82282df49903cd4178913fa9d2
|
||||||
|
2
tests/README
Normal file
2
tests/README
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
The test's Makefiles are not used in Fedora CI infrastructure. But are kept here
|
||||||
|
for backward compatibility with traditional beakerlib test harness in RHEL.
|
@ -0,0 +1,16 @@
|
|||||||
|
summary: Test for BZ#1958954 (annobin fails to skip endbr64 entry point check)
|
||||||
|
description: |
|
||||||
|
Bug summary: annobin fails to skip endbr64 entry point check for shared objects
|
||||||
|
Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1958954
|
||||||
|
contact:
|
||||||
|
- Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- annobin-annocheck
|
||||||
|
- gcc
|
||||||
|
duration: 48h
|
||||||
|
extra-summary: /tools/annobin/Regression/annobin-fails-to-skip-endbr64-entry-point-check
|
||||||
|
extra-task: /tools/annobin/Regression/annobin-fails-to-skip-endbr64-entry-point-check
|
54
tests/Regression/annobin-fails-to-skip-endbr64-entry-point-check/runtest.sh
Executable file
54
tests/Regression/annobin-fails-to-skip-endbr64-entry-point-check/runtest.sh
Executable file
@ -0,0 +1,54 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Regression/annobin-fails-to-skip-endbr64-entry-point-check
|
||||||
|
# Description: Test for BZ#1958954 (annobin fails to skip endbr64 entry point check)
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2021 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartSetup
|
||||||
|
rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory"
|
||||||
|
rlRun "pushd $TmpDir"
|
||||||
|
rlRun "rpm -q annobin-annocheck gcc"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "echo 'void f1(void) {}' > f1.c"
|
||||||
|
rlRun "echo 'void f2(void) {}' > f2.c"
|
||||||
|
rlRun "gcc `rpm --eval %build_cflags` -fpic -c f1.c"
|
||||||
|
rlRun "gcc `rpm --eval %build_cflags` -fpic -c f2.c"
|
||||||
|
rlRun "gcc `rpm --eval %build_ldflags` -shared f1.o f2.o"
|
||||||
|
rlRun "annocheck -v a.out"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartCleanup
|
||||||
|
rlRun "popd"
|
||||||
|
rlRun "rm -r $TmpDir" 0 "Removing tmp directory"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
21
tests/Regression/identify/main.fmf
Normal file
21
tests/Regression/identify/main.fmf
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
summary: identify
|
||||||
|
description: ''
|
||||||
|
contact:
|
||||||
|
- Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- annobin
|
||||||
|
- devtoolset-10
|
||||||
|
- devtoolset-10-annocheck
|
||||||
|
- devtoolset-11
|
||||||
|
- devtoolset-11-annocheck
|
||||||
|
- gcc-toolset-10
|
||||||
|
- gcc-toolset-10-annocheck
|
||||||
|
- gcc-toolset-11
|
||||||
|
- gcc-toolset-11-annocheck
|
||||||
|
duration: 48h
|
||||||
|
extra-summary: /tools/annobin/Regression/identify
|
||||||
|
extra-task: /tools/annobin/Regression/identify
|
43
tests/Regression/identify/runtest.sh
Executable file
43
tests/Regression/identify/runtest.sh
Executable file
@ -0,0 +1,43 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Regression/identify
|
||||||
|
# Description: identify
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2019 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "rpm -qa | fgrep -e redhat-rpm-config -e gcc -e annobin -e binutils | sort"
|
||||||
|
rlRun "tool_v=$(annocheck --version | awk '/^annocheck: Version/ {print $3}')"
|
||||||
|
rlRun "__RPM=$(rpm --queryformat='%{name}\n' -qf $(man -w annobin))"
|
||||||
|
rlRun "rpm_v=$(rpm -q --queryformat='%{version}\n' $__RPM)"
|
||||||
|
# Following fails for annobin-8.89-2.el8
|
||||||
|
rlRun "[[ "x${tool_v}" == "x${rpm_v}." ]]"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
16
tests/Regression/lto-preprocessor-options/main.fmf
Normal file
16
tests/Regression/lto-preprocessor-options/main.fmf
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
summary: lto-preprocessor-options
|
||||||
|
description: ''
|
||||||
|
contact:
|
||||||
|
- Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- gcc
|
||||||
|
- annobin
|
||||||
|
- annobin-annocheck
|
||||||
|
- redhat-rpm-config
|
||||||
|
duration: 48h
|
||||||
|
extra-summary: /tools/annobin/Regression/lto-preprocessor-options
|
||||||
|
extra-task: /tools/annobin/Regression/lto-preprocessor-options
|
44
tests/Regression/lto-preprocessor-options/runtest.sh
Executable file
44
tests/Regression/lto-preprocessor-options/runtest.sh
Executable file
@ -0,0 +1,44 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Regression/lto-preprocessor-options
|
||||||
|
# Description: lto-preprocessor-options
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2020 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartTest
|
||||||
|
b=`mktemp`
|
||||||
|
rlRun "rpm -qa | fgrep -e redhat-rpm-config -e gcc -e annobin -e binutils | sort"
|
||||||
|
rlRun "cflags=\"$(rpm --eval '%build_cflags')\""
|
||||||
|
rlRun "ldflags=\"$(rpm --eval '%build_ldflags')\""
|
||||||
|
rlRun "echo 'int main (void) { return 0; }' | gcc -xc -o $b $cflags $ldflags -flto - "
|
||||||
|
rlRun "annocheck -v $b"
|
||||||
|
rm $b
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
Binary file not shown.
@ -0,0 +1,16 @@
|
|||||||
|
summary: missing-check-for-x86-property-note-content
|
||||||
|
description: |
|
||||||
|
Bug summary: annobin: Missing check for contents of x86 property note
|
||||||
|
Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1991931
|
||||||
|
contact: Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- annobin
|
||||||
|
duration: 48h
|
||||||
|
link:
|
||||||
|
- relates: https://bugzilla.redhat.com/show_bug.cgi?id=1991931
|
||||||
|
extra-summary: /tools/annobin/Regression/missing-check-for-x86-property-note-content
|
||||||
|
extra-task: /tools/annobin/Regression/missing-check-for-x86-property-note-content
|
40
tests/Regression/missing-check-for-x86-property-note-content/runtest.sh
Executable file
40
tests/Regression/missing-check-for-x86-property-note-content/runtest.sh
Executable file
@ -0,0 +1,40 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Regression/missing-check-for-x86-property-note-content
|
||||||
|
# Description: missing-check-for-x86-property-note-content
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2021 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "annocheck main" 1
|
||||||
|
rlRun "annocheck --fixed-format-messages main | \
|
||||||
|
grep '^Hardened: FAIL: test: cf-protection file: main.$'"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
16
tests/Regression/processing-params-in-reverse-order/main.fmf
Normal file
16
tests/Regression/processing-params-in-reverse-order/main.fmf
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
summary: processing-params-in-reverse-order
|
||||||
|
description: |
|
||||||
|
Bug summary: annocheck processes (reports) parameters in reverse order
|
||||||
|
Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1988714
|
||||||
|
contact: Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- annobin
|
||||||
|
duration: 48h
|
||||||
|
link:
|
||||||
|
- relates: https://bugzilla.redhat.com/show_bug.cgi?id=1988714
|
||||||
|
extra-summary: /tools/annobin/Regression/processing-params-in-reverse-order
|
||||||
|
extra-task: /tools/annobin/Regression/processing-params-in-reverse-order
|
42
tests/Regression/processing-params-in-reverse-order/runtest.sh
Executable file
42
tests/Regression/processing-params-in-reverse-order/runtest.sh
Executable file
@ -0,0 +1,42 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Regression/processing-params-in-reverse-order
|
||||||
|
# Description: processing-params-in-reverse-order
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2021 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "TMP=$(mktemp)"
|
||||||
|
rlRun "annocheck --verbose --skip-all --test-stack-prot /bin/bash /bin/cat |& tee $TMP"
|
||||||
|
rlRun "fgrep -i /bin/ $TMP | head -1 | fgrep /bash"
|
||||||
|
rlRun "fgrep -i /bin/ $TMP | tail -1 | fgrep /cat"
|
||||||
|
rlRun "rm -f $TMP"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
@ -0,0 +1,17 @@
|
|||||||
|
summary: segv-when-processing-multiple-params-incl-symlink
|
||||||
|
description: |
|
||||||
|
Bug summary: annocheck segfaults sometimes when processing multiple parameters and symlink is involved
|
||||||
|
Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1988715
|
||||||
|
contact: Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- annobin
|
||||||
|
- libstdc++
|
||||||
|
duration: 48h
|
||||||
|
link:
|
||||||
|
- relates: https://bugzilla.redhat.com/show_bug.cgi?id=1988715
|
||||||
|
extra-summary: /tools/annobin/Regression/segv-when-processing-multiple-params-incl-symlink
|
||||||
|
extra-task: /tools/annobin/Regression/segv-when-processing-multiple-params-incl-symlink
|
@ -0,0 +1,44 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Regression/segv-when-processing-multiple-params-incl-symlink
|
||||||
|
# Description: segv-when-processing-multiple-params-incl-symlink
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2021 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartTest
|
||||||
|
# This tries to test https://bugzilla.redhat.com/show_bug.cgi?id=1988715#c0
|
||||||
|
# keeping in mind that annocheck will evolve in the future, along its
|
||||||
|
# rules / policies, and the surrounding OS will evolve too. This test
|
||||||
|
# shouldn't report false positives though.
|
||||||
|
rlRun "rpm -qf /usr/lib64/libstdc++.so*"
|
||||||
|
rlRun "annocheck --follow-links --skip-all /usr/lib64/libstdc++.so*"
|
||||||
|
rlRun "annocheck --ignore-links --skip-all /usr/lib64/libstdc++.so*"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
28
tests/Regression/testsuite/main.fmf
Normal file
28
tests/Regression/testsuite/main.fmf
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
summary: testsuite
|
||||||
|
description: ''
|
||||||
|
contact:
|
||||||
|
- Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- annobin
|
||||||
|
- annobin-annocheck
|
||||||
|
- binutils-devel
|
||||||
|
- gcc
|
||||||
|
- gcc-c++
|
||||||
|
- elfutils
|
||||||
|
- elfutils-devel
|
||||||
|
- make
|
||||||
|
- rpm-build
|
||||||
|
- rpm-devel
|
||||||
|
- gcc-plugin-devel
|
||||||
|
- yum
|
||||||
|
- dnf
|
||||||
|
- yum-utils
|
||||||
|
- bzip2-devel
|
||||||
|
- rpm-build
|
||||||
|
duration: 48h
|
||||||
|
extra-summary: /tools/annobin/Regression/testsuite
|
||||||
|
extra-task: /tools/annobin/Regression/testsuite
|
85
tests/Regression/testsuite/runtest.sh
Executable file
85
tests/Regression/testsuite/runtest.sh
Executable file
@ -0,0 +1,85 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Regression/testsuite
|
||||||
|
# Description: testsuite
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2018 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="${PACKAGE:-$(rpm -qf --queryformat=%{name} $(man -w annobin))}"
|
||||||
|
export PACKAGE
|
||||||
|
|
||||||
|
GCC="${GCC:-$(which gcc)}"
|
||||||
|
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartSetup
|
||||||
|
rlLogInfo "PACKAGES=$PACKAGES"
|
||||||
|
rlLogInfo "REQUIRES=$REQUIRES"
|
||||||
|
rlLogInfo "COLLECTIONS=$COLLECTIONS"
|
||||||
|
rlLogInfo "X_SCLS=$X_SCLS"
|
||||||
|
rlLogInfo "GCC=$GCC"
|
||||||
|
|
||||||
|
rlRun "rpm -qa | fgrep -e redhat-rpm-config -e gcc -e annobin -e binutils | sort"
|
||||||
|
|
||||||
|
# In case more than one devtoolset- or gcc-toolset -build package is
|
||||||
|
# installed (they can co-exist from the packaging persp, but their
|
||||||
|
# coexistence causes unexpected results with rpm macros), then we have
|
||||||
|
# a mess of defined rpm macros coming e.g. from
|
||||||
|
# /etc/rpm/macros.gcc-toolset-10-config
|
||||||
|
# /etc/rpm/macros.gcc-toolset-9-config etc. To have just the needed
|
||||||
|
# macros (respective to given SCL under test) defined without
|
||||||
|
# uninstalling unneeded RPMs, we'll need an override mechanism. The
|
||||||
|
# following assumes just one SCL *enabled* (more than one installed),
|
||||||
|
# and doesn't care of a (useless) revert:
|
||||||
|
echo ${X_SCLS} | fgrep toolset && \
|
||||||
|
rlRun "cat /etc/rpm/*${X_SCLS%\ }* > ~/.rpmmacros"
|
||||||
|
|
||||||
|
rlAssertRpm $PACKAGE
|
||||||
|
rlRun "TMP=\$(mktemp -d)"
|
||||||
|
rlRun "pushd $TMP"
|
||||||
|
|
||||||
|
rlFetchSrcForInstalled $PACKAGE
|
||||||
|
rlRun "yum-builddep -y *src.rpm"
|
||||||
|
rlRun "rpm --define='_topdir $TMP' -Uvh *src.rpm"
|
||||||
|
rlRun "rpmbuild --define='_topdir $TMP' -bc SPECS/annobin.spec"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "pushd BUILD/annobin-*"
|
||||||
|
set -o pipefail
|
||||||
|
rlRun "make check |& tee $TMP/check.log"
|
||||||
|
rlRun -l "grep '^PASS:' $TMP/check.log" 0
|
||||||
|
rlRun -l "grep '^FAIL:' $TMP/check.log" 1
|
||||||
|
PASSCOUNT=$(grep '^PASS:' $TMP/check.log | wc -l)
|
||||||
|
rlRun "[[ $PASSCOUNT -ge 7 ]]"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartCleanup
|
||||||
|
rlRun "popd"
|
||||||
|
rlRun "rm -r $TMP"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
@ -0,0 +1,16 @@
|
|||||||
|
summary: Test for BZ#1973981 (annocheck silently ignores any file parameter)
|
||||||
|
description: |
|
||||||
|
Bug summary: annocheck silently ignores any file parameter beyond 256
|
||||||
|
Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1973981
|
||||||
|
contact: Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- annobin
|
||||||
|
duration: 48h
|
||||||
|
link:
|
||||||
|
- relates: https://bugzilla.redhat.com/show_bug.cgi?id=1973981
|
||||||
|
extra-summary: /tools/annobin/Sanity/annocheck-silently-ignores-any-file-parameter
|
||||||
|
extra-task: /tools/annobin/Sanity/annocheck-silently-ignores-any-file-parameter
|
54
tests/Sanity/annocheck-silently-ignores-any-file-parameter/runtest.sh
Executable file
54
tests/Sanity/annocheck-silently-ignores-any-file-parameter/runtest.sh
Executable file
@ -0,0 +1,54 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Sanity/annocheck-silently-ignores-any-file-parameter
|
||||||
|
# Description: Test for BZ#1973981 (annocheck silently ignores any file parameter)
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2021 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartSetup
|
||||||
|
rlRun "TMP=$(mktemp -d)"
|
||||||
|
rlRun "pushd $TMP"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartTest
|
||||||
|
for i in `seq 0 299`; do touch ${i}.sample; done
|
||||||
|
samplecnt=$(ls *.sample | wc -l)
|
||||||
|
testcnt=$(ls *.sample | \
|
||||||
|
xargs annocheck |& \
|
||||||
|
fgrep '.sample: is not an ELF format file' | wc -l)
|
||||||
|
rlRun "test $samplecnt -eq 300"
|
||||||
|
rlRun "test $testcnt -eq 300"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartCleanup
|
||||||
|
rlRun "popd"
|
||||||
|
rlRun "rm -r $TMP"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
5
tests/Sanity/gcc-fedora-flags/hello.c
Normal file
5
tests/Sanity/gcc-fedora-flags/hello.c
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
|
void hello() {
|
||||||
|
printf("Hello World\n");
|
||||||
|
}
|
5
tests/Sanity/gcc-fedora-flags/hello.cpp
Normal file
5
tests/Sanity/gcc-fedora-flags/hello.cpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#include <iostream>
|
||||||
|
|
||||||
|
void hello() {
|
||||||
|
std::cout << "Hello World\n";
|
||||||
|
}
|
6
tests/Sanity/gcc-fedora-flags/main.c
Normal file
6
tests/Sanity/gcc-fedora-flags/main.c
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
void hello();
|
||||||
|
|
||||||
|
int main(int argc, char **argv) {
|
||||||
|
hello();
|
||||||
|
return 0;
|
||||||
|
}
|
6
tests/Sanity/gcc-fedora-flags/main.cpp
Normal file
6
tests/Sanity/gcc-fedora-flags/main.cpp
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
void hello();
|
||||||
|
|
||||||
|
int main(int argc, char **argv) {
|
||||||
|
hello();
|
||||||
|
return 0;
|
||||||
|
}
|
17
tests/Sanity/gcc-fedora-flags/main.fmf
Normal file
17
tests/Sanity/gcc-fedora-flags/main.fmf
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
summary: gcc-fedora-flags
|
||||||
|
description: ''
|
||||||
|
contact:
|
||||||
|
- Tom Stellard <tstellar@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- gcc
|
||||||
|
- gcc-c++
|
||||||
|
- annobin
|
||||||
|
- annobin-annocheck
|
||||||
|
- redhat-rpm-config
|
||||||
|
duration: 1h
|
||||||
|
extra-summary: /tools/annobin/Sanity/gcc-fedora-flags
|
||||||
|
extra-task: /tools/annobin/Sanity/gcc-fedora-flags
|
40
tests/Sanity/gcc-fedora-flags/runtest.sh
Executable file
40
tests/Sanity/gcc-fedora-flags/runtest.sh
Executable file
@ -0,0 +1,40 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
set -x
|
||||||
|
|
||||||
|
default_cflags=`rpm -E %{build_cflags}`
|
||||||
|
default_cxxflags=`rpm -E %{build_cxxflags}`
|
||||||
|
default_ldflags=`rpm -E %{build_ldflags}`
|
||||||
|
|
||||||
|
cflags=`rpm -D '%toolchain gcc' -E %{build_cflags}`
|
||||||
|
cxxflags=`rpm -D '%toolchain gcc' -E %{build_cxxflags}`
|
||||||
|
ldflags=`rpm -D '%toolchain gcc' -E %{build_ldflags}`
|
||||||
|
|
||||||
|
set +x
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "rpm -qa | fgrep -e redhat-rpm-config -e gcc -e annobin -e binutils | sort"
|
||||||
|
|
||||||
|
rlRun "test \"$default_cflags\" = \"$cflags\""
|
||||||
|
rlRun "test \"$default_cxxflags\" = \"$cxxflags\""
|
||||||
|
rlRun "test \"$default_ldflags\" = \"$ldflags\""
|
||||||
|
|
||||||
|
rlRun "gcc $cflags -o hello.o -c hello.c"
|
||||||
|
rlRun "annocheck hello.o"
|
||||||
|
rlRun "gcc $cflags -o main.o -c main.c"
|
||||||
|
rlRun "gcc $ldflags -o hello main.o hello.o"
|
||||||
|
rlRun "annocheck hello"
|
||||||
|
rlRun "./hello | grep \"Hello World\""
|
||||||
|
|
||||||
|
rlRun "g++ $cxxflags -o hello-cpp.o -c hello.cpp"
|
||||||
|
rlRun "annocheck hello-cpp.o"
|
||||||
|
rlRun "g++ $cxxflags -o main-cpp.o -c main.cpp"
|
||||||
|
rlRun "g++ $ldflags -o hello-cpp main-cpp.o hello-cpp.o"
|
||||||
|
rlRun "annocheck hello-cpp"
|
||||||
|
rlRun "./hello-cpp | grep \"Hello World\""
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
16
tests/Sanity/smoke/main.fmf
Normal file
16
tests/Sanity/smoke/main.fmf
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
summary: smoke test for annobin plugin
|
||||||
|
description: ''
|
||||||
|
contact:
|
||||||
|
- Martin Cermak <mcermak@redhat.com>
|
||||||
|
component:
|
||||||
|
- annobin
|
||||||
|
test: ./runtest.sh
|
||||||
|
framework: beakerlib
|
||||||
|
recommend:
|
||||||
|
- man-db
|
||||||
|
- gcc
|
||||||
|
- annobin
|
||||||
|
- annobin-annocheck
|
||||||
|
duration: 48h
|
||||||
|
extra-summary: /tools/annobin/Sanity/smoke
|
||||||
|
extra-task: /tools/annobin/Sanity/smoke
|
45
tests/Sanity/smoke/runtest.sh
Executable file
45
tests/Sanity/smoke/runtest.sh
Executable file
@ -0,0 +1,45 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# runtest.sh of /tools/annobin/Sanity/smoke
|
||||||
|
# Description: smoke test for annobin plugin
|
||||||
|
# Author: Martin Cermak <mcermak@redhat.com>
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
#
|
||||||
|
# Copyright (c) 2019 Red Hat, Inc.
|
||||||
|
#
|
||||||
|
# This program 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 2 of
|
||||||
|
# the License, or (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program 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/.
|
||||||
|
#
|
||||||
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
# Include Beaker environment
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
PACKAGE="annobin"
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartSetup
|
||||||
|
rlRun "which gcc"
|
||||||
|
rlRun "man -w annobin"
|
||||||
|
rlRun "echo $X_SCLS"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "rpm -qa | fgrep -e redhat-rpm-config -e gcc -e annobin -e binutils | sort"
|
||||||
|
rlRun "echo 'int main() {return 0;}' | gcc -xc -fplugin=annobin -o /dev/null -"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalPrintText
|
||||||
|
rlJournalEnd
|
Loading…
Reference in New Issue
Block a user