PHP安装后php-config命令干嘛的
php-config 是一个简单的命令行脚本用于查看所安装的 PHP 配置的信息。
我们在命令行执行 php-config 会输出所有的配置信息
Usage: /usr/local/php/bin/php-config [OPTION]
Options:
--prefix [/usr/local/php]
--includes [-I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib]
--ldflags [ -L/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10..sdk/usr/lib -L/usr/local/lib -L/usr/local/mysql/lib]
--libs [ -lz -lresolv -lmysqlclient -lmcrypt -lpng -lz -lcurl -lm -lxml2 -lz -licucore -lm -lcurl -lxml2 -lz -licucore -lm -lmysqlclient -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm ]
--extension-dir [/usr/local/php/lib/php/extensions/no-debug-non-zts-]
--include-dir [/usr/local/php/include/php]
--man-dir [/usr/local/php/php/man]
--php-binary [/usr/local/php/bin/php]
--php-sapis [ cli fpm cgi]
--configure-options [--prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-curl --enable-fpm --with-mcrypt --with-mhash --with-gd -enable-zip --enable-fastCGI --without-iconv]
--version [5.6.]
--vernum []
其实php-config只是一个脚本而已
我们先查一下php-config在哪,然后打开文件研究一番
where php-config localhost% where php-config /usr/local/php/bin/php-config /usr/bin/php-config localhost% vim /usr/local/php/bin/php-config
脚本内容如下
#! /bin/sh SED="/usr/bin/sed"
prefix="/usr"
datarootdir="/usr/php"
exec_prefix="${prefix}"
version="5.5.30"
vernum=""
include_dir="${prefix}/include/php"
includes="-I$include_dir -I$include_dir/main -I$include_dir/TSRM -I$include_dir/Zend -I$include_dir/ext -I$include_dir/ext/date/lib"
ldflags=" -L/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.Internal.sdk/usr/lib "
libs="-lresolv -lcrypto -lssl -lcrypto -lz -lexslt -ltidy -lresolv -ledit -lncurses -lldap -llber -liconv -liconv -lpng -lz -ljpeg -lcrypto -lssl -lcrypto -lcurl -lbz2 -lz -lpcre -lcrypto -lssl -lcrypto -lm -lxml2 -lz -licucore -lm -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lcurl -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lnetsnmp -lcrypto -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lxml2 -lz -licucore -lm -lxml2 -lxslt "
extension_dir='/usr/lib/php/extensions/no-debug-non-zts-20121212'
man_dir=`eval echo /usr/share/man`
program_prefix=""
program_suffix=""
exe_extension=""
php_cli_binary=NONE
php_cgi_binary=NONE
configure_options=" '--prefix=/usr' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--disable-dependency-tracking' '--sysconfdir=/private/etc' '--with-libdir=lib' '--enable-cli' '--with-iconv=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.Internal.sdk/usr' '--with-config-file-path=/etc' '--with-config-file-scan-dir=/Library/Server/Web/Config/php' '--with-libxml-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.Internal.sdk/usr' '--with-openssl=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.Internal.sdk/usr/local"
php_sapis=" apache2handler cli fpm" # Set php_cli_binary and php_cgi_binary if available
for sapi in $php_sapis; do
case $sapi in
cli)
php_cli_binary="${exec_prefix}/bin/${program_prefix}php${program_suffix}${exe_extension}"
;;
cgi)
php_cgi_binary="${exec_prefix}/bin/${program_prefix}php-cgi${program_suffix}${exe_extension}"
;;
esac
done # Determine which (if any) php binary is available
if test "$php_cli_binary" != "NONE"; then
php_binary="$php_cli_binary"
else
php_binary="$php_cgi_binary"
fi # Remove quotes
configure_options=`echo $configure_options | $SED -e "s#'##g"` case "$1" in
--prefix)
echo $prefix;;
--includes)
echo $includes;;
--ldflags)
echo $ldflags;;
--libs)
echo $libs;;
--extension-dir)
echo $extension_dir;;
--include-dir)
echo $include_dir;;
--php-binary)
echo $php_binary;;
--php-sapis)
echo $php_sapis;;
--configure-options)
echo $configure_options;;
--man-dir)
echo $man_dir;;
--version)
echo $version;;
--vernum)
echo $vernum;;
*)
cat << EOF
Usage: $ [OPTION]
Options:
--prefix [$prefix]
--includes [$includes]
--ldflags [$ldflags]
--libs [$libs]
--extension-dir [$extension_dir]
--include-dir [$include_dir]
--man-dir [$man_dir]
--php-binary [$php_binary]
--php-sapis [$php_sapis]
--configure-options [$configure_options]
--version [$version]
--vernum [$vernum]
EOF
exit ;;
esac exit
PHP安装后php-config命令干嘛的的更多相关文章
- fedora安装后,yum命令不能使用,Cannot retrieve metalink for repository: fedora. Please verify its path and try again 解决方法
fedora安装后,yum命令不能使用,Cannot retrieve metalink for repository: fedora. Please verify its path and try ...
- git安装后配置--config
安装git后需要配置一下环境,每台计算机上只需要配置一次,程序升级时会保留配置信息. 你可以在任何时候再次通过运行命令来修改它们. 通过git config命令来配置环境变量,这些变量存储在三个不同的 ...
- Python安装后在CMD命令行下出现“应用程序无法启动.............”问题
问题存在之一:系统是刚刚重做的精简版服务器系统(阉割版) AN就是在阿里云上刚开的Windows Server 2008 系统上碰到的 吓尿了都 症状: 正常安装python环 ...
- CentOS7 mini安装后没有ifconfig命令的解决办法
在CentOS 最小化mini安装后,没有ifconfig命令,此时网卡也没有启动,所以无法yum安装net-tools. 下面三步解决此问题: 1 查看网卡名称 ip addr 2 启动网卡 ifu ...
- CentOs7 minimal安装后没有ifconfig命令解决方法
没有ifconfig命令目前我了解两个原因: 1./sbin/ifconfig 可以执行,但是ifconfig无法执行.这个解决的时候只需要将/sbin 添加到PATH下就可以了. 2.系统未安装if ...
- nvm-windows 安装后,node 命令报错
下载地址: https://github.com/coreybutler/nvm-windows/releases 我是点下面这个直接安装的: 配置文件,我都是习惯在软件目录下建个 files 文件夹 ...
- CentOS 7 安装后没有ifconfig命令
/bin,/sbin,/usr/bin,/usr/sbin下面都没有ifconfig命令. 执行命令 yum install net-tools 即可.
- Fedora最小化安装后没有ifconfig命令
百度了很久,都说添加export PATH=$PATH:/sbin,结果我用whereis 查询了,根本没有这个命令.后来直接yum search ifconfig,查找到原来是net-tools包. ...
- FreeBSD安装后使用su命令显示sorry的解决办法
FreeBSD中,可以使用su命令成为root用户,但FreeBSD对执行su命令的用户进行了更严格的限制,能使用su命令的用户必须属于wheel组(root的基本属组,组ID为0),否则就不能通过 ...
- Redis 配置 CONFIG 命令
redis.conf 文件在 安装目录下 CONFIG 命令查看或设置配置项 先登陆 src/redis-cli -a -a 后面是密码,默认为空,没有密码直接登陆 src/redis-cli 1.查 ...
随机推荐
- SVD分解技术数学解释
SVD分解 SVD分解是LSA的数学基础,本文是我的LSA学习笔记的一部分,之所以单独拿出来,是因为SVD可以说是LSA的基础,要理解LSA必须了解SVD,因此将LSA笔记的SVD一节单独作为一篇文章 ...
- line-height:2、line-height:2em、line-height:200%的区别
文章来源: http://www.zhihu.com/question/20394889 总结: 1.line-height:2em.line-height:200% 根据父元素的字体大小计算行高 ...
- HDU 1312 Red and Black (DFS)
Problem Description There is a rectangular room, covered with square tiles. Each tile is colored eit ...
- JS 点击复制Copy
1.实现点击按钮,复制文本框中的的内容 1 <script type="text/javascript"> 2 function copyUrl2() 3 { 4 va ...
- POJ 2505 A multiplication game(找规律博弈/贪心)
题目链接 #include<iostream> #include<cstdio> using namespace std; typedef long long ll; int ...
- AnimatorController动画遮罩
游戏中,我们的人物在某些时候,可能在一个时间点在做两件事,这样就需要同时播放两个动画,但我们肯定不能简单将其叠加,比如移动着开枪.攻击.挥手等等,那么在Unity中我们应该怎样实现这样的功能呢?且听我 ...
- Django的使用
Django使用介绍 1.MTV Django中的MTV分别表示models.templates和views. models文件主要定义数据库的连接. templates文件可以放一些html的模版. ...
- 4.编写Java应用程序。首先,定义一个时钟类——Clock,它包括三个int型 成员变量分别表示时、分、秒,一个构造方法用于对三个成员变量(时、分、秒) 进行初始化,还有一个成员方法show()用于显示时钟对象的时间。其次,再定义 一个主类——TestClass,在主类的main方法中创建多个时钟类的对象,使用这 些对象调用方法show()来显示时钟的时间。
Clock package com.hanqi.test; public class Clock { int hour,minute,second; Clock(int h,int m,int s) ...
- Ajax.BeginForm 异步上传附件 替代方案
一:问题描述 含有文件信息表单内容,想通过异步上传到服务器,但是使用Ajax.BeginForm上传时,后台无法获取文件信息 二:解决方案 通过 $.ajaxFileUpload 可以实现文件及 ...
- 移动端touch事件影响click事件的相关解决方法
preventDefault()的方法,阻止事件的默认行为. 在移动端,手指点击一个元素,会经过:touchstart --> touchmove -> touchend -->cl ...