~vcs-imports/kupfer/master-new

« back to all changes in this revision

Viewing changes to auxdata/wscript

  • Committer: Ulrik Sverdrup
  • Date: 2011-04-07 03:48:03 UTC
  • Revision ID: git-v1:e2e56d852ff5a08966fda76f0c27321d04892d4a
Install kupfer.desktop as a Thunar/sendto object

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#! /usr/bin/env python
 
2
import os
2
3
 
3
4
from waflib import Options, Utils, Logs
4
5
 
23
24
        # merge translations into the .desktop file
24
25
        # and set it up to be installed
25
26
        def install_desktop_file(desktop_subst_file):
26
 
                bld(
 
27
                return bld(
27
28
                        features="intltool_in",
28
29
                        podir="../po",
29
30
                        flags = ("-d", "-q", "-u", "-c"),
33
34
                        chmod = 0o755,
34
35
                )
35
36
 
36
 
        install_desktop_file("kupfer.desktop")
37
 
        install_desktop_file("kupfer-exec.desktop")
 
37
        k_desktop = install_desktop_file("kupfer.desktop")
 
38
        x_desktop = install_desktop_file("kupfer-exec.desktop")
 
39
 
 
40
        ## install kupfer.desktop as a Thunar sendto object
 
41
        kd_install = os.path.join(
 
42
                Utils.subst_vars(k_desktop.install_path, bld.env), "kupfer.desktop")
 
43
        symlink_location = \
 
44
                Utils.subst_vars("${DATADIR}/Thunar/sendto/kupfer.desktop", bld.env)
 
45
        symlink_target = \
 
46
                os.path.relpath(kd_install, os.path.dirname(symlink_location))
 
47
        bld.symlink_as(symlink_location, symlink_target)
38
48
 
39
49
        ## install mimetype descriptions
40
50