diff options
| author | Harish Sadineni <Harish.Sadineni@windriver.com> | 2025-06-24 04:40:23 -0700 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2025-07-02 09:44:04 -0700 |
| commit | 2ef9449dc02fa010b0f8d235bebe118e13bdaf60 (patch) | |
| tree | 05da50271bc757221536056cbeeb402b0960edbb /dynamic-layers/meta-python | |
| parent | 944524b4ba2a756d578f5e7469113f9f5ddd2a26 (diff) | |
| download | meta-clang-2ef9449dc02fa010b0f8d235bebe118e13bdaf60.tar.gz | |
bcc: export BCC_KERNEL_SOURCE in run-ptest
when running ptest for bcc we need to
export BCC_KERNEL_SOURCE to resolve test errors.
Signed-off-by: Harish Sadineni <Harish.Sadineni@windriver.com>
Diffstat (limited to 'dynamic-layers/meta-python')
| -rw-r--r-- | dynamic-layers/meta-python/recipes-devtools/bcc/bcc/run-ptest | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/dynamic-layers/meta-python/recipes-devtools/bcc/bcc/run-ptest b/dynamic-layers/meta-python/recipes-devtools/bcc/bcc/run-ptest index a27f697..4740ae9 100644 --- a/dynamic-layers/meta-python/recipes-devtools/bcc/bcc/run-ptest +++ b/dynamic-layers/meta-python/recipes-devtools/bcc/bcc/run-ptest | |||
| @@ -17,6 +17,29 @@ print_test_result() { | |||
| 17 | fi | 17 | fi |
| 18 | } | 18 | } |
| 19 | 19 | ||
| 20 | ARCH=$(uname -m) | ||
| 21 | |||
| 22 | case "$ARCH" in | ||
| 23 | x86_64) | ||
| 24 | KDIR="x86" | ||
| 25 | ;; | ||
| 26 | riscv64) | ||
| 27 | KDIR="riscv" | ||
| 28 | ;; | ||
| 29 | aarch64) | ||
| 30 | KDIR="arm64" | ||
| 31 | ;; | ||
| 32 | powerpc64le | ppc64le) | ||
| 33 | KDIR="powerpc" | ||
| 34 | ;; | ||
| 35 | *) | ||
| 36 | echo "Architecture not present, Add the architecture in run-ptest: $ARCH" | ||
| 37 | exit 1 | ||
| 38 | ;; | ||
| 39 | esac | ||
| 40 | |||
| 41 | export BCC_KERNEL_SOURCE="/usr/src/kernel/arch/$KDIR" | ||
| 42 | |||
| 20 | # Run CC tests, set IFS as test names have spaces | 43 | # Run CC tests, set IFS as test names have spaces |
| 21 | IFS=$(printf '\n\t') | 44 | IFS=$(printf '\n\t') |
| 22 | for test_name in $(./cc/test_libbcc_no_libbpf --list-test-names-only); do | 45 | for test_name in $(./cc/test_libbcc_no_libbpf --list-test-names-only); do |
