Commit Graph

576 Commits

Author SHA1 Message Date
Ramkumar Ramachandra
8b87debbc2 configure: replace echo "" with plain echo
When no arguments are given, echo prints a blank line.  These two are
equivalent:

  $ echo ""
  $ echo

Replace the former by the latter.

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
2013-06-08 14:13:37 +05:30
Daniel Micay
933897c5f5 integrate jemalloc into the build 2013-06-01 11:31:44 -04:00
bors
9bfe296eb7 auto merge of #6836 : pnkfelix/rust/fsk-issue6805-ccache-rewrite-basedir, r=catamorphism
Attempt to get reuse of common object code from multiple clones in different directories.

This is a followup to issue #6805.
2013-05-30 14:58:47 -07:00
Corey Richardson
594f40ecbe bump clang version 2013-05-30 13:33:52 -04:00
Felix S. Klock II
7f410b326c Attempt to get reuse of common code from multiple clones in different directories. 2013-05-30 16:26:12 +02:00
bors
bd30285c84 auto merge of #6813 : pnkfelix/rust/fsk-issue-6805-ccache-support, r=catamorphism
Fix #6805: add --enable-ccache configure option to prefix compiler invocations with `ccache` to attempt to reuse common results, e.g. for LLVM (re)builds.

The information at developer [Note-ccache](../../wiki/Note-ccache) and at [ccache and clang concerns](http://petereisentraut.blogspot.fr/2011/09/ccache-and-clang-part-2.html) were what drove my introduction of the `-Qunused-arguments` and `CCACHE_CPP2` options.  (Though I did confirm first-hand that at least the first really is necessary.)

Yes, one certainly can re-route how `gcc` and `clang` are resolved in one's PATH and use that as a way to invoke `ccache`.  But I personally do not want to introduce that change to my own PATH, and this seems like a small enough change that it does not hurt to add it, at least for now.  (I don't know what form it would take when we move over to `rustpkg`.)
2013-05-29 15:10:42 -07:00
Felix S. Klock II
2b083373e4 Fix #6805: add --enable-ccache configure option to prefix compiler invocations with ccache to attempt to reuse common results, e.g. for LLVM (re)builds. 2013-05-29 23:18:09 +02:00
Kevin Ballard
bf57d65a11 Issue #6419: Better clang version detection for Apple Clang
Apple Clang uses different version numbering than "regular" clang, but
it also provides the "regular" version it's based on. Update the sed
pattern to pull out this "regular" version number instead of the Apple
version number.
2013-05-25 15:42:51 -07:00
Tom Lee
e69e80938b Define _RUST_STAGEN when building rustrt.
This lets us use #ifdefs to determine which stage of the build we happen
to be in, which is useful in the event we need to make changes to rustrt
that are incompatible with the code generated by stage0.

This should help pave the way to completing #6575, which will likely
require changes to type signatures for spawn_fn & glue_fn in rustrt.
2013-05-24 00:30:01 -07:00
Patrick Walton
0c820d4123 libstd: Rename libcore to libstd and libstd to libextra; update makefiles.
This only changes the directory names; it does not change the "real"
metadata names.
2013-05-22 21:57:05 -07:00
Alex Crichton
54f2147e8e Get unit tests for rusti working
* They didn't work before, because the location of the tests caused the
  'sysroot' option to crate lookup to be wrong for finding the correct stage's
  core/std libraries. This moves the compiled tests from the $host/test
  directory into a $host/$stage/test directory. This means that the sysroot will
  be correct and the core/std libraries can actually be found
* The LLVM bindings apparently aren't threadsafe, so we can't run multiple tests
  in parallel.
2013-05-14 14:11:07 -04:00
Young-il Choi
35214d3c6c configure: CFG_ADB for adb added 2013-05-04 00:46:52 +09:00
bors
82a8815b94 auto merge of #5837 : tdaede/rust/fix_file_command, r=catamorphism
Without 'file' it assumes a 32 bit userspace even with a 64 bit kernel, which is incorrect in most cases.
2013-04-11 18:24:59 -07:00
Brian Anderson
62c94d3a38 Pass the value of python to LLVM's configure script. #5835 2013-04-11 11:47:46 -07:00
Thomas Daede
22786d6c5b Add check for 'file' command which is necessary for 32-bit userspace detection. 2013-04-11 09:49:43 +04:00
Seo Sanghyeon
156a307f4b LLVM versions 2013-04-10 14:57:49 +09:00
Brian Anderson
dd088afd43 Stop building clang
Removing it from the tree is an ordeal and there is no official way
to disable clang via LLVM's Makefiles so this edits the Makefile
in llvm/tools after running configure.
2013-03-29 11:23:15 -07:00
bors
bb14ea922b auto merge of #5561 : fabiand/rust/wllvm32, r=catamorphism
Previously the build system only checked for llvm-3.1 - 2.8.
Now also 3.2 and 3.2svn is accepted.

