cb424d7448
verify-patch-sanity.py validates every active recipe .patch has internally- consistent hunk line counts — catching the 'malformed patch at line N' failure at commit/CI/preflight time instead of hours into a cook. This cycle hit that class three times (qtwaylandscanner, sddm, xwayland), each only discovered when cookbook tried to apply the patch. Running it across the repo found 29 latent malformed patches (validated against GNU patch: e.g. relibc/P3-sysv-ipc reproduces 'malformed patch at line 22'). They were harmless only because they sit in vendored recipes (baked, not re- applied) — but would fail on any version-bump re-derivation. --fix recounts the hunk headers (body untouched) and repaired all 29. Wired into build-preflight.sh (Phase 1.0D) and redbear-ci.yml, with a unit test (test-patch-sanity.sh). Skips archived/legacy trees and unvalidatable formats (empty placeholders, bare-@@ git hunks).
45 lines
1.7 KiB
ArmAsm
45 lines
1.7 KiB
ArmAsm
// REQUIRES: ppc
|
|
|
|
// RUN: llvm-mc -filetype=obj -triple=powerpc64le-unknown-linux %s -o %t.o
|
|
// RUN: llvm-mc -filetype=obj -triple=powerpc64le-unknown-linux %p/Inputs/shared.s -o %t2.o
|
|
// RUN: ld.lld -shared %t2.o -o %t2.so
|
|
// RUN: ld.lld -dynamic-linker /lib64/ld64.so.1 -rpath foo -rpath bar --export-dynamic %t.o %t2.so -o %t
|
|
// RUN: llvm-readobj --dynamic-table -S %t | FileCheck %s
|
|
|
|
// RUN: llvm-mc -filetype=obj -triple=powerpc64-unknown-linux %s -o %t.o
|
|
// RUN: llvm-mc -filetype=obj -triple=powerpc64-unknown-linux %p/Inputs/shared.s -o %t2.o
|
|
// RUN: ld.lld -shared %t2.o -o %t2.so
|
|
// RUN: ld.lld -dynamic-linker /lib64/ld64.so.1 -rpath foo -rpath bar --export-dynamic %t.o %t2.so -o %t
|
|
// RUN: llvm-readobj --dynamic-table -S %t | FileCheck %s
|
|
|
|
// CHECK: Name: .rela.dyn
|
|
// CHECK-NEXT: Type: SHT_REL
|
|
// CHECK-NEXT: Flags [
|
|
// CHECK-NEXT: SHF_ALLOC
|
|
// CHECK-NEXT: ]
|
|
// CHECK-NEXT: Address: [[RELADDR:.*]]
|
|
// CHECK-NEXT: Offset:
|
|
// CHECK-NEXT: Size: [[RELSIZE:.*]]
|
|
// CHECK-NEXT: Link:
|
|
// CHECK-NEXT: Info:
|
|
// CHECK-NEXT: AddressAlignment:
|
|
// CHECK-NEXT: EntrySize: [[RELENT:.*]]
|
|
|
|
// CHECK: DynamicSection [
|
|
// CHECK-NEXT: Tag Type Name/Value
|
|
// CHECK-NEXT: 0x000000000000001D RUNPATH Library runpath: [foo:bar]
|
|
// CHECK-NEXT: 0x0000000000000001 NEEDED Shared library: [{{.*}}2.so]
|
|
// CHECK-NEXT: 0x0000000000000015 DEBUG 0x0
|
|
// CHECK-NEXT: 0x0000000000000007 RELA [[RELADDR]]
|
|
// CHECK-NEXT: 0x0000000000000008 RELASZ [[RELSIZE]] (bytes)
|
|
// CHECK-NEXT: 0x0000000000000009 RELAENT [[RELENT]] (bytes)
|
|
// CHECK: 0x0000000000000000 NULL 0x0
|
|
// CHECK-NEXT: ]
|
|
|
|
.global _start
|
|
_start:
|
|
.data
|
|
.quad bar
|
|
.quad zed
|
|
|