buildrootschalter/package/cppcms/cppcms.mk
Lucile Quirion a518381ed8 cppcms: fix build with uClibc
This patch modifies the cppcms package in order to support uClibc-based
toolchains.

The booster library by default compiles with the posix backend under
Linux, but this needs monetary.h which isn't provided by uClibc, so
work around that with the help of the DISABLE_POSIX_LOCALE configure
option.

Signed-off-by: Lucile Quirion <lucile.quirion@savoirfairelinux.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2014-04-08 22:53:58 +02:00

35 lines
1.1 KiB
Makefile

################################################################################
#
# cppcms
#
################################################################################
CPPCMS_VERSION = 1.0.4
CPPCMS_SOURCE = cppcms-$(CPPCMS_VERSION).tar.bz2
CPPCMS_LICENSE = LGPLv3
CPPCMS_LICENSE_FILES = COPYING.TXT
CPPCMS_SITE = http://downloads.sourceforge.net/project/cppcms/cppcms/$(CPPCMS_VERSION)
CPPCMS_INSTALL_STAGING = YES
CPPCMS_DEPENDENCIES = zlib pcre libgcrypt
ifeq ($(BR2_PACKAGE_CPPCMS_ICU),y)
CPPCMS_CONF_OPT += -DDISABLE_ICONV=ON
CPPCMS_DEPENDENCIES += icu
endif
ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y)
# posix backend needs monetary.h which isn't available on uClibc
CPPCMS_CONF_OPT += -DDISABLE_POSIX_LOCALE=on
endif
# We copy cppcms_tmpl_cc from staging to host because this file can be
# needed for compiling packages using cppcms. And it is not worth
# creating a host package just for a python script.
define CPPCMS_INSTALL_HOST_TOOLS
cp $(STAGING_DIR)/usr/bin/cppcms_tmpl_cc $(HOST_DIR)/usr/bin/cppcms_tmpl_cc
endef
CPPCMS_POST_INSTALL_STAGING_HOOKS += CPPCMS_INSTALL_HOST_TOOLS
$(eval $(cmake-package))