summaryrefslogtreecommitdiffstats
path: root/package/flatcc
diff options
context:
space:
mode:
Diffstat (limited to 'package/flatcc')
-rw-r--r--package/flatcc/Config.in8
-rw-r--r--package/flatcc/flatcc.hash2
-rw-r--r--package/flatcc/flatcc.mk29
3 files changed, 39 insertions, 0 deletions
diff --git a/package/flatcc/Config.in b/package/flatcc/Config.in
new file mode 100644
index 0000000000..6273f2b500
--- /dev/null
+++ b/package/flatcc/Config.in
@@ -0,0 +1,8 @@
+config BR2_PACKAGE_FLATCC
+ bool "flatcc"
+ help
+ flatcc is C language implementation of Google Flatbuffers. It
+ consists of both a library for the target as well as a
+ flatbuffer compiler tool for the host.
+
+ https://github.com/dvidelabs/flatcc
diff --git a/package/flatcc/flatcc.hash b/package/flatcc/flatcc.hash
new file mode 100644
index 0000000000..357d8b707d
--- /dev/null
+++ b/package/flatcc/flatcc.hash
@@ -0,0 +1,2 @@
+# Locally calculated
+sha256 8c4560ca32e3c555716d9363bed469e2c60e0f443ec32bc08e7abfe681e25ca9 flatcc-v0.5.1.tar.gz
diff --git a/package/flatcc/flatcc.mk b/package/flatcc/flatcc.mk
new file mode 100644
index 0000000000..55356445a2
--- /dev/null
+++ b/package/flatcc/flatcc.mk
@@ -0,0 +1,29 @@
+################################################################################
+#
+# FLATCC
+#
+################################################################################
+
+FLATCC_VERSION = v0.5.1
+FLATCC_SITE = $(call github,dvidelabs,flatcc,$(FLATCC_VERSION))
+FLATCC_LICENSE = Apache-2.0
+FLATCC_LICENSE_FILES = LICENSE
+FLATCC_INSTALL_STAGING = YES
+FLATCC_DEPENDENCIES = host-flatcc
+
+# Disable build of tests and samples
+FLATCC_CONF_OPTS += -DFLATCC_TEST=OFF
+HOST_FLATCC_CONF_OPTS += -DFLATCC_TEST=OFF
+
+# Enable install targets
+FLATCC_CONF_OPTS += -DFLATCC_INSTALL=ON
+HOST_FLATCC_CONF_OPTS += -DFLATCC_INSTALL=ON
+
+define FLATCC_TARGET_REMOVE_FLATCC_COMPILER
+ rm $(TARGET_DIR)/usr/bin/flatcc
+endef
+
+FLATCC_POST_INSTALL_TARGET_HOOKS += FLATCC_TARGET_REMOVE_FLATCC_COMPILER
+
+$(eval $(cmake-package))
+$(eval $(host-cmake-package))
OpenPOWER on IntegriCloud