Skip to content

Commit

Permalink
move v8 to third_party/v8 (denoland#322)
Browse files Browse the repository at this point in the history
  • Loading branch information
kt3k authored and ry committed Jul 3, 2018
1 parent 6d288b6 commit 6f7ca76
Show file tree
Hide file tree
Showing 23 changed files with 45 additions and 36 deletions.
8 changes: 4 additions & 4 deletions .gclient
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ solutions = [{
}
}, {
'url': 'https://github.com/ry/protobuf_chromium.git',
'name': 'third_party/protobuf',
'name': 'protobuf',
}, {
'url':
'https://chromium.googlesource.com/chromium/src/tools/protoc_wrapper@9af82fef8cb9ca3ccc13e2ed958f58f2c21f449b',
Expand All @@ -29,15 +29,15 @@ solutions = [{
'url':
'https://chromium.googlesource.com/chromium/src/third_party/zlib@39b4a6260702da4c089eca57136abf40a39667e9',
'name':
'third_party/zlib'
'zlib'
}, {
'url':
'https://github.com/cpplint/cpplint.git@a33992f68f36fcaa6d0f531a25012a4c474d3542',
'name':
'third_party/cpplint'
'cpplint'
}, {
'url':
'https://github.com/rust-lang/libc.git@8a85d662b90c14d458bc4ae9521a05564e20d7ae',
'name':
'third_party/rust_crates/libc'
'rust_crates/libc'
}]
13 changes: 10 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
# build
/out/

# npm deps
node_modules
/v8/
/tools/protoc_wrapper/

# git deps
/third_party/v8/
/third_party/tools/protoc_wrapper/
/third_party/cpplint/
/third_party/protobuf/
/third_party/zlib/
/third_party/rust_crates/libc/
/.gclient_entries

# gclient files
/third_party/.gclient_entries
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ install:
- export PATH=$HOME/.cargo/bin:$PATH
- rustc --version
- (cd js; yarn)
- gclient sync -j2 --no-history
- (cd third_party; gclient sync -j2 --no-history)
# ccache needs the custom LLVM to be in PATH and other variables.
- export PATH=`pwd`/third_party/llvm-build/Release+Asserts/bin:$PATH
- export CCACHE_CPP2=yes
Expand Down
10 changes: 5 additions & 5 deletions BUILD.gn
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import("//third_party/protobuf/proto_library.gni")
import("//v8/gni/v8.gni")
import("//v8/snapshot_toolchain.gni")
import("//third_party/v8/gni/v8.gni")
import("//third_party/v8/snapshot_toolchain.gni")
import("deno.gni")

config("deno_config") {
include_dirs = [ "v8" ] # This allows us to v8/src/base/ libraries.
configs = [ "v8:external_config" ]
include_dirs = [ "third_party/v8" ] # This allows us to v8/src/base/ libraries.
configs = [ "third_party/v8:external_config" ]
}

rust_executable("deno") {
Expand Down Expand Up @@ -73,7 +73,7 @@ v8_source_set("deno_nosnapshot") {
"src/include/deno.h",
]
deps = [
"v8:v8_monolith",
"third_party/v8:v8_monolith",
]
configs = [ ":deno_config" ]
}
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ You need [rust](https://www.rust-lang.org/en-US/install.html) installed.
You need [ccache](https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Build_Instructions/ccache) installed.

Fetch packages and v8:
``` bash
gclient sync --no-history
```bash
(cd third_party; gclient sync --no-history)
```

Install the javascript deps.
Expand Down
2 changes: 1 addition & 1 deletion build
2 changes: 1 addition & 1 deletion build_overrides
2 changes: 1 addition & 1 deletion buildtools
4 changes: 2 additions & 2 deletions deno.gni
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ template("create_snapshot") {
])
visibility = [ ":*" ] # Only targets in this file can depend on this.
deps += [ ":snapshot_creator" ]
script = "v8/tools/run.py"
script = "third_party/v8/tools/run.py"
data = []
exe = rebase_path(get_label_info(":snapshot_creator", "root_out_dir") +
"/snapshot_creator")
Expand Down Expand Up @@ -66,7 +66,7 @@ template("rust_crate") {
]
outputs = []
depfile = "$target_gen_dir/$target_name.d"
script = "v8/tools/run.py"
script = "third_party/v8/tools/run.py"

args = [
"rustc",
Expand Down
6 changes: 3 additions & 3 deletions src/deno.cc
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ IN THE SOFTWARE.
#include <string.h>
#include <string>

#include "v8/include/libplatform/libplatform.h"
#include "v8/include/v8.h"
#include "v8/src/base/logging.h"
#include "third_party/v8/include/libplatform/libplatform.h"
#include "third_party/v8/include/v8.h"
#include "third_party/v8/src/base/logging.h"

#include "./deno_internal.h"
#include "include/deno.h"
Expand Down
2 changes: 1 addition & 1 deletion src/deno_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

#include <string>
#include "include/deno.h"
#include "v8/include/v8.h"
#include "third_party/v8/include/v8.h"

extern "C" {
// deno_s = Wrapped Isolate.
Expand Down
2 changes: 1 addition & 1 deletion src/file_util.cc
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class StartupDataCppWriter {
private:
void WritePrefix() {
file_ << "// Autogenerated snapshot file. Do not edit.\n\n";
file_ << "#include \"v8/include/v8.h\"\n\n";
file_ << "#include \"third_party/v8/include/v8.h\"\n\n";
file_ << "namespace deno { \n\n";
}

Expand Down
4 changes: 2 additions & 2 deletions src/from_snapshot.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
#include <string.h>
#include <string>

#include "v8/include/v8.h"
#include "v8/src/base/logging.h"
#include "third_party/v8/include/v8.h"
#include "third_party/v8/src/base/logging.h"

#include "./deno_internal.h"
#include "include/deno.h"
Expand Down
2 changes: 1 addition & 1 deletion src/mock_main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

#include "./msg.pb.h"
#include "include/deno.h"
#include "v8/src/base/logging.h"
#include "third_party/v8/src/base/logging.h"

static char** global_argv;
static int global_argc;
Expand Down
4 changes: 2 additions & 2 deletions src/snapshot_creator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
#include "deno_internal.h"
#include "file_util.h"
#include "include/deno.h"
#include "v8/include/v8.h"
#include "v8/src/base/logging.h"
#include "third_party/v8/include/v8.h"
#include "third_party/v8/src/base/logging.h"

namespace deno {

Expand Down
2 changes: 1 addition & 1 deletion testing
1 change: 1 addition & 0 deletions third_party/.gclient
2 changes: 1 addition & 1 deletion third_party/googletest
2 changes: 1 addition & 1 deletion third_party/jinja2
2 changes: 1 addition & 1 deletion third_party/llvm-build
2 changes: 1 addition & 1 deletion third_party/markupsafe
2 changes: 1 addition & 1 deletion tools/clang
1 change: 1 addition & 0 deletions tools/protoc_wrapper

0 comments on commit 6f7ca76

Please sign in to comment.