Skip to content

Commit 23a9110

Browse files
committed
---
yaml --- r: 108221 b: refs/heads/dist-snap c: 11bc14d h: refs/heads/master i: 108219: 7c76d2e v: v3
1 parent 70628dd commit 23a9110

File tree

12 files changed

+450
-121
lines changed

12 files changed

+450
-121
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ refs/heads/try: f64fdf524a434f0e5cd0bc91d09c144723f3c90d
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
9-
refs/heads/dist-snap: e633249b31d6ecfb46a4d7d85b5be4a9dd96b1c0
9+
refs/heads/dist-snap: 11bc14d724052e5567d794c425fcef1c3c73302d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1212
refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0

branches/dist-snap/.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,6 @@
99
[submodule "src/gyp"]
1010
path = src/gyp
1111
url = https://github.com/rust-lang/gyp.git
12+
[submodule "src/compiler-rt"]
13+
path = src/compiler-rt
14+
url = https://github.com/rust-lang/compiler-rt.git

branches/dist-snap/Makefile.in

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,8 @@ endif
355355
# Prerequisites for using the stageN compiler to build target artifacts
356356
TSREQ$(1)_T_$(2)_H_$(3) = \
357357
$$(HSREQ$(1)_H_$(3)) \
358-
$$(TLIB$(1)_T_$(2)_H_$(3))/libmorestack.a
358+
$$(TLIB$(1)_T_$(2)_H_$(3))/libmorestack.a \
359+
$$(TLIB$(1)_T_$(2)_H_$(3))/libcompiler-rt.a
359360

360361
# Prerequisites for a working stageN compiler and libraries, for a specific
361362
# target

branches/dist-snap/mk/clean.mk

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ clean-generic-$(2)-$(1):
5454
$(1)/rt \
5555
$(1)/test \
5656
$(1)/stage* \
57+
-type f \( \
5758
-name '*.[odasS]' -o \
5859
-name '*.so' -o \
5960
-name '*.dylib' -o \
@@ -62,6 +63,7 @@ clean-generic-$(2)-$(1):
6263
-name '*.dll' -o \
6364
-name '*.def' -o \
6465
-name '*.bc' \
66+
\) \
6567
| xargs rm -f
6668
$(Q)find $(1)\
6769
-name '*.dSYM' \
@@ -96,6 +98,7 @@ clean$(1)_T_$(2)_H_$(3): \
9698
$$(foreach crate,$$(CRATES),clean$(1)_T_$(2)_H_$(3)-lib-$$(crate)) \
9799
$$(foreach tool,$$(TOOLS),clean$(1)_T_$(2)_H_$(3)-tool-$$(tool))
98100
$$(Q)rm -f $$(TLIB$(1)_T_$(2)_H_$(3))/libmorestack.a
101+
$$(Q)rm -f $$(TLIB$(1)_T_$(2)_H_$(3))/libcompiler-rt.a
99102
$(Q)rm -f $$(TLIB$(1)_T_$(2)_H_$(3))/librun_pass_stage* # For unix
100103
$(Q)rm -f $$(TLIB$(1)_T_$(2)_H_$(3))/run_pass_stage* # For windows
101104

branches/dist-snap/mk/crates.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ HOST_CRATES := syntax rustc rustdoc fourcc
5555
CRATES := $(TARGET_CRATES) $(HOST_CRATES)
5656
TOOLS := compiletest rustdoc rustc
5757

58-
DEPS_std := native:rustrt
58+
DEPS_std := native:rustrt native:compiler-rt
5959
DEPS_extra := std term sync serialize getopts collections
6060
DEPS_green := std
6161
DEPS_rustuv := std native:uv native:uv_support

branches/dist-snap/mk/install.mk

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ install-target-$(1)-host-$(2): \
9696
$$(call INSTALL_LIB,$$(call CFG_LIB_GLOB_$(1),$$(crate)));\
9797
$$(call INSTALL_LIB,$$(call CFG_RLIB_GLOB,$$(crate)));)
9898
$$(Q)$$(call INSTALL_LIB,libmorestack.a)
99+
$$(Q)$$(call INSTALL_LIB,libcompiler-rt.a)
99100

100101
endef
101102

