Page MenuHomePhabricator

build: skip deploying plugins we dont use in macdeployqtplus
ClosedPublic

Authored by Fabien on Oct 16 2020, 18:30.

Details

Summary
I frequently run make deploy while testing on macOS to get a properly
light themed .app. With a brew installed Qt, this currently results in a
pretty bloated executable:
branch 	.app size 	.dmg size 	make deploy time
master (febf3a8) 	235mb 	86mb 	38s
This PR (da98f6d) 	51mb 	21mb 	22s

Similar change to dd367ff.

                         'QtGui.framework'],
  'pluginPath': '/usr/local/opt/qt/plugins',
  'qtPath': '/usr/local/opt/qt'}
-[('platforminputcontexts', 'libqtvirtualkeyboardplugin.dylib'),
- ('geoservices', 'libqtgeoservices_esri.dylib'),
- ('geoservices', 'libqtgeoservices_mapboxgl.dylib'),
- ('geoservices', 'libqtgeoservices_nokia.dylib'),
- ('geoservices', 'libqtgeoservices_itemsoverlay.dylib'),
- ('geoservices', 'libqtgeoservices_osm.dylib'),
- ('geoservices', 'libqtgeoservices_mapbox.dylib'),
- ('sceneparsers', 'libgltfsceneexport.dylib'),
- ('sceneparsers', 'libgltfsceneimport.dylib'),
- ('platforms', 'libqwebgl.dylib'),
+[('platforms', 'libqwebgl.dylib'),
  ('platforms', 'libqoffscreen.dylib'),
  ('platforms', 'libqminimal.dylib'),
  ('platforms', 'libqcocoa.dylib'),
  ('platformthemes', 'libqxdgdesktopportal.dylib'),
- ('printsupport', 'libcocoaprintersupport.dylib'),
- ('webview', 'libqtwebview_webengine.dylib'),
- ('webview', 'libqtwebview_darwin.dylib'),
- ('geometryloaders', 'libdefaultgeometryloader.dylib'),
- ('geometryloaders', 'libgltfgeometryloader.dylib'),
  ('styles', 'libqmacstyle.dylib'),
- ('canbus', 'libqttinycanbus.dylib'),
- ('canbus', 'libqtpassthrucanbus.dylib'),
- ('canbus', 'libqtvirtualcanbus.dylib'),
- ('canbus', 'libqtpeakcanbus.dylib'),
  ('bearer', 'libqgenericbearer.dylib'),
- ('imageformats', 'libqgif.dylib'),
- ('imageformats', 'libqwbmp.dylib'),
- ('imageformats', 'libqwebp.dylib'),
- ('imageformats', 'libqico.dylib'),
- ('imageformats', 'libqmacheif.dylib'),
- ('imageformats', 'libqjpeg.dylib'),
- ('imageformats', 'libqtiff.dylib'),
- ('imageformats', 'libqicns.dylib'),
- ('imageformats', 'libqtga.dylib'),
- ('imageformats', 'libqmacjp2.dylib'),
- ('texttospeech', 'libqtexttospeech_speechosx.dylib'),
- ('generic', 'libqtuiotouchplugin.dylib'),
- ('renderplugins', 'libscene2d.dylib'),
- ('gamepads', 'libdarwingamepad.dylib'),
- ('virtualkeyboard', 'libqtvirtualkeyboard_thai.dylib'),
- ('virtualkeyboard', 'libqtvirtualkeyboard_openwnn.dylib'),
- ('virtualkeyboard', 'libqtvirtualkeyboard_hangul.dylib'),
- ('virtualkeyboard', 'libqtvirtualkeyboard_pinyin.dylib'),
- ('virtualkeyboard', 'libqtvirtualkeyboard_tcime.dylib')]
+ ('generic', 'libqtuiotouchplugin.dylib')]

Backport of core PR16477.

Test Plan

On OSX:

ninja osx-dmg

On my machine the DMG was ~89MB and is now ~21MB.

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Fabien requested review of this revision.Oct 16 2020, 18:30
deadalnix added a subscriber: deadalnix.

There is a linter for most of this, making sure it run over this would be a plus.

This revision is now accepted and ready to land.Oct 16 2020, 19:32

@deadalnix The script was skipped by the linter because it has no .py extension. I will add it in a follow up.