diff options
author | Melody Horn <melody@boringcactus.com> | 2021-04-04 11:57:10 -0600 |
---|---|---|
committer | Melody Horn <melody@boringcactus.com> | 2021-04-04 11:57:10 -0600 |
commit | 680fca264f442bc91bf877115adc5010bc142229 (patch) | |
tree | 0b39ea8eccb1380170cb752461f80b00ea2cd406 | |
parent | c9cc973f6ea1184b962bc11420f4cd9d9a194c6e (diff) | |
download | makers-680fca264f442bc91bf877115adc5010bc142229.tar.gz makers-680fca264f442bc91bf877115adc5010bc142229.zip |
fix $< so it's only one file
-rw-r--r-- | src/makefile/mod.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/makefile/mod.rs b/src/makefile/mod.rs index f62249b..e13ecff 100644 --- a/src/makefile/mod.rs +++ b/src/makefile/mod.rs @@ -266,7 +266,8 @@ impl<'a> Makefile<'a> { // filename whose existence allowed the inference rule to be // chosen for the target. In the .DEFAULT rule, the $< macro // shall evaluate to the current target name. - target.prerequisites.clone() + // TODO make that actually be the case (rn exists_but_inferring_anyway might fuck that up) + vec![target.prerequisites.get(0).cloned().unwrap_or_default()] } else if name.starts_with('*') { // The $* macro shall evaluate to the current target name with // its suffix deleted. |