-
Notifications
You must be signed in to change notification settings - Fork 37.7k
build: mac deployment unification #20422
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
Conversation
Concept ACK |
🐙 This pull request conflicts with the target branch and needs rebase. Want to unsubscribe from rebase notifications on this pull request? Just convert this pull request to a "draft". |
35bb751
to
cdc84c0
Compare
It's a bug. Looks like they tried to spread the expression over multiple lines but forgot to either add parenthesis around the tuple or https://github.com/al45tair/mac_alias/blob/master/mac_alias/alias.py#L282 Edit: created an upstream issue dmgbuild/mac_alias#9 |
Concept ACK! |
Rather than using OSX_QT_TRANSLATIONS which must be manually updated, and we forget to update anyway, i.e: bitcoin#19059, automatically find and copy available translations from the translations directory.
4 different levels of verbosity is overkill for a fairly simple script, which was always being run at 2 in any case.
We already require Python 3.5 or later
Rather than two lots of logic doing roughly the same thing, dependent on if you're compiling on Linux or macOS, combine the .DS store generation into macdeployqtplus. This also removes the -fancy and -volname options.
cdc84c0
to
5d2cbdf
Compare
Great, thanks. The upstream issue has been resolved with the release of mac_alias 2.1.1. I've added an additional commit to this PR to switch to that version in depends. I've also updated the PR description to remove no-longer-relevant info. This PR should now be ready for review. |
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.
ACK b685f60 - Less and cleaner code looks good. I tested this with make deploy
and everything still works + the popup during DMG generation is gone.
@@ -16,9 +16,13 @@ | |||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
# | |||
|
|||
import subprocess, sys, re, os, shutil, stat, os.path, time | |||
from string import Template | |||
import plistlib |
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.
This import was only used by the -fancy
option and could also be removed since it is now unused.
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.
Good catch. However I'm going to merge this now, and we'll take care of the leftover import shortly.
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.
utACK. I don't have an Apple Developer account so can't get the SDK to test with I'm afraid.
Tested (via master) on macOS and it seems to work. We should add an instruction before
|
Unused since bitcoin#20422, see: bitcoin#20422 (comment)
a68c7d5 depends: mac_alias 2.2.0 (fanquake) d8e2baf doc: Add explicit macdeployqtplus dependencies install step (Hennadii Stepanov) 013305d macdeploy: use Python 3.6 (fanquake) faf77c3 macdeploy: remove runHDIUtil in favor of directly calling subprocess.run (fanquake) 8bcfd58 macdeploy: remove existing PIVX-Core.dmg if present (fanquake) 023d3ca macdeploy: move qt_conf to where it's used (fanquake) 7cdb5bb macdeploy: consolidate .DS_Store generation (fanquake) 4da04d7 macdeploy: assume plistlib is available (fanquake) 56ab77a macdeploy: have a single level of logging output (fanquake) d111cdf macdeploy: remove add-resources argument (fanquake) 4312410 macdeploy: remove codesigning argument (fanquake) c2ee635 build: automatically determine macOS translations (fanquake) 1c44ecf scripts: filter more qt plugins we don't use in macdeployqtplus (fanquake) c854f78 scripts: misc cleanups in macdeployqtplus (fanquake) a3873ea scripts: use format() in macdeployqtplus (fanquake) a65bea5 scripts: add type annotations to macdeployqtplus (fanquake) ba179e5 build: Drop macports support (Ben Woosley) Pull request description: This is a companion to PIVX-Project#2272 that focuses on on the `.dmg` creation aspect of macOS builds (ie, `make deploy`). The following upstream PRs are backported here: - bitcoin#15175 - bitcoin#16477 - bitcoin#20422 - bitcoin#20890 - bitcoin#21658 Also worth mentioning: This drops support for MacPorts entirely, which has been antiquated and un-maintained for quite some time, and never actually used by any PIVX macOS build doc. ACKs for top commit: furszy: Tested using depends, ACK a68c7d5. random-zebra: utACK a68c7d5 and merging... Tree-SHA512: 3e9fa81a905ca3e90f07ff1213ec69dd1220a19a6a215f256ab67f2594476dc95e8fe88f15a1c9f3314b1757a7a2e5d8e6d7a790d85c117bf4236a3833757430
0a5723b macdeploy: cleanup .temp.dmg if present (fanquake) ecffe86 macdeploy: remove qt4 related code (fanquake) 639f064 macdeploy: select the plugins we need, rather than excluding those we don't (fanquake) 3d26b6b macdeploy: fix framework printing when passing -verbose (fanquake) dca6c90 macdeploy: remove unused plistlib import (fanquake) Pull request description: This includes [one followup](#20422 (comment)) and [one bug fix](3d26b6b) from #20422, as well as some simplifications to the `macdeployqtplus` code. ACKs for top commit: hebasto: ACK 0a5723b, tested on macOS Big Sur 11.4 (20F71, x86_64) + Homebrew's Qt 5.15.2. Tree-SHA512: cfad9505eacd32fe3a9d06eb13b2de0b6d2cad7b17778e90b503501cbf922e53d4e7f7f74952d1aed58410bdae9b0bb3248098583ef5b85689cb27d4dc06c029
Unused since bitcoin#20422, see: bitcoin#20422 (comment)
Unused since #20422, see: bitcoin/bitcoin#20422 (comment)
0a5723b macdeploy: cleanup .temp.dmg if present (fanquake) ecffe86 macdeploy: remove qt4 related code (fanquake) 639f064 macdeploy: select the plugins we need, rather than excluding those we don't (fanquake) 3d26b6b macdeploy: fix framework printing when passing -verbose (fanquake) dca6c90 macdeploy: remove unused plistlib import (fanquake) Pull request description: This includes [one followup](bitcoin#20422 (comment)) and [one bug fix](bitcoin@3d26b6b) from bitcoin#20422, as well as some simplifications to the `macdeployqtplus` code. ACKs for top commit: hebasto: ACK 0a5723b, tested on macOS Big Sur 11.4 (20F71, x86_64) + Homebrew's Qt 5.15.2. Tree-SHA512: cfad9505eacd32fe3a9d06eb13b2de0b6d2cad7b17778e90b503501cbf922e53d4e7f7f74952d1aed58410bdae9b0bb3248098583ef5b85689cb27d4dc06c029
It appears this PR breaks
Newer macOS versions—10.15 and 11.x—are not affected. |
This looks like an intermittent issue, and I would be somewhat surprised if the changes here worked on macOS 10.15 but not 10.14. I don't think there's anything we're doing that would be specific to the OS, or a certain version of a tool, like Does |
Yes, it does. I think @jarolrod could also confirm such behavior?
Me too. |
Unused since #20422, see: bitcoin/bitcoin#20422 (comment)
This consolidates our macOS build code so that
.DS_Store
generation is the same when runningmake deploy
for macOS when building on Linux and macOS, rather than maintaining two version of code that essentially do the same thing (just slightly differently).It also removes unused code and any AppleScript usage, automates finding translation files and generally simplifies
macdeployqtplus
. It also gets rid of the annoying "popping up" behaviour during DMG generation, names the created imageBitcoin-Core.dmg
rather thanBitcoin-Qt.dmg
.