Skip to content

Commit f065de9

Browse files
committed
---
yaml --- r: 146383 b: refs/heads/try2 c: 681fda0 h: refs/heads/master i: 146381: a0cda6d 146379: 629f6d5 146375: 0720a36 146367: a1bfbc7 v: v3
1 parent 9cf1e8a commit f065de9

Some content is hidden

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

57 files changed

+1161
-1440
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/snap-stage3: 78a7676898d9f80ab540c6df5d4c9ce35bb50463
55
refs/heads/try: 519addf6277dbafccbb4159db4b710c37eaa2ec5
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: 22dfdc927b65d2e6eb5f9a594615ac2e6a8425a8
8+
refs/heads/try2: 681fda016979786da5d60a5c6d7fcf5c6c649c86
99
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try2/Makefile.in

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -249,12 +249,12 @@ endef
249249
# by $(2) with a space character prefix, which invalidates the
250250
# construction $(1)$(2).
251251
define CHECK_FOR_OLD_GLOB_MATCHES_EXCEPT
252-
$(Q)MATCHES="$(filter-out %$(3),$(wildcard $(1)/$(2)))"; if [ -n "$$MATCHES" ] ; then echo "warning: there are previous" \'$(2)\' "libraries:" $$MATCHES; fi
252+
$(Q)MATCHES="$(filter-out %$(3),$(wildcard $(1)/$(2)))"; if [ -n "$$MATCHES" ] ; then echo "Warning: there are previous" \'$(2)\' "libraries:" $$MATCHES; fi
253253
endef
254254

255255
# Same interface as above, but deletes rather than just listing the files.
256256
define REMOVE_ALL_OLD_GLOB_MATCHES_EXCEPT
257-
$(Q)MATCHES="$(filter-out %$(3),$(wildcard $(1)/$(2)))"; if [ -n "$$MATCHES" ] ; then echo "warning: removing previous" \'$(2)\' "libraries:" $$MATCHES; rm $$MATCHES ; fi
257+
$(Q)MATCHES="$(filter-out %$(3),$(wildcard $(1)/$(2)))"; if [ -n "$$MATCHES" ] ; then echo "Warning: removing previous" \'$(2)\' "libraries:" $$MATCHES; rm $$MATCHES ; fi
258258
endef
259259

260260
# We use a different strategy for LIST_ALL_OLD_GLOB_MATCHES_EXCEPT
@@ -265,7 +265,7 @@ endef
265265
# be run at the outset of a command list in a rule.)
266266
ifdef VERBOSE
267267
define LIST_ALL_OLD_GLOB_MATCHES_EXCEPT
268-
@echo "info: now are following matches for" '$(2)' "libraries:"
268+
@echo "Info: now are following matches for" '$(2)' "libraries:"
269269
@( cd $(1) && ( ls $(2) 2>/dev/null || true ) | grep -v $(3) || true )
270270
endef
271271
else
@@ -677,6 +677,12 @@ ifneq ($(findstring clean,$(MAKECMDGOALS)),)
677677
endif
678678

679679
ifneq ($(findstring install,$(MAKECMDGOALS)),)
680+
ifdef DESTDIR
681+
CFG_INFO := $(info cfg: setting CFG_PREFIX via DESTDIR, $(DESTDIR)/$(CFG_PREFIX))
682+
CFG_PREFIX:=$(DESTDIR)/$(CFG_PREFIX)
683+
export CFG_PREFIX
684+
endif
685+
680686
CFG_INFO := $(info cfg: including install rules)
681687
include $(CFG_SRC_DIR)mk/install.mk
682688
endif

branches/try2/configure

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -400,6 +400,11 @@ valopt infodir "${CFG_PREFIX}/share/info" "install additional info"
400400
valopt mandir "${CFG_PREFIX}/share/man" "install man pages in PATH"
401401
valopt libdir "${CFG_PREFIX}/lib" "install libraries"
402402

403+
#Deprecated opts to keep compatibility
404+
valopt build-triple "${CFG_BUILD}" "LLVM build triple"
405+
valopt host-triples "${CFG_HOST}" "LLVM host triples"
406+
valopt target-triples "${CFG_TARGET}" "LLVM target triples"
407+
403408
# Validate Options
404409
step_msg "validating $CFG_SELF args"
405410
validate_opt
@@ -463,14 +468,12 @@ then
463468
# extract the first 2 version fields, ignore everything else
464469
sed 's/pandoc \([0-9]*\)\.\([0-9]*\).*/\1 \2/')
465470