Signed-off-by: Fabian Deutsch <fabian.deutsch@gmx.de>
2013-03-28 11:48:54 -07:00
bors
8896336770 auto merge of #5576 : yichoi/rust/pull-0327, r=brson
minor fix
configure: cleanup - parsing supported target triples
2013-03-27 18:54:53 -07:00
Brian Anderson
32b8c0eaac Fix cpu type normalization in configure script
This condition was added for cygwin support but appears to simply turn
off the normalization of CPU types
2013-03-27 16:25:49 -07:00
Young-il Choi
8fe7fd6dd6 configure: cleanup - parsing supported target triples 2013-03-27 13:35:20 +09:00
Fabian Deutsch
07f8ce7063 configure: Accept llvm-3.2
Previously the build system only checked for llvm-3.1 - 2.8.
Now also 3.2 and 3.2svn is accepted.

Signed-off-by: Fabian Deutsch <fabian.deutsch@gmx.de>
2013-03-26 20:59:13 +01:00
bors
2815328e41 auto merge of #5540 : dbaupp/rust/configure-pandoc-version, r=brson
The version recognition was failing for pandoc version 1.11, thinking the
minor version was 1 rather than 11, and thus not building the documentation.
2013-03-26 03:31:03 -07:00
bors
ff9c943c08 auto merge of #5537 : yichoi/rust/pull-0325, r=brson
In order to mitigate typo of target-triples, error notification of unsupported target triples which defined in mk/platform.mk added.

minor fix for arm-linux-androideabi added.
2013-03-26 01:27:58 -07:00
Huon Wilson
218093d912 configure: simplify pandoc version recognition.
The version recognition was failing for version 1.11, thinking the
minor version was 1 rather than 11.
2013-03-26 00:20:18 +11:00
Young-il Choi
2911fc29d0 configure: error on unsupported target-triples and arm-linux-androideabi fix 2013-03-25 15:36:34 +09:00
Thad Guidry
9aa0cedc84 changed /configure to be compatible with Cygwin and removed annoying --help not a command available message 2013-03-23 02:21:43 +01:00
Luqman Aden
19c104000e configure: accept clang 3.3 when passed --enable-clang 2013-03-22 15:49:55 -04:00
Brian Anderson
81e370285f Merge remote-tracking branch 'brson/cross7'
Conflicts:
	configure
	mk/rt.mk
2013-03-06 23:54:35 -08:00
Brian Anderson
14e5a6e5f7 mk: Cleanup. Minor fixes 2013-03-06 22:37:52 -08:00
Graydon Hoare
ab500d8b8d build fixes 2013-03-04 22:40:59 -08:00
Jyun-Yan You
0ecd9e03ff rt: MIPS32 support 2013-03-03 19:27:01 -08:00
Young-il Choi
7714d52cd9 mk: cleanup - lib and executable suffix handling 2013-03-02 21:25:12 +09:00
Young-il Choi
2102597392 mk: mingw32 flags added 2013-03-01 20:02:29 +09:00
Young-il Choi
26a5dc593c mk: rewrite make files 2013-02-27 14:53:35 +09:00
Brian Anderson
3e6b2cfab5 Fix --disable-optimize-llvm 2013-02-26 17:30:32 -08:00
Brian Anderson
15c0c35352 mk: Split target triples into bulid triple + host triples + target triples
For cross compiling to targets that don't want to build a compiler
2013-02-21 17:51:55 -08:00
bors
21a0d52a85 auto merge of #4876 : brson/rust/debuginfo, r=brson
Update of #4862
2013-02-12 13:30:07 -08:00
Brian Anderson
79e9b6d6a1 mk: Run debuginfo tests by default, but only if gdb is available 2013-02-10 14:19:12 -08:00
Jeff Olson
3a813e29b6 etc: rework of how libuv is integrated into the build
- thanks to work in libuv's upstream, we can call libuv's Makefile directly
with parameters, instead of descending in gyp-uv madness and generating
our own.
2013-02-10 11:51:05 -08:00
Brian Leibig
6bfbdadd3b Add debug info tests 2013-02-09 13:09:19 -05:00
Brian Anderson
0e913a4c90 mk: Parameterize tests.mk to the max 2013-02-05 20:02:46 -08:00
Dimitri Krassovski
2c46bf7e31 Add support for clang 4.2 (as reported by apple clang) r=graydon 2013-02-04 11:28:51 -08:00
Cody Schroeder
e10d720ee1 Remove CFG_LLVM_CONFIG probe from configure script 2013-01-30 00:40:35 -08:00
William Ting
bb51a8442f Add support for Ubuntu named clang packages.
Ubuntu's clang packages have additional information appended to the end of
the version.

- Building Rust v0.5 with clang v3.0-6ubuntu3 fails.
- Building Rust v0.5 and incoming with clang v3.1-5ppa (backported from Debian)
works.

Closes #4441.
2013-01-28 21:54:11 -08:00
kyeongwoon
987f824f23 Support ARM and Android
Conflicts:
	src/libcore/os.rs
	src/librustc/back/link.rs
	src/librustc/driver/driver.rs
	src/librustc/metadata/loader.rs
	src/librustc/middle/trans/base.rs
