Skip to content
This repository was archived by the owner on Mar 29, 2024. It is now read-only.

Commit d39161f

Browse files
authored
Merge pull request #87 from pinepain/fix-upgrading
Land proper libv8 upgrading
2 parents 3845b5d + f790dab commit d39161f

File tree

157 files changed

+10
-372
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+10
-372
lines changed

.valgrind-docker.supp

Lines changed: 0 additions & 11 deletions
This file was deleted.

.valgrind-v8.supp

Lines changed: 0 additions & 52 deletions
This file was deleted.

.valgrindrc

Lines changed: 0 additions & 3 deletions
This file was deleted.

config.m4

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ if test "$PHP_V8" != "no"; then
117117
PHP_SUBST(V8_SHARED_LIBADD)
118118
PHP_REQUIRE_CXX()
119119

120-
CPPFLAGS="$CPPFLAGS -std=c++11"
120+
CPPFLAGS="$CPPFLAGS -std=c++14"
121121

122122
# On OS X clang reports warnings in zeng_strings.h, like
123123
# php/Zend/zend_string.h:326:2: warning: 'register' storage class specifier is deprecated [-Wdeprecated-register]

scripts/test_v8/hello_world.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,9 @@ void weak_callback(const v8::WeakCallbackInfo<v8::Persistent<v8::String>>& data)
1515
int main(int argc, char* argv[]) {
1616
// Initialize V8.
1717
v8::V8::InitializeICU();
18-
v8::Platform *platform = v8::platform::CreateDefaultPlatform();
19-
v8::V8::InitializePlatform(platform);
2018

21-
// std::unique_ptr<v8::Platform> platform = v8::platform::NewDefaultPlatform();
22-
// v8::V8::InitializePlatform(platform.get());
19+
std::unique_ptr<v8::Platform> platform = v8::platform::NewDefaultPlatform();
20+
v8::V8::InitializePlatform(platform.get());
2321

2422
V8::Initialize();
2523

scripts/test_v8/hello_world_build_deb.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ INCLUDE_DIR=$ROOT/include
88

99
set -x
1010

11-
g++ -std=c++14 hello_world.cpp -o hello_world \
11+
g++ hello_world.cpp -o hello_world \
1212
-g \
1313
-O2 \
14-
-std=c++11 \
14+
-std=c++14 \
1515
-I$INCLUDE_DIR \
1616
-L$LIB_DIR \
1717
-Wl,-rpath,$LIB_DIR \

scripts/test_v8/hello_world_build_osx.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ INCLUDE_DIR=$ROOT/include
99
g++ hello_world.cpp -o hello_world \
1010
-g \
1111
-O2 \
12-
-std=c++11 \
12+
-std=c++14 \
1313
-I$SRC_DIR \
1414
-I$INCLUDE_DIR \
1515
-L$LIB_DIR \

src/php_v8_a.cc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ void php_v8_init()
3131

3232
// If we use snapshot and extenal startup data then we have to initialize it (see https://codereview.chromium.org/315033002/)
3333
// v8::V8::InitializeExternalStartupData(NULL);
34-
v8::Platform *platform = v8::platform::CreateDefaultPlatform();
34+
std::unique_ptr<v8::Platform> platform_unique_ptr = v8::platform::NewDefaultPlatform();
35+
36+
v8::Platform *platform = platform_unique_ptr.release();
3537
v8::V8::InitializePlatform(platform);
3638

3739
// const char *flags = "--no-hard_abort";

stubs/src/FunctionTemplate.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
* v8::Local<v8::ObjectTemplate> instance_t = t->InstanceTemplate();
5454
* instance_t->SetAccessor(String::NewFromUtf8(isolate, "instance_accessor"),
5555
* InstanceAccessorCallback);
56-
* instance_t->SetNamedPropertyHandler(PropertyHandlerCallback);
56+
* instance_t->SetHandler(NamedPropertyHandlerConfiguration(PropertyHandlerCallback));
5757
* instance_t->Set(String::NewFromUtf8(isolate, "instance_property"),
5858
* Number::New(isolate, 3));
5959
*

tests/001-extension_info.phpt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
v8 extension info
33
--SKIPIF--
44
<?php if (!extension_loaded("v8")) print "skip"; ?>
5-
--ENV--
6-
HOME=/tmp/we-need-home-env-var-set-to-load-valgrindrc
75
--FILE--
86
<?php
97

0 commit comments

Comments
 (0)