1 ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
6 lib_LTLIBRARIES = libmoonshot/libmoonshot.la
14 AM_CPPFLAGS = -g -O0 \
16 -DLOCALEDIR=\""$(localedir)"\" \
17 -I$(top_srcdir)/libmoonshot \
18 -I$(top_builddir)/libmoonshot
22 --vapidir=$(top_srcdir)/vapi \
26 libmoonshot_libmoonshot_la_CPPFLAGS = \
27 $(libmoonshot_CFLAGS) \
30 libmoonshot_libmoonshot_la_SOURCES = libmoonshot/libmoonshot-common.c
32 libmoonshot_libmoonshot_la_LIBADD = $(libmoonshot_LIBS)
34 include_HEADERS = libmoonshot/libmoonshot.h
35 noinst_HEADERS = libmoonshot/libmoonshot-common.h
37 src_moonshot_SOURCES = \
38 src/moonshot-identity-manager-app.vala \
39 src/moonshot-identity-management-view.vala \
40 src/moonshot-local-flat-file-store.vala \
41 src/moonshot-idcard-store.vala \
42 src/moonshot-id.vala \
43 src/moonshot-add-dialog.vala \
44 src/moonshot-idcard-widget.vala \
45 src/moonshot-custom-vbox.vala \
46 src/moonshot-identities-manager.vala \
47 src/moonshot-identity-request.vala \
48 src/moonshot-server.vala \
49 src/moonshot-password-dialog.vala \
50 src/moonshot-provisioning-common.vala \
51 src/moonshot-utils.vala
53 src_moonshot_webp_SOURCES = \
54 src/moonshot-webp-parser.vala \
55 src/moonshot-provisioning-common.vala \
58 src_moonshot_VALAFLAGS = --pkg gdk-2.0 --pkg gtk+-2.0 --pkg gee-1.0 $(AM_VALAFLAGS)
59 src_moonshot_CPPFLAGS = $(moonshot_CFLAGS) $(AM_CPPFLAGS)
60 src_moonshot_LDADD = $(moonshot_LIBS)
61 src_moonshot_LDFLAGS = -g -O0
63 src_moonshot_webp_VALAFLAGS = --vapidir=$(top_srcdir)/libmoonshot --pkg gtk+-2.0 --pkg gdk-2.0 --pkg libmoonshot $(AM_VALAFLAGS)
64 src_moonshot_webp_CPPFLAGS = $(moonshot_CFLAGS) $(AM_CPPFLAGS)
65 src_moonshot_webp_LDADD = $(moonshot_LIBS) ${top_builddir}/libmoonshot/libmoonshot.la
69 libmoonshot_libmoonshot_la_LDFLAGS = -no-undefined
71 src_moonshot_CFLAGS = -mwindows
72 src_moonshot_webp_CFLAGS = -mwindows
74 AM_CPPFLAGS += -DOS_WIN32
75 AM_VALAFLAGS += --define=OS_WIN32
77 noinst_DATA = libmoonshot/libmoonshot.lib
79 # Build the MSVC lib. The sed hack fixes execution in the case that
80 # the MSVC toolchain isn't in the PATH.
81 libmoonshot/libmoonshot.lib: libmoonshot/libmoonshot.def
82 PATH="$(shell echo "${MSVC_LIB}" | sed -e s,/VC/bin/lib,/Common7/IDE,)":$$PATH "${MSVC_LIB}" -def:$< -out:$@ -machine:x86
88 AM_CPPFLAGS += -DOS_MACOS $(MAC_CFLAGS)
89 AM_VALAFLAGS += --define=OS_MACOS --pkg gtk-mac-integration
90 moonshot_LIBS += $(MAC_LIBS)
91 src_moonshot_LDADD += $(MAC_LIBS)
96 ## Installing mime type data
97 mimedir = $(datadir)/mime/packages
98 mime_DATA = webprovisioning/moonshot.xml
101 dotdesktopdir = $(datadir)/applications
102 dotdesktop_DATA = moonshot.desktop moonshot-webp.desktop
114 BUILT_SOURCES = libmoonshot/moonshot-msrpc.h \
115 libmoonshot/moonshot-msrpc_s.c \
116 libmoonshot/moonshot-msrpc_c.c
118 DISTCLEANFILES = ${BUILT_SOURCES}
120 libmoonshot/moonshot-msrpc.h: libmoonshot/moonshot-msrpc.idl libmoonshot/moonshot-msrpc.acf
121 ${AM_V_GEN} ${MIDL_WRAPPER} -o libmoonshot -m "${MIDL}" $^
123 libmoonshot/moonshot-msrpc_s.c: libmoonshot/moonshot-msrpc.h
124 libmoonshot/moonshot-msrpc_c.c: libmoonshot/moonshot-msrpc.h
126 libmoonshot_libmoonshot_la_SOURCES += \
127 libmoonshot/libmoonshot-msrpc.c
129 src_moonshot_SOURCES += \
130 src/moonshot-msrpc.vapi
132 nodist_src_moonshot_SOURCES = \
133 libmoonshot/moonshot-msrpc_s.c
135 nodist_libmoonshot_libmoonshot_la_SOURCES = \
136 libmoonshot/moonshot-msrpc_c.c
143 dbusservicedir = $(datadir)/dbus-1/services
145 dbusservice_in_files = org.janet.Moonshot.service.mac
146 dbusservice_DATA = $(dbusservice_in_files:.service.mac=.service)
148 dbusservice_in_files = org.janet.Moonshot.service.in
149 dbusservice_DATA = $(dbusservice_in_files:.service.in=.service)
152 # Rule to make the service file with bindir expanded
153 $(dbusservice_DATA): $(dbusservice_in_files) Makefile
154 @sed -e "s|\@bindir\@|$(bindir)|" $< > $@
156 libmoonshot_libmoonshot_la_SOURCES += libmoonshot/libmoonshot-dbus.c
158 CLEANFILES = $(dbusservice_DATA)
163 --define=IPC_DBUS_GLIB \
173 EXTRA_DIST = webprovisioning/moonshot.xml $(dbusservice_in_files) \
178 examples/service-selection \
181 examples_service_selection_SOURCES = examples/service-selection.c
182 examples_service_selection_CPPFLAGS = $(moonshot_CFLAGS) $(AM_CPPFLAGS)
183 examples_service_selection_LDADD = ${top_builddir}/libmoonshot/libmoonshot.la $(moonshot_LIBS)
185 examples_client_SOURCES = examples/client.c
186 examples_client_CPPFLAGS = $(libmoonshot_CFLAGS) $(AM_CPPFLAGS)
187 examples_client_LDADD = ${top_builddir}/libmoonshot/libmoonshot.la
189 tests_basic_SOURCES = tests/basic.c
190 tests_basic_CPPFLAGS = $(moonshot_CFLAGS) $(AM_CPPFLAGS)
191 tests_basic_LDADD = ${top_builddir}/libmoonshot/libmoonshot.la $(moonshot_LIBS)
195 ## "${UPDATE_MIME_DATABASE}" $(datadir)/mime
196 ## "${UPDATE_DESKTOP_DATABASE}" $(datadir)/applications
198 ## "${UPDATE_MIME_DATABASE}" $(datadir)/mime
199 ## "${UPDATE_DESKTOP_DATABASE}" $(datadir)/applications
204 ## A couple of Windows-specific targets:
206 ## 1. Icons. You must have gnome-icon-theme and gnome-icon-theme-symbolic installed
207 ## in the install prefix; and ImageMagick installed in c:/tools/ImageMagick. This
208 ## pulls in the icons required by moonshot and converts svg's to png's (we have
209 ## no svg support built in to Windows Gtk+ right now).
213 cp ${prefix}/share/icons/gnome/48x48/status/avatar-default.png share/icons
214 "${IMAGEMAGICK_CONVERT}" -background none ${prefix}/share/icons/gnome/scalable/actions/edit-clear-symbolic.svg -size 13x13 share/icons/edit-clear-symbolic.png
215 "${IMAGEMAGICK_CONVERT}" -background none ${prefix}/share/icons/gnome/scalable/actions/edit-find-symbolic.svg -size 13x13 share/icons/edit-find-symbolic.png
218 ## 2. Installer. You must have the Windows Installer XML toolkit version 3.5
219 ## installed in its default path. Note that this requires at least .NET
220 ## runtime with service packs 1 and 2. The installer picks up files from
221 ## the build prefix and mingw dir; you must change these if you have them
222 ## in different locations I'm afraid.
224 installer: moonshot.msi
226 moonshot.msi: windows/app.wxs windows/config.wxi $(bin_PROGRAMS)
228 "${WIX_LIGHT}" -b ${prefix} -b ${prefix}/mingw -o moonshot.msi app.wixobj
233 ## Mac-specific targets
239 cp mac/icons/process-stop.png share/icons
240 cp mac/icons/edit-find.png share/icons
241 cp mac/icons/avatar-default.png share/icons
244 ## gtk-app-bundler must be installed
245 ## moonshot-ui.app will be built in moonshot/mac-client-installer/moonshot-ui/
247 gtk-mac-bundler ./mac/moonshot-ui.bundle
249 ## 3: Installer Package
251 installerdir = $(HOME)/moonshot/mac-client-installer