466-
MIN_PV_MAJOR="1"
467-
MIN_PV_MINOR="9"
468471
# these patterns are shell globs, *not* regexps
469472
PV_MAJOR=${PV_MAJOR_MINOR% *}
470473
PV_MINOR=${PV_MAJOR_MINOR#* }
471-
if [ "$PV_MAJOR" -lt "$MIN_PV_MAJOR" ] || [ "$PV_MINOR" -lt "$MIN_PV_MINOR" ]
474+
if [ "$PV_MAJOR" -lt "1" ] || [ "$PV_MINOR" -lt "8" ]
472475
then
473-
step_msg "pandoc $PV_MAJOR.$PV_MINOR is too old. Need at least $MIN_PV_MAJOR.$MIN_PV_MINOR. Disabling"
476+
step_msg "pandoc $PV_MAJOR.$PV_MINOR is too old. disabling"
474477
BAD_PANDOC=1
475478
fi
476479
fi
@@ -598,6 +601,7 @@ then
598601
fi
599602

600603
# a little post-processing of various config values
604+
601605
CFG_PREFIX=${CFG_PREFIX%/}
602606
CFG_MANDIR=${CFG_MANDIR%/}
603607
CFG_HOST="$(echo $CFG_HOST | tr ',' ' ')"
@@ -612,6 +616,26 @@ do
612616
done
613617
CFG_TARGET=$V_TEMP
614618

619+
# copy host-triples to target-triples so that hosts are a subset of targets
620+
# XXX: remove deprecated variables here
621+
V_TEMP=""
622+
for i in $CFG_HOST_TRIPLES $CFG_TARGET_TRIPLES;
623+
do
624+
echo "$V_TEMP" | grep -qF $i || V_TEMP="$V_TEMP${V_TEMP:+ }$i"
625+
done
626+
CFG_TARGET_TRIPLES=$V_TEMP
627+
628+
# XXX: Support for deprecated syntax, should be dropped.
629+
if [ ! -z "$CFG_BUILD_TRIPLE" ]; then
630+
CFG_BUILD=${CFG_BUILD_TRIPLE}
631+
fi
632+
if [ ! -z "$CFG_HOST_TRIPLES" ]; then
633+
CFG_HOST=${CFG_HOST_TRIPLES}
634+
fi
635+
if [ ! -z "$CFG_TARGET_TRIPLES" ]; then
636+
CFG_TARGET=${CFG_TARGET_TRIPLES}
637+
fi
638+
615639
# check target-specific tool-chains
616640
for i in $CFG_TARGET
617641
do
@@ -646,13 +670,6 @@ do
646670
fi
647671
;;
648672

649-
arm-apple-darwin)
650-
if [ $CFG_OSTYPE != apple-darwin ]
651-
then
652-
err "The iOS target is only supported on Mac OS X"
653-
fi
654-
;;
655-
656673
*)
657674
;;
658675
esac

branches/try2/doc/rust.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -568,7 +568,6 @@ This requirement most often affects name-designator pairs when they occur at the
568568
* `log_syntax!` : print out the arguments at compile time
569569
* `trace_macros!` : supply `true` or `false` to enable or disable macro expansion logging
570570
* `stringify!` : turn the identifier argument into a string literal
571-
* `concat!` : concatenates a comma-separated list of literals
572571
* `concat_idents!` : create a new identifier by concatenating the arguments
573572

574573
# Crates and source files

branches/try2/mk/install.mk

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,24 +18,24 @@
1818
# $(2) is the destination directory
1919
# $(3) is the filename/libname-glob
2020
ifdef VERBOSE
21-
INSTALL = install -m755 $(1)/$(3) $(DESTDIR)$(2)/$(3)
21+
INSTALL = install -m755 $(1)/$(3) $(2)/$(3)
2222
else
23-
INSTALL = $(Q)$(call E, install: $(DESTDIR)$(2)/$(3)) && install -m755 $(1)/$(3) $(DESTDIR)$(2)/$(3)
23+
INSTALL = $(Q)$(call E, install: $(2)/$(3)) && install -m755 $(1)/$(3) $(2)/$(3)
2424
endif
2525

2626
# For MK_INSTALL_DIR
2727
# $(1) is the directory to create
28-
MK_INSTALL_DIR = (umask 022 && mkdir -p $(DESTDIR)$(1))
28+
MK_INSTALL_DIR = (umask 022 && mkdir -p $(1))
2929

