~xavi-garcia-mena/ubuntu/vivid/upower/percentages-power-off

« back to all changes in this revision

Viewing changes to src/Makefile.am

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2010-02-16 10:16:24 UTC
  • Revision ID: james.westby@ubuntu.com-20100216101624-2cmwqsr1ndftdd87
Tags: upstream-0.9.0+git20100216.72bb2
ImportĀ upstreamĀ versionĀ 0.9.0+git20100216.72bb2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
## Process this file with automake to produce Makefile.in
 
2
 
 
3
SUBDIRS = dummy freebsd linux
 
4
 
 
5
INCLUDES = \
 
6
        -I$(top_builddir)/src -I$(top_srcdir)/src               \
 
7
        -DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\"               \
 
8
        -DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\"               \
 
9
        -DPACKAGE_DATA_DIR=\""$(datadir)"\"                     \
 
10
        -DPACKAGE_BIN_DIR=\""$(bindir)"\"                       \
 
11
        -DPACKAGE_LOCALSTATE_DIR=\""$(localstatedir)"\"         \
 
12
        -DPACKAGE_LOCALE_DIR=\""$(localedir)"\"                 \
 
13
        -DPACKAGE_LIB_DIR=\""$(libdir)"\"                       \
 
14
        -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT                 \
 
15
        -DG_UDEV_API_IS_SUBJECT_TO_CHANGE                       \
 
16
        -DUP_COMPILATION                                        \
 
17
        -DUP_DISABLE_DEPRECATED                         \
 
18
        -I$(top_srcdir)/libupower-glib                          \
 
19
        -I$(top_srcdir)/devkit-power-gobject                    \
 
20
        -I$(top_srcdir)                                         \
 
21
        $(GIO_CFLAGS)                                           \
 
22
        $(DBUS_GLIB_CFLAGS)                                     \
 
23
        $(GUDEV_CFLAGS)                                         \
 
24
        $(POLKIT_CFLAGS)                                        \
 
25
        $(GLIB_CFLAGS)
 
26
 
 
27
DEVKIT_POWER_LIBS = $(top_builddir)/devkit-power-gobject/libdevkit-power-gobject.la
 
28
UPOWER_LIBS = $(top_builddir)/libupower-glib/libupower-glib.la
 
29
 
 
30
BUILT_SOURCES =                                                 \
 
31
        up-daemon-glue.h                                        \
 
32
        up-device-glue.h                                        \
 
33
        up-qos-glue.h                                           \
 
34
        up-wakeups-glue.h                                       \
 
35
        up-marshal.h                                            \
 
36
        up-marshal.c
 
37
 
 
38
up-marshal.h: up-marshal.list
 
39
        glib-genmarshal $< --prefix=up_marshal --header > $@
 
40
 
 
41
up-marshal.c: up-marshal.list
 
42
        echo "#include \"up-marshal.h\"" > $@ && glib-genmarshal $< --prefix=up_marshal --body >> $@
 
43
 
 
44
up-daemon-glue.h: org.freedesktop.UPower.xml Makefile.am
 
45
        dbus-binding-tool --prefix=up_daemon --mode=glib-server --output=up-daemon-glue.h org.freedesktop.UPower.xml
 
46
 
 
47
up-device-glue.h: org.freedesktop.UPower.Device.xml Makefile.am
 
48
        dbus-binding-tool --prefix=up_device --mode=glib-server --output=up-device-glue.h org.freedesktop.UPower.Device.xml
 
49
 
 
50
up-qos-glue.h: org.freedesktop.UPower.QoS.xml Makefile.am
 
51
        dbus-binding-tool --prefix=up_qos --mode=glib-server --output=up-qos-glue.h org.freedesktop.UPower.QoS.xml
 
52
 
 
53
up-wakeups-glue.h: org.freedesktop.UPower.Wakeups.xml Makefile.am
 
54
        dbus-binding-tool --prefix=up_wakeups --mode=glib-server --output=up-wakeups-glue.h org.freedesktop.UPower.Wakeups.xml
 
55
 
 
56
libexec_PROGRAMS = upowerd
 
57
 
 
58
dbusifdir = $(datadir)/dbus-1/interfaces
 
59
dbusif_DATA =                                                   \
 
60
        org.freedesktop.UPower.xml                              \
 
61
        org.freedesktop.UPower.Device.xml                       \
 
62
        org.freedesktop.UPower.QoS.xml                          \
 
63
        org.freedesktop.UPower.Wakeups.xml
 
64
 
 
65
upowerd_SOURCES =                                               \
 
66
        egg-debug.c                                             \
 
67
        egg-debug.h                                             \
 
68
        up-polkit.h                                             \
 
69
        up-polkit.c                                             \
 
70
        up-daemon.h                                             \
 
71
        up-daemon.c                                             \
 
72
        up-device.h                                             \
 
73
        up-device.c                                             \
 
74
        up-device-list.h                                        \
 
75
        up-device-list.c                                        \
 
76
        up-qos.h                                                \
 
77
        up-qos.c                                                \
 
78
        up-wakeups.h                                            \
 
79
        up-wakeups.c                                            \
 
80
        up-history.h                                            \
 
81
        up-history.c                                            \
 
82
        up-backend.h                                            \
 
83
        up-native.h                                             \
 
84
        up-main.c                                               \
 
