Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2224600/?format=api
{ "id": 2224600, "url": "http://patchwork.ozlabs.org/api/patches/2224600/?format=api", "web_url": "http://patchwork.ozlabs.org/project/buildroot/patch/20260417171046.12548-1-chakrabortyshubham66@gmail.com/", "project": { "id": 27, "url": "http://patchwork.ozlabs.org/api/projects/27/?format=api", "name": "Buildroot development", "link_name": "buildroot", "list_id": "buildroot.buildroot.org", "list_email": "buildroot@buildroot.org", "web_url": "", "scm_url": "", "webscm_url": "", "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20260417171046.12548-1-chakrabortyshubham66@gmail.com>", "list_archive_url": null, "date": "2026-04-17T17:10:45", "name": "[v2] package/make: fix conflicting prototypes for getenv and getopt", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "a0f0529ea3bad63b2c6761aa16e8dec7bf2668db", "submitter": { "id": 92564, "url": "http://patchwork.ozlabs.org/api/people/92564/?format=api", "name": "Shubham Chakraborty", "email": "chakrabortyshubham66@gmail.com" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/buildroot/patch/20260417171046.12548-1-chakrabortyshubham66@gmail.com/mbox/", "series": [ { "id": 500376, "url": "http://patchwork.ozlabs.org/api/series/500376/?format=api", "web_url": "http://patchwork.ozlabs.org/project/buildroot/list/?series=500376", "date": "2026-04-17T17:10:45", "name": "[v2] package/make: fix conflicting prototypes for getenv and getopt", "version": 2, "mbox": "http://patchwork.ozlabs.org/series/500376/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2224600/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2224600/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<buildroot-bounces@buildroot.org>", "X-Original-To": [ "incoming-buildroot@patchwork.ozlabs.org", "buildroot@buildroot.org" ], "Delivered-To": [ "patchwork-incoming-buildroot@legolas.ozlabs.org", "buildroot@buildroot.org" ], "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=buildroot.org header.i=@buildroot.org\n header.a=rsa-sha256 header.s=default header.b=Tc/eo6no;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org\n (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org;\n envelope-from=buildroot-bounces@buildroot.org; receiver=patchwork.ozlabs.org)" ], "Received": [ "from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fy1cY1Cs1z1yCv\n\tfor <incoming-buildroot@patchwork.ozlabs.org>;\n Sat, 18 Apr 2026 03:11:09 +1000 (AEST)", "from localhost (localhost [127.0.0.1])\n\tby smtp4.osuosl.org (Postfix) with ESMTP id 6EBA740BD3;\n\tFri, 17 Apr 2026 17:11:07 +0000 (UTC)", "from smtp4.osuosl.org ([127.0.0.1])\n by localhost (smtp4.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id Nw0LDhTwzkCl; Fri, 17 Apr 2026 17:11:06 +0000 (UTC)", "from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142])\n\tby smtp4.osuosl.org (Postfix) with ESMTP id 9023440BC6;\n\tFri, 17 Apr 2026 17:11:06 +0000 (UTC)", "from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136])\n by lists1.osuosl.org (Postfix) with ESMTP id 1C337259\n for <buildroot@buildroot.org>; Fri, 17 Apr 2026 17:11:05 +0000 (UTC)", "from localhost (localhost [127.0.0.1])\n by smtp3.osuosl.org (Postfix) with ESMTP id 19A1560EC1\n for <buildroot@buildroot.org>; Fri, 17 Apr 2026 17:11:05 +0000 (UTC)", "from smtp3.osuosl.org ([127.0.0.1])\n by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id f7K6sI2M2tjc for <buildroot@buildroot.org>;\n Fri, 17 Apr 2026 17:11:04 +0000 (UTC)", "from mail-pg1-x52b.google.com (mail-pg1-x52b.google.com\n [IPv6:2607:f8b0:4864:20::52b])\n by smtp3.osuosl.org (Postfix) with ESMTPS id 1D55660EBF\n for <buildroot@buildroot.org>; Fri, 17 Apr 2026 17:11:03 +0000 (UTC)", "by mail-pg1-x52b.google.com with SMTP id\n 41be03b00d2f7-c06cb8004e8so355966a12.0\n for <buildroot@buildroot.org>; Fri, 17 Apr 2026 10:11:03 -0700 (PDT)", "from fedora ([2409:40e5:112e:daba:4994:b597:7615:a059])\n by smtp.gmail.com with ESMTPSA id\n 41be03b00d2f7-c797701d9bfsm1915006a12.16.2026.04.17.10.10.59\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Fri, 17 Apr 2026 10:11:02 -0700 (PDT)" ], "X-Virus-Scanned": [ "amavis at osuosl.org", "amavis at osuosl.org" ], "X-Comment": "SPF check N/A for local connections - client-ip=140.211.166.142;\n helo=lists1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org;\n receiver=<UNKNOWN> ", "DKIM-Filter": [ "OpenDKIM Filter v2.11.0 smtp4.osuosl.org 9023440BC6", "OpenDKIM Filter v2.11.0 smtp3.osuosl.org 1D55660EBF" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=buildroot.org;\n\ts=default; t=1776445866;\n\tbh=ykxMa7jndzx8HacJjpKvi8sJKdOBe8/Sx+Yvq1jMvX0=;\n\th=From:To:Cc:Date:In-Reply-To:References:Subject:List-Id:\n\t List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe:\n\t From;\n\tb=Tc/eo6noDD2ViUzTd4KJDdPjbRyvtMRYjEt27SikIju2+AF/jyBvl0X+URHk0dVdm\n\t kdQXXBafviAhdIwPVCWGjhglPvufaiLKSxpqJ2KXO+n+V8ncpD6ilR0HGy/Him8B6I\n\t CQyHQS6FTbB6ozg/famb+9U/AOsGkNXG8pU0qmlwocGF21u6TtthJ7wc9AiPmFtIRt\n\t GgA99xHeYzFBlR5GoHdEntBa6k9SUR7v5FHvcqoq/7fnDL7YFlTD1uP4Ei4lmTAPbP\n\t H1K4cuW4JvUT40MnhgKG2hUnAcONS15GLS7tzxZLxiUj91nUG2QRvPEzkuSEMJ3W29\n\t NLjdJSgDCE9dw==", "Received-SPF": "Pass (mailfrom) identity=mailfrom;\n client-ip=2607:f8b0:4864:20::52b; helo=mail-pg1-x52b.google.com;\n envelope-from=chakrabortyshubham66@gmail.com; receiver=<UNKNOWN>", "DMARC-Filter": "OpenDMARC Filter v1.4.2 smtp3.osuosl.org 1D55660EBF", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776445863; x=1777050663;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=UxJmcRVL8dJb/Yj2I017hYTAn69XNpKhKjvT0aSkBYI=;\n b=nXNWbUA+7pmwjw8QG6Ftd7+hAgxdTauVTP+LPQ2MCSlJn+Rv9XgtPCryjfe/GmcD7m\n bal87hUzzACNF5N/IZ4brJVSqJI5xjn1muwy6EGJjXdqlxsExf90YvWPphN+Vtz3KRxH\n gkuJxbLs+9FdRnkiuZsxGzDHaYqeGXssJrckLn9Y75Kfi9cOgPcCHvw5J+/+O71PhqlM\n d+yzS5PzXVRJRBlFa4LHjlfWqS136lLx3a2F4DUXHil5Gqu9ZUy3Em7zUR3TEB+aHHNj\n wn97AXI+FkcoQiML4z2K9W9dfn9UhpVp8db9ET0KCz1bDlCMJTQUaVWRrZBuSzLVFpSH\n Mptg==", "X-Gm-Message-State": "AOJu0YzxyNFN7OW60jGdOfPYFSWzGU2arw9Ew2E+fLZaLoTEVW3mCSnc\n knS62SbAIO991cngy/qtGy6gFANeCEzwNlbmMLzuZHS+agWAVVfKhsDOIaXHeg==", "X-Gm-Gg": "AeBDiet8mLWoJgAFRgs6khwU8h3+hi1iXUpc9mnRgboReWQ/2s5kozz65bt1B+NiimI\n 1R6k6Pz6s0/PsddxGAxj14ENaGdxwphY7tTtpnP9XbQUworRIYN9DxzpxJVnBy7YiO7myQYrwxY\n XtDB2dy2vbIKSpVPkxHhPwL/GY2ooVAPvNxMrkjPpHc+EIPBTrqhtqrwwnAUesUFvgnj0UAngHf\n 4OCCs5+MrLB/R7fzSdyQikpXNC5xiGzfJ16/1he7nA528WnET3+8AKeANMDyol2NA4FCPD5oX0E\n AuFwGz6Qf5PlmRiyjMj82Ww2sA/eT6PvSxyanLoq2ExLNCAube0llBxR/Dl+18rRSzlIo8L4elR\n bJkP9IyM0PxCb4Zoo5bxa/GDBM9Nw1t476bopyrNVljOxsqa3vxpddFnETPvYOkLdCdQrW+Nysw\n DpWH59t7hwe0CVjk+wM8eQPCfmKUldq33RQaHumlut0kbnyCASj8sLD9L+", "X-Received": "by 2002:a05:6a21:e082:b0:39f:91e9:cada with SMTP id\n adf61e73a8af0-3a08d677abemr4260803637.9.1776445862759;\n Fri, 17 Apr 2026 10:11:02 -0700 (PDT)", "From": "Shubham Chakraborty <chakrabortyshubham66@gmail.com>", "To": "buildroot@buildroot.org", "Cc": "Shubham Chakraborty <chakrabortyshubham66@gmail.com>", "Date": "Fri, 17 Apr 2026 22:40:45 +0530", "Message-ID": "<20260417171046.12548-1-chakrabortyshubham66@gmail.com>", "X-Mailer": "git-send-email 2.53.0", "In-Reply-To": "<20260220192301.119525-1-chakrabortyshubham66@gmail.com>", "References": "<20260220192301.119525-1-chakrabortyshubham66@gmail.com>", "MIME-Version": "1.0", "X-Mailman-Original-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=gmail.com; s=20251104; t=1776445863; x=1777050663; darn=buildroot.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=UxJmcRVL8dJb/Yj2I017hYTAn69XNpKhKjvT0aSkBYI=;\n b=WPYDCCeJ5X73fGK1UdgEWFKwqkg2OZ0Am1qGomudd5XD+myAsNEvpHx+K1GmatWGIg\n 08eW3RKW5soj9tOG8NVFnm3ov03Oz63BtukcirwguUrgyIKNmiOR6ASmN95p85sxI+v8\n obve5x4dTdh4wrOVm8x+E411F60WD2MH4SD2U6OXNcEVRMTMY62aQQMqjQ/rWmlZdCAr\n aAgfM3XRqC74l8aRQlbZI0kcKNHsdbGO//QASt9E533vKfmZ8Nylda6lYSnWSj41wMCa\n JIb6mfI96oKXJJHwah0JLPKXCzeuGSXyUSZ+SQlDjR7FC0VMlNBKhfMFOeYYmgoV2Jeb\n rrUw==", "X-Mailman-Original-Authentication-Results": [ "smtp3.osuosl.org;\n dmarc=pass (p=none dis=none)\n header.from=gmail.com", "smtp3.osuosl.org;\n dkim=pass (2048-bit key,\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=WPYDCCeJ" ], "Subject": "[Buildroot] [PATCH v2] package/make: fix conflicting prototypes for\n getenv and getopt", "X-BeenThere": "buildroot@buildroot.org", "X-Mailman-Version": "2.1.30", "Precedence": "list", "List-Id": "Discussion and development of buildroot <buildroot.buildroot.org>", "List-Unsubscribe": "<https://lists.buildroot.org/mailman/options/buildroot>,\n <mailto:buildroot-request@buildroot.org?subject=unsubscribe>", "List-Archive": "<http://lists.buildroot.org/pipermail/buildroot/>", "List-Post": "<mailto:buildroot@buildroot.org>", "List-Help": "<mailto:buildroot-request@buildroot.org?subject=help>", "List-Subscribe": "<https://lists.buildroot.org/mailman/listinfo/buildroot>,\n <mailto:buildroot-request@buildroot.org?subject=subscribe>", "Content-Type": "text/plain; charset=\"us-ascii\"", "Content-Transfer-Encoding": "7bit", "Errors-To": "buildroot-bounces@buildroot.org", "Sender": "\"buildroot\" <buildroot-bounces@buildroot.org>" }, "content": "GCC 15 defaults to C23, which rejects old-style K&R empty parameter\nlist declarations that conflict with typed prototypes in system headers.\nThis is particularly visible when using non-glibc C libraries (e.g. musl).\n\nFixes:\nlib/fnmatch.c:124:14: error: conflicting types for 'getenv'; have 'char *(void)'\n| 124 | extern char *getenv ();\n| | ^~~~~~\n\nFix getenv() declarations in lib/fnmatch.c and src/getopt.c, and\nfix getopt() declarations in src/getopt.h to match the prototypes\nin <stdlib.h> and <unistd.h>.\n\nUpstream: https://lists.gnu.org/archive/html/bug-make/2025-03/msg00032.html\n\nSigned-off-by: Shubham Chakraborty <chakrabortyshubham66@gmail.com>\n\n---\nv1 -> v2:\n - Add Upstream: tag with link to bug-make mailing list (Marcus)\n - Include specific GCC 15 error log in commit message\n - Improve commit description with more technical context\n - Update patch headers to standard format\n---\n ...ing-prototypes-for-getenv-and-getopt.patch | 70 +++++++++++++++++++\n 1 file changed, 70 insertions(+)\n create mode 100644 package/make/0001-fix-conflicting-prototypes-for-getenv-and-getopt.patch", "diff": "diff --git a/package/make/0001-fix-conflicting-prototypes-for-getenv-and-getopt.patch b/package/make/0001-fix-conflicting-prototypes-for-getenv-and-getopt.patch\nnew file mode 100644\nindex 0000000000..70f2dc2886\n--- /dev/null\n+++ b/package/make/0001-fix-conflicting-prototypes-for-getenv-and-getopt.patch\n@@ -0,0 +1,70 @@\n+From b64b62d00cb64b62d00cb64b62d00cb64b62d00c Mon Sep 17 00:00:00:00 2001\n+From: Shubham Chakraborty <chakrabortyshubham66@gmail.com>\n+Date: Sat, 21 Feb 2026 12:00:00 +0000\n+Subject: [PATCH] fix conflicting prototypes for getenv and getopt\n+\n+GCC 15 defaults to C23, which rejects old-style K&R empty parameter\n+list declarations that conflict with typed prototypes in system headers.\n+\n+Fix getenv() declarations in lib/fnmatch.c and src/getopt.c, and\n+fix getopt() declarations in src/getopt.h to match the prototypes\n+in <stdlib.h> and <unistd.h>.\n+\n+This fixes build errors like:\n+error: conflicting types for 'getenv'; have 'char *(void)'\n+\n+Upstream: https://lists.gnu.org/archive/html/bug-make/2025-03/msg00032.html\n+Signed-off-by: Shubham Chakraborty <chakrabortyshubham66@gmail.com>\n+---\n+ lib/fnmatch.c | 2 +-\n+ src/getopt.c | 2 +-\n+ src/getopt.h | 4 ++--\n+ 3 files changed, 4 insertions(+), 4 deletions(-)\n+\n+diff --git a/lib/fnmatch.c b/lib/fnmatch.c\n+--- a/lib/fnmatch.c\n++++ b/lib/fnmatch.c\n+@@ -121,7 +121,7 @@\n+ whose names are inconsistent. */\n+ \n+ # if !defined _LIBC && !defined getenv\n+-extern char *getenv ();\n++extern char *getenv (const char *__name);\n+ # endif\n+ \n+ # ifndef errno\n+diff --git a/src/getopt.c b/src/getopt.c\n+--- a/src/getopt.c\n++++ b/src/getopt.c\n+@@ -202,7 +202,7 @@\n+ whose names are inconsistent. */\n+ \n+ #ifndef getenv\n+-extern char *getenv ();\n++extern char *getenv (const char *__name);\n+ #endif\n+ \n+ static char *\n+diff --git a/src/getopt.h b/src/getopt.h\n+--- a/src/getopt.h\n++++ b/src/getopt.h\n+@@ -102,7 +102,7 @@\n+ errors, only prototype getopt for the GNU C library. */\n+ extern int getopt (int argc, char *const *argv, const char *shortopts);\n+ #else /* not __GNU_LIBRARY__ */\n+-extern int getopt ();\n++extern int getopt (int argc, char *const *argv, const char *shortopts);\n+ #endif /* __GNU_LIBRARY__ */\n+ extern int getopt_long (int argc, char *const *argv, const char *shortopts,\n+ \t\t const struct option *longopts, int *longind);\n+@@ -116,7 +116,7 @@\n+ \t\t const struct option *longopts, int *longind,\n+ \t\t\t int long_only);\n+ #else /* not __STDC__ */\n+-extern int getopt ();\n++extern int getopt (int argc, char *const *argv, const char *shortopts);\n+ extern int getopt_long ();\n+ extern int getopt_long_only ();\n+ \n+-- \n+2.43.0\n", "prefixes": [ "v2" ] }