Skip to content

Commit

Permalink
Update install/errorfunc
Browse files Browse the repository at this point in the history
  • Loading branch information
mowangjuanzi committed Dec 3, 2024
1 parent da9f47d commit cca949e
Show file tree
Hide file tree
Showing 4 changed files with 365 additions and 284 deletions.
68 changes: 34 additions & 34 deletions install/pecl.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<!-- EN-Revision: 9e2d8231b5d8a3795b365c6770fab288e59e6249 Maintainer: dallas Status: ready -->
<!-- EN-Revision: 111535af69b070980330fe83ed2eab5ca759c73d Maintainer: dallas Status: ready -->
<!-- CREDITS: mowangjuanzi -->
<chapter xml:id="install.pecl" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>PECL 扩展安装</title>
Expand Down Expand Up @@ -80,11 +80,11 @@
<link xlink:href="&url.php.svn;pecl/">&url.php.svn;pecl/</link>。要直接从
<acronym>SVN</acronym> 中下载,用以下命令:
</simpara>
<para>
<screen>
<screen>
<![CDATA[
$ svn checkout https://svn.php.net/repository/pecl/extname/trunk extname
</screen>
</para>
]]>
</screen>
</listitem>
<listitem>
<simpara>
Expand Down Expand Up @@ -274,11 +274,11 @@ Loaded Configuration File C:\Program Files\PHP\8.2\php.ini
PECL 使建立共享 PHP 扩展库更容易。用
<link xlink:href="&url.php.pear.cli;">pecl 命令</link>这样做:
</simpara>
<para>
<screen>
$ pecl install extname
</screen>
</para>
<screen>
<![CDATA[
$ pecl install extname
]]>
</screen>
<simpara>
这将下载 <emphasis>extname</emphasis> 的源代码,编译之,并将
<filename>extname.so</filename> 安装到 <link
Expand All @@ -291,19 +291,19 @@ Loaded Configuration File C:\Program Files\PHP\8.2\php.ini
<literal>beta</literal> 状态的包。如果没有 <literal>stable</literal>
包可用,也可以用以下命令安装一个 <literal>beta</literal> 包:
</simpara>
<para>
<screen>
$ pecl install extname-beta
</screen>
</para>
<screen>
<![CDATA[
$ pecl install extname-beta
]]>
</screen>
<para>
也可以用此命令安装一个指定的版本:
</para>
<para>
<screen>
$ pecl install extname-0.1
</screen>
</para>
<screen>
<![CDATA[
$ pecl install extname-0.1
]]>
</screen>
<note>
<para>
&php.ini; 中启用扩展之后,需要重新启动 web 服务以使更改生效。
Expand Down Expand Up @@ -475,25 +475,25 @@ $ mv extname-x.x.x extname
<simpara>
这将产生以下目录:
</simpara>
<para>
<screen>
/path/to/php/src/dir/ext/extname
</screen>
</para>
<screen>
<![CDATA[
/path/to/php/src/dir/ext/extname
]]>
</screen>
<simpara>
此时 PHP 需要强制重新生成配置脚本,然后正常编译 PHP:
</simpara>
<para>
<screen>
<screen>
<![CDATA[
$ cd /path/to/php/src/dir
$ rm configure
$ ./buildconf --force
$ ./configure --help
$ ./configure --with-extname --enable-someotherext --with-foobar
$ make
$ make install
</screen>
</para>
]]>
</screen>
<note>
<simpara>
要运行 <command>buildconf</command> 脚本,需要 <command>autoconf</command>
Expand All @@ -507,11 +507,11 @@ $ make install
取决于扩展库。通常不需要外部库文件的扩展库使用
<option role="configure">--enable</option>。当然,在 <command>buildconf</command> 之后运行:
</simpara>
<para>
<screen>
$ ./configure --help | grep extname
</screen>
</para>
<screen>
<![CDATA[
$ ./configure --help | grep extname
]]>
</screen>
</sect1>
</chapter>

