mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-28 11:20:36 +00:00
More log output
This commit is contained in:
parent
be9d1cde34
commit
f1aa37c322
@ -194,6 +194,10 @@ impl TomlManifest {
|
|||||||
// Get targets
|
// Get targets
|
||||||
let targets = normalize(&self.lib, &self.bin);
|
let targets = normalize(&self.lib, &self.bin);
|
||||||
|
|
||||||
|
if targets.is_empty() {
|
||||||
|
debug!("manifest has no build targets; project={}", self.project);
|
||||||
|
}
|
||||||
|
|
||||||
let mut deps = Vec::new();
|
let mut deps = Vec::new();
|
||||||
|
|
||||||
// Collect the deps
|
// Collect the deps
|
||||||
|
@ -26,10 +26,16 @@ use util::{other_error, CargoResult, Wrap};
|
|||||||
pub fn compile(manifest_path: &str) -> CargoResult<()> {
|
pub fn compile(manifest_path: &str) -> CargoResult<()> {
|
||||||
log!(4, "compile; manifest-path={}", manifest_path);
|
log!(4, "compile; manifest-path={}", manifest_path);
|
||||||
|
|
||||||
let root_dep = try!(ops::read_manifest(manifest_path)).to_dependency();
|
let manifest = try!(ops::read_manifest(manifest_path));
|
||||||
|
|
||||||
|
debug!("loaded manifest; manifest={}", manifest);
|
||||||
|
|
||||||
|
let root_dep = manifest.to_dependency();
|
||||||
|
|
||||||
let configs = try!(config::all_configs(os::getcwd()));
|
let configs = try!(config::all_configs(os::getcwd()));
|
||||||
|
|
||||||
|
debug!("loaded config; configs={}", configs);
|
||||||
|
|
||||||
let config_paths = configs.find_equiv(&"paths").map(|v| v.clone()).unwrap_or_else(|| ConfigValue::new());
|
let config_paths = configs.find_equiv(&"paths").map(|v| v.clone()).unwrap_or_else(|| ConfigValue::new());
|
||||||
|
|
||||||
let mut paths: Vec<Path> = match config_paths.get_value() {
|
let mut paths: Vec<Path> = match config_paths.get_value() {
|
||||||
|
@ -10,6 +10,8 @@ use util::result::ProcessError;
|
|||||||
type Args = Vec<String>;
|
type Args = Vec<String>;
|
||||||
|
|
||||||
pub fn compile_packages(pkgs: &core::PackageSet) -> CargoResult<()> {
|
pub fn compile_packages(pkgs: &core::PackageSet) -> CargoResult<()> {
|
||||||
|
debug!("compiling; pkgs={}", pkgs);
|
||||||
|
|
||||||
let mut sorted = match pkgs.sort() {
|
let mut sorted = match pkgs.sort() {
|
||||||
Some(pkgs) => pkgs,
|
Some(pkgs) => pkgs,
|
||||||
None => return Err(other_error("circular dependency detected"))
|
None => return Err(other_error("circular dependency detected"))
|
||||||
@ -29,10 +31,13 @@ pub fn compile_packages(pkgs: &core::PackageSet) -> CargoResult<()> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn compile_pkg<T>(pkg: &core::Package, pkgs: &core::PackageSet, exec: |&ProcessBuilder| -> CargoResult<T>) -> CargoResult<()> {
|
fn compile_pkg<T>(pkg: &core::Package, pkgs: &core::PackageSet, exec: |&ProcessBuilder| -> CargoResult<T>) -> CargoResult<()> {
|
||||||
|
debug!("compiling; pkg={}; targets={}; deps={}", pkg, pkg.get_targets(), pkg.get_dependencies());
|
||||||
// Build up the destination
|
// Build up the destination
|
||||||
// let src = pkg.get_root().join(Path::new(pkg.get_source().path.as_slice()));
|
// let src = pkg.get_root().join(Path::new(pkg.get_source().path.as_slice()));
|
||||||
let target_dir = pkg.get_absolute_target_dir();
|
let target_dir = pkg.get_absolute_target_dir();
|
||||||
|
|
||||||
|
debug!("creating target dir; path={}", target_dir.display());
|
||||||
|
|
||||||
// First ensure that the directory exists
|
// First ensure that the directory exists
|
||||||
try!(mk_target(&target_dir).map_err(|_| other_error("could not create target directory")));
|
try!(mk_target(&target_dir).map_err(|_| other_error("could not create target directory")));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user