2014-02-05 20:37:47 +01:00
|
|
|
PKG_NAME=oonf_api
|
2016-03-19 23:06:30 +01:00
|
|
|
PKG_URL=https://github.com/OLSR/OONF.git
|
2014-02-05 20:37:47 +01:00
|
|
|
PKG_VERSION=v0.3.0
|
2017-01-08 21:55:46 +01:00
|
|
|
PKG_LICENSE=BSD-3-Clause
|
2014-02-05 20:37:47 +01:00
|
|
|
|
2016-03-22 18:29:46 +01:00
|
|
|
MODULE:=$(PKG_NAME)
|
2014-02-05 20:37:47 +01:00
|
|
|
|
2018-01-24 15:48:05 +01:00
|
|
|
# GCC 7.x fails on (intentional) fallthrough, thus disable implicit-fallthrough.
|
|
|
|
CFLAGS += -Wno-implicit-fallthrough
|
|
|
|
|
2019-09-02 16:50:35 +02:00
|
|
|
COMBINED_ARCHIVE = $(BINDIR)/$(MODULE).a
|
|
|
|
|
2016-03-22 18:29:46 +01:00
|
|
|
.PHONY: all
|
2014-02-05 20:37:47 +01:00
|
|
|
|
2019-06-27 15:18:37 +02:00
|
|
|
all:
|
2016-03-22 18:29:46 +01:00
|
|
|
"$(MAKE)" -C $(PKG_BUILDDIR)
|
2019-09-02 16:50:35 +02:00
|
|
|
"$(MAKE)" $(COMBINED_ARCHIVE)
|
|
|
|
|
|
|
|
PARTIAL_ARCHIVES = $(wildcard $(BINDIR)/oonf_*.a)
|
|
|
|
|
|
|
|
$(COMBINED_ARCHIVE): $(BINDIR)/$(MODULE).mri $(PARTIAL_ARCHIVES)
|
|
|
|
ar -M < $<
|
|
|
|
|
|
|
|
define ADDLIB_TEMPLATE
|
|
|
|
addlib $1
|
|
|
|
|
|
|
|
endef
|
|
|
|
|
|
|
|
define MRI_TEMPLATE
|
|
|
|
create $1
|
|
|
|
$(foreach a,$2,$(call ADDLIB_TEMPLATE,$a))
|
|
|
|
save
|
|
|
|
end
|
|
|
|
endef
|
2014-02-05 20:37:47 +01:00
|
|
|
|
2019-09-02 16:50:35 +02:00
|
|
|
$(BINDIR)/$(MODULE).mri:
|
|
|
|
$(file >$@,$(call MRI_TEMPLATE,$(COMBINED_ARCHIVE),$(PARTIAL_ARCHIVES)))
|
|
|
|
@true
|
2015-11-16 09:43:12 +01:00
|
|
|
|
2016-03-22 18:29:46 +01:00
|
|
|
include $(RIOTBASE)/pkg/pkg.mk
|
2018-06-15 01:01:19 +02:00
|
|
|
ifneq (,$(filter -Wformat-nonliteral -Wformat=2, $(CFLAGS)))
|
|
|
|
CFLAGS += -Wno-format-nonliteral
|
|
|
|
endif
|