From 913209ab9acfcd4b547fa0f0d9edbe351f36895e Mon Sep 17 00:00:00 2001 From: Benjamin Franzke Date: Fri, 27 May 2011 12:30:04 +0200 Subject: Add build system (autoconf/make) --- src/.gitignore | 3 +++ src/Makefile.am | 16 ++++++++++++++++ src/gen_message.sh | 2 ++ 3 files changed, 21 insertions(+) create mode 100644 src/.gitignore create mode 100644 src/Makefile.am mode change 100644 => 100755 src/gen_message.sh (limited to 'src') diff --git a/src/.gitignore b/src/.gitignore new file mode 100644 index 0000000..12ac542 --- /dev/null +++ b/src/.gitignore @@ -0,0 +1,3 @@ +messages.h +mumble.pb-c.c +mumble.pb-c.h diff --git a/src/Makefile.am b/src/Makefile.am new file mode 100644 index 0000000..412d668 --- /dev/null +++ b/src/Makefile.am @@ -0,0 +1,16 @@ +bin_PROGRAMS = cmumble + +noinst_HEADERS = messages.h mumble.pb-c.h varint.h +cmumble_SOURCES = cmumble.c mumble.pb-c.c varint.c +cmumble_LDADD = $(PROTOBUF_LIBS) $(GLIB_LIBS) $(GIO_LIBS) $(GSTREAMER_LIBS) $(CELT_LIBS) + +AM_CPPFLAGS = $(PROTOBUF_CFLAGS) $(GLIB_CFLAGS) $(GIO_CFLAGS) $(GSTREAMER_CFLAGS) $(CELT_CFLAGS) +AM_CFLAGS = $(GCC_FLAGS) + +messages.h: messages.txt + ./gen_message.sh < $< > $@ + +mumble.pb-c.c mumble.pb-c.h: mumble.proto + $(PROTOBUF_EXECUTABLE) --c_out=. $< + +CLEANFILES = mumble.pb-c.c mumble.pb-c.h messages.h diff --git a/src/gen_message.sh b/src/gen_message.sh old mode 100644 new mode 100755 index 4b0d1f8..2fbe75c --- a/src/gen_message.sh +++ b/src/gen_message.sh @@ -1,3 +1,5 @@ +#!/bin/sh + echo "static const struct { const ProtobufCMessageDescriptor *descriptor; const char *name; } messages[] = {" while read message do -- cgit