Skip to content

Commit dc81124

Browse files
committed
---
yaml --- r: 101277 b: refs/heads/snap-stage3 c: b349fee h: refs/heads/master i: 101275: 72cdbfc v: v3
1 parent 939b990 commit dc81124

File tree

694 files changed

+19107
-13706
lines changed

Some content is hidden

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

694 files changed

+19107
-13706
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: e3b1f3c443c048913e2d573fcc5a9c2be3484a78
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: bc35eb78e2dab6b7cb3ede9176b0cfcafc4f8362
4+
refs/heads/snap-stage3: b349fee46e393db4cfd8bcf6f89d770a26c9e077
55
refs/heads/try: a97642026c18a624ff6ea01075dd9550f8ed07ff
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ config.mk
6060
/rt/
6161
/rustllvm/
6262
/test/
63-
/build/
63+
/build
6464
/inst/
6565
/mingw-build/
6666
src/.DS_Store

branches/snap-stage3/.travis.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# Use something that's not 'ruby' so we don't set up things like
2+
# RVM/bundler/ruby and whatnot. Right now 'rust' isn't a language on travis and
3+
# it treats unknown languages as ruby-like I believe.
4+
language: c
5+
6+
# Before we start doing anything, install a stock LLVM
7+
install:
8+
- sudo apt-get install llvm-3.3 llvm-3.3-dev clang-3.3 lldb-3.3
9+
10+
# All of the llvm tools are suffixed with "-3.3" which we don't want, so symlink
11+
# them all into a local directory and just use that
12+
#
13+
# FIXME: this shouldn't update the src/llvm sub-repo, that takes about a minute
14+
# it's gotta download so much stuff.
15+
before_script:
16+
- mkdir -p local-llvm/bin
17+
- ln -nsf /usr/bin/llvm-config-3.3 local-llvm/bin/llvm-config
18+
- ln -nsf /usr/bin/llvm-mc-3.3 local-llvm/bin/llvm-mc
19+
- ln -nsf /usr/bin/llvm-as-3.3 local-llvm/bin/llvm-as
20+
- ln -nsf /usr/bin/llvm-dis-3.3 local-llvm/bin/llvm-dis
21+
- ln -nsf /usr/bin/llc-3.3 local-llvm/bin/llc
22+
- ln -nsf /usr/include/llvm-3.3 local-llvm/include
23+
- ./configure --disable-optimize-tests --llvm-root=`pwd`/local-llvm --enable-fast-make --enable-clang
24+
25+
# Tidy everything up first, then build a few things, and then run a few tests.
26+
# Note that this is meant to run in a "fairly small" amount of time, so this
27+
# isn't exhaustive at all.
28+
#
29+
# The "-lffi and -lncurses" are required for LLVM. The LLVM that rust builds
30+
# manually disables bringing in these two libraries, but the stock LLVM was
31+
# apparently built with these options. We provide these options when building so
32+
# the `rustc` binary can successfully link.
33+
#
34+
# As a result of https://github.com/travis-ci/travis-ci/issues/1066, we run
35+
# everything in one large command instead of multiple commands.
36+
script: |
37+
make tidy &&
38+
RUSTFLAGS="-C link-args='-lffi -lncurses'" make -j4 rustc-stage1 &&
39+
make check-stage1-std check-stage1-rpass check-stage1-cfail check-stage1-rfail
40+
41+
env:
42+
- NO_BENCH=1
43+
44+
# We track this ourselves, and in theory we don't have to update the LLVM repo
45+
# (but sadly we do right now anyway).
46+
git:
47+
submodules: false

branches/snap-stage3/AUTHORS.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Adrien Tétar <[email protected]>
77
Alan Andrade <[email protected]>
88
Aleksander Balicki <[email protected]>
99
Alex Crichton <[email protected]>
10+
Alex Lyon <[email protected]>
1011
Alex Rønne Petersen <[email protected]>
1112
Alexander Stavonin <[email protected]>
1213
Alexandros Tasos <[email protected]>

branches/snap-stage3/Makefile.in

