aboutsummaryrefslogtreecommitdiff
path: root/example/Makefile.am
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2011-02-10 13:19:08 -0600
committerTed Gould <ted@gould.cx>2011-02-10 13:19:08 -0600
commit2f8daaccfa12fa4d569dc370803ba88dbd3c1920 (patch)
treeb616a94c1342a218a6128c337e4b39b99779dc0a /example/Makefile.am
parent0faacd13e0e23b202969127e9034605b4fcf90c4 (diff)
parente69e29266aaa82c5af8745301a8c6cd78ffd2e35 (diff)
downloadlibayatana-appindicator-2f8daaccfa12fa4d569dc370803ba88dbd3c1920.tar.gz
libayatana-appindicator-2f8daaccfa12fa4d569dc370803ba88dbd3c1920.tar.bz2
libayatana-appindicator-2f8daaccfa12fa4d569dc370803ba88dbd3c1920.zip
Fixing Vala bindings
Diffstat (limited to 'example/Makefile.am')
-rw-r--r--example/Makefile.am29
1 files changed, 28 insertions, 1 deletions
diff --git a/example/Makefile.am b/example/Makefile.am
index 0900baf..606317c 100644
--- a/example/Makefile.am
+++ b/example/Makefile.am
@@ -4,9 +4,11 @@ else
VER=
endif
+CLEANFILES =
check_PROGRAMS = \
- simple-client
+ simple-client \
+ simple-client-vala
#########################################
## simple-client
@@ -27,3 +29,28 @@ simple_client_LDADD = \
EXTRA_DIST = \
simple-client-test-icon.png
+
+#########################################
+## simple-client-vala
+#########################################
+if HAVE_VALAC
+
+VALAFLAGS = \
+ --pkg appindicator$(VER)-0.1 \
+ --vapidir=$(top_builddir)/bindings/vala
+
+BUILT_SOURCES = simple-client-vala.c
+simple-client-vala.c: $(srcdir)/simple-client-vala.vala
+ $(VALAC) $(VALAFLAGS) -C $< -o $@
+ $(SED) -i "s|#include\s*<\s*libappindicator/app-indicator.h\s*>||g" $@
+
+simple_client_vala_SOURCES = simple-client-vala.c
+simple_client_vala_CFLAGS = \
+ $(simple_client_CFLAGS) \
+ -include $(top_srcdir)/src/app-indicator.h
+
+simple_client_vala_LDADD = $(simple_client_LDADD)
+
+CLEANFILES += *.stamp *-vala.c
+
+endif