Author |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Fri 23 Jun '23 9:23 Post subject: |
|
|
I can see I tried to build the extension for 7.4.29, but that one failed. So that was the end of an era. |
|
Back to top |
|
nambell
Joined: 22 Jun 2023 Posts: 7
|
Posted: Tue 27 Jun '23 14:23 Post subject: |
|
|
For correct enabling v8js extension I just need to write extension=v8js in php.ini? I already tried that, but It throws me an error that: Code: | PHP Warning: PHP Startup: Unable to load dynamic library 'C:/Custom-Server/SP/php74/ext/php_v8js.dll' in Unknown on line 0 |
I checked twice and this dll path is correct and file exists. Also I enabled bz2 extension and it loaded fine and without any error. Maybe there is any other libs that must be copied to apache/bin folder or anything else? |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Tue 27 Jun '23 15:31 Post subject: |
|
|
Try putting the dependent dll's in your PHP-directory
v8.dll
v8_libplatform.dll
v8_libbase.dll
icui18n.dll
icuuc.dll
icudtl.dat needs to be there as well. And this should ne in your php.ini:
extension=v8js
v8js.icudtl_dat_path=icudtl.dat |
|
Back to top |
|
nambell
Joined: 22 Jun 2023 Posts: 7
|
Posted: Tue 27 Jun '23 16:14 Post subject: |
|
|
Jan-E wrote: | v8.dll
v8_libplatform.dll
v8_libbase.dll
icui18n.dll
icuuc.dll |
These files are already in the directory, cuz I'm using your php build, which you mentioned before. If I write something like this: Code: | extension_dir = "C:/Custom-Server/SP/php74/ext"
extension = v8js
v8js.icudtl_dat_path = icudtl.dat |
then it display me that error:
Code: | PHP Warning: PHP Startup: Unable to load dynamic library 'v8js' (tried: C:/Custom-Server/SP/php74/ext\\v8js (The specified module was not found.), C:/Custom-Server/SP/php74/ext\\php_v8js.dll (The specified module was not found.)) in Unknown on line 0 |
I also noticed that for some reason it adds a second backslash to the full path of dll, maybe because of this it is not possible to enable the extension? |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Tue 27 Jun '23 16:45 Post subject: |
|
|
Does it load other extensions with dependencies?
extension=pdflib
extension=ldap
extension=amqp
extension=mbstring
extension=openssl
If they fail as well you have a general PHP-installation problem, not related to v8js. Then try to get a running PHP 7.4 before adding v8js. |
|
Back to top |
|
nambell
Joined: 22 Jun 2023 Posts: 7
|
Posted: Wed 28 Jun '23 8:09 Post subject: |
|
|
Jan-E wrote: | Does it load other extensions with dependencies?
|
Nope, same error on each extension.
Fixed it with adding full path to php folder & ext folder to PATH variable in environment variable for user and system. Now all works as it must. |
|
Back to top |
|
Deadooshka
Joined: 06 Jan 2018 Posts: 4
|
Posted: Thu 06 Jul '23 17:34 Post subject: PHP 8.3.0 Alpha 2 |
|
|
Can't run 8.3 on Windows 7. It requires GetCurrentThreadStackLimits system function. Is that official support ending for Windows 7? |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Sat 08 Jul '23 22:23 Post subject: Re: PHP 8.3.0 Alpha 2 |
|
|
Deadooshka wrote: | Can't run 8.3 on Windows 7. It requires GetCurrentThreadStackLimits system function. Is that official support ending for Windows 7? |
Ouch. Looks like this is unintentional. The commit that introduced GetCurrentThreadStackLimits stated:
Quote: | Minimum supported Windows version bumped to Windows 2008 or Windows Server 2012 |
Windows 2008 is the server equivalent of Windows 7. And I checked: PHP 8.3 (nts x64) does not run on Windows 2008 R2 either.
I reported this to the PHP devs:
https://github.com/php/php-src/pull/9104#issuecomment-1627481475 |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
|
Back to top |
|
tmabell
Joined: 23 Jun 2023 Posts: 5 Location: Mishawaka, IN
|
Posted: Thu 20 Jul '23 15:55 Post subject: |
|
|
Are you referring to Windows 7 or Windows 7 SP1 or both?
|
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Thu 20 Jul '23 16:07 Post subject: |
|
|
tmabell wrote: | Are you referring to Windows 7 or Windows 7 SP1 or both?
|
Both |
|
Back to top |
|
maxrys
Joined: 12 Oct 2023 Posts: 1 Location: Minsk
|
Posted: Thu 12 Oct '23 17:34 Post subject: |
|
|
Otomatic wrote: | virtualprotect() failed 87 the parameter is incorrect. |
About "virtualprotect() failed 87 the parameter is incorrect"...
I was investigating the same case.
I tested CMS EFFCORE on the Windows platform (Windows 10 2021 LTSC x64).
After installing Apache (httpd-2.4.57-win64-VS17.zip) and PHP (php-8.2.11-vs16-x64.zip), I began to include the missing modules to install the system.
I enabled all the required modules and the system installed without problems.
I ran all the tests and they ran successfully.
Then I decided to speed up the system and enabled OPCache + JIT.
After enabling OPCache + JIT I started getting a "white screen" and the message "virtualprotect() failed 87 the parameter is incorrect".
After disabling OPCache + JIT or OPCache the problem went away.
I was wondering what this error was.
I created a small script and placed it in the "test.php" file.
It had the following contents:
Code: | $path = 'data.php';
$lines_num = 2000;
if (!file_exists($path)) {
file_put_contents($path, '<?php'."\n", FILE_APPEND);
for ($i = 0; $i < $lines_num; $i++)
file_put_contents($path, '$data['.$i.'] = \'value '.$i."';\n", FILE_APPEND);
file_put_contents($path, 'print \'COUNT: \'.count($data);', FILE_APPEND);
print 'FILE WAS CREATED. RELOAD THIS PAGE';
} else {
include_once($path);
print "\n".'FILE WAS INCLUDED';
} |
Next, I ran “test.php” from the browser and got a white screen if “lines_num” was greater than 2000 and a normal result if less than 2000.
This is an obvious overflow of some memory segment.
However, the log did not contain any information about the error.
From the console I ran this script with any number of "lines_num" and no problems arose.
Code: | php -d opcache.jit_debug=1 test.php
php -d opcache.jit_debug=1 data.php |
I concluded that the problem is with the Apache + PHP combination as a module.
However, there were no problems under Linux/Unix.
Here is the complete list of links:
- win: Apache + PHP as a module - !!! JIT problem !!!
- win: IIS + PHP as FastCGI - OK
- win: PHP CLI - OK
- nix: Apache + PHP as a module - OK
- nix: NGINX + PHP as FastCGI - OK
- nix: PHP CLI - OK
I had to disable OPCache in "php.ini" via "opcache.enable=0" and the problem went away.
In "php.ini" you can disable only JIT via "opcache.jit_buffer_size=0" but this setting cannot be changed directly from PHP code.
Changing other "opcache.*" settings in "php.ini" did not lead to anything.
You can also disable OPCache + JIT programmatically with the following code:
Code: | if (DIRECTORY_SEPARATOR === '\\') {
ini_set('opcache.enable', false);
} |
Thank you for your attention, I hope it helped. |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Sat 09 Dec '23 0:40 Post subject: |
|
|
All 8.x builds updated to OpenSSL 3.0.12 and Curl 8.5.0, including PHP 8.1.27RC1. |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Wed 17 Jul '24 13:17 Post subject: |
|
|
PHP 8.4 is on its way. As of 8.4.0 Alpha 2 it builds fine with Visual Studio 2022 aka VS17. The PHP devs stick to their preference for the OpenSSL LTS branch, which is 3.0.x. |
|
Back to top |
|
BrainFooLong
Joined: 31 May 2023 Posts: 5
|
Posted: Fri 19 Jul '24 7:05 Post subject: |
|
|
Jan-E wrote: | PHP 8.4 is on its way. As of 8.4.0 Alpha 2 it builds fine with Visual Studio 2022 aka VS17. The PHP devs stick to their preference for the OpenSSL LTS branch, which is 3.0.x. |
Very nice. Works fine here, however i see "php_sqlsrv" extension is missing currently. Is it incompatible with PHP 8.4 as of now? |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Thu 25 Jul '24 0:37 Post subject: |
|
|
BrainFooLong wrote: | Jan-E wrote: | PHP 8.4 is on its way. As of 8.4.0 Alpha 2 it builds fine with Visual Studio 2022 aka VS17. The PHP devs stick to their preference for the OpenSSL LTS branch, which is 3.0.x. |
Very nice. Works fine here, however i see "php_sqlsrv" extension is missing currently. Is it incompatible with PHP 8.4 as of now? |
It is. But a solution is in the making: https://github.com/microsoft/msphpsql/issues/1507 |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Thu 25 Jul '24 12:41 Post subject: |
|
|
Jan-E wrote: | BrainFooLong wrote: | Jan-E wrote: | PHP 8.4 is on its way. As of 8.4.0 Alpha 2 it builds fine with Visual Studio 2022 aka VS17. The PHP devs stick to their preference for the OpenSSL LTS branch, which is 3.0.x. |
Very nice. Works fine here, however i see "php_sqlsrv" extension is missing currently. Is it incompatible with PHP 8.4 as of now? |
It is. But a solution is in the making: https://github.com/microsoft/msphpsql/issues/1507 |
All builds of 8.4.0 Alpha 2 contain the SQLSRV extensions (php_sqlsrv.dll and php_pdo_sqlsrv.dll) now.
@BrainFooLong If you have got a running SQL Server, could you test if this very early release has major issues? I cannot solve them but once PHP 8.4.0 is in the RC state issues should be filed at https://github.com/microsoft/msphpsql/issues |
|
Back to top |
|
BrainFooLong
Joined: 31 May 2023 Posts: 5
|
Posted: Wed 31 Jul '24 9:14 Post subject: |
|
|
@Jan-E
I can confirm this current 8.4.0 Alpha 2 does contain SQLSRV
and it works.
I've tested my use cases (Mostly selects and inserts) and all works like a charm.
Thank you. |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Wed 31 Jul '24 19:38 Post subject: |
|
|
@BrainFooLong Thanks for testing! PHP 8.4.0 Alpha 3 is available now. From now on until the final release of PHP 8.4.0 there will be an alpha, beta or RC of 8.4.0. |
|
Back to top |
|