Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chomp fails to install on Alpine via npm #175

Open
connor4312 opened this issue Sep 28, 2023 · 1 comment
Open

Chomp fails to install on Alpine via npm #175

connor4312 opened this issue Sep 28, 2023 · 1 comment

Comments

@connor4312
Copy link

connor4312 commented Sep 28, 2023

Here's what I'm trying:

/workspaces/es-module-lexer # node --version
v20.7.0
/workspaces/es-module-lexer # npm i -g chomp

changed 147 packages in 1s

6 packages are looking for funding
  run `npm fund` for details
/workspaces/es-module-lexer # chomp --help
node:events:492
      throw er; // Unhandled 'error' event
      ^

Error: spawn /usr/local/lib/node_modules/chomp/vendor/chomp ENOENT
    at ChildProcess._handle.onexit (node:internal/child_process:286:19)
    at onErrorNT (node:internal/child_process:484:16)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
Emitted 'error' event on ChildProcess instance at:
    at ChildProcess._handle.onexit (node:internal/child_process:292:12)
    at onErrorNT (node:internal/child_process:484:16)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  errno: -2,
  code: 'ENOENT',
  syscall: 'spawn /usr/local/lib/node_modules/chomp/vendor/chomp',
  path: '/usr/local/lib/node_modules/chomp/vendor/chomp',
  spawnargs: [ '--help' ]
}

Node.js v20.7.0

file reveals it's a dynamically linked binary, which doesn't run out of the box on Alpine:

/workspaces/es-module-lexer # file /usr/local/lib/node_modules/chomp/vendor/chomp
/usr/local/lib/node_modules/chomp/vendor/chomp: ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=73c85cd956c7a62809badf65af42c53130596b8b, for GNU/Linux 3.2.0, with debug_info, not stripped
/workspaces/es-module-lexer # ls /lib64/ld-linux-x86-64.so.2
ls: /lib64/ld-linux-x86-64.so.2: No such file or directory
@connor4312 connor4312 changed the title Chomp fails to install on the latest Node 20 Chomp fails to install on Alpine via npm Sep 28, 2023
@guybedford
Copy link
Owner

Ah, yeah this sounds like an issue that we don't support Alpine builds.

I would suggest cargo install chompbuild in this case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants