Opened 18 years ago

Closed 18 years ago

Last modified 10 years ago

#1793 closed defect (wontfix)

PKG_CONFIG_PATH not set in extrascripts.sh

Reported by: jason@… Owned by: blfs-book@…
Priority: high Milestone:
Component: BOOK Version: ~CVS
Severity: normal Keywords:
Cc:

Description (last modified by dnicholson@…)

The command to find extra PKG_CONFIG paths in /etc/profile.d/extrascripts.sh does not function correctly and errors out with a find usage error. I have changed mine to be for directory in $(find / -name pkgconfig -type d 2>/dev/null); do

pathappend $directory PKG_CONFIG_PATH

done for directory in $(find / -name bin -type d 2>/dev/null); do

pathappend $directory

done

Change History (2)

comment:1 by dnicholson@…, 18 years ago

Description: modified (diff)
Resolution: wontfix
Status: newclosed

Couple things. Well, this guy's probably long gone, but...

I don't have problems with the for loop as it is from the book:

for directory in $(find /opt/*/lib/pkgconfig -type d 2>/dev/null); do
        pathappend $directory PKG_CONFIG_PATH
done

There's a separate check for /usr/local/lib/pkgconfig.

Second, the OP's suggestions for revised for loops would be terribly slow.

for directory in $(find / -name pkgconfig -type d 2>/dev/null); do
        pathappend $directory PKG_CONFIG_PATH
done

That loop is going to scan everything in the root directory, first checking if it's named pkgconfig and then testing to see if it's a directory. If the type -d came first, that would help, but it would still have to check the name of every directory in /.

I'm closing this bug. If someone else has had errors with the extrapaths.sh script as used in the book please re-open it.

comment:2 by bdubbs@…, 10 years ago

Milestone: old

Milestone old deleted

Note: See TracTickets for help on using tickets.