chiark / gitweb /
analyze: various cleanups
[elogind.git] / make-man-rules.py
index 9c50c8dec2d0af8bf8736cee9730bd8b4c398231..5415984d88e3f4c88e849d5954c76041a5f21bac 100644 (file)
@@ -21,6 +21,7 @@ from __future__ import print_function
 import xml.etree.ElementTree as tree
 import collections
 import sys
+import os
 
 SECTION = '''\
 MANPAGES += \\
@@ -40,7 +41,7 @@ endif
 
 HEADER = '''\
 # Do not edit. Generated by make-man-rules.py.
-# Regenerate with 'make update-man-list'.
+# Regenerate with 'make all update-man-list'.
 
 '''
 
@@ -96,7 +97,8 @@ def make_makefile(rules, cleanfiles):
 
 if __name__ == '__main__':
     sources = set(sys.argv[1:])
+    basenames = [os.path.basename(source) for source in sources]
     spares = set([source for source in sources
-                  if source + '.in' in sources])
+                  if os.path.basename(source) + '.in' in basenames])
     rules = create_rules(*(sources - spares))
     print(make_makefile(rules, spares), end='')