aboutsummaryrefslogtreecommitdiff
path: root/yapymake/makefile/__init__.py
diff options
context:
space:
mode:
Diffstat (limited to 'yapymake/makefile/__init__.py')
-rw-r--r--yapymake/makefile/__init__.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/yapymake/makefile/__init__.py b/yapymake/makefile/__init__.py
index cb6fe85..609281e 100644
--- a/yapymake/makefile/__init__.py
+++ b/yapymake/makefile/__init__.py
@@ -161,6 +161,9 @@ class Makefile:
command_token_strings.append(tokenize(next_line.lstrip('\t').rstrip('\n')))
commands = [CommandLine(c) for c in command_token_strings]
+ # apparently we can have no targets? if so, don't do anything
+ if len(targets) == 0:
+ continue
# we don't know yet if it's a target rule or an inference rule
match = re.fullmatch(r'(?P<s2>(\.[^/.]+)?)(?P<s1>\.[^/.]+)', targets[0])
# we don't want to catch special targets, though