2013-01-13 16:43:39 -08:00
Jyun-Yan You
37f97ff504 support clang 3.2 2013-01-12 12:02:22 +08:00
Brian Anderson
b43e639bf6 Remove unused bigint from runtime 2013-01-08 13:53:45 -08:00
Jimmy Lu
b17b3d9c12 add option validation to configure, now it will error out on undefined options 2012-11-30 23:20:18 -05:00
Graydon Hoare
4b0e1336b2 configure: force clang when on freebsd. 2012-11-14 15:03:29 -08:00
Brian Anderson
1b0c6665d9 Merge remote-tracking branch 'brson/repl'
Conflicts:
	mk/install.mk
	src/rt/rustrt.def.in
2012-11-04 13:42:39 -08:00
Zack Corr
ea996556b9 rusti: Remove linenoise module, add to rt, remove core::rl 2012-10-30 11:08:36 +10:00
Zack Corr
4912428cb5 rusti: Add linenoise, wrap into core::rl and add rusti REPL tool
Add Brian Leibig to AUTHORS.txt for REPL contributions
2012-10-27 18:03:15 +10:00
Gabriel
f1da4424bf submodule sync won't work in a leaf submodule. 2012-10-22 14:35:31 -07:00
Mahmut Bulut
c05d96c191 Valgrind check disable 2012-10-20 13:57:47 -07:00
Luqman Aden
3d76a75193 configure: check for pandoc version properly. 2012-10-18 20:58:57 -04:00
Graydon Hoare
e0b71dd6b3 configure: note dep on head. 2012-10-18 14:51:20 -07:00
Graydon Hoare
33795bc4d3 configure: fix use of bash-specific here strings (also awk, please no more deps). 2012-10-18 14:51:20 -07:00
Tony Young
2c1ed186fc Check pandoc's version correctly for >=1.10. 2012-10-19 00:30:17 +13:00
Arkaitz Jimenez
cf8bded7aa Enable configure to detect 32 bit systems on 64 bit kernels
These systems run 32 bit binaries so arch needs to be forced
to 32 bits.
2012-10-17 13:42:47 -07:00
Brian Anderson
c56a7e5c25 Reorder the submodule ops in configure 2012-10-05 11:32:28 -07:00
Erick Tryzelaar
2d903abeab configure should recursively sync submodules 2012-10-05 11:32:28 -07:00
auREAX
26ed387d7f Rename configure --enable-pax-marks flag to --enable-pax-flags flag. 2012-10-05 00:08:34 +02:00
auREAX
039110ba22 Fix unnecessary tool detection at non-Linux OSes, fix GRSecurity detection documentation error. 2012-10-05 00:00:55 +02:00
auREAX
0bb437aafa Add GRSecurity compatibility with --enable-pax-marks configure flag; add GRSecurity autodetection code to configure. 2012-10-04 11:56:24 -07:00
Brian Anderson
fd0de8bfd7 doc: Split out task tutorail. Add links to sub-tutorials 2012-09-22 15:34:01 -07:00
Francisco Souza
25bc65b487 configure: support clang 4.1 (provided by XCode 4.5)
Apple keeps calling 4.x its version of clang 3.1.
2012-09-20 11:29:28 -03:00
Brian Anderson
864cca14ee docs: Make supplemental tutorials testable 2012-09-15 18:06:20 -07:00
Zack Corr
d7aa9918ef Add experimental JIT compiler 2012-08-31 16:20:35 -07:00
Francisco Souza
50f2db4a0e configure: fix compatibility issue with Apple clang 4.0
Fix compatibility with Mountain Lion.

Closes #3049.
2012-07-30 15:46:42 -07:00
Zack Corr
de5c15edfb Allow 3.0, 3.1, 3.0svn and 3.1svn for llvm-root 2012-07-24 17:11:13 -07:00
Ben Striegel
6322eda35c Fail to configure without an LLVM-friendly Python
This addresses issue #2720. According to LLVM's documentation, it requires a
version of Python between 2.4 and 2.7. Without the proper version, LLVM fails
to build with cryptic errors. Prior to this commit, the configure script
checked for the `python` command in the environment, but didn't actually check
the version, which can cause problems e.g. on Linux distros where the default
is Python 3. Now the configure script always prefers to select a more specific
version of Python when available, in the order `python2.7` > `python2.6` >
`python2` > `python`, and will always check to ensure that the interpreter's
version is in the correct range.
2012-06-25 20:18:09 -04:00
Brian Anderson
630c084da6 test: Move tests with rustc deps into run-pass-fulldeps
These tests require a lot more to be built before running so are not part of
check-lite
2012-06-01 16:01:56 -07:00
Graydon Hoare
079c3b02a8 Update llvm and integrate clang and compiler-rt. 2012-04-30 17:48:38 -07:00
Brian Anderson
7ba0dce013 build: Fix logic around --enable-local-rust 2012-04-19 15:46:25 -07:00
Evan McClanahan
2c93b1b2df add the option --enable-local-rust to pull rust from your environment
rather than the snapshots.

make sure to get all of the files.

update to add nmatsakis' requested feature of pointing to a
different rustc install root.

usage: --enable-local-rust to enable
--local-rust-root="/path/to/rustc/" to change the path, which defaults to
"/usr/local/"