Lines changed: 28 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,17 @@
1919
#
2020
# First, start with one of these build targets:
2121
#
22-
# * all - The default. Builds a complete, bootstrapped compiler.
22+
# * all - The default. Build a complete, bootstrapped compiler.
2323
# `rustc` will be in `${target-triple}/stage2/bin/`. Run it
2424
# directly from the build directory if you like. This also
2525
# comes with docs in `doc/`.
2626
#
2727
# * check - Run the complete test suite
2828
#
29+
# * clean - Clean the build repertory. It is advised to run this
30+
# command if you want to build Rust again, after an update
31+
# of the git repository.
32+
#
2933
# * install - Install Rust. Note that installation is not necessary
3034
# to use the compiler.
3135
#
@@ -103,7 +107,7 @@
103107
#
104108
# </tips>
105109
#
106-
# <nittygritty>
110+
# <nitty-gritty>
107111
#
108112
# # The Rust Build System
109113
#
@@ -152,12 +156,12 @@
152156
# libraries are managed and versioned without polluting the common
153157
# areas of the filesystem.
154158
#
155-
# General rust binaries may stil live in the host bin directory; they
159+
# General rust binaries may still live in the host bin directory; they
156160
# will just link against the libraries in the target lib directory.
157161
#
158162
# Admittedly this is a little convoluted.
159163
#
160-
# </nittygritty>
164+
# </nitty-gritty>
161165
#
162166

163167
######################################################################
@@ -198,16 +202,6 @@ include $(CFG_SRC_DIR)mk/llvm.mk
198202
# Secondary makefiles, conditionalized for speed
199203
######################################################################
200204

201-
# Source and binary distribution artifacts
202-
ifneq ($(strip $(findstring dist,$(MAKECMDGOALS)) \
203-
$(findstring check,$(MAKECMDGOALS)) \
204-
$(findstring test,$(MAKECMDGOALS)) \
205-
$(findstring tidy,$(MAKECMDGOALS)) \
206-
$(findstring clean,$(MAKECMDGOALS))),)
207-
CFG_INFO := $(info cfg: including dist rules)
208-
include $(CFG_SRC_DIR)mk/dist.mk
209-
endif
210-
211205
# Binary snapshots
212206
ifneq ($(strip $(findstring snap,$(MAKECMDGOALS)) \
213207
$(findstring clean,$(MAKECMDGOALS))),)
@@ -230,18 +224,33 @@ ifneq ($(findstring perf,$(MAKECMDGOALS)),)
230224
include $(CFG_SRC_DIR)mk/perf.mk
231225
endif
232226

233-
# Cleaning
234-
ifneq ($(findstring clean,$(MAKECMDGOALS)),)
235-
CFG_INFO := $(info cfg: including clean rules)
236-
include $(CFG_SRC_DIR)mk/clean.mk
227+
# Copy all the distributables to another directory for binary install
228+
ifneq ($(strip $(findstring prepare,$(MAKECMDGOALS)) \
229+
$(findstring dist,$(MAKECMDGOALS)) \
230+
$(findstring install,$(MAKECMDGOALS))),)
231+
CFG_INFO := $(info cfg: including prepare rules)
232+
include $(CFG_SRC_DIR)mk/prepare.mk
237233
endif
238234

239-
# Installation from the build directory
235+
# (Unix) Installation from the build directory
240236
ifneq ($(findstring install,$(MAKECMDGOALS)),)
241237
CFG_INFO := $(info cfg: including install rules)
242238
include $(CFG_SRC_DIR)mk/install.mk
243239
endif
244240

241+
# Source and binary distribution artifacts
242+
ifneq ($(strip $(findstring dist,$(MAKECMDGOALS)) \
243+
$(findstring clean,$(MAKECMDGOALS))),)
244+
CFG_INFO := $(info cfg: including dist rules)
245+
include $(CFG_SRC_DIR)mk/dist.mk
246+
endif
247+
248+
# Cleaning
249+
ifneq ($(findstring clean,$(MAKECMDGOALS)),)
250+
CFG_INFO := $(info cfg: including clean rules)
251+
include $(CFG_SRC_DIR)mk/clean.mk
252+
endif
253+
245254
# CTAGS building
246255
ifneq ($(strip $(findstring TAGS.emacs,$(MAKECMDGOALS)) \
247256
$(findstring TAGS.vi,$(MAKECMDGOALS))),)

branches/snap-stage3/configure

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,7 @@ then
604604
LLVM_VERSION=$($LLVM_CONFIG --version)
605605

606606
case $LLVM_VERSION in
607-
(3.[2-4]svn|3.[2-4])
607+
(3.[2-5]svn|3.[2-5])
608608
msg "found ok version of LLVM: $LLVM_VERSION"
609609
;;
610610
(*)
@@ -626,7 +626,7 @@ then
626626
| cut -d ' ' -f 2)
627627

