about summary refs log tree commit diff
path: root/src/librustpkg/rustpkg.rc
AgeCommit message (Collapse)AuthorLines
2013-06-25Rename all files with the 'rc' extensionAlex Crichton-474/+0
2013-06-14rustpkg: Write more automated testsTim Chevalier-11/+30
Automate more tests described in the commands.txt file, and add infrastructure for running them. Right now, tests shell out to call rustpkg. This is not ideal.
2013-06-14add IteratorUtil to the preludeDaniel Micay-1/+0
2013-06-13Use @str instead of @~str in libsyntax and librustc. Fixes #5048.Huon Wilson-2/+2
This almost removes the StringRef wrapper, since all strings are Equiv-alent now. Removes a lot of `/* bad */ copy *`'s, and converts several things to be &'static str (the lint table and the intrinsics table). There are many instances of .to_managed(), unfortunately.
2013-06-11option: remove redundant old_iter implsDaniel Micay-2/+2
2013-06-10std: replace str::each_split* with an iteratorHuon Wilson-4/+3
2013-06-09rustpkg: Accept package IDs like github.com/foo/bar#0.3Tim Chevalier-259/+9
If the package ID is of the form s#v, where v is a valid version string, fetch tag v of that package.
2013-06-08rustpkg: Extract version number from git, as per #5684Tim Chevalier-0/+2
For now, the test I added just checks that PkgId::new parses the version number out of a git repo's tags list, where relevant.
2013-06-06Clean up a handful of build warnings.Michael Sullivan-3/+3
2013-06-01rustc/rusti/rustpkg: Infer packages from `extern mod` directivesTim Chevalier-51/+62
This commit won't be quite as useful until I implement RUST_PATH and until we change `extern mod` to take a general string instead of an identifier (#5682 and #6407). With that said, now if you're using rustpkg and a program contains: extern mod foo; rustpkg will attempt to search for `foo`, so that you don't have to provide a -L directory explicitly. In addition, rustpkg will actually try to build and install `foo`, unless it's already installed (specifically, I tested that `extern mod extra;` would not cause it to try to find source for `extra` and compile it again). This is as per #5681. Incidentally, I changed some driver code to infer the link name from the crate link_meta attributes. If that change isn't ok, say something. Also, I changed the addl_lib_search_paths field in the session options to be an @mut ~[Path] so that it can be modified after expansion but before later phases.
2013-06-01Remove all uses of `pub impl`. rs=stylePatrick Walton-7/+6
2013-05-29librustc: Stop reexporting the standard modules from prelude.Patrick Walton-2/+11
2013-05-28librustc: drop AST before running LLVM, frees 400mb on a librustc buildGraydon Hoare-1/+1
2013-05-27Refactor core::run in order to address many of the issuesgareth-4/+4
mentioned in #2625. This change makes the module more oriented around Process values instead of having to deal with process ids directly. Apart from issues mentioned in #2625, other changes include: - Changing the naming to be more consistent - Process/process is now used instead of a mixture of Program/program and Process/process. - More docs/tests. Some io/scheduler related issues remain (mentioned in #2625).
2013-05-22libextra: Rename the actual metadata names of libcore to libstd and libstd ↵Patrick Walton-1/+6
to libextra
2013-05-22librustc: Disallow `use` from reaching into impls or traits.Patrick Walton-9/+12
This can perhaps be restored in the future. For now this is a precursor to making typedefs work as expected.
2013-05-21Remove unnecessary allocations flagged by lint from rustpkgSeo Sanghyeon-13/+13
2013-05-18auto merge of #6603 : thestinger/rust/whitespace, r=thestingerbors-1/+0
2013-05-19reduce the usage of explicit version markersDaniel Micay-3/+3
2013-05-18minor automated whitespace fixesDaniel Micay-1/+0
2013-05-14rustpkg: Tests for well-formed and ill-formed package IDs...Tim Chevalier-72/+16
...and cleanup, making how we handle version numbers more rational (specifically, not passing in a versioned name to rustc with the -o flag), and removing unused code.
2013-05-14rustpkg: Implement URL-like package IDsTim Chevalier-106/+54
This patch implements package IDs like github.com/catamorphism/test-pkg. To support such package IDs, I changed the PkgId struct to contain a LocalPath and a RemotePath field, where the RemotePath reflects the actual URL and the LocalPath reflects the file name of the cached copy. Right now, the only difference is that the local path doesn't contain dashes, but this will change when we implement #6407. Also, PkgIds now have a short_name field -- though the short name can be derived from the LocalPath, I thought it was cleaner not to call option::get() wantonly.
2013-05-14Fix test fallout from removing vecs_implicitly_copyableAlex Crichton-0/+1
2013-05-14rustpkg: Remove #[allow(vecs_implicitly_copyable)]Alex Crichton-42/+40
2013-05-14Fix cosmetics for fail!() callsMarvin Löbel-2/+1
2013-05-14Use static string with fail!() and remove fail!(fmt!())Björn Steinbrink-10/+10
fail!() used to require owned strings but can handle static strings now. Also, it can pass its arguments to fmt!() on its own, no need for the caller to call fmt!() itself.
2013-05-12Don't create subprocesses for the `rust` commandAlex Crichton-1/+2
Instead link against the built libraries and directly invoke those.
2013-05-03rustpkg: Handle sysroot more correctlyTim Chevalier-12/+17
In rustpkg, pass around sysroot; in rustpkg tests, set the sysroot manually so that tests can find libcore and such. With bonus metadata::filesearch refactoring to avoid copies.
2013-05-03rustpkg: Implement install commandTim Chevalier-51/+81
The install command should work now, though it only installs in-place (anything else has to wait until I implement RUST_PATH). Also including: core: Add remove_directory_recursive, change copy_file Make copy_file preserve permissions, and add a remove_directory_recursive function.
2013-04-27only use #[no_core] in libcoreDaniel Micay-4/+0
2013-04-24rustpkg: Preliminary work on install commandTim Chevalier-29/+21
Mostly just tests (that are ignored); install command is still stubbed out.
2013-04-24rustpkg: Make path searching work as described in the rustpkg docTim Chevalier-96/+62
rustpkg now searches for package directories in ./src rather than in . . I also added a rudimentary RUST_PATH that's currently hard-wired to the current directory. rustpkg now uses src/, lib/, and build/ directories as described in the manual. Most of the existing test scenarios build now; the README file (in a separate commit) explains which ones.
2013-04-19Assorted fixes from de-modeing rustc/syntax (rusti, rustdoc, fuzzer, rustpkg)Alex Crichton-4/+4
2013-04-18auto merge of #5914 : catamorphism/rust/copy-cops, r=catamorphismbors-2/+2
2013-04-18rustc: Anti-copy policeTim Chevalier-2/+2
In this case, some copies are still necessary to convert from a mutable to an immutable @-box. It's still an improvement, I hope.
2013-04-18TidyTim Chevalier-1/+1
2013-04-17rustpkg: Don't execute the standard build logic if there is a pkg.rsTim Chevalier-4/+5
2013-04-17rustpkg: Implement clean; replace boolean result flags with fail!()Tim Chevalier-156/+61
1. Implemented the `clean` command 2. The methods implementing rustpkg commands all returned `bool`. Since most of not all of the error situations seem unrecoverable, I changed the methods to return unit (and also stubbed out several more methods that were assuming a package script existed, to be re-implemented in the future)
2013-04-17rustpkg: Fail when crate inference fails; inject link attributesTim Chevalier-54/+38
1. Fail when there's no package script and no crates named main.rs, lib.rs, bench.rs, or test.rs. 2. Inject the crate link_meta "name" and "vers" attributes, so that the output file gets named correctly in the library case. 3. Normalize '-' to '_' in package names.
2013-04-15auto merge of #5861 : catamorphism/rust/rustpkg, r=catamorphismbors-46/+5
r? @graydon Pulled out tests into their own modules inside the files they test, as per the draft style guidelines. Started a new module, path_util, for utility functions to do with paths and directories. Changed default_dest_dir to use a condition and return Path instead of Option<Path>.
2013-04-12rustpkg: Factor out tests; use a condition instead of returning an optionTim Chevalier-46/+5
Pulled out tests into their own modules inside the files they test, as per the draft style guidelines. Started a new module, path_util, for utility functions to do with paths and directories. Changed default_dest_dir to use a condition and return Path instead of Option<Path>.
2013-04-12auto merge of #5847 : catamorphism/rust/rustpkg, r=catamorphismbors-545/+450
r? @graydon This is preliminary work on bringing rustpkg up to conformance with #5679 and related issues. This change makes rustpkg infer a package ID from its containing directory, instead of requiring name and vers attributes in the code. Many aspects of it are incomplete; I've only tested one package (see README.txt) and one command, "build". So far it only works for local packages. I also removed code for several of the package commands other than "build", replacing them with stubs that fail, since they used package IDs in ways that didn't jibe well with the new scheme. I will re-implement the commands one at a time.
2013-04-12TidyTim Chevalier-8/+5
2013-04-11rustpkg: Use pkg IDs, remove old code for now that required packages to ↵Tim Chevalier-593/+343
declare IDs explicitly This is preliminary work on bringing rustpkg up to conformance with #5679 and related issues. This change makes rustpkg infer a package ID from its containing directory, instead of requiring name and vers attributes in the code. Many aspects of it are incomplete; I've only tested one package (see README.txt) and one command, "build". So far it only works for local packages. I also removed code for several of the package commands other than "build", replacing them with stubs that fail, since they used package IDs in ways that didn't jibe well with the new scheme. I will re-implement the commands one at a time.
2013-04-10Bump version to 0.7-preBrian Anderson-5/+5
2013-04-09Bump version to 0.7-preBrian Anderson-5/+5
2013-04-05checkpointGraydon Hoare-16/+174
2013-04-03rename Linear{Map,Set} => Hash{Map,Set}Daniel Micay-5/+5
2013-04-03hashmap: rm linear namespaceDaniel Micay-1/+1
2013-03-29Add AbiSet and integrate it into the AST.Niko Matsakis-1/+1
I believe this patch incorporates all expected syntax changes from extern function reform (#3678). You can now write things like: extern "<abi>" fn foo(s: S) -> T { ... } extern "<abi>" mod { ... } extern "<abi>" fn(S) -> T The ABI for foreign functions is taken from this syntax (rather than from an annotation). We support the full ABI specification I described on the mailing list. The correct ABI is chosen based on the target architecture. Calls by pointer to C functions are not yet supported, and the Rust type of crust fns is still *u8.