Tested on OS X and Linux, likely broken on windows.
2012-04-10 20:32:40 -07:00
Haitao Li
b2ec26c152 Print configure script found toolchain version
Closes #2169
2012-04-10 18:29:57 +08:00
Brian Anderson
f452973a7f build: Add --enable-debug configure option
When CFG_ENABLE_DEBUG is defined it will call rustc with -g --cfg=debug
and cc with -DRUST_DEBUG. Otherwise it calls rustc with --cfg=ndebug and cc
with -DRUST_NDEBUG.

I plan to use this for a few things in the runtime.
2012-03-29 19:10:38 -07:00
Graydon Hoare
59336b8acb Move config.stamp touch to configure script. 2012-03-26 18:03:53 -07:00
Graydon Hoare
89dec28a5c Be more careful with CFG_{SRC,BUILD}_DIR ending in slash. 2012-03-26 18:03:53 -07:00
Brian Anderson
57281f52e5 test: Begin running the language ref examples. Mostly xfailed 2012-03-20 18:59:21 -07:00
Brian Anderson
93a082149a build: Switch from naturaldocs to rustdoc 2012-03-09 22:56:53 -08:00
Brian Anderson
a7c4c18667 configure: Cleanup 2012-03-08 12:57:40 -08:00
Daniel Brooks
2049d1f05e only require git if the source looks like it was checked out from git, otherwise don't attempt to manage the submodules 2012-03-08 12:57:40 -08:00
Daniel Brooks
11b403d513 it'll fail if you don't have git, so mark that as required 2012-03-08 12:57:39 -08:00
Brian Anderson
8a32f8efe5 build: Add --enable-helgrind option 2012-03-02 14:08:02 -08:00
Graydon Hoare
cccb0fbf72 Un-silence one too many greps. 2012-02-28 22:39:46 -08:00
Graydon Hoare
8c337026b5 configure: correct submodule code, only reconfigure LLVM when changed. 2012-02-28 22:39:45 -08:00
Graydon Hoare
341f414220 configure: quiet some greps. 2012-02-28 22:39:44 -08:00
Graydon Hoare
1c14d36e72 configure: chmod the right artifact and cp / mv with -f to overwrite. 2012-02-28 22:39:43 -08:00
Graydon Hoare
418c6bcec3 Only modify Makefile and config.mk if they change during configure. 2012-02-28 12:08:26 -08:00
Niko Matsakis
bceea8339a change def's that are always local to use node_id, add --inline opt 2012-02-28 06:31:28 -08:00
Graydon Hoare
5fc2e9e9ab support a fast-make mode that avoids globbing into llvm and libuv 2012-02-10 12:07:11 -08:00
Graydon Hoare
c485301d21 Update libuv. 2012-02-02 17:39:47 -08:00
Graydon Hoare
3a5c75eff9 Tidy up redundant code in configure relating to valopt and triples. 2012-01-30 16:29:13 -08:00
Graydon Hoare
0bf992969f Merge pull request #1669 from graydon/inno-setup
Add Inno Setup installer script rather than NSIS
2012-01-26 18:16:30 -08:00
Jyun-Yan You
5257a5c6c3 let clang build llvm 2012-01-26 11:44:16 -08:00
unknown
fe57a7e582 Add Inno Setup installer script rather than NSIS 2012-01-25 16:02:53 -08:00
Jyun-Yan You
c2bf9b7726 freebsd clang support 2012-01-24 11:48:36 -08:00
Brian Anderson
327c8bc733 build: Run tutorial tests 2012-01-20 19:56:06 -08:00
Graydon Hoare
0d7df062f4 Teach configure to search for multiple commands-with-similar-names. Add NaturalDocs (vs. naturaldocs). 2012-01-19 13:10:14 -08:00
Brian Anderson
17fef6caaf configure: Don't use pandoc < 1.8. Closes #1513 2012-01-18 14:32:37 -08:00
Graydon Hoare
193279daa2 Refactor the doc building rules a bit, sensitize them to the presence or absence of xetex and luatex (for now). 2012-01-18 14:14:42 -08:00
Graydon Hoare
af4e18d980 Improve the node-doc-building logic. 2012-01-17 14:46:51 -08:00
Grahame Bowland
9be247b9b8 build the tutorial if node.js is available 2012-01-17 23:56:20 +08:00
Haitao Li
ef0775fec8 build: Check and set perf --log-fd option
Linux perf tool version 3.2 introduced a new option "--log-fd" defaults
to 0, which leads to error "Failed opening logfd: Illegal argument" when
executing perf tests.

Set logfd to stderr to let perf test work.