3030
# For INSTALL_LIB,
3131
# Target-specific $(LIB_SOURCE_DIR) is the source directory
3232
# Target-specific $(LIB_DESTIN_DIR) is the destination directory
3333
# $(1) is the filename/libname-glob
3434
ifdef VERBOSE
35-
DO_INSTALL_LIB = install -m644 `ls -drt1 $(LIB_SOURCE_DIR)/$(1) | tail -1` $(DESTDIR)$(LIB_DESTIN_DIR)/
35+
DO_INSTALL_LIB = install -m644 `ls -drt1 $(LIB_SOURCE_DIR)/$(1) | tail -1` $(LIB_DESTIN_DIR)/
3636
else
37-
DO_INSTALL_LIB = $(Q)$(call E, install_lib: $(DESTDIR)$(LIB_DESTIN_DIR)/$(1)) && \
38-
install -m644 `ls -drt1 $(LIB_SOURCE_DIR)/$(1) | tail -1` $(DESTDIR)$(LIB_DESTIN_DIR)/
37+
DO_INSTALL_LIB = $(Q)$(call E, install_lib: $(LIB_DESTIN_DIR)/$(1)) && \
38+
install -m644 `ls -drt1 $(LIB_SOURCE_DIR)/$(1) | tail -1` $(LIB_DESTIN_DIR)/
3939
endif
4040

4141
# Target-specific $(LIB_SOURCE_DIR) is the source directory
@@ -50,7 +50,7 @@ define INSTALL_LIB
5050
MATCHES="$(filter-out %$(notdir $(lastword $(wildcard $(LIB_SOURCE_DIR)/$(1)))),\
5151
$(wildcard $(LIB_DESTIN_DIR)/$(1)))"; \
5252
if [ -n "$$MATCHES" ]; then \
53-
echo "warning: one or libraries matching Rust library '$(1)'" && \
53+
echo "Warning, one or libraries matching Rust library '$(1)'" && \
5454
echo " (other than '$$LIB_NAME' itself) already present" && \
5555
echo " at destination $(LIB_DESTIN_DIR):" && \
5656
echo $$MATCHES ; \
@@ -152,9 +152,9 @@ install-host: $(CSREQ$(ISTAGE)_T_$(CFG_BUILD_)_H_$(CFG_BUILD_))
152152
$(Q)$(call INSTALL_LIB,$(LIBRUSTDOC_GLOB_$(CFG_BUILD)))
153153
$(Q)$(call INSTALL,$(HL),$(PHL),$(CFG_RUNTIME_$(CFG_BUILD)))
154154
$(Q)$(call INSTALL,$(HL),$(PHL),$(CFG_RUSTLLVM_$(CFG_BUILD)))
155-
$(Q)$(call INSTALL,$(S)/man,$(CFG_MANDIR)/man1,rustc.1)
156-
$(Q)$(call INSTALL,$(S)/man,$(CFG_MANDIR)/man1,rustdoc.1)
157-
$(Q)$(call INSTALL,$(S)/man,$(CFG_MANDIR)/man1,rustpkg.1)
155+
$(Q)$(call INSTALL,$(S)/man, $(CFG_MANDIR)/man1,rustc.1)
156+
$(Q)$(call INSTALL,$(S)/man, $(CFG_MANDIR)/man1,rustdoc.1)
157+
$(Q)$(call INSTALL,$(S)/man, $(CFG_MANDIR)/man1,rustpkg.1)
158158

159159
install-targets: $(INSTALL_TARGET_RULES)
160160

branches/try2/mk/platform.mk

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -193,35 +193,6 @@ CFG_LDPATH_i686-unknown-linux-gnu :=
193193
CFG_RUN_i686-unknown-linux-gnu=$(2)
194194
CFG_RUN_TARG_i686-unknown-linux-gnu=$(call CFG_RUN_i686-unknown-linux-gnu,,$(2))
195195