628628
case $CFG_CLANG_VERSION in
629-
(3.0svn | 3.0 | 3.1* | 3.2* | 3.3* | 3.4* )
629+
(3.0svn | 3.0 | 3.1* | 3.2* | 3.3* | 3.4* | 3.5* )
630630
step_msg "found ok version of CLANG: $CFG_CLANG_VERSION"
631631
CFG_C_COMPILER="clang"
632632
;;
@@ -803,7 +803,6 @@ do
803803
make_dir $h/test/doc-guide-pointers
804804
make_dir $h/test/doc-guide-container
805805
make_dir $h/test/doc-guide-tasks
806-
make_dir $h/test/doc-guide-conditions
807806
make_dir $h/test/doc-complement-cheatsheet
808807
make_dir $h/test/doc-rust
809808
done

branches/snap-stage3/mk/clean.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ clean-generic-$(2)-$(1):
5858
-name '*.[odasS]' -o \
5959
-name '*.so' -o \
6060
-name '*.dylib' -o \
61+
-name '*.rlib' -o \
6162
-name 'stamp.*' -o \
6263
-name '*.lib' -o \
6364
-name '*.dll' -o \

branches/snap-stage3/mk/crates.mk

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -50,36 +50,39 @@
5050
################################################################################
5151

5252
TARGET_CRATES := std extra green rustuv native flate arena glob term semver \
53-
uuid serialize sync getopts collections num
53+
uuid serialize sync getopts collections num test time
5454
HOST_CRATES := syntax rustc rustdoc fourcc
5555
CRATES := $(TARGET_CRATES) $(HOST_CRATES)
5656
TOOLS := compiletest rustdoc rustc
5757

5858
DEPS_std := native:rustrt native:compiler-rt
59-
DEPS_extra := std term sync serialize getopts collections
59+
DEPS_extra := std term sync serialize getopts collections time
6060
DEPS_green := std native:context_switch
6161
DEPS_rustuv := std native:uv native:uv_support
6262
DEPS_native := std
6363
DEPS_syntax := std term serialize collections
6464
DEPS_rustc := syntax native:rustllvm flate arena serialize sync getopts \
65-
collections extra
66-
DEPS_rustdoc := rustc native:sundown serialize sync getopts collections
67-
DEPS_flate := std native:miniz
65+
collections time extra
66+
DEPS_rustdoc := rustc native:sundown serialize sync getopts collections \
67+
test time
68+
DEPS_flate := std extra native:miniz
6869
DEPS_arena := std collections
6970
DEPS_glob := std
70-
DEPS_serialize := std
71-
DEPS_term := std
71+
DEPS_serialize := std collections
72+
DEPS_term := std collections
7273
DEPS_semver := std
7374
DEPS_uuid := std serialize
7475
DEPS_sync := std
7576
DEPS_getopts := std
76-
DEPS_collections := std serialize
77+
DEPS_collections := std
7778
DEPS_fourcc := syntax std
78-
DEPS_num := std extra
79+
DEPS_num := std
80+
DEPS_test := std extra collections getopts serialize term
81+
DEPS_time := std serialize
7982

80-
TOOL_DEPS_compiletest := extra green rustuv getopts
81-
TOOL_DEPS_rustdoc := rustdoc green rustuv
82-
TOOL_DEPS_rustc := rustc green rustuv
83+
TOOL_DEPS_compiletest := test green rustuv getopts
84+
TOOL_DEPS_rustdoc := rustdoc native
85+
TOOL_DEPS_rustc := rustc native
8386
TOOL_SOURCE_compiletest := $(S)src/compiletest/compiletest.rs
8487
TOOL_SOURCE_rustdoc := $(S)src/driver/driver.rs
8588
TOOL_SOURCE_rustc := $(S)src/driver/driver.rs

branches/snap-stage3/mk/dist.mk

Lines changed: 50 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ PKG_ICO = $(S)src/etc/pkg/rust-logo.ico
1212
PKG_EXE = $(PKG_DIR)-install.exe
1313
endif
1414

15+
ifeq ($(CFG_OSTYPE), apple-darwin)
16+
PKG_OSX = $(PKG_DIR).pkg
17+
endif
18+
1519
PKG_GITMODULES := $(S)src/libuv $(S)src/llvm $(S)src/gyp $(S)src/compiler-rt
1620

