[KDE/Mac] Thoughts on standard directories in Qt5 - QStandardPaths

Marko Käning mk-lists at email.de
Tue Dec 23 09:34:08 UTC 2014

Hi David,

On 23 Dec 2014, at 09:42 , David Faure <faure at kde.org> wrote:

> On Monday 22 December 2014 20:56:57 René J.V. Bertin wrote:
>> Those almost certainly find their stuff because it's in the proper location
>> w.r.t. the install prefix, as your question implies already.
> I doubt that. Any code that looks up mimetypes using the freedesktop shared-
> mime-info spec, is supposed to look into $XDG_DATA_DIRS, which defaults to 
> /usr/share;/usr/local/share.
> That's unrelated to the install prefix of the app.

ok, but:

> So if shared-mime-info is installed elsewhere, apps need that env var, to find 
> it.
> Can one of you install shared-mime-info with MacPorts and watch where it gets 
> installed? And if not in /usr/share or /usr/local/share, can you check if 
> $XDG_DATA_DIRS is set?

It is installed here on my OSX/CI system and its files are in MacPorts’ standard
location /opt/local/:
$ port installed shared-mime-info
The following ports are currently installed:
  shared-mime-info @1.3_0 (active)
$ port contents shared-mime-info
Port shared-mime-info contains:
MVM2:scripts marko$ 
and are found by the OSX/CI system no problem.

I have on this system currently no other ports installed which need this port, but on a KDE4
system e.g. kdelibs4 needs it as a dependency, like SO MANY other ports for also e.g. Gnome,
Perl, etc...

For KDE4 I figure the kde4 or qt4 PortGroups [1,2] define all the necessary cmake variables
which do the magic necessary for letting the apps find shared-mime-info’s files.

	So, THIS is NOT about setting the XDG_DATA_DIRS var here at all!

The MacPorts-prefix /opt/local is being taken care of in all individual ports installed
through the MacPorts-infrastructure. If not, than it is usually an indication of a miswritten


[1] http://trac.macports.org/browser/trunk/dports/_resources/port1.0/group/kde4-1.1.tcl
[2] http://trac.macports.org/browser/trunk/dports/_resources/port1.0/group/cmake-1.0.tcl

More information about the kde-mac mailing list