196-
# arm-apple-darwin configuration
197-
ifeq ($(CFG_OSTYPE),apple-darwin)
198-
CFG_IOS_SDK = $(shell xcrun --show-sdk-path -sdk iphoneos)
199-
CFG_IOS_FLAGS = -target arm-apple-darwin -isysroot $(CFG_IOS_SDK) -I $(CFG_IOS_SDK)/usr/include -I $(CFG_IOS_SDK)/usr/include/c++/4.2.1 -I /usr/include
200-
CC_arm-apple-darwin = $(shell xcrun -find -sdk iphoneos clang)
201-
CXX_arm-apple-darwin = $(shell xcrun -find -sdk iphoneos clang++)
202-
CPP_arm-apple-darwin = $(shell xcrun -find -sdk iphoneos clang++)
203-
AR_arm-apple-darwin = $(shell xcrun -find -sdk iphoneos ar)
204-
CFG_LIB_NAME_arm-apple-darwin = lib$(1).dylib
205-
CFG_LIB_GLOB_arm-apple-darwin = lib$(1)-*.dylib
206-
CFG_LIB_DSYM_GLOB_arm-apple-darwin = lib$(1)-*.dylib.dSYM
207-
CFG_GCCISH_CFLAGS_arm-apple-darwin := -Wall -Werror -g -fPIC $(CFG_IOS_FLAGS)
208-
CFG_GCCISH_CXXFLAGS_arm-apple-darwin := -fno-rtti $(CFG_IOS_FLAGS)
209-
CFG_GCCISH_LINK_FLAGS_arm-apple-darwin := -dynamiclib -lpthread -framework CoreServices -Wl,-no_compact_unwind
210-
CFG_GCCISH_DEF_FLAG_arm-apple-darwin := -Wl,-exported_symbols_list,
211-
CFG_GCCISH_PRE_LIB_FLAGS_arm-apple-darwin :=
212-
CFG_GCCISH_POST_LIB_FLAGS_arm-apple-darwin :=
213-
CFG_DEF_SUFFIX_arm-apple-darwin := .darwin.def
214-
CFG_INSTALL_NAME_arm-apple-darwin = -Wl,-install_name,@rpath/$(1)
215-
CFG_LIBUV_LINK_FLAGS_arm-apple-darwin =
216-
CFG_EXE_SUFFIX_arm-apple-darwin :=
217-
CFG_WINDOWSY_arm-apple-darwin :=
218-
CFG_UNIXY_arm-apple-darwin := 1
219-
CFG_PATH_MUNGE_arm-apple-darwin := true
220-
CFG_LDPATH_arm-apple-darwin :=
221-
CFG_RUN_arm-apple-darwin = $(2)
222-
CFG_RUN_TARG_arm-apple-darwin = $(call CFG_RUN_arm-apple-darwin,,$(2))
223-
endif
224-
225196
# x86_64-apple-darwin configuration
226197
CC_x86_64-apple-darwin=$(CC)
227198
CXX_x86_64-apple-darwin=$(CXX)

branches/try2/mk/stage0.mk

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,14 @@ $(HLIB0_H_$(CFG_BUILD))/$(CFG_EXTRALIB_$(CFG_BUILD)): \
4242
| $(HLIB0_H_$(CFG_BUILD))/
4343
$(Q)touch $@
4444

45-
$(HLIB0_H_$(CFG_BUILD))/$(CFG_LIBRUSTUV_$(CFG_BUILD)): \
46-
$(HBIN0_H_$(CFG_BUILD))/rustc$(X_$(CFG_BUILD)) \
47-
| $(HLIB0_H_$(CFG_BUILD))/
45+
$(HLIB0_H_$(CFG_BUILD_TRIPLE))/$(CFG_LIBRUSTUV_$(CFG_BUILD)): \
46+
$(HBIN0_H_$(CFG_BUILD_TRIPLE))/rustc$(X_$(CFG_BUILD)) \
47+
| $(HLIB0_H_$(CFG_BUILD_TRIPLE))/
4848
$(Q)touch $@
4949

50-
$(HLIB0_H_$(CFG_BUILD))/$(CFG_LIBRUSTC_$(CFG_BUILD)): \
51-
$(HBIN0_H_$(CFG_BUILD))/rustc$(X_$(CFG_BUILD)) \
52-
| $(HLIB0_H_$(CFG_BUILD))/
50+
$(HLIB0_H_$(CFG_BUILD_TRIPLE))/$(CFG_LIBRUSTC_$(CFG_BUILD)): \
51+
$(HBIN0_H_$(CFG_BUILD_TRIPLE))/rustc$(X_$(CFG_BUILD)) \
52+
| $(HLIB0_H_$(CFG_BUILD_TRIPLE))/
5353
$(Q)touch $@
5454

5555
$(HLIB0_H_$(CFG_BUILD))/$(CFG_RUSTLLVM_$(CFG_BUILD)): \
@@ -124,5 +124,5 @@ endef
124124

