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

chore(maker-rpm): map arm64 -> aarch64 #3137

Merged
merged 1 commit into from
Feb 7, 2023
Merged

chore(maker-rpm): map arm64 -> aarch64 #3137

merged 1 commit into from
Feb 7, 2023

Conversation

dsanders11
Copy link
Member

Summarize your changes:

The canonical name used by the rpm package is aarch64. The current behavior of leaving the name arm64 unmapped can lead to subtle behavior differences, since during the RPM building process, the platform name is used for matching against macros under /usr/lib/rpm/platform/<platform>/macros, and the platform name there is aarch64-linux. Mapping to aarch64 also ensures that the behavior of --arch=arm64 is the same as running on a Linux Arm64 machine, where uname will be returning aarch64, not arm64.

Note that this does change the extension of the final RPM to *.aarch64.rpm instead of *.arm64.rpm.

@dsanders11 dsanders11 requested a review from a team January 11, 2023 20:55
Copy link
Member

@malept malept left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Eventually all of this logic should be upstreamed, but for now this looks fine.

@malept
Copy link
Member

malept commented Jan 12, 2023

There is one thing I'm worried about - changing the default filename seems like a breaking change since that would cause a lot of churn for projects using Forge and generating RPMs. I would suggest avoiding this change and making the break when we decide to release v7.

@dsanders11
Copy link
Member Author

Good point @malept, will certainly result in some issues if the name changes. Maybe for now I can update this PR to provide a rename function for electron-install-redhat (ref packages/maker/rpm/src/MakerRpm.ts#L46) to avoid the name change on the resulting RPM.

@dsanders11 dsanders11 marked this pull request as draft January 15, 2023 01:31
@dsanders11 dsanders11 marked this pull request as ready for review January 16, 2023 04:49
@dsanders11
Copy link
Member Author

@malept, I've updated this PR to use the rename option to keep the name of the RPM the same, ending with .arm64.rpm. The architecture of the RPM if you inspect it (rpm -qip foo.arm64.rpm) says aarch64 now instead of arm64, but I don't think that's enough of a concern to force this to be a breaking change.

@erickzhao erickzhao merged commit fd9de41 into main Feb 7, 2023
@erickzhao erickzhao deleted the rpm-maker-aarch64 branch February 7, 2023 00:31
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.

3 participants