1

I have just built PHP from source. Usually when I do this, I don't have any problems just running php from anywhere. This time however, the console returns 'command not found'. What do I need to correct for this to work properly?

Ben Dauphinee
  • 203
  • 3
  • 10

1 Answers1

3

As you suspected by your subject, the PATH variable needs to be properly updated.

If you are using bash as your shell, this can be done in your personal ~/.bashrc file, or in the global /etc/profile or /etc/bashrc files for all users. You would add a line like this in either case:

PATH=$PATH:/path/to/php/directory/
Kyle Smith
  • 9,683
  • 1
  • 31
  • 32