source: trunk/debathena/config/gdm-config/debian/rules @ 25396

Revision 25396, 2.8 KB checked in by geofft, 13 years ago (diff)
In gdm-config: * Support Debian's gdm3 package (Trac: #976). * Fix typos caught by Lintian and do some other cleanup.
  • Property svn:executable set to *
Line 
1#!/usr/bin/make -f
2
3GDM_VERSION = $(shell dpkg-query --showformat='$${Version}' --show gdm)
4GDM3_VERSION = $(shell dpkg-query --showformat='$${Version}' --show gdm3)
5ifneq ($(GDM3_VERSION),)
6    gdm = gdm3
7    NEW_GDM = y
8else
9    gdm = gdm
10    NEW_GDM = $(shell dpkg --compare-versions $(GDM_VERSION) ge '2.25.2~' && echo y)
11endif
12CDBS_BUILD_DEPENDS += $(gdm)
13
14binary-predeb/debathena-gdm-config:: debathena-gdm-config-substvars
15debathena-gdm-config-substvars::
16        echo "debathena-gdm=$(gdm)" \
17            >> debian/debathena-gdm-config.substvars
18
19ifneq ($(wildcard /etc/gdm/gdm.conf-custom),)
20    GDM_CONFFILE = /etc/gdm/gdm.conf-custom.debathena
21    DEB_DH_LINK_ARGS_debathena-gdm-config=/etc/gdm/gdm.conf-custom.debathena /etc/gdm/gdm.conf.debathena
22else
23    GDM_CONFFILE = /etc/gdm/gdm.conf.debathena
24endif
25
26DEB_DIVERT_EXTENSION = .debathena
27DEB_TRANSFORM_SCRIPT_${GDM_CONFFILE} = debian/transform_gdm.conf.debathena
28DEB_DIVERT_FILES_debathena-gdm-config += \
29        /etc/$(gdm)/PreSession/Default.debathena \
30        /etc/$(gdm)/PostSession/Default.debathena
31DEB_REMOVE_FILES_debathena-gdm-config += \
32        /usr/share/xsessions/ssh.desktop
33
34ifneq ($(NEW_GDM),y)
35    DEB_TRANSFORM_FILES_debathena-gdm-config += \
36        ${GDM_CONFFILE}
37    DEB_DIVERT_FILES_debathena-gdm-config += \
38        /usr/share/gdm/BuiltInSessions/default.desktop.debathena
39endif
40
41include /usr/share/cdbs/1/rules/debhelper.mk
42include /usr/share/cdbs/1/rules/config-package.mk
43
44common-build-indep:: debathena/distro.svg
45
46debathena/distro.svg: debian/distro.svg.sh
47        sh $< > $@
48
49install/debathena-gdm-config::
50        dh_install debian/PreSession/Default.debathena etc/$(gdm)/PreSession
51        dh_install debian/PostSession/Default.debathena etc/$(gdm)/PostSession
52
53ifneq ($(NEW_GDM),y)
54    install/debathena-gdm-config::
55        dh_install debian/default.desktop.debathena usr/share/gdm/BuiltInSessions
56else
57    install/debathena-gdm-config::
58        dh_install debian/background.jpg usr/share/debathena-gdm-config
59        dh_install debian/%gconf-tree.xml var/lib/$(gdm)/.gconf.debathena-gdm-config
60        dh_install debian/athena.desktop usr/share/xsessions
61        dh_install debian/athena-session usr/bin
62
63        install -m 660 debian/gconf.path.debathena debian/$(cdbs_curpkg)/var/lib/$(gdm)/.gconf.path.debathena
64        dh_install debian/debathena-branding usr/lib/debathena-branding
65        dh_install debian/debathena-branding.glade usr/share/debathena-branding
66        dh_install debian/debathena-branding.desktop usr/share/gdm/autostart/LoginWindow
67        dh_install debian/debathena-nologin-monitor usr/lib/debathena-nologin-monitor
68        dh_install debian/debathena-nologin-monitor.desktop usr/share/gdm/autostart/LoginWindow
69
70    debathena-gdm-config-substvars::
71        echo "debathena-gdm-gconf-depends=debathena-gconf2-config (>= 1.8~)" \
72            >> debian/debathena-gdm-config.substvars
73
74    install/debathena-gdm-config::
75        dh_gconf --priority 90
76endif
77
78clean::
79        -rm debathena/distro.svg
Note: See TracBrowser for help on using the repository browser.