From patchwork Tue May 4 21:10:16 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabrice Fontaine X-Patchwork-Id: 1473991 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=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) 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=u0g+xRmB; dkim-atps=neutral Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4FZXdT624Tz9sSs for ; Wed, 5 May 2021 07:13:49 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id B8B6F418C9; Tue, 4 May 2021 21:13:46 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GSjDARLdkyy9; Tue, 4 May 2021 21:13:45 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id A442A418CB; Tue, 4 May 2021 21:13:44 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 367F21BF2EC for ; Tue, 4 May 2021 21:13:43 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 3206160791 for ; Tue, 4 May 2021 21:13:43 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp3.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Ct6Rtwvhoq0e for ; Tue, 4 May 2021 21:13:39 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by smtp3.osuosl.org (Postfix) with ESMTPS id 3F021606BD for ; Tue, 4 May 2021 21:13:39 +0000 (UTC) Received: by mail-wm1-x32d.google.com with SMTP id 82-20020a1c01550000b0290142562ff7c9so2263601wmb.3 for ; Tue, 04 May 2021 14:13:38 -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:mime-version :content-transfer-encoding; bh=Msri+mK6Gwmsh7SyzUf/6k47W8l7F+N7roICAJ7fet8=; b=u0g+xRmBbOFEgzFkudbZpjmbVhuedqaA01L5skcW7WaLDLk06muJCuU8sx4/Q+07TT QzZJFLwv+fqQabiLuqF+JhHNhdbNX3ctB5PP0dJEqpilT2yKOSv5yLj17XCDY/t3bF6b 6Cphe09BW3XerG5siCUmwgqmMijWo74N0Bff3drQBxbYea6ZWflAcjuPGZ7n4cfiItK2 OSCXlSGSNuehafa7Lyt+fO7TLkfsTi7C4gph8OceFOs8SlbvuBo5Kf9V1Do9imIKaEO8 nljl9dwoO307LTsYXaKvacmnolaT1s4AwpS4+jBWnSwfahUoLCAYQ9uObOEOLiNxyRw2 GJLQ== 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=Msri+mK6Gwmsh7SyzUf/6k47W8l7F+N7roICAJ7fet8=; b=anrXGaKM24aPxttZwEFb6TuMWEKcsyRLNontEAxbNwpGTAf5Am7TiMQOcA5i8ab4Mz BB9MAkx9QJrR19CDOB8OqkuryxDIi9AytPbIaaTPbOsHX/pfDXhT+/xHFY4Cm4stXvYK IHISVUUB89a4A+voC3VsB7qd42gmPyGv5XtkSTgpgRyM9rXP2og9o9nraRx8VRIImsKS /B9ohPHIIPIHvjHbxmgKq7H3yM+TpAEREE8kbP0wE0CI2bHxGlTI425+Elze/NTE/jJZ sG6nOVYXbGNIvbz9yoMec/6HfuPkGgokEIXGJ0AmNFl62IkOwP/opplVwOlelhD/TTxb 9XIA== X-Gm-Message-State: AOAM532gHci1uw/PeB9LuJoPD4w7rCWy6kXntjpJpgX7NNJJZ4QTx/1C krCMemzVPTjO1DamXdzo3Kg3lmLoiBM= X-Google-Smtp-Source: ABdhPJz1JU1so7eiGBPF9EHhAnPELxcGS+56aoxj6aJZ9BOpTiDihH2V/xLbbFn7bvebwcJXsjKp1A== X-Received: by 2002:a1c:790f:: with SMTP id l15mr6453462wme.30.1620162816998; Tue, 04 May 2021 14:13:36 -0700 (PDT) Received: from kali.home (lfbn-ren-1-1383-171.w86-229.abo.wanadoo.fr. [86.229.230.171]) by smtp.gmail.com with ESMTPSA id n124sm3703311wmn.40.2021.05.04.14.13.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 04 May 2021 14:13:36 -0700 (PDT) From: Fabrice Fontaine To: buildroot@buildroot.org Date: Tue, 4 May 2021 23:10:16 +0200 Message-Id: <20210504211016.1216759-1-fontaine.fabrice@gmail.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Subject: [Buildroot] [PATCH 1/1] package/pipewire: fix build with uclibc-ng 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: James Hilliard , Fabrice Fontaine Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Build fails with uclibc-ng since bump to version 0.3.26 in commit a6d88d3ba5e30e11f4d726f341bc56c1be7c71c9 Fixes: - http://autobuild.buildroot.org/results/a45f0ee009d90cef867dee4b1093225610fa10df Signed-off-by: Fabrice Fontaine --- ...meson.build-fix-build-with-uclibc-ng.patch | 52 +++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 package/pipewire/0002-meson.build-fix-build-with-uclibc-ng.patch diff --git a/package/pipewire/0002-meson.build-fix-build-with-uclibc-ng.patch b/package/pipewire/0002-meson.build-fix-build-with-uclibc-ng.patch new file mode 100644 index 0000000000..36b14d3f16 --- /dev/null +++ b/package/pipewire/0002-meson.build-fix-build-with-uclibc-ng.patch @@ -0,0 +1,52 @@ +From 8f1de87381d270a8f4e5927187ae0466a9c9504a Mon Sep 17 00:00:00 2001 +From: Fabrice Fontaine +Date: Tue, 4 May 2021 22:56:54 +0200 +Subject: [PATCH] meson.build: fix build with uclibc-ng + +Build with uclib-ng fails since commit +a4b0b9afe5a782a7f4a8fe153ecf51bcb0180ae3 on: + +FAILED: src/pipewire/libpipewire-0.3.so.0.326.0.p/impl-core.c.o +/srv/storage/autobuild/run/instance-2/output-1/host/bin/mips64el-linux-gcc -Isrc/pipewire/libpipewire-0.3.so.0.326.0.p -Isrc/pipewire -I../src/pipewire -Isrc -I../src -I. -I.. -Ispa/include -I../spa/include -fdiagnostics-color=always -pipe -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -O3 -fvisibility=hidden -Werror=suggest-attribute=format -Wsign-compare -Wpointer-arith -Wpointer-sign -Wformat -Wformat-security -Wimplicit-fallthrough -Wmissing-braces -Wtype-limits -Wvariadic-macros -Wno-missing-field-initializers -Wno-unused-parameter -Wno-pedantic -Wold-style-declaration -Wunused-result -DFASTPATH -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -Os -fPIC -pthread -DHAVE_CONFIG_H -D_GNU_SOURCE -D_POSIX_C_SOURCE -MD -MQ src/pipewire/libpipewire-0.3.so.0.326.0.p/impl-core.c.o -MF src/pipewire/libpipewire-0.3.so.0.326.0.p/impl-core.c.o.d -o src/pipewire/libpipewire-0.3.so.0.326.0.p/impl-core.c.o -c ../src/pipewire/impl-core.c +../src/pipewire/impl-core.c:54:9: error: conflicting types for 'getrandom' + ssize_t getrandom(void *buf, size_t buflen, unsigned int flags) { + ^~~~~~~~~ +In file included from ../src/pipewire/impl-core.c:34: +/srv/storage/autobuild/run/instance-2/output-1/host/mips64el-buildroot-linux-uclibc/sysroot/usr/include/sys/random.h:28:12: note: previous declaration of 'getrandom' was here + extern int getrandom(void *__buf, size_t count, unsigned int flags) + ^~~~~~~~~ + +Fix this build failure by adding -D_GNU_SOURCE as getrandom is protected +by: + +if defined __UCLIBC_LINUX_SPECIFIC__ && defined __USE_GNU + +Extracted from: + - https://github.com/wbx-github/uclibc-ng/blob/master/libc/sysdeps/linux/common/sys/random.h + +Fixes: + - http://autobuild.buildroot.org/results/a45f0ee009d90cef867dee4b1093225610fa10df + +Signed-off-by: Fabrice Fontaine +[Upstream status: +https://gitlab.freedesktop.org/pipewire/pipewire/-/merge_requests/649] +--- + meson.build | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/meson.build b/meson.build +index 0a9963fb..11b63c08 100644 +--- a/meson.build ++++ b/meson.build +@@ -274,7 +274,7 @@ if cc.has_function('memfd_create', prefix : '#include ', args : [ '- + cdata.set('HAVE_MEMFD_CREATE', 1) + endif + +-if cc.has_function('getrandom', prefix : '#include ') ++if cc.has_function('getrandom', prefix : '#include ', args : [ '-D_GNU_SOURCE' ]) + cdata.set('HAVE_GETRANDOM', 1) + endif + +-- +2.30.2 +