1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/dist/tools/flatc/Makefile
Kasper Hjort Berthelsen 410fd5afc8 pkg/flatbuffers: downgrade to v23.5.26
Because that's what tflite-micro depends on
2024-05-24 11:57:34 +02:00

32 lines
877 B
Makefile

PKG_NAME=flatbuffers
PKG_URL=https://github.com/google/flatbuffers
PKG_VERSION=0100f6a5779831fa7a651e4b67ef389a8752bd9b
PKG_LICENSE=Apache2.0
# manually set some RIOT env vars, so this Makefile can be called stand-alone
RIOTBASE ?= $(CURDIR)/../../..
RIOTTOOLS ?= $(CURDIR)/..
PKG_SOURCE_DIR ?= $(CURDIR)/bin
PKG_BUILD_DIR ?= $(CURDIR)/bin/build
CMAKE_OPTIONS = \
-DCMAKE_BUILD_TYPE=Release \
-DFLATBUFFERS_BUILD_TESTS=OFF \
-DFLATBUFFERS_BUILD_FLATHASH=OFF \
-DFLATBUFFERS_BUILD_FLATLIB=OFF \
#
ifneq (, $(CCACHE))
CMAKE_OPTIONS += -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
endif
include $(RIOTBASE)/pkg/pkg.mk
all:
@env -i PATH="$(PATH)" cmake -G "Unix Makefiles" $(CMAKE_OPTIONS) -H"$(PKG_SOURCE_DIR)" -B"$(PKG_BUILD_DIR)"
"$(MAKE)" -C "$(PKG_BUILD_DIR)"
@mv "$(PKG_BUILD_DIR)"/flatc $(CURDIR)/flatc
distclean::
@rm -f $(CURDIR)/flatc