From patchwork Sat Sep 12 15:05:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Titouan Christophe X-Patchwork-Id: 1362882 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=140.211.166.137; helo=fraxinus.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=railnova.eu Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=railnova-eu.20150623.gappssmtp.com header.i=@railnova-eu.20150623.gappssmtp.com header.a=rsa-sha256 header.s=20150623 header.b=ZC1y7Pft; dkim-atps=neutral Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4BpbXk0gpJz9sTH for ; Sun, 13 Sep 2020 01:05:40 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 7C8C1868CF; Sat, 12 Sep 2020 15:05:37 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hoGBs84OGdZl; Sat, 12 Sep 2020 15:05:36 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 8C27D85F69; Sat, 12 Sep 2020 15:05:36 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id CFCEE1BF324 for ; Sat, 12 Sep 2020 15:05:35 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id C6769875C3 for ; Sat, 12 Sep 2020 15:05:35 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id j8-AuHoK32oL for ; Sat, 12 Sep 2020 15:05:34 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mail-ej1-f67.google.com (mail-ej1-f67.google.com [209.85.218.67]) by hemlock.osuosl.org (Postfix) with ESMTPS id 3DA1B874E5 for ; Sat, 12 Sep 2020 15:05:34 +0000 (UTC) Received: by mail-ej1-f67.google.com with SMTP id e23so17319899eja.3 for ; Sat, 12 Sep 2020 08:05:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=railnova-eu.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ab1QHbrgLKbU4VCFEPSQzz0qu/r3CgHIxl/aLfT+gAU=; b=ZC1y7PftpwyxLfkktRE8so88nLjQVAHkvhwlzn9NVA7JGjlxr4O8ix7cHPvf8zb8qe 5IHrqXFGam8hCmgqL2scPR6HRVzz10qh1fdNP1wgzTXgWd09oe9oVEYhlz01aWJoGRo/ LEkTL9OSG4+fteQH0I8xdZDE/tP0QAKhMRn/cCKZ+U4ZzqIDBQsYatvBUuoeQ9pQzUsC IIxo4RhcSip26fAGFbv2hZtgMU/2C93C5uS7lRigkDCtcupvTur5JykT5l+KA9PpPPYr bsxL/zb5WIoMq783ZCnlw1qtYdsglbYVB96mutA/PBMess0pudhQxfWYjCvIn2GhMc9g AocA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ab1QHbrgLKbU4VCFEPSQzz0qu/r3CgHIxl/aLfT+gAU=; b=lUcBCUrc2jaSojYZm33gld5M06/GiNQEijAbJ58+MqNwqvDp29Fr/wZqykEC3fZbfW Qsrj7vsdkl6hN2uoWDIv4Py71BZ40qHNlzyJR2jHRL8gDW7trh4vvNWltjMOzokXdXeC YTpa5cUF/Opd1nYGmbnDN+K476vwaLhT3ycZLRfqzS2aiIDEuf04afj4wLVHmqjWKEfA SNzdskBxQKUVw0S3AisPbb7crohvCH6R80M7fCkEWmeMcQbQPl6FkAVXs0M2R8OxAO+P Q7RV+T9loO0wItSTle+jDkXHNZ6GxQQ1gT88Gkif0Umw+ssNjd4EZgnmrYbV1H2O48vt s+JA== X-Gm-Message-State: AOAM532OOyNmu0OBVcHvZ87TfGI1wMuRnw76AJeC4vyhcK7xMMhlduKH ex6nLlbcpMN8HPZVB35RRdlTliIiqH2Z5wAz X-Google-Smtp-Source: ABdhPJzmmekTziBo1o4nRuR1FO0nS6Om3E0VgspbxQ74ZUBKBn34/tl+tTARwextbmQDdWsz7ThSPw== X-Received: by 2002:a17:907:72cc:: with SMTP id du12mr6222086ejc.150.1599923132131; Sat, 12 Sep 2020 08:05:32 -0700 (PDT) Received: from localhost.localdomain ([2a02:a03f:63d3:7700:5fb9:2a66:a7a8:378f]) by smtp.gmail.com with ESMTPSA id bz5sm3290063ejc.83.2020.09.12.08.05.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 12 Sep 2020 08:05:31 -0700 (PDT) From: Titouan Christophe To: buildroot@buildroot.org Date: Sat, 12 Sep 2020 17:05:27 +0200 Message-Id: <20200912150527.228019-1-titouan.christophe@railnova.eu> X-Mailer: git-send-email 2.25.3 MIME-Version: 1.0 Subject: [Buildroot] [PATCH 1/1] package/htpdate: fix build with static openssl X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Angelo Compagnucci , Titouan Christophe Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Depending on its build configuration, openssl might not be compiled with dynamic zlib support, and programs that link against openssl need to link against zlib as well. This can be generally and easily handled using the pkg-config files installed by openssl. Fixes: http://autobuild.buildroot.net/results/ae9/ae946ca72238840b3eaa5fe823e8d620618f7462/ Signed-off-by: Titouan Christophe --- ...-config-to-determine-openssl-LDFLAGS.patch | 36 +++++++++++++++++++ package/htpdate/htpdate.mk | 2 +- 2 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 package/htpdate/0001-Use-pkg-config-to-determine-openssl-LDFLAGS.patch diff --git a/package/htpdate/0001-Use-pkg-config-to-determine-openssl-LDFLAGS.patch b/package/htpdate/0001-Use-pkg-config-to-determine-openssl-LDFLAGS.patch new file mode 100644 index 0000000000..c1749e995d --- /dev/null +++ b/package/htpdate/0001-Use-pkg-config-to-determine-openssl-LDFLAGS.patch @@ -0,0 +1,36 @@ +From 32d6cec3be361c3d2228967d41b868b7b3b910c0 Mon Sep 17 00:00:00 2001 +From: Titouan Christophe +Date: Sat, 12 Sep 2020 16:49:57 +0200 +Subject: [PATCH 1/1] Use pkg-config to determine openssl LDFLAGS + +Depending on its build configuration, openssl might not be compiled with +dynamic zlib support, and programs that link against openssl need to link +against zlib as well, as illustrated in this build failure: +http://autobuild.buildroot.net/results/ae9/ae946ca72238840b3eaa5fe823e8d620618f7462/ + +Signed-off-by: Titouan Christophe +[upstream status: https://github.com/angeloc/htpdate/pull/1] +--- + Makefile | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 09eea4a..21668a6 100644 +--- a/Makefile ++++ b/Makefile +@@ -4,10 +4,11 @@ mandir = ${prefix}/share/man + + CC ?= gcc + CFLAGS += -Wall -std=c99 -pedantic -O2 ++PKG_CONFIG ?= pkg-config + + ifdef ENABLE_HTTPS + CFLAGS += -DENABLE_HTTPS +-LDFLAGS += -lssl -lcrypto ++LDFLAGS += $(shell $(PKG_CONFIG) --libs openssl) + endif + + INSTALL = install -c +-- +2.25.3 + diff --git a/package/htpdate/htpdate.mk b/package/htpdate/htpdate.mk index 99d3adafcd..ed74830494 100644 --- a/package/htpdate/htpdate.mk +++ b/package/htpdate/htpdate.mk @@ -11,7 +11,7 @@ HTPDATE_LICENSE_FILES = LICENSE ifeq ($(BR2_PACKAGE_OPENSSL),y) HTPDATE_BUILD_OPTS = ENABLE_HTTPS=1 -HTPDATE_DEPENDENCIES += openssl +HTPDATE_DEPENDENCIES += openssl host-pkgconf endif define HTPDATE_BUILD_CMDS