如果正在使用 PHP 不支持的 Web 服务器,或者要在命令 shell 中而不在 Web 页上执行 PHP 脚本,则应将 PHP 作为 CGI 可执行文件进行编译。
前提条件
执行此任务没有前提条件。
确保设置了适用于 SQL Anywhere 的环境。
根据您使用的 shell,从 SQL Anywhere 的安装目录(缺省情况下为 /opt/sqlanywhere16)输入相应的命令。在 Mac OS X 上,缺省目录为 /Applications/SQLAnywhere16/System。
如果正在使用此 shell... | ...使用此命令 | ||
---|---|---|---|
sh, ksh, bash |
|
||
csh, tcsh |
|
将 PHP 作为 CGI 可执行文件进行配置,与 SQL Anywhere PHP 扩展一起使用。
从提取 PHP 文件的目录中运行以下命令:
$ cd PHP-source-directory $ ./configure --with-sqlanywhere |
以下示例适用于 PHP 5.2.11 版。必须将 php-5.2.11 改为为正在使用的 PHP 版本。
$ cd ~/php-5.2.11 $ ./configure --with-sqlanywhere |
配置脚本将尝试确定 SQL Anywhere 安装的版本及位置。如果检查此命令的输出,应看到与以下内容类似的几行:
checking for SQL Anywhere support... yes checking SQL Anywhere install dir... /opt/sqlanywhere16 checking SQL Anywhere version... 16 |
编译可执行文件:
$ make |
安装组件。
$ make install |
![]() |
使用DocCommentXchange讨论此页。
|
版权 © 2013, SAP 股份公司或其关联公司. - SAP Sybase SQL Anywhere 16.0 |