11 Release Notes for
22 P4PHP, Perforce's script API for PHP
33
4- Version 2023 .2
4+ Version 2020 .2
55
66Introduction
77
@@ -20,72 +20,99 @@ Introduction
2020
2121--------------------------------------------------------------------------
2222
23- Installation
24-
25- Unix and Mac: Building the P4PHP Extension
23+ Unix and Mac: Building the P4PHP Extension
2624
27- The official version of P4Python exists as source on:
28- https://github.com/perforce/p4php
25+ To build P4PHP, you need the header files and libraries used by
26+ PHP and the "phpize" command-line utility. Both of these
27+ requirements can be met by installing PHP from source or by
28+ installing the development php packages (php-devel) appropriate
29+ for your operating system.
2930
30- Instructions for building are in the build.md file which can be found
31- here - https://github.com/perforce/p4php/blob/master/build.md
32-
31+ After you have obtained the required files and the phpize utility,
32+ perform the following steps:
3333
34- Windows: Building the P4PHP DLL
34+ 1. Download the Perforce P4PHP files.
35+ ftp://ftp.perforce.com/perforce/r20.2/bin.tools/p4php.tgz
36+ for the 2020.2 P4PHP.
3537
36- For instructions how to build P4PHP on windows please contact
37- support@perforce.com
38+ 2. Download the Perforce C++ API from the Perforce FTP site at
39+ "ftp://ftp.perforce.com/perforce". The API archive is located
40+ in release and platform-specific subdirectories, choose one
41+ matching OpenSSL version available at target system and the
42+ C library, for example p4api-glibc2.12-openssl1.1.1.tgz.
3843
39- --------------------------------------------------------------------------
44+ Note: 32-bit builds of P4PHP require a 32-bit version of the
45+ C++ API and a 32-bit version of PHP. 64-bit builds of
46+ P4PHP require a 64-bit version of the C++ API and a
47+ 64-bit version of PHP.
4048
41- Compatibility Statements
49+ 3. Extract both archives into an empty directory.
4250
43- Server Compatibility
51+ 4. To build P4PHP, change to the p4php-<version> directory, and run
52+ the following commands:
4453
45- You can use any release of P4PHP with any release of the Perforce server
46- later than 2001.1 but it is recommended to use the 2023.2 release
54+ phpize
4755
48- API Compatibility
56+ ./configure --with-perforce=<path to Perforce C++ API>
4957
50- This release of P4PHP requires the 2023.2 (2023.2/2519561) Perforce API.
51- Older releases will not work and will fail to compile.
58+ make
5259
53- OpenSSL compatibility
60+ 5. To test your P4PHP build, run the following command:
5461
55- The minimum version of OpenSSL libraries required is driven by the
56- 2023.2 server; the minimum version needed is 1.0.2. The latest 3.0.x or
57- 1.1.1 patch is recommended.
62+ make test
5863
59- PHP compatibility
64+ Note: the test harness requires a copy of the Perforce server
65+ executable, p4d, be installed in the current working
66+ directory.
6067
61- This release of P4PHP is compatible with PHP versions: 7.2.x - 8.2.x
68+ 6. To install P4PHP, run the following command:
6269
63- Platform compatibility
70+ make install
6471
65- Though P4PHP is generally portable, this release is tested on the
66- following platforms:
67-
68- Linux
69- Ubuntu 16.04, 18.04, 20.04, 22.04
70- CentOS/Rocky Linux 7, 8
71- Windows
72- Server 2016
72+ Note: the installation typically needs to be performed as
73+ the root user.
7374
74- Compiler compatibility
75+ 7. To enable P4PHP, edit your "php.ini" file and add the following
76+ line:
77+
78+ extension=perforce.so;
79+
80+ Note: to locate your "php.ini" file, run the following command:
81+
82+ php --ini
83+
84+ Now run:
85+
86+ php -m
87+
88+ to confirm that the P4PHP module is being loaded.
89+
90+ 8. To verify that P4PHP works, run the following command:
91+
92+ php --ri perforce
93+
94+ If the extension is correctly installed, P4PHP displays
95+ its version information.
96+
97+ SSL support
98+ -----------
99+
100+ Perforce Server 2020.2 supports SSL connections and the C++ API has
101+ been compiled with this support. This means that in order to build
102+ P4PHP, the underlying PHP framework must include OpenSSL.
103+
104+ --------------------------------------------------------------------------
105+
106+ Windows: Building the P4PHP DLL
75107
76- To build P4PHP from source, you must use a version of PHP that has been
77- compiled with the same compiler used to build the Perforce C++ API. For
78- most platforms, use gcc/g++.
108+ For instructions how to build P4PHP on windows please contact support@perforce.com
79109
80- Attempting to use a different compiler or a different version of the
81- compiler causes linker errors due to differences in name handling.
82-
83110--------------------------------------------------------------------------
84111
85112Testing P4PHP
86113
87- You can use the following small script to test P4PHP. Place it into a file
88- named "p4php_info.php":
114+ You can use the following small script to test P4PHP. Place it
115+ into a file named "p4php_info.php":
89116
90117 <?php
91118 $p4 = new P4();
@@ -137,62 +164,52 @@ Testing P4PHP
137164
138165--------------------------------------------------------------------------
139166
140- Key to symbols used in change notes below.
141-
142- * -- requires new P4PHP
143- ** -- requires P4PHP built with new P4API
144- *** -- requires new p4d server program
167+ Compatibility Statements
145168
146- --------------------------------------------------------------------------
169+ Server Compatibility
147170
148- New functionality in 2023.2 (2023.2/2552260) (2024/02/06)
171+ You can use any release of P4PHP with any release of the
172+ Perforce server later than 2001.1
149173
150- #2545331 (Job #119067) * **
151- This release of P4PHP is built against P4API 2023.2 (2023.2/2519561)
174+ API Compatibility
152175
153- --------------------------------------------------------------------------
176+ The 2020.2 release of P4PHP requires the 2020.2 Perforce API.
177+ Older releases will not work and will fail to compile.
154178
155- New functionality in 2023.1 Patch 1 (2023.1/2541299) (2024/01/12)
156-
157- (Job #118832) * **
158- This release is built against P4API (2023.1/2513900),
159- to address possible vulnerability: CVE-2023-5759.
179+ OpenSSL compatibility
160180
161- --------------------------------------------------------------------------
181+ The minimum version of OpenSSL libraries required is driven
182+ by the 2020.2 server; the minimum version needed is 1.0.2.
162183
163- New functionality in 2023.1 (2023.1/2469314) (2023/07/26)
184+ PHP compatibility
164185
165- #2457062 (Job #116145) * **
166- This release is built against latest P4API (2023.1/2442900)
186+ The 2020.2 release of P4PHP is compatible with PHP versions: 7.2.x - 8.0.x
167187
168- #2468224, #2460254 (Job #114508) * **
169- Added support for Windows builds for PHP 8.2
188+ Platform compatibility
170189
171- --------------------------------------------------------------------------
190+ Though P4PHP is generally portable, this release is certified
191+ only on the following platforms:
172192
173- New functionality in 2022.2 Patch 2 (2022.2/2541286) (2024/01/12)
174-
175- (Job #118832) * **
176- This release is built against P4API (2022.2/2531894),
177- to address possible vulnerability: CVE-2023-5759.
193+ Linux 2.6 Intel (x86, x86_64)
194+ Windows 10, 2016, 2019
178195
179- --------------------------------------------------------------------------
196+ Compiler compatibility
180197
181- New functionality in 2022.2 Patch 1
198+ To build P4PHP from source, you must use a version of PHP that
199+ has been compiled with the same compiler used to build the
200+ Perforce C++ API. For most platforms, use gcc/g++.
182201
183- #2389314, #2388708 (Job #113738) * **
184- Added support for PHP 8.2
185-
186- (Job #113737) * **
187- This release is built against latest P4API (2022.2/2407422), which
188- supports OpenSSL3
202+ Attempting to use a different compiler or a different version
203+ of the compiler causes linker errors due to differences in name
204+ handling.
189205
190206--------------------------------------------------------------------------
191207
192- New functionality in 2022.2
208+ Key to symbols used in change notes below.
193209
194- #2371665 (Job #111053) * **
195- Added support for PHP 8.1
210+ * -- requires new P4PHP
211+ ** -- requires P4PHP built with new P4API
212+ *** -- requires new p4d server program
196213
197214--------------------------------------------------------------------------
198215
@@ -439,4 +456,4 @@ Bugs fixed in 2010.1
439456
440457 #237983 (Job #38074) *
441458 Text output could be truncated if it contained null characters.
442- This change makes handling of text output binary-safe.
459+ This change makes handling of text output binary-safe.
0 commit comments