{
    "name": "@gjsify/sab-native",
    "version": "0.51.1",
    "description": "Optional Vala/GObject bridge providing cross-process shared memory + atomics for @gjsify/worker_threads. Wraps Linux memfd_create(2) + mmap(MAP_SHARED) to back JS-visible SharedBuffer regions whose fds can be passed to child workers via SCM_RIGHTS over a Unix-domain socket; exposes typed accessors (getInt32LE / setUint8 / etc.) plus atomics built on __atomic_* GCC builtins and SYS_futex for wait/notify. Workaround for the stock-GJS gap where SharedArrayBuffer is unavailable (Mozilla disables the SAB constructor without COOP/COEP opts) and SAB cannot share backing stores across Gio.Subprocess workers anyway.",
    "type": "module",
    "main": "lib/esm/index.js",
    "module": "lib/esm/index.js",
    "types": "lib/types/index.d.ts",
    "exports": {
        ".": {
            "types": "./lib/types/index.d.ts",
            "default": "./lib/esm/index.js"
        }
    },
    "files": [
        "lib",
        "meson.build",
        "src/vala"
    ],
    "gjsify": {
        "platforms": [
            "linux-x64",
            "linux-x64-musl",
            "linux-arm64",
            "linux-arm64-musl",
            "linux-ppc64",
            "linux-s390x",
            "linux-riscv64"
        ],
        "runtimes": {
            "gjs": "polyfill",
            "node": "none",
            "browser": "none",
            "nativescript": "none"
        },
        "tier": 1
    },
    "scripts": {
        "clear": "gjsify clear lib build tsconfig.tsbuildinfo tsconfig.types.tsbuildinfo test.gjs.mjs",
        "check": "gjsify tsc --noEmit",
        "init:meson": "meson setup build .",
        "init:meson:wipe": "gjsify run init:meson --wipe",
        "build": "gjsify run build:gjsify && gjsify run build:types",
        "build:gjsify": "gjsify build --library 'src/ts/**/*.{ts,js}' --exclude 'src/ts/**/*.spec.{mts,ts}' 'src/ts/test.{mts,ts}'",
        "build:meson": "gjsify run init:meson && meson compile -C build",
        "build:types": "gjsify tsc",
        "build:prebuilds": "gjsify run build:meson && node ../../../scripts/stage-prebuild.mjs .",
        "build:gir-types": "ts-for-gir generate --externalDeps --allowMissingDeps --girDirectories=../sab-native-linux-x64/prebuilds/linux-x64 --girDirectories=/usr/share/gir-1.0 --modules=GjsifySabNative-1.0 --outdir=src/ts --npmScope=@girs --package=false --ignoreVersionConflicts=true",
        "build:test": "gjsify run build:test:gjs",
        "build:test:gjs": "gjsify build src/ts/test.mts --app gjs --outfile test.gjs.mjs",
        "test": "gjsify run build:gjsify && gjsify run build:test && gjsify run test:gjs",
        "test:gjs": "gjsify run test.gjs.mjs"
    },
    "keywords": [
        "gjs",
        "shared-memory",
        "shared-array-buffer",
        "atomics",
        "memfd",
        "mmap",
        "futex",
        "worker-threads",
        "vala",
        "native"
    ],
    "dependencies": {
        "@girs/gjs": "5.0.0",
        "@girs/glib-2.0": "5.0.0",
        "@girs/gobject-2.0": "5.0.0",
        "@girs/gio-2.0": "5.0.0"
    },
    "devDependencies": {
        "@gjsify/cli": "^0.51.1",
        "@gjsify/unit": "^0.51.1",
        "@ts-for-gir/cli": "^4.1.0",
        "@types/node": "^25.9.2",
        "typescript": "^6.0.3"
    },
    "license": "MIT",
    "repository": {
        "type": "git",
        "url": "git+https://github.com/gjsify/gjsify.git",
        "directory": "packages/node/sab-native"
    },
    "bugs": {
        "url": "https://github.com/gjsify/gjsify/issues"
    },
    "homepage": "https://github.com/gjsify/gjsify/tree/main/packages/node/sab-native#readme",
    "optionalDependencies": {
        "@gjsify/sab-native-linux-arm64": "0.51.1",
        "@gjsify/sab-native-linux-arm64-musl": "0.51.1",
        "@gjsify/sab-native-linux-ppc64": "0.51.1",
        "@gjsify/sab-native-linux-riscv64": "0.51.1",
        "@gjsify/sab-native-linux-s390x": "0.51.1",
        "@gjsify/sab-native-linux-x64": "0.51.1",
        "@gjsify/sab-native-linux-x64-musl": "0.51.1"
    }
}
