aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/makefile/input.rs13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/makefile/input.rs b/src/makefile/input.rs
index 3fe28e7..3707aef 100644
--- a/src/makefile/input.rs
+++ b/src/makefile/input.rs
@@ -265,6 +265,14 @@ impl<'a, 'parent, R: BufRead> MakefileReader<'a, 'parent, R> {
LineType::Macro => self.read_macro(line_tokens, line_number)?,
LineType::Unknown => {
if !line_tokens.is_empty() {
+ #[cfg(feature = "full")]
+ if line_tokens.starts_with("export") {
+ log::error!("export directive not supported yet");
+ continue;
+ } else if line_tokens.starts_with("unexport") {
+ log::error!("unexport directive not supported yet");
+ continue;
+ }
bail!(
"error: line {}: unknown line \"{}\"",
line_number,
@@ -562,7 +570,10 @@ impl<'a, 'parent, R: BufRead> MakefileReader<'a, 'parent, R> {
value.trim_start();
let value = if expand_value {
- TokenString::text(self.expand_macros(&value)?)
+ TokenString::text(
+ self.expand_macros(&value)
+ .wrap_err_with(|| format!("while defining {} on line {}", name, line_number))?,
+ )
} else {
value
};