Note that `src/Makefile` is written in such a way that the Vim icons are
not installed in case the following directories don't exist:
```
ICON48PATH = $(DESTDIR)$(DATADIR)/icons/hicolor/48x48/apps
ICON32PATH = $(DESTDIR)$(DATADIR)/icons/locolor/32x32/apps
ICON16PATH = $(DESTDIR)$(DATADIR)/icons/locolor/16x16/apps
```
Vim's build system won't create those directories currently.

Before doing actual installation, Patch 7.4.904 should have checked the
existence of the destination directory for `*.desktop` in a way similar to
icons, because, if no icons are installed, `*.desktop` will be of little
use.

I think the current icon installation policy (no destination, no
installation) is reasonable.  After all, it's up to distributors and
administrators where to install `*.desktop`s and how to set `XDG_DATA_DIRS`
accordingly.

2015-11-03 16:06 GMT+09:00 lilydjwg <[email protected]>:

> On Tue, Nov 03, 2015 at 07:37:33AM +0100, Tony Mechelynck wrote:
> > [...]
> >
> > in /etc/profile maybe, or in some other script sourced by all shells?
> > Ah, there: /etc/profile.d/xdg-environment.sh and
> > /etc/profile.d/xdg-environment.csh (which IIUC are sourced by some
> > other shell startup script): here are the lines I have in the .sh
> > script:
>
> I'm on Arch Linux and I don't have the environment variable
> $XDG_DATA_DIRS set. I only have a $XDG_RUNTIME_DIR set by systemd.
>
> I get that setting from python-xdg, from this code snippet:
>
> _home = os.path.expanduser('~')
> xdg_data_home = os.environ.get('XDG_DATA_HOME') or \
>             os.path.join(_home, '.local', 'share')
>
> xdg_data_dirs = [xdg_data_home] + \
>     (os.environ.get('XDG_DATA_DIRS') or
> '/usr/local/share:/usr/share').split(':')
>
> It seems that it's getting a default value, but with one more than the
> Freedesktop.org spec.
>
> I've checked the source of the awesome window manager, it always uses
> a similiar default path list, but /usr/local/share comes last (maybe this
> should be fixed).
>
> > > And I don't think a script can
> > > determine it automatically when e.g. someone wants to install Vim to
> > > /opt and has that file placed where they want.
> >
> > /opt/*/share is among the places where my shells will look at startup
> > for an applications/ subdirectory, see above.
>
> However, it seems to me that $prefix/share/applications is a good
> default if the script is going to install .desktop files, rather than
> check $XDG_DATA_DIRS and pick one up. The user can move / link the files
> if necessary, or perhaps another ./configure option?
>
> --
> Best regards,
> lilydjwg
>
> --
> --
> You received this message from the "vim_dev" maillist.
> Do not top-post! Type your reply below the text you are replying to.
> For more information, visit http://www.vim.org/maillist.php
>
> ---
> You received this message because you are subscribed to the Google Groups
> "vim_dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui