diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:20:39 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:20:39 +0000 |
commit | 1376c5a617be5c25655d0d7cb63e3beaa5a6e026 (patch) | |
tree | 3bb8d61aee02bc7a15eab3f36e3b921afc2075d0 /tests/run-make-fulldeps/cross-lang-lto | |
parent | Releasing progress-linux version 1.69.0+dfsg1-1~progress7.99u1. (diff) | |
download | rustc-1376c5a617be5c25655d0d7cb63e3beaa5a6e026.tar.xz rustc-1376c5a617be5c25655d0d7cb63e3beaa5a6e026.zip |
Merging upstream version 1.70.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/run-make-fulldeps/cross-lang-lto')
-rw-r--r-- | tests/run-make-fulldeps/cross-lang-lto/Makefile | 57 | ||||
-rw-r--r-- | tests/run-make-fulldeps/cross-lang-lto/lib.rs | 4 | ||||
-rw-r--r-- | tests/run-make-fulldeps/cross-lang-lto/main.rs | 3 |
3 files changed, 0 insertions, 64 deletions
diff --git a/tests/run-make-fulldeps/cross-lang-lto/Makefile b/tests/run-make-fulldeps/cross-lang-lto/Makefile deleted file mode 100644 index 92058f952..000000000 --- a/tests/run-make-fulldeps/cross-lang-lto/Makefile +++ /dev/null @@ -1,57 +0,0 @@ - -include ../tools.mk - -# ignore windows due to libLLVM being present in PATH and the PATH and library path being the same -# (so fixing it is harder). See #57765 for context -ifndef IS_WINDOWS - -# This test makes sure that the object files we generate are actually -# LLVM bitcode files (as used by linker LTO plugins) when compiling with -# -Clinker-plugin-lto. - -# this only succeeds for bitcode files -ASSERT_IS_BITCODE_OBJ=("$(LLVM_BIN_DIR)"/llvm-bcanalyzer $(1)) -EXTRACT_OBJS=(cd $(TMPDIR); rm -f ./*.o; "$(LLVM_BIN_DIR)"/llvm-ar x $(1)) - -BUILD_LIB=$(RUSTC) lib.rs -Copt-level=2 -Clinker-plugin-lto -Ccodegen-units=1 -BUILD_EXE=$(RUSTC) main.rs -Copt-level=2 -Clinker-plugin-lto -Ccodegen-units=1 --emit=obj - -all: staticlib staticlib-fat-lto staticlib-thin-lto rlib exe cdylib rdylib - -staticlib: lib.rs - $(BUILD_LIB) --crate-type=staticlib -o $(TMPDIR)/liblib.a - $(call EXTRACT_OBJS, liblib.a) - for file in $(TMPDIR)/liblib.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done - -staticlib-fat-lto: lib.rs - $(BUILD_LIB) --crate-type=staticlib -o $(TMPDIR)/liblib-fat-lto.a -Clto=fat - $(call EXTRACT_OBJS, liblib-fat-lto.a) - for file in $(TMPDIR)/liblib-fat-lto.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done - -staticlib-thin-lto: lib.rs - $(BUILD_LIB) --crate-type=staticlib -o $(TMPDIR)/liblib-thin-lto.a -Clto=thin - $(call EXTRACT_OBJS, liblib-thin-lto.a) - for file in $(TMPDIR)/liblib-thin-lto.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done - -rlib: lib.rs - $(BUILD_LIB) --crate-type=rlib -o $(TMPDIR)/liblib.rlib - $(call EXTRACT_OBJS, liblib.rlib) - for file in $(TMPDIR)/liblib.*.rcgu.o; do $(call ASSERT_IS_BITCODE_OBJ, $$file); done - -cdylib: lib.rs - $(BUILD_LIB) --crate-type=cdylib --emit=obj -o $(TMPDIR)/cdylib.o - $(call ASSERT_IS_BITCODE_OBJ, $(TMPDIR)/cdylib.o) - -rdylib: lib.rs - $(BUILD_LIB) --crate-type=dylib --emit=obj -o $(TMPDIR)/rdylib.o - $(call ASSERT_IS_BITCODE_OBJ, $(TMPDIR)/rdylib.o) - -exe: lib.rs - $(BUILD_EXE) -o $(TMPDIR)/exe.o - $(call ASSERT_IS_BITCODE_OBJ, $(TMPDIR)/exe.o) - -else - -all: - -endif diff --git a/tests/run-make-fulldeps/cross-lang-lto/lib.rs b/tests/run-make-fulldeps/cross-lang-lto/lib.rs deleted file mode 100644 index 94cfef6ad..000000000 --- a/tests/run-make-fulldeps/cross-lang-lto/lib.rs +++ /dev/null @@ -1,4 +0,0 @@ -#[no_mangle] -pub extern "C" fn foo() { - println!("abc"); -} diff --git a/tests/run-make-fulldeps/cross-lang-lto/main.rs b/tests/run-make-fulldeps/cross-lang-lto/main.rs deleted file mode 100644 index f6320bcb0..000000000 --- a/tests/run-make-fulldeps/cross-lang-lto/main.rs +++ /dev/null @@ -1,3 +0,0 @@ -fn main() { - println!("Hello World"); -} |