I was having quite the problem with trying to install programs from the command line: Bash would complain I didn't have libraries installed that I most certainly did, and pkg-config was no help, since it apparently wouldn't talk to X11 or Bash at all. Nice. Those are hours of my life I'll never get back.
Thanks to MacOSXHints, I actually have time to use my iBook, instead of just griping at it, or troubleshooting it. I searched for "pkg-config", and, in a comment concerning the installation of GNU's Midnight Commander, I found my salvation.
Here's how to make certain that your computer knows where all your stuff, namely the passkey pkg-config, is:
(Note: I'm assuming you're using the default shell Bash. For other shells, simply substitute that shell's own method for getting a root shell before issuing the modified configure command. Simply adding sudo before this command apparently Does Not Work.)
To install any program requiring the typical configure-make-make-install chain of events, open your terminal of choice (mine's iTerm), get your Bash prompt, then type:
sudo bash
and hit Return. You'll be prompted for your password; enter it as normal, and hit Return.
Careful: Now, your Bash prompt should end in "root" instead of your user name. So don't act up.
Now, enter the following, instead of the usual ./configure to get the ball rolling:
PATH=/usr/local/bin:$PATH ./configure
It's the Bash equivalent of smacking your computer gently in the back of the head. Not only will you not receive that annoying you don't have pkg-config response, but you'll notice that lots of configure's confirmations will be affirmative, where they were negative. Suddendly, my iBook knew I had gawk installed, and Fortran, and...
You get the idea.
I've attached a screenshot, so you can see the joy in action. Hope this helps cut down on someone else's frustration.
If you couldn’t figure out that pkg_config needed to be in your $PATH, then you probably should be using something like macports or fink to manage installing the tools that you need (and even if you can figure it out, it’s not a bad idea to use tools to help you manage your installed software).
Post new comment