85
        $(BUILT_SOURCES)
 
86
 
 
87
upowerd_CPPFLAGS =                                              \
 
88
        -I$(top_srcdir)/src                                     \
 
89
        -DG_LOG_DOMAIN=\"up-daemon\"                            \
 
90
        $(AM_CPPFLAGS)
 
91
 
 
92
upowerd_LDADD =                                                 \
 
93
        -lm                                                     \
 
94
        $(USB_LIBS)                                             \
 
95
        $(GIO_LIBS)                                             \
 
96
        $(DBUS_GLIB_LIBS)                                       \
 
97
        $(POLKIT_LIBS)                                          \
 
98
        $(UPOWER_LIBS)
 
99
 
 
100
if BACKEND_TYPE_DUMMY
 
101
upowerd_LDADD +=                                                \
 
102
        dummy/libupshared.la
 
103
endif
 
104
 
 
105
if BACKEND_TYPE_FREEBSD
 
106
upowerd_LDADD +=                                                \
 
107
        freebsd/libupshared.la                                  \
 
108
        $(DEVKIT_POWER_LIBS)
 
109
endif
 
110
 
 
111
if BACKEND_TYPE_LINUX
 
112
upowerd_LDADD +=                                                \
 
113
        linux/libupshared.la                                    \
 
114
        $(GUDEV_LIBS)                                           \
 
115
        $(DEVKIT_POWER_LIBS)
 
116
endif
 
117
 
 
118
upowerd_CFLAGS =                                                \
 
119
        $(WARNINGFLAGS_C)                                       \
 
120
        $(NULL)
 
121
 
 
122
if EGG_BUILD_TESTS
 
123
check_PROGRAMS =                                                \
 
124
        up-self-test
 
125
 
 
126
up_self_test_SOURCES =                                          \
 
127
        egg-test.h                                              \
 
128
        egg-test.c                                              \
 
129
        egg-debug.c                                             \
 
130
        egg-debug.h                                             \
 
131
        up-self-test.c                                          \
 
132
        up-polkit.h                                             \
 
133
        up-polkit.c                                             \
 
134
        up-daemon.h                                             \
 
135
        up-daemon.c                                             \
 
136
        up-device.h                                             \
 
137
        up-device.c                                             \
 
138
        up-device-list.h                                        \
 
139
        up-device-list.c                                        \
 
140
        up-qos.h                                                \
 
141
        up-qos.c                                                \
 
142
        up-wakeups.h                                            \
 
143
        up-wakeups.c                                            \
 
144
        up-history.h                                            \
 
145
        up-history.c                                            \
 
146
        up-backend.h                                            \
 
147
        up-native.h                                             \
 
148
        $(BUILT_SOURCES)
 
149
 
 
150
up_self_test_LDADD =                                            \
 
151
        -lm                                                     \
 
152
        dummy/libupshared.la                                    \
 
153
        $(GLIB_LIBS)                                            \
 
154
        $(GIO_CFLAGS)                                           \
 
155
        $(DBUS_GLIB_LIBS)                                       \
 
156
        $(DEVKIT_POWER_LIBS)                                    \
 
157
        $(POLKIT_LIBS)                                          \
 
158
        $(UPOWER_LIBS)
 
159
 
 
160
up_self_test_CFLAGS = -DEGG_TEST $(AM_CFLAGS) $(WARNINGFLAGS_C)
 
161
 
 
162
TESTS = up-self-test
 
163
endif
 
164
 
 
165
servicedir       = $(datadir)/dbus-1/system-services
 
166
service_in_files = org.freedesktop.UPower.service.in
 
167
service_DATA     = $(service_in_files:.service.in=.service)
 
168
 
 
169
$(service_DATA): $(service_in_files) Makefile
 
170
        @sed -e "s|\@libexecdir\@|$(libexecdir)|" $< > $@
 
171
 
 
172
dbusconfdir = $(sysconfdir)/dbus-1/system.d
 
173
dbusconf_in_files = org.freedesktop.UPower.conf.in
 
174
dbusconf_DATA = $(dbusconf_in_files:.conf.in=.conf)
 
175
 
 
176
$(dbusconf_DATA): $(dbusconf_in_files) Makefile
 
177
        cp $< $@
 
178
 
 
179
install-data-hook:
 
180
        if test -w $(DESTDIR)$(prefix)/; then \
 
181
                mkdir -p $(DESTDIR)$(localstatedir)/lib/upower; \
 
182
        fi
 
183
 
 
184
install-exec-hook:
 
185
        cd $(DESTDIR)$(libexecdir) && $(LN_S) -f upowerd devkit-power-daemon
 
186
 
 
187
CLEANFILES = $(BUILT_SOURCES)
 
188
 
 
189
EXTRA_DIST =                                                    \
 
190
        org.freedesktop.UPower.xml                              \
 
191
        org.freedesktop.UPower.Device.xml                       \
 
192
        org.freedesktop.UPower.QoS.xml                          \
 
193
        org.freedesktop.UPower.Wakeups.xml                      \
 
194
        up-marshal.list                                         \
 
195
        $(service_in_files)                                     \
 
196
        $(dbusconf_in_files)
 
197
 
 
198
clean-local :
 
199
        rm -f *~ $(service_DATA) $(dbusconf_DATA)
 
200