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

Add support to specify build architecture for deb release #123

Closed
wants to merge 2 commits into from

Conversation

animator
Copy link
Contributor

@animator animator commented May 6, 2023

Fix for Linux deb packager highlighted in #116

Users can now specify build architecture - arm64, amd64 (default if not specified)
in the make_config.yaml file via build_arch option (same option name as used by rpm maker)

Tested it by building foss42/api-dash linux builds.

@animator
Copy link
Contributor Author

animator commented May 7, 2023

No idea why lint / format (pull_request) failed 🤷🏻‍♀️

@lijy91
Copy link
Member

lijy91 commented May 7, 2023

I think the arch should not be specified by the user, but should be obtained from the current system, just like this.

String get arch {
if (_arch == null) {
ProcessResult r = Process.runSync('uname', ['-m']);
if ('${r.stdout}'.trim() == 'aarch64') {
_arch = 'arm64';
} else {
_arch = 'x64';
}
}
return _arch!;
}

@animator
Copy link
Contributor Author

animator commented May 7, 2023

The reason I took this route is because it requires minimum code changes and gives more control to the user as arm64 and amd64 are just two architectures, there are plenty more which the current getter in builders/linux/build_linux_result.dart does not handle. Let me know your thoughts.

@animator animator closed this May 19, 2023
@animator animator deleted the deb-arm64-fix branch May 19, 2023 11:14
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