Trouble building Flatpak with SVGO dependency

Hello. I contribute to the app Curtail, and we’ve been having trouble moving from Scour to SVGO for SVG compression. Both the maintainer and I have attempted to get the app to build with it as a dependency, but our attempts have failed. Please let me know if any more information is needed, or if there’s a better place to ask for help with this. Any help would be appreciated.

The last attempt can found here. When I try to build this, I get the following error:

Running: npm install
npm warn deprecated inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
npm warn deprecated glob@7.2.3: Glob versions prior to v9 are no longer supported
npm warn deprecated glob@7.2.3: Glob versions prior to v9 are no longer supported
npm warn deprecated glob@7.2.3: Glob versions prior to v9 are no longer supported
npm warn deprecated glob@7.2.3: Glob versions prior to v9 are no longer supported

added 527 packages, and audited 528 packages in 23s

85 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities
npm notice
npm notice New patch version of npm available! 11.6.1 -> 11.6.2
npm notice Changelog: https://github.com/npm/cli/releases/tag/v11.6.2
npm notice To update run: npm install -g npm@11.6.2
npm notice
Running: ls /usr/lib/sdk/node24/bin
corepack  node	npm  npx  yarn	yarnpkg
Running: install -Dm755 /usr/lib/sdk/node24/bin/svgo /app/bin/svgo
install: cannot stat '/usr/lib/sdk/node24/bin/svgo': No such file or directory
Error: module svgo: Child process exited with code 1

Thank you!

Since /usr comes from the runtime and SDK, it is read-only and can’t be written to.

You should build your library to either /app directly or first into the working directory.

Building to /app directly worked, thank you very much!

This topic was automatically closed after 3 days. New replies are no longer allowed.