2
1

0002-SConstruct-Do-not-crash-when-not-building-python-man-pages.patch 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. From 02d21faebec245e1526449fb54e7078914d75db7 Mon Sep 17 00:00:00 2001
  2. From: "Gary E. Miller" <gem@rellim.com>
  3. Date: Thu, 1 Nov 2018 15:49:01 -0700
  4. Subject: SConstruct: Do not crash when not building python man pages.
  5. Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
  6. [Retrieved from:
  7. https://git.savannah.gnu.org/cgit/gpsd.git/commit/?id=02d21faebec245e1526449fb54e7078914d75db7]
  8. ---
  9. SConstruct | 13 +++++++++----
  10. 1 file changed, 9 insertions(+), 4 deletions(-)
  11. diff --git a/SConstruct b/SConstruct
  12. index 0fc3614..0226cd2 100644
  13. --- a/SConstruct
  14. +++ b/SConstruct
  15. @@ -1751,14 +1751,19 @@ if tiocmiwait:
  16. "ppscheck.8": "ppscheck.xml",
  17. })
  18. -all_manpages = list(base_manpages.keys()) + list(python_manpages.keys())
  19. +all_manpages = list(base_manpages.keys())
  20. +if python_manpages:
  21. + all_manpages += list(python_manpages.keys())
  22. man_env = env.Clone()
  23. if man_env.GetOption('silent'):
  24. man_env['SPAWN'] = filtered_spawn # Suppress stderr chatter
  25. manpage_targets = []
  26. if manbuilder:
  27. - items = list(base_manpages.items()) + list(python_manpages.items())
  28. + items = list(base_manpages.items())
  29. + if python_manpages:
  30. + items += list(python_manpages.items())
  31. +
  32. for (man, xml) in items:
  33. manpage_targets.append(man_env.Man(source=xml, target=man))
  34. @@ -1907,7 +1912,7 @@ if qt_env:
  35. maninstall = []
  36. -for manpage in list(base_manpages.keys()) + list(python_manpages.keys()):
  37. +for manpage in all_manpages:
  38. if not manbuilder and not os.path.exists(manpage):
  39. continue
  40. section = manpage.split(".")[1]
  41. @@ -2517,7 +2522,7 @@ if os.path.exists("gpsd.c") and os.path.exists(".gitignore"):
  42. if ".gitignore" in distfiles:
  43. distfiles.remove(".gitignore")
  44. distfiles += generated_sources
  45. - distfiles += list(base_manpages.keys()) + list(python_manpages.keys())
  46. + distfiles += all_manpages
  47. if "packaging/rpm/gpsd.spec" not in distfiles:
  48. distfiles.append("packaging/rpm/gpsd.spec")
  49. --
  50. cgit v1.0-41-gc330