-
-
Notifications
You must be signed in to change notification settings - Fork 136
ARM: native build support #754
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
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for this! Leaving few comments, I don't test this yet though.
case "$ARCH" in | ||
amd64|i386) | ||
MIRROR_BINARY_URL="http://archive.ubuntu.com/ubuntu/" | ||
MIRROR_BINARY_SECURITY_URL="http://security.ubuntu.com/ubuntu/" | ||
;; | ||
arm64) | ||
MIRROR_BINARY_URL="http://ports.ubuntu.com/ubuntu-ports/" | ||
MIRROR_BINARY_SECURITY_URL="http://ports.ubuntu.com/ubuntu-ports/" | ||
;; | ||
esac | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we may want to put these variables into terraform*.conf and remove the case sentence here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand your suggestion; however, MIRROR_URL
currently varies across etc/terraform*.conf
files (official or Azure source), while these MIRROR_BINARY_URL
and MIRROR_BINARY_SECURITY_URL
should use the official source and remain consistent. Moving them into etc/terraform*.conf
files would introduce duplication, conflicting with the single source of truth principle.
@@ -0,0 +1,33 @@ | |||
# target architecture - i386, amd64 or all |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we release stable arm64 images soon because it needs testing, could you rename this file to etc/terraform-daily-8.0-arm64.conf
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also you should update the comment i386, amd64 or all
in terraform*.conf.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe etc/terraform-arm64.conf
(similar to etc/terraform.conf
) is intended for local builds and testing. Perhaps I should add a etc/terraform-daily-8.0-arm64.conf
to align with etc/terraform-daily-8.0-azure.conf
?
VERSION="8.0" | ||
|
||
# distribution channel | ||
CHANNEL="stable" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CHANNEL="stable" | |
CHANNEL="daily" |
Based on etc/terraform-daily-8.0-azure.conf
MIRROR_URL="http://ports.ubuntu.com/ubuntu-ports/" | ||
|
||
# use HWE kernel and packages? | ||
HWE_KERNEL="yes" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
HWE_KERNEL="yes" | |
HWE_KERNEL="no" |
Based on etc/terraform-daily-8.0-azure.conf
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm a bit confused about the configuration here. I noticed that daily builds are set with HWE_KERNEL="no"
, while stable builds use HWE_KERNEL="yes"
. Could you clarify the reasoning behind this?
For ARM64 specifically, since mainline kernel support for most hardware is still a work in progress, the HWE kernel may perform better.
I think this is because the installer is only built for amd64 at the moment, maybe because we only provide arm64 image for Raspberry Pi and PineBook Pro, which users write images to SD cards directly and don't use the installer. The above file you mentioned is generated from this and it's simply ignored if there is no such package in the each architectures. |
I just copied latest distinst to the patches PPA which should also have support for arm64 |
This PR introduces native ARM64 build support. Related to #682.
Thanks to @t3rminus for the initial attempt.
Current limitations:
live-build
is required.io.elementary.installer
package is currently not included in metapackages/live-arm64, preventing installation to disk.Tested using UTM on Apple Silicon Mac.