X-Git-Url: http://vcs.maemo.org/git/?a=blobdiff_plain;f=Makefile;h=96cdc745b7fef164a4ee8371ab819dafbac865eb;hb=9f84e2d13760ba085fffecea34e887d1e47f91eb;hp=9bc5d326fe8841c20b6362d824c7dcec6fff523f;hpb=64dd9db2258cc6d38aba0b60b931741456694a58;p=led-pattern-ed diff --git a/Makefile b/Makefile index 9bc5d32..96cdc74 100644 --- a/Makefile +++ b/Makefile @@ -1,13 +1,16 @@ .PHONY: all clean install +bindir=/usr/bin pluginlibdir=`pkg-config hildon-control-panel --variable pluginlibdir` plugindesktopentrydir=`pkg-config hildon-control-panel --variable plugindesktopentrydir` HILDON_CFLAGS = `pkg-config --cflags hildon-1` OSSO_CFLAGS = `pkg-config --cflags libosso` +GLIB_CFLAGS = `pkg-config --cflags glib-2.0 gobject-2.0` HILDON_LIBS = `pkg-config --libs hildon-1` OSSO_LIBS = `pkg-config --libs libosso` +GLIB_LIBS = `pkg-config --libs glib-2.0 gobject-2.0` pluginlib_LTLIBRARY = \ libled-pattern-editor.so @@ -15,7 +18,10 @@ pluginlib_LTLIBRARY = \ plugindesktopentry_DATA = \ data/led-pattern-editor.desktop -all: ${pluginlib_LTLIBRARY} +bin_PROGRAM = \ + led-pattern-helper + +all: ${pluginlib_LTLIBRARY} ${bin_PROGRAM} led_pattern_editor_SOURCES = $(patsubst %.vala,%.c,${led_pattern_editor_VALASOURCES}) @@ -36,12 +42,26 @@ ${pluginlib_LTLIBRARY}: ${led_pattern_editor_SOURCES} src/led-pattern-editor.c: ${led_pattern_editor_VALASOURCES} valac -C ${led_pattern_editor_VALAFLAGS} -o $@ $^ +led_pattern_helper_SOURCES = \ + src/led-pattern-helper.c + +led_pattern_helper_VALASOURCES = \ + src/led-pattern-helper.vala + +${bin_PROGRAM}: ${led_pattern_helper_SOURCES} + gcc ${GLIB_CFLAGS} -o $@ $^ ${GLIB_LIBS} + +src/led-pattern-helper.c: ${led_pattern_helper_VALASOURCES} + valac -C -o $@ $^ + clean: - rm ${pluginlib_LTLIBRARY} src/*.c + rm ${pluginlib_LTLIBRARY} ${bin_PROGRAM} src/*.c install: install -d ${DESTDIR}${pluginlibdir} install libled-pattern-editor.so ${DESTDIR}${pluginlibdir}/libled-pattern-editor.so install -d ${DESTDIR}${plugindesktopentrydir} install ${plugindesktopentry_DATA} ${DESTDIR}${plugindesktopentrydir}/`basename ${plugindesktopentry_DATA}` + install -d ${DESTDIR}${bindir} + install led-pattern-helper ${DESTDIR}${bindir}/led-pattern-helper