Expand Down
35 changes: 12 additions & 23 deletions reference/curl/constants_curl_setopt.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4142,10 +4142,7 @@
</term>
<listitem>
<para>
Accepts a bitmask setting WebSocket behavior options.
The only available option is <constant>CURLWS_RAW_MODE</constant>.
Defaults to <literal>0</literal>.
Available as of PHP 8.3.0 and cURL 7.86.0.
接受位掩码设置 WebSocket 行为选项。唯一可用的选项是 <constant>CURLWS_RAW_MODE</constant>。默认为 <literal>0</literal>。自 PHP 8.3.0 和 cURL 7.86.0 起可用。
</para>
</listitem>
</varlistentry>
Expand All @@ -4156,7 +4153,7 @@
</term>
<listitem>
<para>
A <type>callable</type> with the following signature:
具有以下签名的 <type>callable</type>
<methodsynopsis>
<type>int</type><methodname><replaceable>callback</replaceable></methodname>
<methodparam><type>resource</type><parameter>curlHandle</parameter></methodparam>
Expand All @@ -4170,46 +4167,44 @@
<term><parameter>curlHandle</parameter></term>
<listitem>
<simpara>
The cURL handle.
cURL 句柄。
</simpara>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>bytesToDownload</parameter></term>
<listitem>
<simpara>
The total number of bytes expected to be downloaded in this transfer.
本次传输预计下载的总字节数。
</simpara>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>bytesDownloaded</parameter></term>
<listitem>
<simpara>
The number of bytes downloaded so far.
迄今已下载的字节数。
</simpara>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>bytesToUpload</parameter></term>
<listitem>
<simpara>
The total number of bytes expected to be uploaded in this transfer.
本次传输预计上传的总字节数。
</simpara>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>bytesUploaded</parameter></term>
<listitem>
<simpara>
The number of bytes uploaded so far.
迄今已上传的字节数。
</simpara>
</listitem>
</varlistentry>
</variablelist>
Return <literal>1</literal> to abort the transfer
and set a <constant>CURLE_ABORTED_BY_CALLBACK</constant> error.
Available as of PHP 8.2.0 and cURL 7.32.0.
返回 <literal>1</literal> 可中止传输并设置 <constant>CURLE_ABORTED_BY_CALLBACK</constant> 错误。自 PHP 8.2.0 和 cURL 7.32.0 起可用。
</para>
</listitem>
</varlistentry>
Expand All @@ -4220,12 +4215,9 @@
</term>
<listitem>
<para>
A timeout in seconds cURL will wait for a response from an
<acronym>FTP</acronym>, <acronym>SFTP</acronym>, <acronym>IMAP</acronym>,
<acronym>SCP</acronym>, <acronym>SMTP</acronym>, or a <acronym>POP3</acronym> server.
This option replaces the existing <constant>CURLOPT_FTP_RESPONSE_TIMEOUT</constant>
option which is deprecated in cURL 7.85.0.
Available as of PHP 8.4.0.
cURL 将等待来自 <acronym>FTP</acronym>、<acronym>SFTP</acronym>、<acronym>IMAP</acronym>、<acronym>SCP</acronym>、<acronym>SMTP</acronym>
或 <acronym>POP3</acronym> 服务器响应的超时秒数。此选项取代了现有的 <constant>CURLOPT_FTP_RESPONSE_TIMEOUT</constant> 选项,该选项在
cURL 7.85.0 中已弃用。自 PHP 8.4.0 起可用。
</para>
</listitem>
</varlistentry>
Expand All @@ -4236,10 +4228,7 @@
</term>
<listitem>
<para>
Specifies the OAuth 2.0 access token.
Set to &null; to disable.
Defaults to &null;.
Available as of PHP 7.0.7 and cURL 7.33.0.
指定 OAuth 2.0 访问 token。设置为 &null; 以禁用。默认为 &null;。自 PHP 7.0.7 和 cURL 7.33.0 起可用。
</para>
</listitem>
</varlistentry>
Expand Down
Loading

0 comments on commit cca949e

Please sign in to comment.