https://github.com/blacktop/darwin-webkit-build
WebKit/JSC CodeQL Databases
https://github.com/blacktop/darwin-webkit-build
codeql compile-commands-json darwin javascriptcore jsc webkit
Last synced: 6 months ago
JSON representation
WebKit/JSC CodeQL Databases
- Host: GitHub
- URL: https://github.com/blacktop/darwin-webkit-build
- Owner: blacktop
- License: mit
- Created: 2024-02-26T17:56:04.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2025-05-20T21:33:13.000Z (7 months ago)
- Last Synced: 2025-05-20T22:53:22.551Z (7 months ago)
- Topics: codeql, compile-commands-json, darwin, javascriptcore, jsc, webkit
- Language: Shell
- Homepage:
- Size: 86.9 KB
- Stars: 17
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# darwin-webkit-build
[](https://github.com/blacktop/darwin-webkit-build/actions/workflows/jsc.yml) 
[](https://doge.mit-license.org)
> WebKit/JSC CodeQL DBs and `compile_commands.json`
## Supported OS Versions
### macOS
| Version | Compiles | CodeQL | Binary | Compile Commands JSON |
| ------- | :------: | :----: | :----: | :-------------------: |
| 14.3 | ❌ | ❌ | ❌ | ❌ |
### iOS
| Version | Compiles | CodeQL | Binary | Compile Commands JSON |
| ------- | :------: | :----: | :----: | :-------------------: |
| 18.2 | ✅ | [JSC](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.2/jsc-codeql-18.2-release.zip) | ❌ | [JSON](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.2/jsc-compile_commands-18.2-release.zip) |
| 18.3 | ✅ | [JSC](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.3/jsc-codeql-18.3-release.zip) | ❌ | [JSON](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.3/jsc-compile_commands-18.3-release.zip) |
| 18.3.1 | ✅ | [JSC](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.3.1/jsc-codeql-18.3.1-release.zip) | ❌ | [JSON](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.3.1/jsc-compile_commands-18.3.1-release.zip) |
| 18.3.2 | ✅ | [JSC](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.3.2/jsc-codeql-18.3.2-release.zip) | ❌ | [JSON](https://github.com/blacktop/darwin-webkit-build/releases/download/v18.3.2/jsc-compile_commands-18.3.2-release.zip) |
### nightly
| Version | Compiles | CodeQL | Binary | Compile Commands JSON |
| ------- | :------: | :----: | :----: | :-------------------: |
| `main` | ✅ | [DB](https://github.com/blacktop/darwin-webkit-build/releases/download/nightly/webkit-codeql.zip) | ❌ | ❌ |
## Getting Started
### Dependencies
- [homebrew](https://brew.sh)
- [codeql CLI](https://codeql.github.com/docs/codeql-cli/)
- [jq](https://stedolan.github.io/jq/)
- [gum](https://github.com/charmbracelet/gum)
- [cmake](https://cmake.org)
- [ninja](https://ninja-build.org)
- XCode
- python3
> [!NOTE]
> The `codeql.sh` script will install all these for you if you are connected to the internet.
### Generate a CodeQL database
```bash
./codeql.sh
```
```bash
[2023-03-03 22:33:20] [build-stdout] 🎉 WebKit Build Done!
Finalizing database at darwin-webkit-build/webkit-codeql.
Running TRAP import for CodeQL database at darwin-webkit-build/webkit-codeql...
TRAP import complete (1m46s).
Successfully created database at darwin-webkit-build/webkit-codeql.
[info] Deleting log files...
[info] Zipping the CodeQL database...
🎉 CodeQL Database Create Done!
```
Script builds and zips up the CodeQL database
```bash
❯ ll webkit-codeql.zip
-rw-r--r--@ 1 blacktop staff 219M Mar 3 22:35 webkit-codeql.zip
```
### Generate a CodeQL database *(in a `local` **Tart** VM)*
Install deps: *[packer](https://developer.hashicorp.com/packer), [tart](https://tart.ru) and [cirrus](https://github.com/cirruslabs/cirrus-cli)*
```bash
make deps
```
Build VM image
```bash
make build-vm
```
Create CodeQL DB
```bash
OS_VERSION=18.3.1 make codeql-db-jsc
```
```bash
> Building CodeQL Database
🕓 'Build' Task 08:22
✅ pull virtual machine 0.0s
✅ 'Build' Task 47:59
🎉 Done! 🎉
🕒 'Build' Task 46:28
✅ 'Build' Task 48:15
```
```bash
tree artifacts/
artifacts/
└── Build
└── binary
├── jsc-codeql-18.3.1-release.zip
├── jsc-codeql-18.3.1-release.zip.sha256
└── jsc-compile_commands-18.3.1-release.zip
3 directories, 1 file
```
## License
MIT Copyright (c) 2024-2025 blacktop