Issue #1538
2012-01-17 10:48:46 +08:00
Brian Anderson
6860dcc958 Register snapshots 2012-01-15 13:50:37 -08:00
Brian Anderson
9e40e43e74 build: Build libraries in the bin directory on win32 2012-01-14 13:43:04 -08:00
Reuben Morais
04dd610053 Fix clang option in configure script 2012-01-14 02:41:12 -02:00
Brian Anderson
dcac427795 Revert "build: Build libraries in the bin directory on win32"
This reverts commit 23e0d16b5f.
2012-01-12 20:06:45 -08:00
Brian Anderson
6becf517e3 Revert "Register snapshots"
This reverts commit 17d504e0a9.
2012-01-12 20:06:30 -08:00
Brian Anderson
d95de0dd95 Merge remote-tracking branch 'brson/win32' 2012-01-12 19:25:27 -08:00
Graydon Hoare
fefdb63c4c Begin shift over to using pandoc, markdown and llnextgen for reference manual. Fix man page URL while at it. 2012-01-12 19:10:30 -08:00
Brian Anderson
17d504e0a9 Register snapshots 2012-01-12 17:16:31 -08:00
Brian Anderson
23e0d16b5f build: Build libraries in the bin directory on win32 2012-01-12 13:59:05 -08:00
Brian Anderson
f921e2e3d1 Revert "build: Build libraries in the bin directory on win32"
This reverts commit c00ec5f9c9.
2012-01-11 14:13:11 -08:00
Brian Anderson
c00ec5f9c9 build: Build libraries in the bin directory on win32 2012-01-11 13:57:11 -08:00
Reuben Morais
d593b74469 Allow Clang 3.1 2012-01-08 23:53:26 -02:00
Brian Anderson
90c07f38c1 configure: Disable git submodule management when there is no .git dir
Tarballs for distribution will not have a git repo.
2012-01-07 14:26:54 -08:00
Graydon Hoare
c74d5ce046 Stop configure early if git or subconfigures fail. 2012-01-05 19:00:37 -08:00
User Jyyou
a59c4b1b47 freebsd support 2012-01-01 20:18:55 -08:00
Stefan Plantikow
9c4b3c26f0 Changes to configure (Fix for #1291) 2011-12-14 01:46:08 +01:00
Austin Seipp
638b51488f Disable unused features in the LLVM build.
Issue #1274 - should make the build a wee bit faster.
2011-12-09 19:27:18 -08:00
Graydon Hoare
447414f007 Establish 'core' library separate from 'std'. 2011-12-06 12:13:04 -08:00
Brian Anderson
f1eb7ce013 configure: LLVM 3.0 no longer supported 2011-12-04 15:01:41 -08:00
Niko Matsakis
9acc2bfcad add --host-triple 2011-12-02 19:05:49 -08:00
Niko Matsakis
50e2e07255 use 64-bit as host if on 64-bit CPU 2011-11-30 15:44:35 -08:00
Niko Matsakis
21ffc55e57 update io test to use tmp directory, and update configure to create it 2011-11-29 12:51:09 -08:00
Niko Matsakis
c9061733c6 misc fixes 2011-11-29 12:51:07 -08:00
Niko Matsakis
9c12c7c7f5 basic builds function 2011-11-29 12:51:07 -08:00
Brian Anderson
8d7863fad0 configure: Add --disable-manage-submodules switch
This will keep configure/make from updating submodules, which becomes
very annoying when you are working on LLVM
2011-11-28 18:01:42 -08:00
Brian Anderson
d2199e8716 Various fixes for x86_64 on linux
Configure LLVM correctly, use the right data layout, add the readlink
function back, fix C constants, etc.
2011-11-16 15:24:56 -08:00
Niko Matsakis
895822a61c more consistent naming convention 2011-11-16 15:16:41 -08:00
Niko Matsakis
cda2e07c37 reverse sense of check 2011-11-16 15:16:41 -08:00
Niko Matsakis
1456a23f72 make CFG_OPTIMIZE_CXX an option 2011-11-16 15:16:41 -08:00
Niko Matsakis
b55b8dc8bc add default for --debug-llvm option 2011-11-16 15:16:41 -08:00
Niko Matsakis
d77968dd7c finish up the shim approach 2011-11-16 15:16:40 -08:00
Niko Matsakis
34a5074432 fix handling of target-triples: use a comma to separate hosts 2011-11-08 21:11:47 -08:00
Brian Anderson
81a93eff93 configure: Handle absolute source paths when configuring LLVM 2011-11-05 13:23:11 -07:00
Brian Anderson
c0d220362f configure: Quote the git command 2011-11-05 13:23:11 -07:00
Brian Anderson
2e54a76737 Cleanup configure script 2011-11-05 13:23:11 -07:00
Brian Anderson
8e14d188de configure: Use i686 as the CPU type instead of i386
Seems to prevent the warning about linking bitcode with different triples.
2011-11-05 13:23:11 -07:00
Brian Anderson
4b6585c924 Parameterize the LLVM build over the target triples 2011-11-05 13:23:11 -07:00
Brian Anderson
a4e1a438f6 Cleanup LLVM build rules after rebase onto x64 changes 2011-11-05 13:23:11 -07:00
Brian Anderson
225f50ea96 Begin remove old LLVM configuration code 2011-11-05 13:23:11 -07:00
Brian Anderson
a0ff3db258 LLVM build cleanup 2011-11-05 13:23:11 -07:00
Brian Anderson
e47f410536 Use LLVM directly from the build directory
This will cut out the few seconds it takes to run make install.
2011-11-05 13:23:10 -07:00
Brian Anderson
26bb6716ef Tie the LLVM build into ours 2011-11-05 13:23:10 -07:00
Brian Anderson
bd67c70163 Call LLVM's configure script from ours 2011-11-05 13:23:10 -07:00
Brian Anderson
1a05274738 Add submodule management to configure script 2011-11-05 13:23:10 -07:00
Brian Anderson
7c3616057d configure: change --only-gcc to --enable-clang to make clang opt-in 2011-11-03 12:01:31 -07:00
Brian Anderson
1deaf97002 configure: cleanup 2011-11-02 16:26:22 -07:00
Brian Anderson
4151a3a67f configure: abort early on --help 2011-11-02 16:25:22 -07:00
Elly Jones
098cf43761 configure: support --target-triples and --only-gcc.
Signed-off-by: Elly Jones <elly@leptoquark.net>
2011-11-02 19:19:33 -04:00
Brian Anderson
0003a50e33 Change the error message when no LLVM is found 2011-11-02 16:10:40 -07:00
Elly Jones
234a4e58bd configure: add --llvm-root
Signed-off-by: Elly Jones <elly@leptoquark.net>
2011-11-02 16:10:40 -07:00
Elly Jones
a26554d97b configure: add support for --prefix=<prefix>
Signed-off-by: Elly Jones <elly@leptoquark.net>
2011-11-02 16:10:40 -07:00
Niko Matsakis
2bfa72ea42 virtualize rustllvm construction per target triple 2011-11-02 14:14:20 -07:00
Niko Matsakis
54af489e6f virtualize the runtime per target triple. 2011-11-02 14:14:20 -07:00
Niko Matsakis
93781297bf enable building with different target arch 2011-11-02 14:13:22 -07:00
Niko Matsakis
20946e6970 start going back to an i386 build 2011-11-02 14:13:22 -07:00
Brian Anderson
e0abcf3cd5 Document CFG_ONLY_GCC 2011-10-29 14:14:30 -07:00
Austin Seipp
83413b59a0 Prioritize GCC over Clang if CFG_ONLY_GCC is set.
On OS X I'd rather just be able to use GCC instead of the clang
builds I use/play with.
2011-10-29 14:11:23 -07:00
Brian Anderson
0c6200743c Add std docs to the build process 2011-10-27 14:59:22 -07:00
Brian Anderson
7ae757583a Begin documenting std and add doc generation using naturaldocs
Naturaldocs isn't really that great but it seems easier to get
something working than with doxygen, for which we would need to
convert rust code to something C++ish. We probably want to just
write a rustdoc utility at some point.
2011-10-25 18:01:52 -07:00
Austin Seipp
5ccf372755 Make sure $CFG_LLVM_CONFIG is set to $CFG_LLVM_ROOT/bin/llvm-config
On my machine I have two LLVM builds, one of regular HEAD and one
for Rust in ~/rust-llvm - by default CFG_LLVM_CONFIG is set to
/usr/local/bin/llvm-config which is wrong, because the probe for it
initially happens earlier in configure and succeeds (so putvar is called.)

This causes it to be emitted twice into the Makefile but the second
instance wins.
2011-10-23 01:07:40 -05:00
Brian Anderson
d77996a30f Add LLVM 3.1svn to supported versions 2011-10-15 15:53:18 -07:00
Brian Anderson
6e654564db Lots of build system cleanup and documentation
This splits mk/stageN.mk into host.mk and target.mk and makes
the build rules somewhat simpler - there's no more building from stageN
into stageN+1; instead we always build from stageN(host) to
stageN(target) then promote from stageN(target) to stageN+1(host).

Add a big honkin explaination right at the top of Makefile.in
2011-10-02 00:57:53 -07:00
Brian Anderson
9563c17d78 Have 'make install' do something close to useful
We'll copy the files to the right location. Still need to rpath.

Issue #529
2011-09-30 22:47:40 -07:00
Brian Anderson
821dd6c02c Change the directory for target libs
This pushes them down from stageN/lib/rustc/$(target) to
stageN/lib/rustc/$(target)/lib in order to make room for a target bin dir
2011-09-30 17:19:24 -07:00
Brian Anderson
76e8dd248c Fix configure script to use valgrind again 2011-09-26 16:17:22 -07:00
Erick Tryzelaar
5f066e06b9 Update to libuv commit 3ca382.
This patch changes libuv's gyp build system to
make it's own makefiles. To generate them for rust,
run these commands. They requires python 2.x to
work:

$ mkdir -p src/rt/libuv/build
$ svn co http://gyp.googlecode.com/svn src/rt/libuv/build/gyp
$ ./etc/src/gyp_uv
2011-09-23 16:53:06 -07:00
Graydon Hoare
18c6cc6371 More steps to arch-specific target libs (#474) 2011-09-23 10:50:16 -07:00
Graydon Hoare
13215809a8 Expand our own config.guess-like logic in configure, rather than only asking LLVM. We have to decide some things before we get an LLVM to ask. 2011-09-21 11:24:59 -07:00
Graydon Hoare
68d50b5928 Add target_triple to session::options. Use host triple by default, accept --target on command line. 2011-09-21 08:46:44 -07:00
Graydon Hoare
d5b2d62b20 Add build-system mechanisms for running benchmarks under 'perf'. 2011-09-13 15:06:41 -07:00
Graydon Hoare
7da64ae461 Munge libuv makefiles sufficiently to build out of tree. 2011-08-05 11:57:07 -07:00
Patrick Walton
ad925955d8 build: Don't error out if clang is too old. Instead, build with GCC. 2011-08-05 09:25:27 -07:00
Brian Anderson
0fbb6782bb Add dedicated pretty-printer tests with new pp-exact directive
Add a new src/test/pretty directory to hold just source files for testing the
pretty-printer.

Add a new pp-exact directive. When this directive is followed by a file name
it specifies a file containing the output that the pretty-printer should
generate. When pp-exact is not followed by a filename it says that the file
should pretty-print as written.
2011-08-02 10:39:13 -07:00
Brian Anderson
2573fe7026 The Big Test Suite Overhaul
This replaces the make-based test runner with a set of Rust-based test
runners. I believe that all existing functionality has been
preserved. The primary objective is to dogfood the Rust test
framework.

A few main things happen here:

1) The run-pass/lib-* tests are all moved into src/test/stdtest. This
is a standalone test crate intended for all standard library tests. It
compiles to build/test/stdtest.stageN.

2) rustc now compiles into yet another build artifact, this one a test
runner that runs any tests contained directly in the rustc crate. This
allows much more fine-grained unit testing of the compiler. It
compiles to build/test/rustctest.stageN.

