Description of Problem: When having a PKG_CONFIG_PATH ending with a '/', the character before will be stripped also: | $ PKG_CONFIG_PATH='bar/' strace -eopen pkg-config foo | ... | open("ba", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = -1 ENOENT (No such file or directory) scan_dir() in pkg.c seems to be responsible: | if (dirnamelen > 1 && dirname[dirnamelen-1] == G_DIR_SEPARATOR) | { | dirnamelen--; | dirname_copy[dirnamelen-1] = '\0'; | } Since decrementing happened already, the '[dirnamelen-1]' should be replaced by a simple '[dirnamelen]'. I could not find another bugreport-address, so please forward this report to upstream! Version-Release number of selected component (if applicable): pkgconfig-0.9.0-2
Fixed in CVS pkg-config, will be in Red Hat when we upgrade to pkg-config 0.12: 2002-02-12 Havoc Pennington <hp> * pkg.c (scan_dir): use g_strdup, and fix the location where we assign the nul byte, so we don't mangle things for directories that end in '/' - reported by Enrico Scholz
Upgraded.