https://github.com/kuoruan/libv8
prebuilt v8 monolith static libraries
https://github.com/kuoruan/libv8
monolith static v8
Last synced: 3 months ago
JSON representation
prebuilt v8 monolith static libraries
- Host: GitHub
- URL: https://github.com/kuoruan/libv8
- Owner: kuoruan
- Created: 2021-02-05T09:01:06.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2025-02-13T02:10:23.000Z (3 months ago)
- Last Synced: 2025-02-13T03:22:02.617Z (3 months ago)
- Topics: monolith, static, v8
- Language: Batchfile
- Homepage:
- Size: 170 KB
- Stars: 35
- Watchers: 4
- Forks: 14
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Build V8 Monolith Library with GitHub Actions


## File Structure
```
.
├── VERSION # Current V8 version
├── archive.bat # Archive V8 library for Windows
├── archive.sh # Archive V8 library for Linux and macOS
├── args
│ ├── Linux.gn # GN args for Linux
│ ├── Windows.gn # GN args for Windows
│ └── macOS.gn # GN args for macOS
├── v8_compile.bat # Compile V8 library for Windows
├── v8_compile.sh # Compile V8 library for Linux and macOS
├── v8_download.bat # Download V8 source code for Windows
├── v8_download.sh # Download V8 source code for Linux and macOS
├── v8_test.bat # Test V8 library for Windows
└── v8_test.sh # Test V8 library for Linux and macOS
```## Custom Version Build
- Fork this repository.
- Modify the `VERSION` file to change the V8 version. (All versions can be found [here](https://chromium.googlesource.com/v8/v8.git/+refs))
- Commit and push to GitHub.
- Wait for the test build to complete.
- Tag the commit with the version number(prefixed with `v`) and push to GitHub.
- Wait for the release to complete.### Build Old Versions
**Note**: Usually, we can only build the versions within the last year.
- The old versions may not be compatible with the latest tools.
- The old versions may require old version of toolchains, which may not be available in the latest systems.If you want to build an old version, you may need to modify the build scripts and use the old version of `depot_tools` and other tools.
### Find the Match `depot_tools` Version
You can find the match `depot_tools` version for the V8 version in the `DEPS` file in the V8 source code.
For example, the `depot_tools` version for V8 version `10.6.1` is git revision: `0ba2fd429dd6db431fcbee6995c1278d2a3657a0`.
If there is no `depot_tools` version in the `DEPS` file, you can find the `depot_tools` version by the release date of V8 version.
For example, the V8 version `10.6.1` was released on `2022-07-22`, so you can find the `depot_tools` version around this date.
Check the `depot_tools` git log to find the match version. [commit log](https://chromium.googlesource.com/chromium/tools/depot_tools.git/+log/refs/heads/main)
Find the commit that is close to the release date of the target V8 version.
Once you find the match `depot_tools` version, you can checkout the version by the following command:
```bash
# make sure you have `git` installed
git submodule update --initcd depot_tools
git checkout 0ba2fd429dd6db431fcbee6995c1278d2a3657a0
```### Find the Match `python` Version
The `depot_tools` may require a specific version of `python`. You can find the required version in the `depot_tools` README file.
### Modify the Build Scripts
The `gclient`, `gn`, `ninja` and other tools may have different arguments or behaviors in the old versions.
The `v8_download`, `v8_compile` as well as other scripts may need to be modified.