3) There is a new custom test runner crate at src/test/compiletest
that reproduces all the functionality for running the compile-fail,
run-fail, run-pass and bench tests while integrating with Rust's test
framework. It compiles to build/test/compiletest.stageN.

4) The build rules have been completely changed to use the new test
runners, while also being less redundant, following the example of the
recent stageN.mk rewrite.

It adds two new features to the cfail/rfail/rpass/bench tests:

1) Tests can specify multiple 'error-pattern' directives which must be
satisfied in order.

2) Tests can specify a 'compile-flags' directive which will make the
test runner provide additional command line arguments to rustc.

There are some downsides, the primary being that Rust has to be
functioning pretty well just to run _any_ tests, which I imagine will
be the source of some frustration when the entire test suite
breaks. Will also cause some headaches during porting.

Not having individual make rules, each rpass, etc test no longer
remembers between runs whether it completed successfully. As a result,
it's not possible to incrementally fix multiple tests by just running
'make check', fixing a test, and repeating without re-running all the
tests contained in the test runner. Instead you can filter just the
tests you want to run by using the TESTNAME environment variable.

This also dispenses with the ability to run stage0 tests, but they
tended to be broken more often than not anyway.
2011-07-24 15:34:34 -07:00
Graydon Hoare
ad954fcecc Add an NSIS script for building a win32 installer. Closes #522. 2011-07-23 12:27:06 -07:00
Eric Holk
8f2254b8c2 Update configure script to make the task-perf output directory. 2011-07-22 18:45:34 -07:00
Rafael Ávila de Espíndola
88894b6f9c Add support for building with a static libstd for testing static crate support. 2011-07-20 16:02:36 -04:00
Brian Anderson
a38ba01fa4 Move stdtest output files up a directory. Issue #428 2011-07-12 16:54:46 -07:00
Brian Anderson
2f7bc90514 Add a stdtest crate to hold the standard library tests
This will link to std and compile with the --test flag. Eventually the
run-pass/lib* tests will move here.

