mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-07 23:21:08 -09:00
When using BR2_STATIC_LIBS=y, tinysshd's build was successful, but the binary didn't work on the final target: this is because a dynamically linked ELF was produced, on a target having no dynamic loader at all. Using $(TARGET_CONFIGURE_OPTS) propagates all the options and not only "CC", resulting in a correct static binary able to run on the target. Without the patch: > tinysshd: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), > dynamically linked, interpreter /lib/ld-musl-armhf.so.1, stripped With the patch: > tinysshd: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), > statically linked, stripped Fixes:a7b3de8a3bSigned-off-by: Martin Wetterwald <martin@wetterwald.eu> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> (cherry picked from commit90e22ff48b) Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
21 lines
558 B
Makefile
21 lines
558 B
Makefile
################################################################################
|
|
#
|
|
# tinyssh
|
|
#
|
|
################################################################################
|
|
|
|
TINYSSH_VERSION = 20240101
|
|
TINYSSH_SITE = $(call github,janmojzis,tinyssh,$(TINYSSH_VERSION))
|
|
TINYSSH_LICENSE = CC0-1.0
|
|
TINYSSH_LICENSE_FILES = LICENCE
|
|
|
|
define TINYSSH_BUILD_CMDS
|
|
$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D) cross-compile
|
|
endef
|
|
|
|
define TINYSSH_INSTALL_TARGET_CMDS
|
|
$(MAKE) DESTDIR="$(TARGET_DIR)" -C $(@D) install
|
|
endef
|
|
|
|
$(eval $(generic-package))
|