Giter Club home page Giter Club logo

v8-monolith-builds's Introduction

V8 Monolith Builds 💼

Build V8 Static Library
➡️ Precompiled V8 static libraries for use in embedded C++ projects

V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++. It is used in Chrome and in Node.js, among others. It implements ECMAScript and WebAssembly, and runs on Windows 7 or later, macOS 10.12+, and Linux systems that use x64, IA-32, ARM, or MIPS processors. V8 can run standalone, or can be embedded into any C++ application. https://v8.dev

V8's practicality is evident in the world of embedded scripting environments, allowing developers to implement a hugely powerful JavaScript / WASM engine into their C++ project. However, given V8's massive codebase and freqeuent update schedule, it isn't maintainable to manually build and deploy the library following every release. Building from source is cumbersome, time-consuming and frustrating on most platforms, especially when system resources may be scarce. In order to aid in projects which desire to include V8's capabilities within themselves, this repository has been created, to automatically compile, and release subsequent builds following the latest stable release of V8.

Build System

Workflow
Our build process utilizes GitHub actions to dispatch workflows which manage the building and bumping of V8 versions. In particular, the build workflow produces monolithic libraries, meaning that you're given a single binary which can be included into your C++ project along with the provided header files. Each platform also provides a compiled executable of the d8 debugging environment. Every build makes a release with the compiled binaries.

Project Layout
Google's GN build system utilizes args.gn files to define the parameters for a build, to access the build arguments for a specific platform you can navigate to the platforms/ directory, and then the respective subdirectory for your targeted platform. The version of V8 that will be built is mandated by the V8_VERSION file in the root directory of the repository.

Manual Workflow Invocation
The build workflow can also be manually invoked by enacting a workflow dispatch event. You can either populate the "V8 Version" input field to target a specific version of V8 for the build, or leave it empty and have it target the version specified in the V8_VERSION file.

Supported Platforms
We currently produce builds for the following platforms:

Operating System x86-64 / x64 aarch64 / ARM64
Windows ✔️
macOS ✔️ w/ Rosetta 2
Linux ✔️

Commit Prefixes

The workflow responsible for building the V8 libraries recognises a couple prefixes to control the behavior of the build.

Prefix Behavior
[Skip] The workflow will not run if this prefix is present.

ℹ️ Notes:

  • Only use the [Skip] prefix when updating documentation or non-build-impacting files. Any changes to build configurations or V8 versions must be rebuilt to assure the master branch is always working.

Custom Build Arguments

If you need to customize the build arguments to better match your use-case feel free to fork and modify this repo! Since this repo is configured to be generally usable within our own projects, and those of a vast amount of embedders, we try not too deviate too far from what would be acceptable to everyone. If you have any suggestions however, regarding the optimization of file size, performance, or modifications to the workflow, please open a GitHub issue so we can get started!

v8-monolith-builds's People

Contributors

github-actions[bot] avatar pexien avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.