[4/4] fenv: Update makedocbookpy for eae68bfc

Message ID 20190812183037.55230-5-jon.turney@dronecode.org.uk
State Accepted
Commit 8922b85d6bb5072441468ea24e764a825b9e1d9f
Headers show
Series
  • fenv doc fixes
Related show

Commit Message

Jon Turney Aug. 12, 2019, 6:30 p.m.
Teach makedocbook how to handle some new things seen in the makedoc markup
since eae68bfc:
- 'link with' lines appearing in SYNOPSIS sections
---
 newlib/doc/makedocbook.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

-- 
2.21.0

Patch

diff --git a/newlib/doc/makedocbook.py b/newlib/doc/makedocbook.py
index cf48c3402..97255345d 100755
--- a/newlib/doc/makedocbook.py
+++ b/newlib/doc/makedocbook.py
@@ -297,6 +297,8 @@  def synopsis(c, t):
 	    # preprocessor # directives, structs, comments in square brackets
 	    funcsynopsisinfo = lxml.etree.SubElement(funcsynopsis, 'funcsynopsisinfo')
 	    funcsynopsisinfo.text = l.strip() + '\n'
+	elif re.match('[Ll]ink with', l):
+	    pass
 	else:
 	    s = s + l
 
@@ -312,7 +314,7 @@  def synopsis(c, t):
 
     if s.strip():
 	print("surplus synopsis '%s'" % s, file=sys.stderr)
-	raise
+	exit(1)
 
 def synopsis_for_prototype(funcsynopsis, s):
     s = s.strip()