summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Makefile.am2
-rwxr-xr-xsrc/genbuiltin17
2 files changed, 18 insertions, 1 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 8fe055c0..11dac64b 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -40,7 +40,7 @@ AM_CFLAGS = @GTHREAD_CFLAGS@ @GLIB_CFLAGS@ @GDBUS_CFLAGS@ @GATCHAT_CFLAGS@ \
INCLUDES = -I$(top_builddir)/include -I$(top_builddir)
-EXTRA_DIST = ofono.conf
+EXTRA_DIST = genbuiltin ofono.conf
MAINTAINERCLEANFILES = Makefile.in
diff --git a/src/genbuiltin b/src/genbuiltin
new file mode 100755
index 00000000..d64bc725
--- /dev/null
+++ b/src/genbuiltin
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+for i in $*
+do
+ echo "extern struct ofono_plugin_desc __ofono_builtin_$i;"
+done
+
+echo
+echo "static struct ofono_plugin_desc *__ofono_builtin[] = {"
+
+for i in $*
+do
+ echo " &__ofono_builtin_$i,"
+done
+
+echo " NULL"
+echo "};"