Commit e576718
committed
Merge: selftests/bpf: Fix build of test_progs
MR: https://gitlab.com/redhat/centos-stream/src/kernel/centos-stream-10/-/merge_requests/31
There was a number of reasons why `test_progs` didn't compile in RHEL 10. This PR addresses all of them:
- BPF selftests Makefiles did not correctly support passing options via env variables - this is addressed by the patch #1.
- RPM build uses some compiler options unsupported by Clang (e.g. `-spec=...`). This is addressed by patch #2.
- Not all binaries in BPF selftests were compiled as PIE which caused linker and feature detection issues. This is addressed by patches #3-#5.
- BPF selftests do not build with source fortification so we disable it for selftests build in patch #6.
- The `urandom_read` binary doesn't pass the `check-rpaths` step. The check is bypassed by patch #7.
- BPF selftests need `libxml2-devel` as a dependency. This is added by patch #8.
- One test prog skeleton cannot be built in Brew as it needs to read `/proc/kallsyms` which in Brew builders has permissions 000. Until that is changed, we remove the test prog in patch #9.
Majority of the patches are either backports of upstream commits or are RHEL-only patches of the specfile. The only exception is the last patch which is a RHEL-only patch in kernel code (BPF selftests Makefile). Hopefully, we will be eventually able to drop it.
JIRA: https://issues.redhat.com/browse/RHEL-48593
Signed-off-by: Viktor Malik <vmalik@redhat.com>
Signed-off-by: Artem Savkov <asavkov@redhat.com>
Approved-by: Derek Barbosa <debarbos@redhat.com>
Approved-by: Jerome Marchand <jmarchan@redhat.com>
Approved-by: CKI KWF Bot <cki-ci-bot+kwf-gitlab-com@redhat.com>
Merged-by: Jan Stancek <jstancek@redhat.com>File tree
4 files changed
+54
-47
lines changed- redhat
- tools
- bpf/bpftool
- testing/selftests/bpf
- prog_tests
4 files changed
+54
-47
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
791 | 791 | | |
792 | 792 | | |
793 | 793 | | |
794 | | - | |
| 794 | + | |
795 | 795 | | |
796 | 796 | | |
797 | 797 | | |
| |||
3202 | 3202 | | |
3203 | 3203 | | |
3204 | 3204 | | |
3205 | | - | |
| 3205 | + | |
3206 | 3206 | | |
3207 | 3207 | | |
3208 | 3208 | | |
| |||
3217 | 3217 | | |
3218 | 3218 | | |
3219 | 3219 | | |
3220 | | - | |
| 3220 | + | |
| 3221 | + | |
| 3222 | + | |
| 3223 | + | |
| 3224 | + | |
| 3225 | + | |
| 3226 | + | |
| 3227 | + | |
| 3228 | + | |
| 3229 | + | |
| 3230 | + | |
| 3231 | + | |
3221 | 3232 | | |
3222 | 3233 | | |
3223 | 3234 | | |
| |||
3243 | 3254 | | |
3244 | 3255 | | |
3245 | 3256 | | |
| 3257 | + | |
| 3258 | + | |
| 3259 | + | |
| 3260 | + | |
| 3261 | + | |
| 3262 | + | |
| 3263 | + | |
| 3264 | + | |
| 3265 | + | |
3246 | 3266 | | |
3247 | 3267 | | |
3248 | 3268 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
147 | 147 | | |
148 | 148 | | |
149 | 149 | | |
150 | | - | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
151 | 155 | | |
152 | 156 | | |
153 | 157 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
274 | 274 | | |
275 | 275 | | |
276 | 276 | | |
| 277 | + | |
277 | 278 | | |
278 | 279 | | |
279 | 280 | | |
| |||
282 | 283 | | |
283 | 284 | | |
284 | 285 | | |
| 286 | + | |
285 | 287 | | |
286 | 288 | | |
287 | 289 | | |
| |||
295 | 297 | | |
296 | 298 | | |
297 | 299 | | |
298 | | - | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
299 | 303 | | |
300 | 304 | | |
301 | 305 | | |
302 | 306 | | |
303 | 307 | | |
304 | | - | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
305 | 311 | | |
306 | 312 | | |
307 | 313 | | |
308 | 314 | | |
309 | 315 | | |
310 | | - | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
311 | 319 | | |
312 | 320 | | |
313 | 321 | | |
314 | 322 | | |
315 | 323 | | |
316 | | - | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
317 | 327 | | |
318 | 328 | | |
319 | 329 | | |
| |||
333 | 343 | | |
334 | 344 | | |
335 | 345 | | |
336 | | - | |
337 | | - | |
| 346 | + | |
| 347 | + | |
338 | 348 | | |
339 | 349 | | |
340 | 350 | | |
| |||
368 | 378 | | |
369 | 379 | | |
370 | 380 | | |
371 | | - | |
| 381 | + | |
| 382 | + | |
372 | 383 | | |
373 | 384 | | |
374 | 385 | | |
| |||
379 | 390 | | |
380 | 391 | | |
381 | 392 | | |
382 | | - | |
| 393 | + | |
| 394 | + | |
383 | 395 | | |
384 | 396 | | |
385 | 397 | | |
| |||
402 | 414 | | |
403 | 415 | | |
404 | 416 | | |
405 | | - | |
406 | | - | |
| 417 | + | |
| 418 | + | |
407 | 419 | | |
408 | 420 | | |
409 | 421 | | |
410 | 422 | | |
411 | 423 | | |
412 | 424 | | |
413 | 425 | | |
414 | | - | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
415 | 429 | | |
416 | 430 | | |
417 | 431 | | |
| |||
518 | 532 | | |
519 | 533 | | |
520 | 534 | | |
521 | | - | |
| 535 | + | |
522 | 536 | | |
523 | 537 | | |
524 | 538 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | 10 | | |
12 | 11 | | |
13 | 12 | | |
| |||
111 | 110 | | |
112 | 111 | | |
113 | 112 | | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | 113 | | |
142 | 114 | | |
143 | 115 | | |
| |||
180 | 152 | | |
181 | 153 | | |
182 | 154 | | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | 155 | | |
187 | 156 | | |
188 | 157 | | |
| |||
0 commit comments