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

patch: etcher-util is corrupted in RPM package #4304

Closed
wants to merge 1 commit into from

Conversation

rglidden
Copy link
Contributor

rpmbuild strips executables by default when generating an rpm packge. This was causing the JavaScript code bundled in the etcher-util file to be removed, causing "Pkg: Error reading from file." whenever etcher-util was called.

This in turn caused balena-etcher to generate the error message Error: (0, h.requestMetadata) is not a function when attempting to write an SD card.

This fixes the issue for RPM builds by replacing the strip command with true so that rpmbuild no longer strips the executables and the embeded code stays intact.

See: #4150

rpmbuild strips executables by default when generating an rpm packge.
This was causing the JavaScript code bundled in the etcher-util file
to be removed, causing "Pkg: Error reading from file." whenever
etcher-util was called.

This in turn caused balena-etcher to generate the error message
`Error: (0, h.requestMetadata) is not a function` when attempting
to write an SD card.

This fixes the issue for RPM builds by replacing the `strip` command
with `true` so that rpmbuild no longer strips the executables and
the embeded code stays intact.

See: balena-io#4150

Signed-off-by: Richard Glidden <[email protected]>
@rglidden rglidden changed the title fix: etcher-util is corrupted in RPM package patch: etcher-util is corrupted in RPM package Aug 31, 2024
@aethernet
Copy link
Contributor

aethernet commented Oct 9, 2024

Thanks @rglidden. It's very much appreciated.
I've cherry picked it in #4333 as it touches workflows.

@aethernet aethernet closed this Oct 9, 2024
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

Successfully merging this pull request may close these issues.

2 participants