2014-05-05 23:17:01 +02:00
|
|
|
################################################################################
|
|
|
|
#
|
|
|
|
# musl
|
|
|
|
#
|
|
|
|
################################################################################
|
|
|
|
|
musl: bump to version 1.1.21
>From the upstream release announcement:
"""
This release makes improvements with respect to default thread stack size,
including increasing the default from 80k to 128k, increasing the default
guard size from 4k to 8k, and allowing the default to be increased via ELF
headers so that programs that need larger stacks can be build without
source-level changes, using just LDFLAGS. Insufficient stack size for AIO
threads on kernels that don't honor the constant MINSIGSTKSZ is also fixed.
The glob core has been rewritten to fix inability to see past
searchable-but-unreadable path components, and to avoid excessive stack usage
and unnecessary syscalls. The tsearch AVL tree implementation has also been
rewritten for better size and performance. The math library adds more native
single-instruction implementations for arm, s390x, powerpc, and x86_64.
Various bugs are fixed, including several possible deadlocks, one of which was
a new regression in 1.1.20.
"""
Drop upstream patch 0002 which is included in the release.
Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-01-22 09:54:36 +01:00
|
|
|
MUSL_VERSION = 1.1.21
|
2014-07-31 10:46:58 +02:00
|
|
|
MUSL_SITE = http://www.musl-libc.org/releases
|
2014-05-05 23:17:01 +02:00
|
|
|
MUSL_LICENSE = MIT
|
|
|
|
MUSL_LICENSE_FILES = COPYRIGHT
|
|
|
|
|
|
|
|
# Before musl is configured, we must have the first stage
|
|
|
|
# cross-compiler and the kernel headers
|
|
|
|
MUSL_DEPENDENCIES = host-gcc-initial linux-headers
|
|
|
|
|
2016-08-18 23:50:13 +02:00
|
|
|
# musl does not provide an implementation for sys/queue.h or sys/cdefs.h.
|
|
|
|
# So, add the musl-compat-headers package that will install those files,
|
|
|
|
# into the staging directory:
|
|
|
|
# sys/queue.h: header from NetBSD
|
|
|
|
# sys/cdefs.h: minimalist header bundled in Buildroot
|
|
|
|
MUSL_DEPENDENCIES += musl-compat-headers
|
2015-12-02 01:58:28 +01:00
|
|
|
|
2014-05-05 23:17:01 +02:00
|
|
|
# musl is part of the toolchain so disable the toolchain dependency
|
|
|
|
MUSL_ADD_TOOLCHAIN_DEPENDENCY = NO
|
|
|
|
|
|
|
|
MUSL_INSTALL_STAGING = YES
|
|
|
|
|
2016-03-31 21:00:08 +02:00
|
|
|
# Thumb build is broken, build in ARM mode, since all architectures
|
|
|
|
# that support Thumb1 also support ARM.
|
|
|
|
ifeq ($(BR2_ARM_INSTRUCTIONS_THUMB),y)
|
|
|
|
MUSL_EXTRA_CFLAGS += -marm
|
|
|
|
endif
|
|
|
|
|
2014-09-14 11:50:01 +02:00
|
|
|
define MUSL_CONFIGURE_CMDS
|
2014-05-05 23:17:01 +02:00
|
|
|
(cd $(@D); \
|
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
2014-07-17 14:43:57 +02:00
|
|
|
CFLAGS="$(filter-out -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64,$(TARGET_CFLAGS)) $(MUSL_EXTRA_CFLAGS)" \
|
2014-05-05 23:17:01 +02:00
|
|
|
CPPFLAGS="$(filter-out -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64,$(TARGET_CPPFLAGS))" \
|
|
|
|
./configure \
|
|
|
|
--target=$(GNU_TARGET_NAME) \
|
|
|
|
--host=$(GNU_TARGET_NAME) \
|
|
|
|
--prefix=/usr \
|
2014-12-09 02:44:35 +01:00
|
|
|
--libdir=/lib \
|
2015-10-14 06:29:37 +02:00
|
|
|
--disable-gcc-wrapper \
|
2015-10-15 17:27:18 +02:00
|
|
|
--enable-static \
|
|
|
|
$(if $(BR2_STATIC_LIBS),--disable-shared,--enable-shared))
|
2014-05-05 23:17:01 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define MUSL_BUILD_CMDS
|
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D)
|
|
|
|
endef
|
|
|
|
|
|
|
|
define MUSL_INSTALL_STAGING_CMDS
|
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) \
|
2014-09-14 11:50:01 +02:00
|
|
|
DESTDIR=$(STAGING_DIR) install-libs install-tools install-headers
|
2014-05-05 23:17:01 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define MUSL_INSTALL_TARGET_CMDS
|
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) \
|
2014-12-09 02:44:36 +01:00
|
|
|
DESTDIR=$(TARGET_DIR) install-libs
|
2019-03-06 17:33:16 +01:00
|
|
|
$(RM) $(addprefix $(TARGET_DIR)/lib/,crt1.o crtn.o crti.o rcrt1.o Scrt1.o)
|
2014-05-05 23:17:01 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
$(eval $(generic-package))
|