docs: fix up more brew --prefix usage.
The new form used to be slow but both are now fast.
This commit is contained in:
parent
5b80085837
commit
11f94af0f2
@ -60,7 +60,7 @@ which therefore don’t need sudo.
|
||||
|
||||
_This is only recommended if you **don't** use rbenv or RVM._
|
||||
|
||||
Brewed Ruby installs executables to `$(brew --prefix)/opt/ruby/bin`
|
||||
Brewed Ruby installs executables to `$(brew --prefix ruby)/bin`
|
||||
without sudo. You should add this to your path. See the caveats in the
|
||||
`ruby` formula for up-to-date information.
|
||||
|
||||
@ -91,7 +91,7 @@ Just install everything into the Homebrew prefix like this:
|
||||
echo "export GEM_HOME=\"$(brew --prefix)\"" >> ~/.bashrc
|
||||
```
|
||||
|
||||
### It doesn’t work! I get some “permissions” error when I try to install stuff!
|
||||
### It doesn’t work! I get some “permissions” error when I try to install stuff
|
||||
|
||||
_Note that you may not want to do this, since Apple has decided it
|
||||
is not a good default._
|
||||
|
||||
@ -27,13 +27,13 @@ Useful, reliable alternatives exist should you wish to use keg-only tools outsid
|
||||
You can set flags to give configure scripts or Makefiles a nudge in the right direction. An example of flag setting:
|
||||
|
||||
```sh
|
||||
./configure --prefix=/Users/Dave/Downloads CFLAGS="-I$(brew --prefix)/opt/openssl/include" LDFLAGS="-L$(brew --prefix)/opt/openssl/lib"
|
||||
./configure --prefix=/Users/Dave/Downloads CFLAGS="-I$(brew --prefix openssl)/include" LDFLAGS="-L$(brew --prefix openssl)/lib"
|
||||
```
|
||||
|
||||
An example using `pip`:
|
||||
|
||||
```sh
|
||||
CFLAGS="-I$(brew --prefix)/opt/icu4c/include" LDFLAGS="-L$(brew --prefix)/opt/icu4c/lib" pip install pyicu
|
||||
CFLAGS="-I$(brew --prefix icu4c)/include" LDFLAGS="-L$(brew --prefix icu4c)/lib" pip install pyicu
|
||||
```
|
||||
|
||||
### `PATH` modification
|
||||
@ -41,7 +41,7 @@ CFLAGS="-I$(brew --prefix)/opt/icu4c/include" LDFLAGS="-L$(brew --prefix)/opt/ic
|
||||
You can temporarily prepend your `PATH` with the tool’s `bin` directory, such as:
|
||||
|
||||
```sh
|
||||
export PATH="$(brew --prefix)/opt/openssl/bin:${PATH}"
|
||||
export PATH="$(brew --prefix openssl)/bin:${PATH}"
|
||||
```
|
||||
|
||||
This will prepend the directory to your `PATH`, ensuring any build script that searches the `PATH` will find it first.
|
||||
@ -55,7 +55,7 @@ If the tool you are attempting to build is [pkg-config](https://en.wikipedia.org
|
||||
An example of this is:
|
||||
|
||||
```sh
|
||||
export PKG_CONFIG_PATH="$(brew --prefix)/opt/openssl/lib/pkgconfig"
|
||||
export PKG_CONFIG_PATH="$(brew --prefix openssl)/lib/pkgconfig"
|
||||
```
|
||||
|
||||
If you’re curious about the `PKG_CONFIG_PATH` variable, `man pkg-config` goes into more detail.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user