fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
1.5 KiB37 linesraw
1# needs-llvm-components: x86 arm
2
3include ../tools.mk
4
5all: default output_to_file
6	$(RUSTC) --target x86_64-pc-windows-gnu --print cfg | $(CGREP) windows
7	$(RUSTC) --target x86_64-pc-windows-gnu --print cfg | $(CGREP) x86_64
8	$(RUSTC) --target i686-pc-windows-msvc --print cfg | $(CGREP) msvc
9	$(RUSTC) --target i686-apple-darwin --print cfg | $(CGREP) macos
10	$(RUSTC) --target i686-unknown-linux-gnu --print cfg | $(CGREP) gnu
11	$(RUSTC) --target arm-unknown-linux-gnueabihf --print cfg | $(CGREP) target_abi=
12	$(RUSTC) --target arm-unknown-linux-gnueabihf --print cfg | $(CGREP) eabihf
13
14output_to_file:
15	# Backend-independent, printed by rustc_driver_impl/src/lib.rs
16	$(RUSTC) --target x86_64-pc-windows-gnu --print cfg=$(TMPDIR)/cfg.txt
17	$(CGREP) windows < $(TMPDIR)/cfg.txt
18
19	# Printed from CodegenBackend trait impl in rustc_codegen_llvm/src/lib.rs
20	$(RUSTC) --print relocation-models=$(TMPDIR)/relocation-models.txt
21	$(CGREP) dynamic-no-pic < $(TMPDIR)/relocation-models.txt
22
23	# Printed by compiler/rustc_codegen_llvm/src/llvm_util.rs
24	$(RUSTC) --target wasm32-unknown-unknown --print target-features=$(TMPDIR)/target-features.txt
25	$(CGREP) reference-types < $(TMPDIR)/target-features.txt
26
27	# Printed by C++ code in rustc_llvm/llvm-wrapper/PassWrapper.cpp
28	$(RUSTC) --target wasm32-unknown-unknown --print target-cpus=$(TMPDIR)/target-cpus.txt
29	$(CGREP) generic < $(TMPDIR)/target-cpus.txt
30
31ifdef IS_WINDOWS
32default:
33	$(RUSTC) --print cfg | $(CGREP) windows
34else
35default:
36	$(RUSTC) --print cfg | $(CGREP) unix
37endif