1721
PKG_FILES := \
@@ -24,10 +28,10 @@ PKG_FILES := \
2428
$(S)RELEASES.txt \
2529
$(S)configure $(S)Makefile.in \
2630
$(S)man \
27-
$(S)doc \
2831
$(addprefix $(S)src/, \
2932
README.md \
3033
compiletest \
34+
doc \
3135
driver \
3236
etc \
3337
$(foreach crate,$(CRATES),lib$(crate)) \
@@ -41,23 +45,35 @@ PKG_FILES := \
4145

4246
UNROOTED_PKG_FILES := $(patsubst $(S)%,./%,$(PKG_FILES))
4347

44-
ifdef CFG_ISCC
4548
LICENSE.txt: $(S)COPYRIGHT $(S)LICENSE-APACHE $(S)LICENSE-MIT
4649
cat $^ > $@
4750

51+
ifdef CFG_ISCC
4852
%.iss: $(S)src/etc/pkg/%.iss
4953
cp $< $@
5054

5155
%.ico: $(S)src/etc/pkg/%.ico
5256
cp $< $@
5357

5458
$(PKG_EXE): rust.iss modpath.iss LICENSE.txt rust-logo.ico \
55-
$(PKG_FILES) $(CSREQ3_T_$(CFG_BUILD)_H_$(CFG_BUILD))
56-
$(CFG_PYTHON) $(S)src/etc/copy-runtime-deps.py i686-pc-mingw32/stage3/bin
59+
$(PKG_FILES) $(CSREQ3_T_$(CFG_BUILD)_H_$(CFG_BUILD)) \
60+
dist-prepare-win
61+
$(CFG_PYTHON) $(S)src/etc/copy-runtime-deps.py tmp/dist/win/bin
5762
@$(call E, ISCC: $@)
5863
$(Q)"$(CFG_ISCC)" $<
59-
endif
6064

65+
dist-prepare-win: PREPARE_HOST=$(CFG_BUILD)
66+
dist-prepare-win: PREPARE_TARGETS=$(CFG_BUILD)
67+
dist-prepare-win: PREPARE_DEST_DIR=tmp/dist/win
68+
# On windows we're using stage3, unlike Unix...
69+
dist-prepare-win: PREPARE_STAGE=3
70+
dist-prepare-win: PREPARE_DIR_CMD=$(DEFAULT_PREPARE_DIR_CMD)
71+
dist-prepare-win: PREPARE_BIN_CMD=$(DEFAULT_PREPARE_BIN_CMD)
72+
dist-prepare-win: PREPARE_LIB_CMD=$(DEFAULT_PREPARE_LIB_CMD)
73+
dist-prepare-win: PREPARE_MAN_CMD=$(DEFAULT_PREPARE_MAN_CMD)
74+
dist-prepare-win: prepare-base
75+
76+
endif
6177

6278
$(PKG_TAR): $(PKG_FILES)
6379
@$(call E, making dist dir)
@@ -91,7 +107,7 @@ distcheck: dist
91107

92108
else
93109

94-
dist: $(PKG_TAR)
110+
dist: $(PKG_TAR) $(PKG_OSX)
95111

96112
distcheck: $(PKG_TAR)
97113
$(Q)rm -Rf dist
@@ -112,3 +128,31 @@ distcheck: $(PKG_TAR)
112128
@echo -----------------------------------------------
113129

114130
endif
131+
132+
ifeq ($(CFG_OSTYPE), apple-darwin)
133+
134+
dist-prepare-osx: PREPARE_HOST=$(CFG_BUILD)
135+
dist-prepare-osx: PREPARE_TARGETS=$(CFG_BUILD)
136+
dist-prepare-osx: PREPARE_DEST_DIR=tmp/dist/pkgroot
137+
dist-prepare-osx: PREPARE_STAGE=2
138+
dist-prepare-osx: PREPARE_DIR_CMD=$(DEFAULT_PREPARE_DIR_CMD)
139+
dist-prepare-osx: PREPARE_BIN_CMD=$(DEFAULT_PREPARE_BIN_CMD)
140+
dist-prepare-osx: PREPARE_LIB_CMD=$(DEFAULT_PREPARE_LIB_CMD)
141+
dist-prepare-osx: PREPARE_MAN_CMD=$(DEFAULT_PREPARE_MAN_CMD)
142+
dist-prepare-osx: prepare-base
143+
144+
$(PKG_OSX): Distribution.xml LICENSE.txt dist-prepare-osx
145+
@$(call E, making OS X pkg)
146+
$(Q)pkgbuild --identifier org.rust-lang.rust --root tmp/dist/pkgroot rust.pkg
147+
$(Q)productbuild --distribution Distribution.xml --resources . $(PKG_OSX)
148+
$(Q)rm -rf tmp rust.pkg
149+
150+
dist-osx: $(PKG_OSX)
151+
152+
distcheck-osx: $(PKG_OSX)
153+
@echo
154+
@echo -----------------------------------------------
155+
@echo $(PKG_OSX) ready for distribution
156+
@echo -----------------------------------------------
157+
158+
endif

0 commit comments

Comments
 (0)