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

Build: Mac: Fix universal build to contain both archs #2825

Merged

Conversation

hoffie
Copy link
Member

@hoffie hoffie commented Aug 29, 2022

Short description of changes

  • Build: Mac: Fix universal build to contain both archs

    One of the last-minute changes broke the universal build and resulted in a universal build which only contained a single architecture. The reason was that the added distclean action removed the artifact for the first architecture.

    This change moves the intermediate artifacts to a temporary, already defined directory which is definitely not touched by make distclean.

  • Build: Mac: Fail if universal build lacks an expected architecture

    This should prevent any silent build failures result in an incomplete output.

CHANGELOG: Build: Mac: Combined Intel & M1 builds into a single Universal binary and improved M1 -dev build user-friendliness by introducing ad-hoc signing support

Context: Fixes an issue?

Related: #2808 (comment)
Related: #2808 (comment)

Does this change need documentation? What needs to be documented and how?
No.

Status of this Pull Request

What is missing until this pull request can be merged?
Confirmation by @ann0see (Logs look good).

Checklist

One of the last-minute changes broke the universal build and resulted in
a universal build which only contained a single architecture.
The reason was that the added `distclean` action removed the artifact
for the first architecture.

This change moves the intermediate artifacts to a temporary, already
defined directory which is definitely not touched by `make distclean`.

Related: jamulussoftware#2808 (comment)
Related: jamulussoftware#2808 (comment)
@hoffie hoffie added this to the Release 3.9.1 milestone Aug 29, 2022
@hoffie hoffie requested a review from ann0see August 29, 2022 21:14
This should prevent any silent build failures result in an incomplete
output.
@hoffie hoffie force-pushed the autobuild-fix-mac-universal-build branch from 8c06d6b to c9c18f1 Compare August 29, 2022 21:16
file_output=$(file "${build_path}/${target_name}.app/Contents/MacOS/${target_name}")
echo "${file_output}"
for target_arch in "${target_archs_array[@]}"; do
if ! grep -q "for architecture ${target_arch}" <<< "${file_output}"; then
Copy link
Collaborator

Choose a reason for hiding this comment

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

Oooh, hairy bash.

Copy link
Member

@ann0see ann0see left a comment

Choose a reason for hiding this comment

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

Works as expected now (on Intel Mac)

@ann0see ann0see merged commit 4c55c39 into jamulussoftware:master Aug 30, 2022
This pull request was closed.
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