We could also put the std tests directly into the library and compile both a
library version and a test version, but I think this way will make for faster
builds.

Issue #428
2011-07-06 14:39:40 -07:00
Graydon Hoare
8fc51dfc65 Some work on reviving the mingw-cross build. Not working yet. 2011-06-27 11:53:28 -07:00
Brian Anderson
59c76a371f Move creation of stageN/lib directories to the configure script 2011-06-17 18:36:44 -07:00
Eric Holk
d1857d30fc This is the mega-ucontext commit. It replaces the task switching mechanism with a new one inspired by ucontext. It works under Linux, OS X and Windows, and is Valgrind clean on Linux and OS X (provided the runtime is built with gcc).
This commit also moves yield and join to the standard library, as requested in #42. Join is currently a no-op though.
2011-06-13 18:14:13 -07:00
Graydon Hoare
0a8f9a394b Handle missing git in build env. 2011-06-13 14:45:49 -07:00
Eric Holk
193c1fac4c Enabling valgrind on OSX. It appears to work now. 2011-05-27 16:58:11 -07:00
Erick Tryzelaar
7341055b84 Make sure we're using clang >=3.0svn. 2011-05-20 12:32:44 -07:00
Erick Tryzelaar
134b61a317 Use CFG_LLVM_ROOT's llvm-config if it exists.
On some platform (OS X), llvm needs macros like
__STDC_LIMIT_MACROS defined in order to work, which is
normally defined in llvm-config. This patch modifies
the config to use CFG_LLVM_ROOT's llvm-config if it
exists, which fixes the compile failures.
2011-05-20 12:32:44 -07:00
Graydon Hoare
6a4a85f452 Re-export CFG_LLVM_ROOT to reconfiguring. 2011-05-18 12:00:33 -07:00
Graydon Hoare
6997adf763 Remove rustboot from the repository. 2011-05-13 18:38:28 -07:00
Graydon Hoare
ae784df3ce Add support for 'T' transition snapshots, which are identical to S snapshots except they tell the makefile to stop at stage1. 2011-05-13 17:06:58 -07:00
Patrick Walton
11d22debef build: Search for clang++. Tinderboxes don't have it. 2011-05-09 10:16:56 -07:00
Patrick Walton
269550f673 build: Use clang to compile the runtime if available 2011-05-08 21:10:43 -07:00
Patrick Walton
f8514d95d0 build: uname -m is a lie on 64-bit Darwin. Add a workaround. 2011-05-08 21:10:42 -07:00
Patrick Walton
518e2d249c build: Disable valgrind by default on the Mac. Our suppressions file doesn't even begin to cover the huge stream of errors that dyld generates. 2011-05-05 18:11:40 -07:00
Ralph Giles
0b2cfcaab9 Make ocamlc and optional dependency.
Since moving to a downloadable snapshot for stage0, it's been
possible to complete the build without compiling code written
in ocaml. However, the configure script still required it to
be present.

