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
67 lines
2.6 KiB
C
67 lines
2.6 KiB
C
/// This tests the expected error case when there is a mismatch between the pcm dependencies passed in
|
|
/// the command line with `fmodule-file` and whats encoded in the pcm.
|
|
|
|
/// The steps are:
|
|
/// 1. Build the module A with no dependencies. The first variant to build is A-1.pcm.
|
|
/// 2. Build the same module with files that resolve from different search paths.
|
|
/// This variant is named A-2.pcm.
|
|
/// 3. Build module B that depends on the earlier module A-1.pcm.
|
|
/// 4. Build client that directly depends on both modules (A & B),
|
|
/// but depends on a incompatible variant of A (A-2.pcm) for B to use.
|
|
|
|
// RUN: rm -rf %t
|
|
// RUN: split-file %s %t
|
|
|
|
// RUN: %clang_cc1 -emit-module -x c -fmodules -fno-implicit-modules -isysroot %t/Sysroot \
|
|
// RUN: -I%t/Sysroot/usr/include \
|
|
// RUN: -fmodule-name=A %t/Sysroot/usr/include/A/module.modulemap -o %t/A-1.pcm
|
|
|
|
// RUN: %clang_cc1 -emit-module -x c -fmodules -fno-implicit-modules -isysroot %t/Sysroot \
|
|
// RUN: -I%t/BuildDir \
|
|
// RUN: -fmodule-name=A %t/BuildDir/A/module.modulemap -o %t/A-2.pcm
|
|
|
|
// RUN: %clang_cc1 -emit-module -x c -fmodules -fno-implicit-modules -isysroot %t/Sysroot \
|
|
// RUN: -I%t/Sysroot/usr/include \
|
|
// RUN: -fmodule-map-file=%t/Sysroot/usr/include/A/module.modulemap \
|
|
// RUN: -fmodule-file=A=%t/A-1.pcm \
|
|
// RUN: -fmodule-name=B %t/Sysroot/usr/include/B/module.modulemap -o %t/B-1.pcm
|
|
|
|
// RUN: %clang_cc1 -x c -fmodules -fno-implicit-modules -isysroot %t/Sysroot \
|
|
// RUN: -I%t/BuildDir -I%t/Sysroot/usr/include \
|
|
// RUN: -fmodule-map-file=%t/BuildDir/A/module.modulemap \
|
|
// RUN: -fmodule-map-file=%t/Sysroot/usr/include/B/module.modulemap \
|
|
// RUN: -fmodule-file=A=%t/A-2.pcm -fmodule-file=B=%t/B-1.pcm \
|
|
// RUN: -Wmodule-file-mapping-mismatch -verify %s
|
|
|
|
|
|
#include <A/A.h>
|
|
#include <B/B.h> // expected-warning {{conflicts with imported file}} \
|
|
// expected-note {{imported by module 'B'}} \
|
|
// expected-note {{size changed}} \
|
|
// expected-note {{earlier input file validation was disabled for this kind of precompiled file}} \
|
|
// expected-error {{out of date and needs to be rebuilt}}
|
|
|
|
//--- Sysroot/usr/include/A/module.modulemap
|
|
module A [system] {
|
|
umbrella header "A.h"
|
|
}
|
|
//--- Sysroot/usr/include/A/A.h
|
|
typedef int A_t;
|
|
|
|
//--- Sysroot/usr/include/B/module.modulemap
|
|
module B [system] {
|
|
umbrella header "B.h"
|
|
}
|
|
|
|
//--- Sysroot/usr/include/B/B.h
|
|
#include <A/A.h>
|
|
typedef int B_t;
|
|
|
|
//--- BuildDir/A/module.modulemap
|
|
module A [system] {
|
|
umbrella header "A.h"
|
|
}
|
|
|
|
//--- BuildDir/A/A.h
|
|
typedef int A_t;
|