changed 'filename' to 'outfile'
This commit is contained in:
parent
d299abbcff
commit
36a41c2789
1 changed files with 4 additions and 6 deletions
10
src/main.rs
10
src/main.rs
|
@ -60,9 +60,9 @@ fn target_generator(name: &str, config_table: &Table) -> String {
|
|||
Value::String(s) => s,
|
||||
_ => panic!("fatal: {name}.linker_libs: invalid type (must be string)"),
|
||||
};
|
||||
let filename = match config_table.get("filename").unwrap_or(&aout) {
|
||||
let outfile = match config_table.get("outfile").unwrap_or(&aout) {
|
||||
Value::String(s) => s,
|
||||
_ => panic!("fatal: {name}.filename: invalid type (must be string)"),
|
||||
_ => panic!("fatal: {name}.outfile: invalid type (must be string)"),
|
||||
};
|
||||
let compiler_linker = Value::String(compiler.to_string());
|
||||
let linker = match config_table.get("linker").unwrap_or(&compiler_linker) {
|
||||
|
@ -114,12 +114,10 @@ build $builddir/{name}/dep: mkdir
|
|||
_ => panic!("fatal: {name}.sources: invalid sources type (must be a list of strings)"),
|
||||
};
|
||||
|
||||
ret.push_str(&format!(
|
||||
"\nbuild $builddir/{name}/{filename}: link_{name} "
|
||||
));
|
||||
ret.push_str(&format!("\nbuild $builddir/{name}/{outfile}: link_{name} "));
|
||||
ret.push_str(&object_list.join(" "));
|
||||
ret.push_str(&format!(
|
||||
" \nbuild {name}: phony $builddir/{name}/{filename}\n"
|
||||
" \nbuild {name}: phony $builddir/{name}/{outfile}\n"
|
||||
));
|
||||
ret.push_str(&format!("# END TARGET {name}\n"));
|
||||
|
||||
|
|
Loading…
Reference in a new issue