This commit changes detection failure to a non-fatal condition,
allowing the build to complete on systems without an ocaml
compiler.

An info message is also made conditional.
2011-05-05 11:02:16 -07:00
Patrick Walton
1299e74db3 build: Whitespace police in configure. Puts out burning tinderbox. 2011-05-04 19:14:19 -07:00
Patrick Walton
04f966f0bc build: Build intrinsics.bc 2011-05-04 18:29:08 -07:00
Graydon Hoare
dbe5dc9768 Attempt to shift build to stage0-from-snapshots. 2011-05-03 11:34:44 -07:00
Graydon Hoare
73ba2dd4c7 Shift stages around; stage0/rustc depends on stage0/libstd.so. 2011-04-30 18:44:34 +00:00
Graydon Hoare
cae703c0b1 Add support for --disable-optimize 2011-04-08 15:49:14 -07:00
Graydon Hoare
94731fa458 Add support for --enable-foo and --disable-foo flags to configure, that Makefile.in respects. 2011-03-30 04:45:09 +00:00
Graydon Hoare
10f336055c Auto-reconfigure on Makefile.in or configure change. 2011-03-25 10:29:45 -07:00
Graydon Hoare
9b617dab3c More bandaids for win32. 2011-03-23 16:30:26 -07:00
Patrick Walton
865a2812b6 build: Fix minor typo in "cp" output 2011-03-23 15:55:58 -07:00
Graydon Hoare
e6969929db More miserable win32 configury fixes. Getting closer. 2011-03-23 14:35:28 -07:00
Graydon Hoare
afa6960338 Silly typo. 2011-03-23 13:34:42 -07:00
Graydon Hoare
f740747ea5 Guard texi2pdf on tex probe as well. OSX package systems are real permissive. 2011-03-23 13:33:15 -07:00
Graydon Hoare
9d925436f3 Someday I'll have a talk with the person who thought backslashes were wise in win32. 2011-03-23 13:28:41 -07:00
Graydon Hoare
7ac885ee8c Repair some fallout from pcwalton's last few build changes. 2011-03-21 23:06:42 -07:00
Patrick Walton
35951c92db Support CFG_LLVM_ROOT since CMake-built LLVM has no llvm-config 2011-03-21 18:08:57 -07:00
Graydon Hoare
7941b41b6a Include benchmark dirs in test build dirs. 2011-03-21 14:45:03 -07:00
Graydon Hoare
d9dc070588 Fix typo. 2011-03-20 19:43:36 -07:00
Graydon Hoare
4691a75150 Begin porting rules for testsuite execution. 2011-03-20 01:12:26 -07:00
Graydon Hoare
65f6fcb23a Minor clarification. 2011-03-19 18:34:44 -07:00
Graydon Hoare
3e7ff65201 Truncate long lines in configure output. 2011-03-19 18:34:42 -07:00
Graydon Hoare
50c78313f2 Separate scan for commands used during configure. 2011-03-19 18:34:40 -07:00
Graydon Hoare
b56f4540e9 Probe for python, git, makeinfo and texi2pdf, but not sed. 2011-03-19 18:34:38 -07:00
Graydon Hoare
5d5b63adb9 Probe for llvm libdir as well. 2011-03-19 18:34:37 -07:00
Graydon Hoare
7055c3928c Make the llvmext dir in builddir from configure. 2011-03-18 16:06:45 -07:00
Graydon Hoare
4c2245d842 Yet more painstaking configure/make logic. 2011-03-17 23:52:15 -07:00
Graydon Hoare
3ae9ca444c Move Makefile.in and configure to top level, BOOT_-qualify names, various tweaks. 2011-03-17 14:26:32 -07:00