If a spec file contains a build dependecy with the form
'pkgconfig(<pkg-name>)', automatically add a build dependency on
pkgconfig.
Change-Id: If6b3876658658859d4a5576b9678fb6fdf255d04
Signed-off-by: Kévin THIERRY <kevin.thierry@open.eurogiciel.org>
'''
package_replacement = SPEC2YOCTO_CONFIG.get_substitute()
build_requires_res = []
+ pkgconfig = 0
for line in lines:
build_requires = re.findall( RePattern.buildRequiresPackage, line )
for tmp_res in build_requires:
+ # If a dependency uses pkgconfig, explicitely add pkgconfig as a dependency.
+ if pkgconfig == 0 and 'pkgconfig' in tmp_res:
+ build_requires_res.append(['pkgconfig', '', ''])
+ pkgconfig = 1
for tmp_clean in self.__clean_package_line( tmp_res ):
if len( tmp_clean ) >= 1:
if tmp_clean[0] in package_replacement.keys():