CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
76 lines
4.6 KiB
C
76 lines
4.6 KiB
C
/// PS4 clang emits warnings when SDK headers (<SDKROOT>/target/include/) or
|
|
/// libraries (<SDKROOT>/target/lib/) are missing. If the the user takes control
|
|
/// of header search paths, the existence check for <SDKROOT>/target/include is
|
|
/// skipped.
|
|
///
|
|
/// User control of header search is assumed if `--sysroot`, `-isysroot`,
|
|
/// `-nostdinc` or `-nostdlibinc` is supplied.
|
|
///
|
|
/// Warnings are emitted if a specified `-isysroot` or `--sysroot` does not
|
|
/// exist.
|
|
///
|
|
/// The default <SDKROOT> for both headers and libraries is taken from the
|
|
/// SCE_ORBIS_SDK_DIR environment variable.
|
|
///
|
|
/// In ThinLTO code generation mode (-fthinlto-index=) SDK files are not required
|
|
/// so all warnings are suppressed.
|
|
|
|
// RUN: echo "-### -Winvalid-or-nonexistent-directory -target x86_64-scei-ps4" > %t.rsp
|
|
|
|
/// If SDK headers and/or libraries are found, associated warnings are absent.
|
|
// RUN: rm -rf %t.inconly && mkdir -p %t.inconly/target/include
|
|
// RUN: env SCE_ORBIS_SDK_DIR=%t.inconly %clang @%t.rsp %s 2>&1 | FileCheck -check-prefixes=WARN-SYS-LIBS,NO-WARN %s
|
|
|
|
// RUN: rm -rf %t.libonly && mkdir -p %t.libonly/target/lib
|
|
// RUN: env SCE_ORBIS_SDK_DIR=%t.libonly %clang @%t.rsp %s 2>&1 | FileCheck -check-prefixes=WARN-SYS-HEADERS,NO-WARN %s
|
|
|
|
// RUN: rm -rf %t.both && mkdir -p %t.both/target/lib && mkdir %t.both/target/include
|
|
// RUN: env SCE_ORBIS_SDK_DIR=%t.both %clang @%t.rsp %s 2>&1 | FileCheck -check-prefix=NO-WARN %s
|
|
|
|
/// In the following invocations, SCE_ORBIS_SDK_DIR is set to an existing
|
|
/// location where SDK headers and libraries are absent.
|
|
|
|
/// When compiling and linking, we should see a warnings about both missing
|
|
/// headers and libraries.
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s 2>&1 | FileCheck -check-prefixes=WARN-SYS-HEADERS,WARN-SYS-LIBS,NO-WARN %s
|
|
|
|
/// -fthinlto-index= warning suppression.
|
|
// RUN: touch %t_dummy.o
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %t_dummy.o -fthinlto-index=ignored -c 2>&1 | FileCheck -check-prefixes=NO-WARN %s
|
|
|
|
/// If `-c`, `-S`, `-E` or `-emit-ast` is supplied, the existence check for SDK
|
|
/// libraries is skipped because no linking will be performed. We only expect
|
|
/// warnings about missing headers.
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -c 2>&1 | FileCheck -check-prefixes=WARN-SYS-HEADERS,NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -S 2>&1 | FileCheck -check-prefixes=WARN-SYS-HEADERS,NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -E 2>&1 | FileCheck -check-prefixes=WARN-SYS-HEADERS,NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -emit-ast 2>&1 | FileCheck -check-prefixes=WARN-SYS-HEADERS,NO-WARN %s
|
|
|
|
/// If the user takes control of include paths, the existence check for headers
|
|
/// is not performed.
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -c -nostdinc 2>&1 | FileCheck -check-prefix=NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -c -nostdlibinc 2>&1 | FileCheck -check-prefix=NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -c -isysroot . 2>&1 | FileCheck -check-prefixes=NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -c --sysroot=. 2>&1 | FileCheck -check-prefixes=NO-WARN %s
|
|
|
|
/// --sysroot disables the existence check for headers. The check for libraries
|
|
/// remains.
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s --sysroot=. 2>&1 | FileCheck -check-prefixes=WARN-SYS-LIBS,NO-WARN %s
|
|
|
|
/// -isysroot overrides --sysroot for header search, but not library search.
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -isysroot . --sysroot=%t.inconly 2>&1 | FileCheck -check-prefixes=ISYSTEM,WARN-SYS-LIBS,NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s --sysroot=%t.inconly -isysroot . 2>&1 | FileCheck -check-prefixes=ISYSTEM,WARN-SYS-LIBS,NO-WARN %s
|
|
|
|
/// Warnings are emitted if non-existent --sysroot/-isysroot are supplied.
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s --sysroot=foo -isysroot %t.both 2>&1 | FileCheck -check-prefixes=WARN-SYSROOT,WARN-SYS-LIBS,NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s -isysroot foo --sysroot=%t.both 2>&1 | FileCheck -check-prefixes=WARN-SYSROOT,NO-WARN %s
|
|
// RUN: env SCE_ORBIS_SDK_DIR=.. %clang @%t.rsp %s --sysroot=foo -isysroot bar 2>&1 | FileCheck -check-prefixes=WARN-SYSROOT,WARN-SYSROOT2,WARN-SYS-LIBS,NO-WARN %s
|
|
|
|
// NO-WARN-NOT: {{warning:|error:}}
|
|
// WARN-SYSROOT: warning: no such sysroot directory: 'foo'
|
|
// WARN-SYSROOT2: warning: no such sysroot directory: 'bar'
|
|
// WARN-SYS-LIBS: warning: unable to find PS4 system libraries directory
|
|
// WARN-SYS-HEADERS: warning: unable to find PS4 system headers directory
|
|
// NO-WARN-NOT: {{warning:|error:}}
|
|
// ISYSTEM: "-cc1"{{.*}}"-internal-externc-isystem" "./target/include"
|