blob: 06bb9715412b6b80a878d6c97454ad4a7062626d [file] [log] [blame]
Andrew Geissler82c905d2020-04-13 13:39:40 -05001SUMMARY = "Memory Efficient Serialization Library"
2HOMEPAGE = "https://github.com/google/flatbuffers"
3SECTION = "console/tools"
4LICENSE = "Apache-2.0"
5
Andrew Geissler72956ed2021-01-08 16:11:14 -06006inherit python3-dir
7
8PACKAGE_BEFORE_PN = "${PN}-compiler ${PN}-${PYTHON_PN}"
Andrew Geissler82c905d2020-04-13 13:39:40 -05009
Patrick Williams213cb262021-08-07 19:21:33 -050010RDEPENDS:${PN}-compiler = "${PN}"
11RDEPENDS:${PN}-${PYTHON_PN} = "${PN}"
12RDEPENDS:${PN}-dev += "${PN}-compiler"
Andrew Geissler82c905d2020-04-13 13:39:40 -050013
14LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=3b83ef96387f14655fc854ddc3c6bd57"
15
William A. Kennington IIIb95905d2021-06-02 12:40:56 -070016SRCREV = "a9a295fecf3fbd5a4f571f53b01f63202a3e2113"
Andrew Geissler595f6302022-01-24 19:11:47 +000017SRC_URI = "git://github.com/google/flatbuffers.git;branch=master;protocol=https"
William A. Kennington IIIb95905d2021-06-02 12:40:56 -070018S = "${WORKDIR}/git"
Andrew Geissler82c905d2020-04-13 13:39:40 -050019
Andrew Geisslereef63862021-01-29 15:58:13 -060020CVE_CHECK_WHITELIST += "CVE-2020-35864"
21
Andrew Geissler7f40b712020-05-15 14:09:53 -050022CXXFLAGS += "-fPIC"
23BUILD_CXXFLAGS += "-fPIC"
Andrew Geissler82c905d2020-04-13 13:39:40 -050024
25# BUILD_TYPE=Release is required, otherwise flatc is not installed
26EXTRA_OECMAKE += "\
27 -DCMAKE_BUILD_TYPE=Release \
28 -DFLATBUFFERS_BUILD_TESTS=OFF \
29 -DFLATBUFFERS_BUILD_SHAREDLIB=ON \
30"
31
32inherit cmake
33
Patrick Williams213cb262021-08-07 19:21:33 -050034do_install:append() {
Andrew Geissler72956ed2021-01-08 16:11:14 -060035 install -d ${D}${PYTHON_SITEPACKAGES_DIR}
36 cp -rf ${S}/python/flatbuffers ${D}${PYTHON_SITEPACKAGES_DIR}
37}
38
Patrick Williams213cb262021-08-07 19:21:33 -050039FILES:${PN}-compiler = "${bindir}"
Andrew Geissler82c905d2020-04-13 13:39:40 -050040
Patrick Williams213cb262021-08-07 19:21:33 -050041FILES:${PN}-${PYTHON_PN} = "${PYTHON_SITEPACKAGES_DIR}"
Andrew Geissler72956ed2021-01-08 16:11:14 -060042
Andrew Geissler82c905d2020-04-13 13:39:40 -050043BBCLASSEXTEND = "native nativesdk"