@brookesia/pipeline 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brookesia/pipeline",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "Build and release pipeline for ESP-Brookesia app projects",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
@@ -30,9 +30,9 @@
30
30
  "test": "vitest run"
31
31
  },
32
32
  "dependencies": {
33
- "@brookesia/config-schema": "0.1.1",
34
- "@brookesia/packager": "0.1.1",
35
- "@brookesia/shared-utils": "0.1.1",
33
+ "@brookesia/config-schema": "0.1.2",
34
+ "@brookesia/packager": "0.1.2",
35
+ "@brookesia/shared-utils": "0.1.2",
36
36
  "execa": "^9.5.2",
37
37
  "fs-extra": "^11.3.0"
38
38
  },
@@ -1,3 +0,0 @@
1
- import type { PipelineContext } from '../context.js';
2
- export declare function runCompileWasm(ctx: PipelineContext): Promise<void>;
3
- //# sourceMappingURL=compile-wasm.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"compile-wasm.d.ts","sourceRoot":"","sources":["../../src/steps/compile-wasm.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAErD,wBAAsB,cAAc,CAAC,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC,CAqCxE"}
@@ -1,37 +0,0 @@
1
- import { loadManifestFromDir, logStep, wasiClangPath, } from '@brookesia/shared-utils';
2
- import { execa } from 'execa';
3
- import fs from 'fs-extra';
4
- import path from 'node:path';
5
- export async function runCompileWasm(ctx) {
6
- const wasm = ctx.config.wasm;
7
- if (!wasm?.sources?.length) {
8
- return;
9
- }
10
- const packageRoot = ctx.config.pack?.skipBuildMirror ? ctx.sourceRoot : ctx.buildDir;
11
- await fs.ensureDir(packageRoot);
12
- const manifest = loadManifestFromDir(ctx.sourceRoot);
13
- const outputRel = wasm.output ?? manifest.runtime.entry;
14
- const outputPath = path.join(packageRoot, outputRel);
15
- await fs.ensureDir(path.dirname(outputPath));
16
- const clang = wasiClangPath(ctx.config);
17
- const sourcePaths = wasm.sources.map((rel) => {
18
- const p = path.join(packageRoot, rel);
19
- if (!fs.existsSync(p)) {
20
- throw new Error(`wasm source not found: ${rel} (expected at ${p})`);
21
- }
22
- return p;
23
- });
24
- const args = [
25
- '--target=wasm32-wasip1',
26
- ...sourcePaths,
27
- '-o',
28
- outputPath,
29
- ...(wasm.clangArgs ?? []),
30
- ];
31
- logStep(`compile-wasm: ${wasm.sources.join(', ')} → ${outputRel}`);
32
- await execa(clang, args, { stdio: 'inherit' });
33
- if (!fs.existsSync(outputPath)) {
34
- throw new Error(`compile-wasm: output missing: ${outputPath}`);
35
- }
36
- }
37
- //# sourceMappingURL=compile-wasm.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"compile-wasm.js","sourceRoot":"","sources":["../../src/steps/compile-wasm.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,OAAO,EACP,aAAa,GACd,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC;AAC9B,OAAO,EAAE,MAAM,UAAU,CAAC;AAC1B,OAAO,IAAI,MAAM,WAAW,CAAC;AAG7B,MAAM,CAAC,KAAK,UAAU,cAAc,CAAC,GAAoB;IACvD,MAAM,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC;IAC7B,IAAI,CAAC,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC;QAC3B,OAAO;IACT,CAAC;IAED,MAAM,WAAW,GAAG,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,eAAe,CAAC,CAAC,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,GAAG,CAAC,QAAQ,CAAC;IACrF,MAAM,EAAE,CAAC,SAAS,C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