From patchwork Fri Jul 24 23:25:51 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Duskett X-Patchwork-Id: 1336027 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=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=k4oqnG0D; 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 4BD51R36pDz9sR4 for ; Sat, 25 Jul 2020 09:26:19 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id D6962873EC; Fri, 24 Jul 2020 23:26:17 +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 rQAappRUX0Kb; Fri, 24 Jul 2020 23:26:15 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 3DDA587390; Fri, 24 Jul 2020 23:26:15 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 3A9231BF365 for ; Fri, 24 Jul 2020 23:26:11 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 37DA488B72 for ; Fri, 24 Jul 2020 23:26:11 +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 cqSyzbkI0O0s for ; Fri, 24 Jul 2020 23:26:08 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-pl1-f195.google.com (mail-pl1-f195.google.com [209.85.214.195]) by whitealder.osuosl.org (Postfix) with ESMTPS id 4CCDA88B71 for ; Fri, 24 Jul 2020 23:26:08 +0000 (UTC) Received: by mail-pl1-f195.google.com with SMTP id 72so5412254ple.0 for ; Fri, 24 Jul 2020 16:26: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=Ta1C9db1y01Zv0+CRlcOaXFFgW3ulYRPXmkAPPsjEXM=; b=k4oqnG0DZF7mYyJHQe8rg+d9S8KPBBOHLHSxyj4G5JfbhHgMsGfD8vQt0qWZdo8vFk dl7K9I0Y80Vksevb84/WvK0KpJwxBhq9J47uqEXRJxHlRJi2VCwrvxNl8a4TwoNqbigz F/Jx82RJgWPMflG/3ZMr5/nAEoLBZBObHeDBD5PTvwyONYzP3kxzns0l92TvClPYEC+Y 8jb8OuCWihrVgfAkkWBi7CWm6ztY+hrSLfo48PpsITZbz+6Zg2r09GI0SJneuwVMNcEs f9HPCF4rXpsGeXFFuDnHdP7wDauf6WbHDUuYdic/5wSZE119UpZWIj3QLQsxsbsaUQXB f0hA== 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=Ta1C9db1y01Zv0+CRlcOaXFFgW3ulYRPXmkAPPsjEXM=; b=O8KQ6KxdyAW53/PdymDfjeZXTRkAYgFeE6PVr6eRJ0TDgc5fG/oFdoE2L4NSrPbWh6 +Cc09O3vXy/ACBl7O7+BSLXFjuhkc92X7/4z16HAMRe36gr3mVWOpWG/OMLsOOTEQzPG e793FXcLOi8VJQRMsTFTGRW5SX+2nyOC20z8DUtjOtbYLFIf2Geckl5sAM0InaPk4Hoi /nhQSUBV3DbHqGV4NZf/EWEXJAQgxkBqKay25T5qDx+/DXwJDd2EaFQonPFyIYobkY62 4TbH2kuujtG39D8K1582u8P6cR1dOeyoWvEaBVPFHJ3ZdppF0dYSA3mha9haN9XUAu3x W0Sg== X-Gm-Message-State: AOAM53085twQEUq00Nam+AHWKX2aPB7HspEqOSt45CKlDB43VQinWOxS 8uHc3GvgdjbNiGpayLx1CoakbeInV8E= X-Google-Smtp-Source: ABdhPJwnmr2cCrprrdiz0NN10qrqY/+U82GJYYXH595AVx3+LAEAAtHQfZ1GFGON0SSPhYs2M2P6Mw== X-Received: by 2002:a17:90a:b889:: with SMTP id o9mr1059267pjr.187.1595633167627; Fri, 24 Jul 2020 16:26:07 -0700 (PDT) Received: from localhost.localdomain ([47.149.8.172]) by smtp.gmail.com with ESMTPSA id d9sm7214516pgv.45.2020.07.24.16.26.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 Jul 2020 16:26:06 -0700 (PDT) From: aduskett@gmail.com To: buildroot@buildroot.org Date: Fri, 24 Jul 2020 16:25:51 -0700 Message-Id: <20200724232601.2441272-4-aduskett@gmail.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200724232601.2441272-1-aduskett@gmail.com> References: <20200724232601.2441272-1-aduskett@gmail.com> MIME-Version: 1.0 Subject: [Buildroot] [PATCH v2 03/13] package/libbytesize: new package 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: Giulio Benetti , Adam Duskett , Marek Belisko Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" From: Adam Duskett Libbytesize is a small library providing a C "class" for working with arbitrary big sizes in bytes. The mdraid plugin for libblockdev depends on this package, which newer versions of udisks require when building with the udisks daemon enabled. Signed-off-by: Adam Duskett --- Changes v1 -> v2: - Add 0001-remove-msgcat-dependency.patch (Thomas) - Remove dependency on gettext-gnu (Thomas) DEVELOPERS | 1 + .../0001-remove-msgcat-dependency.patch | 36 +++++++++++++++++++ package/libbytesize/Config.in | 10 ++++++ package/libbytesize/libbytesize.hash | 3 ++ package/libbytesize/libbytesize.mk | 27 ++++++++++++++ 5 files changed, 77 insertions(+) create mode 100644 package/libbytesize/0001-remove-msgcat-dependency.patch create mode 100644 package/libbytesize/Config.in create mode 100644 package/libbytesize/libbytesize.hash create mode 100644 package/libbytesize/libbytesize.mk diff --git a/DEVELOPERS b/DEVELOPERS index cd489754ed..72216b8fce 100644 --- a/DEVELOPERS +++ b/DEVELOPERS @@ -44,6 +44,7 @@ F: package/imx-usb-loader/ F: package/janus-gateway/ F: package/json-for-modern-cpp/ F: package/libblockdev/ +F: package/libbytesize/ F: package/libcpprestsdk/ F: package/libcutl/ F: package/libodb/ diff --git a/package/libbytesize/0001-remove-msgcat-dependency.patch b/package/libbytesize/0001-remove-msgcat-dependency.patch new file mode 100644 index 0000000000..4c9b96020e --- /dev/null +++ b/package/libbytesize/0001-remove-msgcat-dependency.patch @@ -0,0 +1,36 @@ +From ac16b1a905dbdb06ac7bba6ac105686aa7958093 Mon Sep 17 00:00:00 2001 +From: Adam Duskett +Date: Fri, 24 Jul 2020 11:49:14 -0700 +Subject: [PATCH] remove msgcat dependency + +Gettext-tiny does not include the msgcat utility, which causes issues when +building libbytesize for embedded systems, as many embedded systems do not +build the full gettext, but instead use the gettext-tiny library. + +Because msgcat is not needed to build libbytesize, it's safe to remove the +dependency. + +Upstream-status: pending +https://github.com/storaged-project/libbytesize/pull/76 +Signed-off-by: Adam Duskett +--- + configure.ac | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 2ec4062..7d7f218 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -13,8 +13,7 @@ AC_CONFIG_MACRO_DIR([m4]) + AC_PATH_PROG([XGETTEXT], [xgettext]) + AC_PATH_PROG([MSGFMT], [msgfmt]) + AC_PATH_PROG([MSGMERGE], [msgmerge]) +-AC_PATH_PROG([MSGCAT], [msgcat]) +-AS_IF([test -z "$XGETTEXT" -o -z "$MSGFMT" -o -z "$MSGMERGE" -o -z "$MSGCAT"], ++AS_IF([test -z "$XGETTEXT" -o -z "$MSGFMT" -o -z "$MSGMERGE"], + [AC_MSG_FAILURE([gettext not found])]) + + # Define this so gettext.h works without requiring the whole gettext macro +-- +2.26.2 + diff --git a/package/libbytesize/Config.in b/package/libbytesize/Config.in new file mode 100644 index 0000000000..6cc550e488 --- /dev/null +++ b/package/libbytesize/Config.in @@ -0,0 +1,10 @@ +config BR2_PACKAGE_LIBBYTESIZE + bool "libbytesize" + select BR2_PACKAGE_GMP + select BR2_PACKAGE_MPFR + select BR2_PACKAGE_PCRE2 + help + A tiny library that facilitates the common operations with + sizes in bytes + + https://github.com/storaged-project/libbytesize/ diff --git a/package/libbytesize/libbytesize.hash b/package/libbytesize/libbytesize.hash new file mode 100644 index 0000000000..34cb3b210f --- /dev/null +++ b/package/libbytesize/libbytesize.hash @@ -0,0 +1,3 @@ +# Locally calculated +sha256 3c74113fc8cd1a2fbd8870fa0ed7cef2ef24d60ef91e7145fbc041f9aa144479 libbytesize-2.3.tar.gz +sha256 97bdc721d875501b6243a456333fdfdb1ab64d31c4da2554de845caf4674b946 LICENSE diff --git a/package/libbytesize/libbytesize.mk b/package/libbytesize/libbytesize.mk new file mode 100644 index 0000000000..b1309c1731 --- /dev/null +++ b/package/libbytesize/libbytesize.mk @@ -0,0 +1,27 @@ +################################################################################ +# +# libbytesize +# +################################################################################ + +LIBBYTESIZE_VERSION = 2.3 +LIBBYTESIZE_SITE = https://github.com/storaged-project/libbytesize/releases/download/$(LIBBYTESIZE_VERSION) +LIBBYTESIZE_LICENSE = LGPL-2.1+ +LIBBYTESIZE_LICENSE_FILES = LICENSE +LIBBYTESIZE_INSTALL_STAGING = YES + +# 0001-remove-msgcat-dependency.patch +LIBBYTESIZE_AUTORECONF = YES + +LIBBYTESIZE_DEPENDENCIES = \ + host-pkgconf \ + host-gettext \ + gmp \ + mpfr \ + pcre2 + +LIBBYTESIZE_CONF_OPTS += \ + --without-python3 \ + --without-tools + +$(eval $(autotools-package))