bisq-network / bisq

A decentralized bitcoin exchange network
https://bisq.network
GNU Affero General Public License v3.0
4.64k stars 1.26k forks source link

Reduce bundled javacv library size #7166

Closed devinbileck closed 1 week ago

devinbileck commented 1 week ago

With the introduction of the javacv library when re-adding the QR code scanner feature for mobile notification pairing in #7050, the Bisq binary increased to nearly 1 GB from its previous size of around 300 MB.

When including the javacv-platform dependency, it pulls in binaries for all platforms. But it is possible to limit this by utilizing the gradle-javacpp platform plugin which by default will pull in binaries only for the current platform.

Reference: https://github.com/bytedeco/gradle-javacpp#the-platform-plugin

With this change, the included libs went from ~980 MB down to ~366 MB.