New issue
Advanced search Search tips

Issue 725388 link

Starred by 0 users

Issue metadata

Status: Unconfirmed
Owner: ----
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

pkg-config.py does not strip pkg-config prefixes properly

Reported by marcin.z...@gmail.com, May 23 2017

Issue description

Chrome Version       : 58.0.3029.110
Category:            : Build system
Source commit        : 273adbb1efcdb09bbbb83a861bca8f07375c5ea7
File                 : build/config/linux/pkg-config.py
Function (lines)     : GetPkgConfigPrefixToStrip 81, 82

See https://chromium.googlesource.com/chromium/src.git/+/273adbb1efcdb09bbbb83a861bca8f07375c5ea7/build/config/linux/pkg-config.py#81

The test in line 81 and return in 82 does not seem to be doing, what the comment asks them to do:

The "prefix[-4]" is indexing, not slicing, so at most it will see '/'. Probably "prefix[-4:]" would fix that.

The "prefix[4:]" will turn '/build/x86-generic/usr' into 'ld/x86-generic/usr', not '/build/x86-generic'; for that "prefix[:-4]" would be probably needed.
 

Comment 1 by hdodda@chromium.org, May 24 2017

Labels: TE-NeedsTriageHelp
Components: Build

Sign in to add a comment