@@ -110,6 +111,7 @@ install-target-$(1)-host-$(2): $$(CSREQ$$(ISTAGE)_T_$(1)_H_$(2))
110111
$$(Q)$$(foreach crate,$$(TARGET_CRATES),\
111112
$$(call INSTALL_LIB,$$(call CFG_RLIB_GLOB,$$(crate)));)
112113
$$(Q)$$(call INSTALL_LIB,libmorestack.a)
114+
$$(Q)$$(call INSTALL_LIB,libcompiler-rt.a)
113115
endef
114116

115117
$(foreach target,$(CFG_TARGET), \

branches/dist-snap/mk/rt.mk

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,37 @@ $$(LIBUV_DIR_$(1))/Release/libuv.a: $$(LIBUV_DEPS) $$(LIBUV_MAKEFILE_$(1)) \
217217

218218
endif
219219

220+
################################################################################
221+
# compiler-rt
222+
################################################################################
223+
224+
ifdef CFG_ENABLE_FAST_MAKE
225+
COMPRT_DEPS := $(S)/.gitmodules
226+
else
227+
COMPRT_DEPS := $(wildcard \
228+
$(S)src/compiler-rt/* \
229+
$(S)src/compiler-rt/*/* \
230+
$(S)src/compiler-rt/*/*/* \
231+
$(S)src/compiler-rt/*/*/*/*)
232+
endif
233+
234+
COMPRT_NAME_$(1) := $$(call CFG_STATIC_LIB_NAME_$(1),compiler-rt)
235+
COMPRT_LIB_$(1) := $$(RT_OUTPUT_DIR_$(1))/$$(COMPRT_NAME_$(1))
236+
COMPRT_BUILD_DIR_$(1) := $$(RT_OUTPUT_DIR_$(1))/compiler-rt
237+
238+
$$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS)
239+
@$$(call E, make: compiler-rt)
240+
$$(Q)$$(MAKE) -C "$(S)src/compiler-rt" \
241+
ProjSrcRoot="$(S)src/compiler-rt" \
242+
ProjObjRoot="$$(abspath $$(COMPRT_BUILD_DIR_$(1)))" \
243+
CC="$$(CC_$(1))" \
244+
AR="$$(AR_$(1))" \
245+
RANLIB="$$(AR_$(1)) s" \
246+
CFLAGS="$$(CFG_GCCISH_CFLAGS_$(1))" \
247+
TargetTriple=$(1) \
248+
triple-runtime
249+
$$(Q)cp $$(COMPRT_BUILD_DIR_$(1))/triple/runtime/libcompiler_rt.a $$(COMPRT_LIB_$(1))
250+
220251
endef
221252

222253
# Instantiate template for all stages/targets

branches/dist-snap/mk/target.mk

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,12 @@ $$(TBIN$(1)_T_$(2)_H_$(3))/:
138138
$$(TLIB$(1)_T_$(2)_H_$(3))/:
139139
mkdir -p $$@
140140

141+
$$(TLIB$(1)_T_$(2)_H_$(3))/libcompiler-rt.a: \
142+
$$(RT_OUTPUT_DIR_$(2))/$$(call CFG_STATIC_LIB_NAME_$(2),compiler-rt) \
143+
| $$(TLIB$(1)_T_$(2)_H_$(3))/ $$(SNAPSHOT_RUSTC_POST_CLEANUP)
144+
@$$(call E, cp: $$@)
145+
$$(Q)cp $$< $$@
146+
141147
$$(TLIB$(1)_T_$(2)_H_$(3))/libmorestack.a: \
142148
$$(RT_OUTPUT_DIR_$(2))/$$(call CFG_STATIC_LIB_NAME_$(2),morestack) \
143149
| $$(TLIB$(1)_T_$(2)_H_$(3))/ $$(SNAPSHOT_RUSTC_POST_CLEANUP)

branches/dist-snap/mk/tests.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,7 @@ tidy:
262262
| grep '^$(S)src/gyp' -v \
263263
| grep '^$(S)src/etc' -v \
264264
| grep '^$(S)src/doc' -v \
265+
| grep '^$(S)src/compiler-rt' -v \
265266
| xargs $(CFG_PYTHON) $(S)src/etc/check-binaries.py
266267

267268
endif

branches/dist-snap/src/compiler-rt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Subproject commit d4606f1818dd8dfeaa3e509cd1cbac4482c3513e

0 commit comments

Comments
 (0)