Skip to content

Commit 18f4496

Browse files
committed
---
yaml --- r: 98134 b: refs/heads/master c: 6361c1d h: refs/heads/master v: v3
1 parent e8a7939 commit 18f4496

File tree

141 files changed

+4945
-14142
lines changed

Some content is hidden

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

141 files changed

+4945
-14142
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: c57920b37b401ca364b6d4c99dc714f28988c7f0
2+
refs/heads/master: 6361c1dee5df03ae5ef915423814c29ab56315d0
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: b6400f998497c3958f40997a71756ead344a776d
55
refs/heads/try: c274a6888410ce3e357e014568b43310ed787d36

trunk/Makefile.in

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,8 @@ export CFG_ENABLE_MINGW_CROSS
417417
export CFG_PREFIX
418418
export CFG_LIBDIR
419419
export CFG_RUSTLIBDIR
420-
export LIBDIR_RELATIVE
420+
export CFG_LIBDIR_RELATIVE
421+
export CFG_DISABLE_INJECT_STD_VERSION
421422

422423
######################################################################
423424
# Subprograms
@@ -435,7 +436,7 @@ define SREQ
435436
# Destinations of artifacts for the host compiler
436437
HROOT$(1)_H_$(3) = $(3)/stage$(1)
437438
HBIN$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/bin
438-
HLIB$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/$$(LIBDIR_RELATIVE)
439+
HLIB$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/$$(CFG_LIBDIR_RELATIVE)
439440

440441
# Destinations of artifacts for target architectures
441442
TROOT$(1)_T_$(2)_H_$(3) = $$(HLIB$(1)_H_$(3))/$$(CFG_RUSTLIBDIR)/$(2)

trunk/configure

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -381,6 +381,7 @@ opt clang 0 "prefer clang to gcc for building the runtime"
381381
opt ccache 0 "invoke gcc/clang via ccache to reuse object files between builds"
382382
opt local-rust 0 "use an installed rustc rather than downloading a snapshot"
383383
opt pax-flags 0 "apply PaX flags to rustc binaries (required for GRSecurity/PaX-patched kernels)"
384+
opt inject-std-version 1 "inject the current compiler version of libstd into programs"
384385
valopt prefix "/usr/local" "set installation prefix"
385386
valopt local-rust-root "/usr/local" "set prefix for local rust binary"
386387
valopt llvm-root "" "set LLVM root"
@@ -401,13 +402,13 @@ valopt mandir "${CFG_PREFIX}/share/man" "install man pages in PATH"
401402
# On windows we just store the libraries in the bin directory because
402403
# there's no rpath
403404
# FIXME: Thise needs to parameterized over target triples. Do it in platform.mk
404-
LIBDIR_RELATIVE=lib
405+
CFG_LIBDIR_RELATIVE=lib
405406
if [ "$CFG_OSTYPE" = "pc-mingw32" ]
406407
then
407-
LIBDIR_RELATIVE=bin
408+
CFG_LIBDIR_RELATIVE=bin
408409
fi
409410

410-
valopt libdir "${CFG_PREFIX}/${LIBDIR_RELATIVE}" "install libraries"
411+
valopt libdir "${CFG_PREFIX}/${CFG_LIBDIR_RELATIVE}" "install libraries"
411412
valopt rustlibdir "rustlib" "subdirectory name for rustc's libraries"
412413

413414
# Validate Options
@@ -771,16 +772,16 @@ do
771772
make_dir $h/stage$i/bin
772773

773774
# host lib dir
774-
make_dir $h/stage$i/$LIBDIR_RELATIVE
775+
make_dir $h/stage$i/$CFG_LIBDIR_RELATIVE
775776

776777
# host test dir
777778
make_dir $h/stage$i/test
778779

779780
# target bin dir
780-
make_dir $h/stage$i/$LIBDIR_RELATIVE/$CFG_RUSTLIBDIR/$t/bin
781+
make_dir $h/stage$i/$CFG_LIBDIR_RELATIVE/$CFG_RUSTLIBDIR/$t/bin
781782

782783
# target lib dir
783-
make_dir $h/stage$i/$LIBDIR_RELATIVE/$CFG_RUSTLIBDIR/$t/lib
784+
make_dir $h/stage$i/$CFG_LIBDIR_RELATIVE/$CFG_RUSTLIBDIR/$t/lib
784785
done
785786
done
786787

@@ -795,6 +796,7 @@ do
795796
make_dir $h/test/codegen
796797
make_dir $h/test/doc-tutorial
797798
make_dir $h/test/doc-guide-ffi
799+
make_dir $h/test/doc-guide-runtime
798800
make_dir $h/test/doc-guide-macros
799801
make_dir $h/test/doc-guide-lifetimes
800802
make_dir $h/test/doc-guide-pointers
@@ -1036,11 +1038,12 @@ putvar CFG_TARGET
10361038
putvar CFG_C_COMPILER
10371039
putvar CFG_LIBDIR
10381040
putvar CFG_RUSTLIBDIR
1039-
putvar LIBDIR_RELATIVE
1041+
putvar CFG_LIBDIR_RELATIVE
10401042
putvar CFG_DISABLE_MANAGE_SUBMODULES
10411043
putvar CFG_ANDROID_CROSS_PATH
10421044
putvar CFG_MINGW32_CROSS_PATH
10431045
putvar CFG_MANDIR
1046+
putvar CFG_DISABLE_INJECT_STD_VERSION
10441047

10451048
# Avoid spurious warnings from clang by feeding it original source on
10461049
# ccache-miss rather than preprocessed input.

trunk/doc/README.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@ source code.
88
the Markdown docs (reference manual, tutorials, etc.) distributed with
99
this git repository.
1010

11+
[po4a](http://po4a.alioth.debian.org/) is required for generating translated
12+
docs from the master (English) docs.
13+
14+
[GNU gettext](http://www.gnu.org/software/gettext/) is required for managing
15+
the translation data.
16+
1117
# Building
1218

1319
To generate all the docs, just run `make docs` from the root of the repository.
@@ -38,3 +44,43 @@ http://johnmacfarlane.net/pandoc/README.html#pandocs-markdown
3844

3945
A nice quick reference (for non-pandoc markdown) is at:
4046
http://kramdown.rubyforge.org/quickref.html
47+
48+
# Notes for translators
49+
50+
Notice: The procedure described below is a work in progress. We are working on
51+
translation system but the procedure contains some manual operations for now.
52+
53+
To start the translation for a new language, see po4a.conf at first.
54+
55+
To generate .pot and .po files, do something like:
56+
57+
~~~~
58+
po4a --copyright-holder="The Rust Project Developers" \
59+
--package-name="Rust" \
60+
--package-version="0.10-pre" \
61+
-M UTF-8 -L UTF-8 \
62+
po4a.conf
63+
~~~~
64+
65+
(the version number must be changed if it is not 0.10-pre now.)
66+
67+
Now you can translate documents with .po files, commonly used with gettext. If
68+
you are not familiar with gettext-based translation, please read the online
69+
manual linked from http://www.gnu.org/software/gettext/ . We use UTF-8 as the
70+
file encoding of .po files.
71+
72+
When you want to make a commit, do the command below before staging your
73+
change:
74+
75+
~~~~
76+
for f in doc/po/**/*.po; do
77+
msgattrib --translated $f -o $f.strip
78+
if [ -e $f.strip ]; then
79+
mv $f.strip $f
80+
else
81+
rm $f
82+
fi
83+
done
84+
~~~~
85+
86+
This removes untranslated entries from .po files to save disk space.

0 commit comments

Comments
 (0)