Skip to content
This repository was archived by the owner on Sep 19, 2025. It is now read-only.

Commit d72c342

Browse files
Ensure the build scripts restrict by platform and architecture
1 parent a3a10e7 commit d72c342

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

packages/google-closure-compiler-linux-arm64/build-image.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env node
22
/*
3-
* Copyright 2018 The Closure Compiler Authors.
3+
* Copyright 2025 The Closure Compiler Authors.
44
*
55
* Licensed under the Apache License, Version 2.0 (the "License");
66
* you may not use this file except in compliance with the License.
@@ -28,7 +28,7 @@ const runCommand = require('../../build-scripts/run-command');
2828

2929
if (fs.existsSync(path.resolve(__dirname, 'compiler'))) {
3030
process.stdout.write(` ${DIM}google-closure-compiler-linux-arm64 binary already exists${RESET}\n`);
31-
} else if (process.platform !== 'linux') {
31+
} else if (process.platform !== 'linux' || process.arch !== 'arm64') {
3232
process.stdout.write(` ${DIM}google-closure-compiler-linux-arm64 build wrong platform${RESET}\n`);
3333
} else {
3434
process.stdout.write(` ${DIM}google-closure-compiler-linux-arm64 building image${RESET}\n`);

packages/google-closure-compiler-linux-arm64/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2018 The Closure Compiler Authors.
2+
* Copyright 2025 The Closure Compiler Authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

packages/google-closure-compiler-linux-arm64/test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env node
22
/*
3-
* Copyright 2018 The Closure Compiler Authors.
3+
* Copyright 2025 The Closure Compiler Authors.
44
*
55
* Licensed under the Apache License, Version 2.0 (the "License");
66
* you may not use this file except in compliance with the License.

packages/google-closure-compiler-linux/build-image.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ const runCommand = require('../../build-scripts/run-command');
2828

2929
if (fs.existsSync(path.resolve(__dirname, 'compiler'))) {
3030
process.stdout.write(` ${DIM}google-closure-compiler-linux binary already exists${RESET}\n`);
31-
} else if (process.platform !== 'linux') {
31+
} else if (process.platform !== 'linux' || ['x86', 'x64'].includes(process.arch)) {
3232
process.stdout.write(` ${DIM}google-closure-compiler-linux build wrong platform${RESET}\n`);
3333
} else {
3434
process.stdout.write(` ${DIM}google-closure-compiler-linux building image${RESET}\n`);

0 commit comments

Comments
 (0)