1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-21 15:04:11 -05:00

First pass at libdeno.

This commit is contained in:
Ryan Dahl 2018-06-10 04:55:31 +02:00
parent aa857984b0
commit 3062039ffe
7 changed files with 22 additions and 18 deletions

View file

@ -88,31 +88,34 @@ create_snapshot("deno") {
v8_executable("snapshot_creator") {
sources = [
"deno.cc",
"deno.h",
"snapshot_creator.cc",
]
configs = [ "v8:libplatform_config" ]
deps = [
"v8:v8",
"v8:v8_libbase",
"v8:v8_libplatform",
"v8:v8_libsampler",
"//build/config:exe_and_shlib_deps",
"//build/win:default_exe_manifest",
":libdeno",
]
}
v8_executable("deno") {
sources = [
"deno.cc",
"deno.h",
"main.cc",
]
include_dirs = [ target_gen_dir ]
configs = [ "v8:libplatform_config" ]
deps = [
":create_snapshot_deno",
":libdeno",
]
}
v8_component("libdeno") {
sources = [
"deno.cc",
"include/deno.h",
]
include_dirs = [ "include/" ]
configs = [ "v8:libplatform_config" ]
deps = [
":msg_proto",
"v8:v8",
"v8:v8_libbase",
@ -129,6 +132,7 @@ executable("deno_test") {
"deno_test.cc",
]
deps = [
":libdeno",
"//testing/gtest:gtest",
]
}

View file

@ -28,7 +28,7 @@ IN THE SOFTWARE.
#include "v8/include/libplatform/libplatform.h"
#include "v8/include/v8.h"
#include "./deno.h"
#include "include/deno.h"
#define CHECK(x) assert(x) // TODO(ry) use V8's CHECK.

View file

@ -2,7 +2,7 @@
// All rights reserved. MIT License.
#include "testing/gtest/include/gtest/gtest.h"
#include "./deno.h"
#include "include/deno.h"
TEST(SnapshotTest, InitializesCorrectly) {
EXPECT_TRUE(true);

View file

@ -1,7 +1,7 @@
// Copyright 2018 Ryan Dahl <ry@tinyclouds.org>
// All rights reserved. MIT License.
#ifndef DENO_H_
#define DENO_H_
#ifndef INCLUDE_DENO_H_
#define INCLUDE_DENO_H_
#include <string>
#include "v8/include/v8.h"
@ -48,4 +48,4 @@ void deno_terminate_execution(Deno* d);
} // namespace deno
#endif // DENO_H_
#endif // INCLUDE_DENO_H_

View file

@ -5,7 +5,7 @@
#include "v8/include/v8.h"
#include "./deno.h"
#include "include/deno.h"
#include "natives_deno.cc"
#include "snapshot_deno.cc"

View file

@ -9,7 +9,7 @@
#include "v8/include/v8.h"
#include "./deno.h"
#include "include/deno.h"
class StartupDataCppWriter {
public:

View file

@ -1,4 +1,4 @@
#!/bin/sh
cd `dirname "$0"`/..
set -e -v
cpplint --repository=. *.cc *.h
cpplint --repository=. *.cc *.h include/*.h