From patchwork Sun Jul 26 02:28:58 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Duskett X-Patchwork-Id: 1336425 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.138; helo=whitealder.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=QW9ZyflR; dkim-atps=neutral Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4BDn2B4kTqz9sRN for ; Sun, 26 Jul 2020 12:29:22 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 47C3687BF6; Sun, 26 Jul 2020 02:29:19 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2FZBjuqCcbTD; Sun, 26 Jul 2020 02:29:14 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id F229187AD2; Sun, 26 Jul 2020 02:29:13 +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 1EFA21BF5A7 for ; Sun, 26 Jul 2020 02:29:09 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 1BEE78844E for ; Sun, 26 Jul 2020 02:29:09 +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 eR92+EK8DIcO for ; Sun, 26 Jul 2020 02:29:08 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-pg1-f171.google.com (mail-pg1-f171.google.com [209.85.215.171]) by hemlock.osuosl.org (Postfix) with ESMTPS id 9F8868844C for ; Sun, 26 Jul 2020 02:29:08 +0000 (UTC) Received: by mail-pg1-f171.google.com with SMTP id m22so7465821pgv.9 for ; Sat, 25 Jul 2020 19:29:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KfVtGP4XyLfo/FXtNClOaNj3gPuY5eK2K8LYbirVinI=; b=QW9ZyflRQaFFqO7SspactfDOqqyjNk3gjKhg7Gov9Q3SWM0MIZI3jpqGp6NYjnFG8P wDtLeKIGE09r/fVGyxfZaZhPbUQTrf779FckISRRC/asrR5OxXjMfMT6FQWkLEujsn1A MM5GT6j9OS9CdasjXDIqCXgSKFiHSRmNaAuQm3OaI2szgq0ouDkrY/zrCeKWWYAWEvzd PDFClIU/XnSO4ZrL6rVXiC1zHcYXlqlp3jooPSlGbwevKbZCw0Bscefkw77+2RBsSFvB sYaU873A+KbCM8ZUuRXSSEUJ+l+eNYK5gH+FMR7T18gDnZK5JqgNtss0bqzo/wvyib7l zgbg== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=KfVtGP4XyLfo/FXtNClOaNj3gPuY5eK2K8LYbirVinI=; b=d+FeKWqc4pr6RkWTbIgdzsX9DP6PDEVP1XOXypUcOnGUrX6WMe6H2PUeRZmMgc0dZT y9bsJYj/f2z+Y4XdoFdp4X2fBRI8TJt41IcOfLlK0dvYLYF+FsmtRZdKMTlMcSheQBml 2w7KqY5svDzlM7Hw7wen5Ttx5LE8U9I5L7elHGrOOwArAMxUVCR42medrg97PHQu3k/4 NH6L3Z+x7aasdkmU4rTizBUkwSfXe4X9pcAvhcuw5ZuCSYGDZBEnD6GjCyxSNOOAFHr5 4Z8aecEkLnKtpmTUBaDkx97UHtsmBqqjBgXkpZ5DSLBLmecJF/xXbE8Rpper3kZgQ/hv eHyA== X-Gm-Message-State: AOAM532339mXEybSiNKbX3kOdAjg70iYDIoiuZ/lqHMof6dk1jGbOXt2 T4LVdXXWBT35wPxGOZ22rw+CmVam X-Google-Smtp-Source: ABdhPJw3KfCICJLjEc/4HCRNGKbw9F0XM+3rmNJ7+IyIrpMC0dC4xk94CeC36itzGQqq8R7cNtzeNw== X-Received: by 2002:a63:db57:: with SMTP id x23mr14245836pgi.178.1595730547832; Sat, 25 Jul 2020 19:29:07 -0700 (PDT) Received: from localhost.localdomain ([47.149.8.172]) by smtp.gmail.com with ESMTPSA id p9sm9735534pgc.77.2020.07.25.19.29.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 25 Jul 2020 19:29:07 -0700 (PDT) From: aduskett@gmail.com To: buildroot@buildroot.org Date: Sat, 25 Jul 2020 19:28:58 -0700 Message-Id: <20200726022901.295552-3-aduskett@gmail.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200726022901.295552-1-aduskett@gmail.com> References: <20200726022901.295552-1-aduskett@gmail.com> MIME-Version: 1.0 Subject: [Buildroot] [PATCH 2/5] package/libwebsockets: add support for extensions 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: Adam Duskett Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" From: Adam Duskett libwebsockets currently depends on zlib, however, as of commit 13ba5bbc633ea962d46d9f2bfb2e87c9f7e83b62 (from 2013!) zlib is not actually a requirement if extensions are not enabled. By default, libwebsockets sets the "LWS_WITHOUT_EXTENSIONS" option to "ON," which removes the need for zlib as a dependency. Because of this default setting, there are two options: 1) Remove the dependency on zlib, create a new option under Config.in to allow a user to enable extensions, add zlib as a dependency, and set LWS_WITHOUT_EXTENSIONS to "OFF" if that option is selected. 2) Keep the dependency and explicitly set LWS_WITHOUT_EXTENSIONS to "OFF." Below are the size differences in bytes: - Without zlib and extensions: 44636 - With zlib and without extensions: 44720 - With zlib and with extensions: 44732 Considering the size difference between all 3 is an incredible 96 bytes, and the difference between what we have now, and enabling extensions is an insurmountable 12 bytes, it is safe to keep the dependency on zlib and always enable extensions. Signed-off-by: Adam Duskett --- package/libwebsockets/libwebsockets.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/package/libwebsockets/libwebsockets.mk b/package/libwebsockets/libwebsockets.mk index 3af34a61ab..6716d52796 100644 --- a/package/libwebsockets/libwebsockets.mk +++ b/package/libwebsockets/libwebsockets.mk @@ -13,7 +13,8 @@ LIBWEBSOCKETS_INSTALL_STAGING = YES LIBWEBSOCKETS_CONF_OPTS = \ -DLWS_WITHOUT_TESTAPPS=ON \ -DLWS_IPV6=ON \ - -DLWS_UNIX_SOCK=ON + -DLWS_UNIX_SOCK=ON \ + -DLWS_WITHOUT_EXTENSIONS=OFF # If LWS_MAX_SMP=1, then there is no code related to pthreads compiled # in the library. If unset, LWS_MAX_SMP defaults to 32 and a small