CARVIEW |
Select Language
HTTP/2 200
date: Fri, 25 Jul 2025 02:58:37 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
etag: W/"67d5b7e67298acf2fd91d70785f9b64b"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: no-referrer-when-downgrade
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=QB6kr2T%2BsxrpTiiInUidxDi34eTzv2EFS1fNMpfVDpaNrsEoh8aBtJTLc%2FIEHw5bvHOWPAw256%2F0UXQdg%2BOV%2Fxe9ILt87Im3BOdHWMDN5QeQutHAON3TqXLwtUum%2BP6WCsOi3qcervwwiPjpHYqWkzJPCwgf4yDSXzUKkNojGkkw6Rdjt5kdILFTbGqdTmzzE9%2FxeKEio%2BLvetyNTGoTiGvSfjBneRQ9Zb8LSst6SURrUqUgIFiDOq7oMU1FJObh26HNIxOLs3hGa6gPdekdLQ%3D%3D--enqTmtts1fv6YSXQ--9nUAEZ5VQv61ixOarE7BLQ%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.1246115544.1753412316; Path=/; Domain=github.com; Expires=Sat, 25 Jul 2026 02:58:36 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Sat, 25 Jul 2026 02:58:36 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: B8EE:2EEC20:E0AD8:153EF0:6882F2DC
Release v1.0.0 · EmbeddedEnterprises/cmake-ts · GitHub
Loading
Skip to content
Navigation Menu
{{ message }}
-
-
Notifications
You must be signed in to change notification settings - Fork 5
Compare
cmake-ts re-imagined
New features
Build configs, Cross-compilation, and new CLI
Now, cmake-ts can build the projects with built-in configurations that are selected depending on the arguments and the environment. This includes cross-compilation for different architectures, including Windows arm64, Linux arm64, etc.
cmake-ts build
cmake-ts build --config debug
You can cross-compile by specifying the built-in cross configs
cmake-ts build --config cross-win32-arm64-release
CLI Arguments
build
command:
Usage: cmake-ts build [options]
Build the project
Options:
--config, --configs <configs...>
Named config(s) to build, which could be from default configs or the ones defined in the config file (package.json)
If no config is provided, it will build for the current runtime on the current system with the Release build type
The default configs are combinations of `<Runtime>`, `<BuildType>`, `<Platform>`, and `<Architecture>`.
- `<Runtime>`: the runtime to use
e.g.: `node`, `electron`, `iojs`
- `<BuildType>`: the cmake build type (optimization level)
e.g.: `debug`, `release`, `relwithdebinfo`, or `minsizerel`
- `<Platform>`: the target platform
e.g.: `win32`, `linux`, `darwin`, `aix`, `android`, `freebsd`, `haiku`, `openbsd`, `sunos`, `cygwin`, `netbsd`
- `<Architecture>`: the target architecture
e.g.: `x64`, `arm64`, `ia32`, `arm`, `loong64`, `mips`, `mipsel`, `ppc`, `ppc64`, `riscv64`, `s390`, `s390x`
Any combination of `<BuildType>`, `<Runtime>`, `<Platform>`, and `<Architecture>` is valid. Some examples:
- `release`
- `debug`
- `relwithdebinfo`
- `node-release`
- `node-debug`
- `electron-release`
- `electron-debug`
- `win32-x64`
- `win32-x64-debug`
- `linux-x64-debug`
- `linux-x64-node-debug`
- `linux-x64-electron-release`
- `darwin-x64-node-release`
- `darwin-arm64-node-release`
- `darwin-arm64-electron-relwithdebinfo`
To explicitly indicate cross-compilation, prefix the config name with \`cross-\`:
- \`cross-win32-ia32-node-release\`
- \`cross-linux-arm64-node-release\`
- \`cross-darwin-x64-electron-relwithdebinfo\`
You can also define your own configs in the config file (package.json).
- `<ConfigName>`: the name of the config
e.g.: `my-config`
The configs can also be in format of `named-<property>`, which builds the configs that match the property.
- `named-os`: build all the configs in the config file that have the same OS
- `named-os-dev`: build all the configs in the config file that have the same OS and `dev` is true
- `named-all`: build all the configs in the config file
The configs can be combined with `,` or multiple `--configs` flags. They will be merged together.
(default: [])
-h, --help display help for command
Runtime Addon Loader
The runtime addon loader allows you to load the addon for the current runtime during runtime.
In ES modules:
import { loadAddon } from 'cmake-ts/build/loader.mjs';
import path from 'path';
import { fileURLToPath } from 'url';
const __dirname = path.dirname(fileURLToPath(import.meta.url));
const addon = loadAddon(path.resolve(__dirname, '..', 'build'));
or in CommonJS:
const { loadAddon } = require('cmake-ts/build/loader.js');
const addon = loadAddon(path.resolve(__dirname, '..', 'build'));
You can pass the types of the addon to the loader to get type safety:
type MyAddon = {
myFunction: (name: string) => void;
};
const addon = loadAddon<MyAddon>(path.resolve(__dirname, '..', 'build'));
Changelog
- feat: introduce build configs, triplets, and Cmake config + revamp arg parsing by @aminya in #42
- test: run the zeromq tests in CI + smoke tests by @aminya in #45
- fix: improve the logger + add deprecation warnings + update dev-deps by @aminya in #47
- fix: prevent conflict between binaries by @aminya in #48
- fix: fix cmake-ts build not working without configs by @aminya in #49
- feat: support cross-compilation by @aminya in #50
- feat: set up Windows toolchain variables for cross-compilation by @aminya in #51
- feat: add the runtime loader module by @aminya in #53
- fix: prevent test/download/build conflicts in parallel runs by @aminya in #54
- test: add tests for the utils by @aminya in #55
Full Changelog: v0.6.0...v1.0.0
Assets 2
You can’t perform that action at this time.