1
0
mirror of https://https.git.savannah.gnu.org/git/gnulib.git synced 2026-09-01 02:34:55 +00:00

gnulib-tool.py: Fix libgnu_la_LDFLAGS section in generated Makefile.am.

Reported by Dagobert Michelsen <dam@opencsw.org> in
<https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00086.html>.

* pygnulib/GLModuleSystem.py (getLink): Don't join the parts. Return a
list of strings instead of one string.
* pygnulib/GLEmiter.py (lib_Makefile_am): Adapt accordingly.
* pygnulib/GLImport.py (execute): Likewise.
This commit is contained in:
Tim Rühsen
2019-11-30 13:04:28 +01:00
committed by Bruno Haible
parent 82e12f20ef
commit c2dbe35347
4 changed files with 30 additions and 17 deletions
+4 -6
View File
@@ -791,13 +791,11 @@ Include:|Link:|License:|Maintainer:)'
Return link directive.'''
section = 'Link:'
if 'link' not in self.cache:
if section not in self.content:
result = string()
else: # if section in self.content
parts = list()
if section in self.content:
snippet = self.content.split(section)[-1]
snippet = snippet.replace('\r\n', '\n')
lines = ['%s\n' % line for line in snippet.split('\n')]
parts = list()
for line in lines:
regex = '^(Description|Comment|Status|Notice|Applicability|'
regex += 'Files|Depends-on|configure\\.ac-early|configure\\.ac|'
@@ -808,8 +806,8 @@ Include:|Link:|License:|Maintainer:)'
break
parts += [line]
parts = [part.strip() for part in parts if part.strip()]
result = ''.join(parts)
self.cache['link'] = result
# result = ' '.join(parts)
self.cache['link'] = parts
return(self.cache['link'])
def getLicense(self):