clementine-player / Clementine

:tangerine: Clementine Music Player
https://www.clementine-player.org/
GNU General Public License v3.0
3.75k stars 676 forks source link

make dbus and devicekit optional #1177

Closed Clementine-Issue-Importer closed 10 years ago

Clementine-Issue-Importer commented 10 years ago

From Nickollai on December 25, 2010 16:44:06

Every new version of clementine has a lot new not optional features what make binary size bigger and bigger. Ability for building lightweight Qt4 player with collection and nothing additional would be great.

Sizes of /usr/bin/clementine (disabled all optional features): 0.6 5123 +24,4 % (without liblastfm) 0.5.3 4117 +5,8 % 0.4.2 3893 +15,3 % 0.3 3375

Sizes of clementine-0.6_build/src/CMakeFiles/clementine_lib.dir/ dirs after "rm find -type f|grep -v '.o$'": 76 qrc_translations.cxx.o 228 transcoder 240 analyzers 244 dbus 296 engines 304 playlistparsers 540 smartplaylists 608 songinfo 840 devices 864 qrc_data.cxx.o 1088 radio 1108 library 1132 widgets 1308 playlist 1376 ui 1764 core

Please add cmake options for disabling: devicekit (Also solves 'Error connecting to the DeviceKit-disks DBUS service' console messages problem for system without udisks.) devices dbus (+mpris) extras (ultimate)lyrics radio (internet) smartplaylists transcoder

Attached patch makes dbus, mpris and DeviceKit optional, for patching 0.6 you need to apply 'clementine-0.6-optional-liblastfm.patch' first.

Attachment: clementine-0.6-optional-dbus-devicekit.patch

Original issue: http://code.google.com/p/clementine-player/issues/detail?id=1177

Clementine-Issue-Importer commented 10 years ago

From davidsansome on December 25, 2010 07:49:57

Seriously? We're talking about two megabytes here...

Clementine-Issue-Importer commented 10 years ago

From Nickollai on December 25, 2010 07:59:56

Seriously? Yes :) We're talking about two megabytes here... Not about just 2 MB, but about making binary size 2 or 3 times smaller.

Clementine-Issue-Importer commented 10 years ago

From keirangtp on December 25, 2010 09:17:45

The problem is not adding this now but later modifying any of this funcionalities - each and every time you need to think whether the change will work in the reduced environment.

My vote is no - maybe you should look for another player instead - something really lightweight?

Oh - no devicekit sounds ok if it removes some runtime warnings.

Clementine-Issue-Importer commented 10 years ago

From Nickollai on December 25, 2010 10:46:17

The problem is not adding this now but later modifying any of this
funcionalities - each and every time you need to think whether the change
will work in the reduced environment.

1) What size will have /usr/bin/clementine in 3 years if everything will go like in last release? Approximately: release every 3 months, every version is 25% bigger, current size is 5 MB. 5_(1,25^(4_3))=73 MB Do you really think it is good idea? 2) Look at other media projects: ffmpeg, mplayer, vlc, gstreamer are modular, have a lot build options and are ported to many platforms. Having small, stable, portable and well tested core with optional modules makes porting to new software or hardware platforms and turning for different tasks much easier.

My vote is no - maybe you should look for another player instead -
something really lightweight?

I like clementine, it works fine, is enough stable and already habitual for me. Also I spent quite a few time for turning build system and packaging for my distro. Now clementine is not heavy or bloated, but I am afraid it may become so in near future.

Oh - no devicekit sounds ok if it removes some runtime warnings

My patch will not create problems or make further development harder: dbus is already optional (disabled on mac and win), mostly I just renamed '#ifdef Q_WS_X11' to '#ifdef HAVE_DBUS'. May be you can apply it?

Clementine-Issue-Importer commented 10 years ago

From keirangtp on December 26, 2010 05:37:20

That's David's decision. But if we do this, we should probably build the mini version on buildbot too. Mostly, to see if everything compiles OK on a revision-by-revision basis.

Clementine-Issue-Importer commented 10 years ago

From davidsansome on December 26, 2010 05:37:47

So in three years we'll be just about catching up to iTunes? :p Also while I do hope our growth will be exponential as you suggest I think it's more realistic to expect it to be constant, putting the size in three years at 7.1 MB.

I'll accept your dbus patch because it has to be conditional anyway. But I consider the other stuff you mentioned core functionality. It also comes with no runtime cost - everything is lazy loaded so there's no delay at startup from having that stuff in there (if there is it's a bug and should be fixed). So just don't use it - if you don't like looking at it in the UI stick a post-it on your monitor to cover it up. If you can't afford the 5 MB disk space then I suggest you may have other troubles :p

Clementine-Issue-Importer commented 10 years ago

From davidsansome on December 26, 2010 05:38:43

This issue was closed by revision r2497 .

Status: Fixed

Clementine-Issue-Importer commented 10 years ago

From keirangtp on December 26, 2010 05:47:52

Summary: make dbus and devicekit optional
Labels: Milestone-0.7

Clementine-Issue-Importer commented 10 years ago

From vastone on December 26, 2010 09:05:06

Dbus/Mpris is now disabled on SVN 2499 (since 2497) and I understand that it has been set as an option to enable/disable. Where, when or how do you re enable it? I do not see it in the options..

Clementine-Issue-Importer commented 10 years ago

From keirangtp on December 26, 2010 09:14:10

It should be enabled by default - are you sure it's not?

Clementine-Issue-Importer commented 10 years ago

From vastone on December 26, 2010 09:22:54

Using D-Feet Dbus Debugger , org.mpris.clementine is not there at all verifying it is not loaded

Clementine-Issue-Importer commented 10 years ago

From keirangtp on December 26, 2010 10:33:48

What about the newest revisions? David made some changes there.

Clementine-Issue-Importer commented 10 years ago

From vastone on December 26, 2010 10:38:50

Confirmed - 2501 corrected the issue