2020-06-07 16:02:34 +02:00
|
|
|
# Description: An efficient cross platform serialization library for C++, with support for Java, C# and Go
|
|
|
|
# URL: https://google.github.io/flatbuffers/
|
|
|
|
# Maintainer: Tim Biermann, tbier at posteo dot de
|
|
|
|
# Depends on: cmake python3-setuptools
|
|
|
|
|
|
|
|
name=flatbuffers
|
|
|
|
version=1.12.0
|
|
|
|
release=1
|
|
|
|
source=(https://github.com/google/flatbuffers/archive/v$version/$name-$version.tar.gz)
|
|
|
|
|
|
|
|
build() {
|
2020-11-08 12:02:14 +01:00
|
|
|
[[ -e /usr/bin/ninja ]] && PKGMK_FLATBUFFERS+=' -G Ninja'
|
|
|
|
cmake -S $name-$version -B build $PKGMK_FLATBUFFERS \
|
|
|
|
-D CMAKE_INSTALL_PREFIX=/usr \
|
|
|
|
-D CMAKE_INSTALL_LIBDIR=lib \
|
|
|
|
-D CMAKE_BUILD_TYPE=Release \
|
2020-12-07 00:52:29 +01:00
|
|
|
-D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
|
|
|
|
-D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
|
2020-11-08 12:02:14 +01:00
|
|
|
-D FLATBUFFERS_BUILD_FLATLIB=OFF \
|
|
|
|
-D FLATBUFFERS_BUILD_SHAREDLIB=ON \
|
|
|
|
-Wno-dev
|
2020-11-03 18:59:44 +01:00
|
|
|
cmake --build build
|
|
|
|
DESTDIR=$PKG cmake --install build
|
2020-06-07 16:02:34 +02:00
|
|
|
}
|