(Mac OS)Varnishインストールログ


By: Roban lee ([email protected])
最近会社はvarnishをいじって、午后LINUXの下でソースコードでインストールする时も1つの问题に出会ったPKG_CONFIG_PATH環境変数の問題は、最後にBAIDUを使って
export PKG_CONFIG_PATH =/usr/local/lib/pkg_config_path

片付ける.
 
それからMAC OSの下で少し小さい問題があります
初回export後に端末EXPORTで倒れていないことを発見
その結果、何度も見た結果、実際にインポートされていることがわかりましたが、変数が間違っています.
declare -x PATH="/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin"
declare -x PKG_CONFIG="/usr/local/lib/pkgconfig"
declare -x PWD="/usr/local/installed_source_files/varnish-3.0.3"
declare -x SHELL="/bin/bash"
declare -x SHLVL="1"

ここで導入したのはPKG_PKGではなくCONFIG_CONFIG_PATH
次にCONFIGUREがエラーを報告します.
checking for library containing pthread_create... none required
checking for socket in -lsocket... no
checking for getaddrinfo in -lnsl... no
checking pkg-config is at least version 0.9.0... ./configure: line 13952: /usr/local/lib/pkgconfig: is a directory
no
checking for PCRE... no
configure: error: in `/usr/local/installed_source_files/varnish-3.0.3':
configure: error: The pkg-config script could not be found or is too old.  Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.

Alternatively, you may set the environment variables PCRE_CFLAGS
and PCRE_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.

To get pkg-config, see <http://pkg-config.freedesktop.org/>.

 
結論としてMAC OSにPKG-CONFIGがインストールされていないため、
http://www.linuxfromscratch.org/blfs/view/6.3/general/pkgconfig.html最新のソースをダウンロード
インストール
 
インストール完了後
export PKG_CONFIG=/usr/local/bin/pkg-config

注意はPKG_LINUXではなくCONFIGでのPKG_CONFIG_PATH
インストールして、すべてが終わりました!
^ ^ Roban Lee