Skip to content

Commit 27ae68d

Browse files
committed
---
yaml --- r: 59920 b: refs/heads/master c: 17b368f h: refs/heads/master v: v3
1 parent be0b679 commit 27ae68d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

98 files changed

+1750
-2068
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: f8dffc6789113a10c9dbf1d815c3569b19b53e96
2+
refs/heads/master: 17b368fd2225ffc65333a9a5293fca4f6bdcf7f5
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 2d28d645422c1617be58c8ca7ad9a457264ca850
55
refs/heads/try: c50a9d5b664478e533ba1d1d353213d70c8ad589

trunk/Makefile.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ $(foreach target,$(CFG_TARGET_TRIPLES),\
238238

239239
CORELIB_CRATE := $(S)src/libcore/core.rc
240240
CORELIB_INPUTS := $(wildcard $(addprefix $(S)src/libcore/, \
241-
core.rc *.rs */*.rs */*/*rs */*/*/*rs))
241+
core.rc *.rs */*.rs */*/*rs))
242242

243243
######################################################################
244244
# Standard library variables

trunk/doc/rust.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2393,7 +2393,7 @@ variables in the arm's block, and control enters the block.
23932393
An example of an `match` expression:
23942394

23952395

2396-
~~~~ {.xfail-test}
2396+
~~~~
23972397
# fn process_pair(a: int, b: int) { }
23982398
# fn process_ten() { }
23992399

trunk/mk/clean.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ clean-misc:
4848
$(Q)rm -f $(RUSTLLVM_LIB_OBJS) $(RUSTLLVM_OBJS_OBJS) $(RUSTLLVM_DEF)
4949
$(Q)rm -Rf $(DOCS)
5050
$(Q)rm -Rf $(GENERATED)
51-
$(Q)rm -f tmp/*.log tmp/*.rc tmp/*.rs tmp/*.ok
51+
$(Q)rm -f tmp/*
5252
$(Q)rm -Rf rust-stage0-*.tar.bz2 $(PKG_NAME)-*.tar.gz dist
5353
$(Q)rm -Rf $(foreach ext, \
5454
html aux cp fn ky log pdf pg toc tp vr cps, \

trunk/mk/docs.mk

Lines changed: 39 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,15 @@ DOCS :=
1616

1717

1818
######################################################################
19-
# Docs, from pandoc, rustdoc (which runs pandoc), and node
19+
# Pandoc (reference-manual related)
2020
######################################################################
21+
ifeq ($(CFG_PANDOC),)
22+
$(info cfg: no pandoc found, omitting doc/rust.pdf)
23+
else
24+
25+
ifeq ($(CFG_NODE),)
26+
$(info cfg: no node found, omitting doc/tutorial.html)
27+
else
2128

2229
doc/rust.css: rust.css
2330
@$(call E, cp: $@)
@@ -27,18 +34,6 @@ doc/manual.css: manual.css
2734
@$(call E, cp: $@)
2835
$(Q)cp -a $< $@ 2> /dev/null
2936

30-
ifeq ($(CFG_PANDOC),)
31-
$(info cfg: no pandoc found, omitting docs)
32-
NO_DOCS = 1
33-
endif
34-
35-
ifeq ($(CFG_NODE),)
36-
$(info cfg: no node found, omitting docs)
37-
NO_DOCS = 1
38-
endif
39-
40-
ifneq ($(NO_DOCS),1)
41-
4237
DOCS += doc/rust.html
4338
doc/rust.html: rust.md doc/version_info.html doc/rust.css doc/manual.css
4439
@$(call E, pandoc: $@)
@@ -52,8 +47,19 @@ doc/rust.html: rust.md doc/version_info.html doc/rust.css doc/manual.css
5247
--css=manual.css \
5348
--include-before-body=doc/version_info.html \
5449
--output=$@
50+
endif
5551

56-
DOCS += doc/rust.tex
52+
ifeq ($(CFG_PDFLATEX),)
53+
$(info cfg: no pdflatex found, omitting doc/rust.pdf)
54+
else
55+
ifeq ($(CFG_XETEX),)
56+
$(info cfg: no xetex found, disabling doc/rust.pdf)
57+
else
58+
ifeq ($(CFG_LUATEX),)
59+
$(info cfg: lacking luatex, disabling pdflatex)
60+
else
61+
62+
DOCS += doc/rust.pdf
5763
doc/rust.tex: rust.md doc/version.md
5864
@$(call E, pandoc: $@)
5965
$(Q)$(CFG_NODE) $(S)doc/prep.js $< | \
@@ -64,6 +70,17 @@ doc/rust.tex: rust.md doc/version.md
6470
--from=markdown --to=latex \
6571
--output=$@
6672

73+
doc/rust.pdf: doc/rust.tex
74+
@$(call E, pdflatex: $@)
75+
$(Q)$(CFG_PDFLATEX) \
76+
-interaction=batchmode \
77+
-output-directory=doc \
78+
$<
79+
80+
endif
81+
endif
82+
endif
83+
6784
DOCS += doc/rustpkg.html
6885
doc/rustpkg.html: rustpkg.md doc/version_info.html doc/rust.css doc/manual.css
6986
@$(call E, pandoc: $@)
@@ -78,6 +95,13 @@ doc/rustpkg.html: rustpkg.md doc/version_info.html doc/rust.css doc/manual.css
7895
--include-before-body=doc/version_info.html \
7996
--output=$@
8097

98+
######################################################################
99+
# Node (tutorial related)
100+
######################################################################
101+
ifeq ($(CFG_NODE),)
102+
$(info cfg: no node found, omitting doc/tutorial.html)
103+
else
104+
81105
DOCS += doc/tutorial.html
82106
doc/tutorial.html: tutorial.md doc/version_info.html doc/rust.css
83107
@$(call E, pandoc: $@)
@@ -129,29 +153,9 @@ doc/tutorial-tasks.html: tutorial-tasks.md doc/version_info.html doc/rust.css
129153
--include-before-body=doc/version_info.html \
130154
--output=$@
131155

132-
ifeq ($(CFG_PDFLATEX),)
133-
$(info cfg: no pdflatex found, omitting doc/rust.pdf)
134-
else
135-
ifeq ($(CFG_XETEX),)
136-
$(info cfg: no xetex found, disabling doc/rust.pdf)
137-
else
138-
ifeq ($(CFG_LUATEX),)
139-
$(info cfg: lacking luatex, disabling pdflatex)
140-
else
141-
142-
DOCS += doc/rust.pdf
143-
doc/rust.pdf: doc/rust.tex
144-
@$(call E, pdflatex: $@)
145-
$(Q)$(CFG_PDFLATEX) \
146-
-interaction=batchmode \
147-
-output-directory=doc \
148-
$<
149-
150-
endif
151-
endif
152156
endif
157+
endif
153158

154-
endif # No pandoc / node
155159

156160
######################################################################
157161
# LLnextgen (grammar analysis from refman)

trunk/mk/install.mk

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,3 +154,69 @@ uninstall:
154154
done
155155
$(Q)rm -Rf $(PHL)/rustc
156156
$(Q)rm -f $(PREFIX_ROOT)/share/man/man1/rustc.1
157+
158+
# target platform specific variables
159+
# for arm-linux-androidabi
160+
define DEF_ADB_STATUS
161+
CFG_ADB_DEVICE=$(1)
162+
endef
163+
164+
$(foreach target,$(CFG_TARGET_TRIPLES), \
165+
$(if $(findstring $(target),"arm-linux-androideabi"), \
166+
$(if $(findstring adb,$(shell which adb)), \
167+
$(if $(findstring device,$(shell adb devices 2>/dev/null | grep -E '^[A-Za-z0-9-]+[[:blank:]]+device')), \
168+
$(info install: install-runtime-target for arm-linux-androideabi enabled \
169+
$(info install: android device attached) \
170+
$(eval $(call DEF_ADB_STATUS, true))), \
171+
$(info install: install-runtime-target for arm-linux-androideabi disabled \
172+
$(info install: android device not attached) \
173+
$(eval $(call DEF_ADB_STATUS, false))) \
174+
), \
175+
$(info install: install-runtime-target for arm-linux-androideabi disabled \
176+
$(info install: adb not found) \
177+
$(eval $(call DEF_ADB_STATUS, false))) \
178+
), \
179+
) \
180+
)
181+
182+
ifeq ($(CFG_ADB_DEVICE),true)
183+
184+
CFG_RUNTIME_PUSH_DIR=/system/lib
185+
186+
ifdef VERBOSE
187+
ADB = adb $(1)
188+
ADB_PUSH = adb push $(1) $(2)
189+
ADB_SHELL = adb shell $(1) $(2)
190+
else
191+
ADB = $(Q)$(call E, adb $(1)) && adb $(1) 1>/dev/null 2>/dev/null
192+
ADB_PUSH = $(Q)$(call E, adb push $(1)) && adb push $(1) $(2) 1>/dev/null 2>/dev/null
193+
ADB_SHELL = $(Q)$(call E, adb shell $(1) $(2)) && adb shell $(1) $(2) 1>/dev/null 2>/dev/null
194+
endif
195+
196+
define INSTALL_RUNTIME_TARGET_N
197+
install-runtime-target-$(1)-host-$(2): $$(TSREQ$$(ISTAGE)_T_$(1)_H_$(2)) $$(SREQ$$(ISTAGE)_T_$(1)_H_$(2))
198+
$(Q)$(call ADB_SHELL,mkdir,$(CFG_RUNTIME_PUSH_DIR))
199+
$(Q)$(call ADB_PUSH,$$(TL$(1)$(2))/$$(CFG_RUNTIME_$(1)),$(CFG_RUNTIME_PUSH_DIR))
200+
$(Q)$(call ADB_PUSH,$$(TL$(1)$(2))/$$(CORELIB_GLOB_$(1)),$(CFG_RUNTIME_PUSH_DIR))
201+
$(Q)$(call ADB_PUSH,$$(TL$(1)$(2))/$$(STDLIB_GLOB_$(1)),$(CFG_RUNTIME_PUSH_DIR))
202+
endef
203+
204+
define INSTALL_RUNTIME_TARGET_CLEANUP_N
205+
install-runtime-target-$(1)-cleanup:
206+
$(Q)$(call ADB,remount)
207+
$(Q)$(call ADB_SHELL,rm,$(CFG_RUNTIME_PUSH_DIR)/$(CFG_RUNTIME_$(1)))
208+
$(Q)$(call ADB_SHELL,rm,$(CFG_RUNTIME_PUSH_DIR)/$(CORELIB_GLOB_$(1)))
209+
$(Q)$(call ADB_SHELL,rm,$(CFG_RUNTIME_PUSH_DIR)/$(STDLIB_GLOB_$(1)))
210+
endef
211+
212+
$(eval $(call INSTALL_RUNTIME_TARGET_N,arm-linux-androideabi,$(CFG_BUILD_TRIPLE)))
213+
$(eval $(call INSTALL_RUNTIME_TARGET_CLEANUP_N,arm-linux-androideabi))
214+
215+
install-runtime-target: \
216+
install-runtime-target-arm-linux-androideabi-cleanup \
217+
install-runtime-target-arm-linux-androideabi-host-$(CFG_BUILD_TRIPLE)
218+
219+
else
220+
install-runtime-target:
221+
@echo
222+
endif

trunk/mk/rt.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ $$(LIBUV_LIB_$(1)): $$(LIBUV_DEPS)
169169
else ifeq ($(OSTYPE_$(1)), linux-androideabi)
170170
$$(LIBUV_LIB_$(1)): $$(LIBUV_DEPS)
171171
$$(Q)$$(MAKE) -C $$(S)src/libuv/ \
172-
CFLAGS="$$(LIBUV_FLAGS_$$(HOST_$(1))) $$(SNAP_DEFINES) $$(CFLAGS)" \
172+
CFLAGS="$$(LIBUV_FLAGS_$$(HOST_$(1))) $$(SNAP_DEFINES)" \
173173
LDFLAGS="$$(LIBUV_FLAGS_$$(HOST_$(1)))" \
174174
CC="$$(CC_$(1))" \
175175
CXX="$$(CXX_$(1))" \
@@ -181,7 +181,7 @@ $$(LIBUV_LIB_$(1)): $$(LIBUV_DEPS)
181181
else
182182
$$(LIBUV_LIB_$(1)): $$(LIBUV_DEPS)
183183
$$(Q)$$(MAKE) -C $$(S)src/libuv/ \
184-
CFLAGS="$$(LIBUV_FLAGS_$$(HOST_$(1))) $$(SNAP_DEFINES) $$(CFLAGS)" \
184+
CFLAGS="$$(LIBUV_FLAGS_$$(HOST_$(1))) $$(SNAP_DEFINES)" \
185185
LDFLAGS="$$(LIBUV_FLAGS_$$(HOST_$(1)))" \
186186
CC="$$(CC_$(1))" \
187187
CXX="$$(CXX_$(1))" \

0 commit comments

Comments
 (0)