Hi, using variable contents with UTF8, yields the following: pkg-config> ./pkg-config --define-variable=x=ΓΆ pkg-config Invalid byte sequence in conversion input pkg-config> echo $? 1 pkg-config> git rev-parse HEAD 0e847a2201ace5e53e474c52ad5b51e70607980e (current master) Glib is version 2.42.0-2 (Debian sid). In our particular use-case we put a path name into a variable and that path contains UTF8 characters.
Unfortunately, pkg-config doesn't currently handle non-ASCII correctly. You can add a call to 'setlocale(LC_ALL, "")' at the beginning of main to get past this error (g_option validating the input), but later you'll likely not get back the results you expected. In particular, strdup_escape_shell(), the function used by the parser to escape special shell characters, make the assumption that it's operating on an ASCII byte string. This should get fixed, but I don't expect it to happen really soon. Sorry.
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/pkg-config/pkg-config/issues/19.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.