kumquat-buildroot/package/libloki/libloki.mk
Fabrice Fontaine 0239ea5615 package/libloki: fix build with gcc 11
Fix the following build failure with gcc 11:

In file included from ../include/loki/SmartPtr.h:33,
                 from SmartPtr.cpp:20:
../include/loki/SmallObj.h: At global scope:
../include/loki/SmallObj.h:462:57: error: ISO C++17 does not allow dynamic exception specifications
  462 |         static void * operator new ( std::size_t size ) throw ( std::bad_alloc )
      |

Fixes:
 - http://autobuild.buildroot.org/results/768727160beaca5df3ef18be29cfbaa3ced67ad5

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2021-08-01 20:47:03 +02:00

40 lines
1.2 KiB
Makefile

################################################################################
#
# libloki
#
################################################################################
LIBLOKI_VERSION = 0.1.7
LIBLOKI_SOURCE = loki-$(LIBLOKI_VERSION).tar.bz2
LIBLOKI_SITE = https://sourceforge.net/projects/loki-lib/files/Loki/Loki%20$(LIBLOKI_VERSION)
LIBLOKI_LICENSE = MIT
LIBLOKI_INSTALL_STAGING = YES
ifeq ($(BR2_STATIC_LIBS),y)
LIBLOKI_BUILD_TARGETS += build-static
LIBLOKI_INSTALL_TARGETS += install-static
else ifeq ($(BR2_SHARED_LIBS),y)
LIBLOKI_BUILD_TARGETS += build-shared
LIBLOKI_INSTALL_TARGETS += install-shared
else ifeq ($(BR2_SHARED_STATIC_LIBS),y)
LIBLOKI_BUILD_TARGETS += build-static build-shared
LIBLOKI_INSTALL_TARGETS += install-static install-shared
endif
define LIBLOKI_BUILD_CMDS
$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) \
CXXFLAGS="$(TARGET_CXXFLAGS) -std=c++11" \
-C $(@D) $(LIBLOKI_BUILD_TARGETS)
endef
define LIBLOKI_INSTALL_STAGING_CMDS
$(MAKE) -C $(@D)/src DESTDIR=$(STAGING_DIR) $(LIBLOKI_INSTALL_TARGETS)
$(MAKE) -C $(@D)/include DESTDIR=$(STAGING_DIR) install
endef
define LIBLOKI_INSTALL_TARGET_CMDS
$(MAKE) -C $(@D)/src DESTDIR=$(TARGET_DIR) $(LIBLOKI_INSTALL_TARGETS)
endef
$(eval $(generic-package))