125125
# Use stage1 to build other architectures: then you don't have to wait
126126
# for stage2, but you get the latest updates to the compiler source.
127-
$(foreach t,$(NON_BUILD_HOST), \
127+
$(foreach t,$(NON_BUILD_HOSTS), \
128128
$(eval $(call BOOTSTRAP_STAGE0,$(t),1,$(CFG_BUILD))))

branches/try2/mk/tests.mk

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ $(info check: android device test dir $(CFG_ADB_TEST_DIR) ready \
164164
$(CFG_ADB_TEST_DIR)) \
165165
$(shell adb push $(TLIB2_T_arm-linux-androideabi_H_$(CFG_BUILD))/$(EXTRALIB_GLOB_arm-linux-androideabi) \
166166
$(CFG_ADB_TEST_DIR)) \
167-
$(shell adb push $(TLIB2_T_arm-linux-androideabi_H_$(CFG_BUILD))/$(LIBRUSTUV_GLOB_arm-linux-androideabi) \
167+
$(shell adb push $(TLIB2_T_arm-linux-androideabi_H_$(CFG_BUILD_TRIPLE))/$(LIBRUSTUV_GLOB_arm-linux-androideabi) \
168168
$(CFG_ADB_TEST_DIR)) \
169169
)
170170
else
@@ -471,8 +471,8 @@ define DEF_RUSTPKG_STACK_FIX
471471
$$(call TEST_OK_FILE,$(1),$(2),$(3),rustpkg): export RUST_MIN_STACK=8000000
472472
endef
473473

474-
$(foreach host,$(CFG_HOST), \
475-
$(foreach target,$(CFG_TARGET), \
474+
$(foreach host,$(CFG_HOST_TRIPLES), \
475+
$(foreach target,$(CFG_TARGET_TRIPLES), \
476476
$(foreach stage,$(STAGES), \
477477
$(eval $(call DEF_RUSTPKG_STACK_FIX,$(stage),$(target),$(host))))))
478478

branches/try2/src/etc/ziggurat_tables.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
import random
2020

2121
# The order should match the return value of `tables`
22-
TABLE_NAMES = ['X', 'F']
22+
TABLE_NAMES = ['X', 'F', 'F_DIFF']
2323

2424
# The actual length of the table is 1 more, to stop
2525
# index-out-of-bounds errors. This should match the bitwise operation
@@ -43,10 +43,13 @@ def tables(r, v, f, f_inv):
4343

4444
# cache the f's
4545
fvec = [0]*(TABLE_LEN+1)
46+
fdiff = [0]*(TABLE_LEN+1)
4647
for i in range(TABLE_LEN+1):
4748
fvec[i] = f(xvec[i])
49+
if i > 0:
50+
fdiff[i] = fvec[i] - fvec[i-1]
4851

49-
return xvec, fvec
52+
return xvec, fvec, fdiff
5053

5154
# Distributions
5255
# N(0, 1)

branches/try2/src/libextra/extra.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,9 @@ pub mod extra {
118118
pub use std::clone;
119119
pub use std::condition;
120120
pub use std::cmp;
121+
// NOTE: Remove import after next snapshot
122+
#[cfg(stage0)]
123+
pub use std::sys;
121124
pub use std::unstable;
122125
pub use std::str;
123126
pub use std::os;

branches/try2/src/libextra/test.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -869,10 +869,6 @@ pub fn run_test(force_ignore: bool,
869869
do task::spawn {
870870
let mut task = task::task();
871871
task.unlinked();
872-
task.name(match desc.name {
873-
DynTestName(ref name) => SendStrOwned(name.clone()),
874-
StaticTestName(name) => SendStrStatic(name),
875-
});
876872
let result_future = task.future_result();
877873
task.spawn(testfn_cell.take());
878874

branches/try2/src/librustc/front/feature_gate.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -140,12 +140,12 @@ impl Visitor<()> for Context {
140140

141141
},
142142
ast::ty_box(_) => {
143-
self.gate_feature("managed_boxes", t.span,
144-
"The managed box syntax will be replaced \
145-
by a library type, and a garbage \
146-
collector is not yet implemented. \
147-
Consider using the `std::rc::Rc` type \
148-
for reference counted pointers.");
143+
self.gate_feature("managed_boxes", t.span, "The managed box syntax may be replaced \
144+
by a library type, and a garbage \
145+
collector is not yet implemented. \
146+
Consider using the `std::rc` module \
147+
as it performs much better as a \
148+
reference counting implementation.");
149149
}
150150
_ => {}
151151
}

0 commit comments

Comments
 (0)