From nobody Wed Jan 8 13:40:26 2025 X-Original-To: standards@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4YSpvZ5yy1z5kScV for ; Wed, 08 Jan 2025 13:40:26 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (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 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4YSpvZ2Dlmz4fCT for ; Wed, 8 Jan 2025 13:40:26 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1736343626; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=oNP2pVQaS3ePExRTDxBGhWff0GmWWfeyDQxd8Po0iqM=; b=A0wI92onCbrtmRjm2UORSPq2vGte/gRegplf9cwA60rEhlmc5O8V1G0WatlHC5MCrnfnhh SOvaxFABtAtmqZf9yZ/aC3TATVH4/gTbkKSRXzRfu4xEZd5JZaFpCItrbA7cOpA0IxhW0z laJ0MAoLZlo2x0lfnD3MStx5TOhgvENv4+HNhSAOjY0NSLlG4JHH7hdSZC5qzDNSxxHDz6 4JihP226Yx27bIIzlB3z6KMrH5h6e61RrDrevcuj6Akmr1PPE6QeFbsM9Dh/lGMRfdwHKR 7x9HvVqQFzMxr6uJF25271JZUd221qOkkxNpQufiPHjxJR8rkC4wJyV4wGzfng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1736343626; a=rsa-sha256; cv=none; b=JxpV8gwVoDPlzX/MC4wYn7iL04pcYf2dHJKbOc/m7WD8JXk9LfSokYpafr6EtXa14jgkWP 0B1aL2X7KDh0FpNievfPFltEZX8Sr6VasbnneB4BnMdS2mGlHsioSdVdfalKg50oTqqEid Nq8sFMJ+4ICYN0ZxWhlqIC9NWORjR6IgXMED0nmViRoVTJr6LEByP1XiwrBUmUmcLWjS5c fdWOHstujs7X/c352ohqRIKxranRFB9I8eTVBkTvzLP5aHX8qxbrT8KabVzISW9I2/Ae48 c/TeKKGt3P8Bz0FVzKsSfZjZ/4Ky1ucbGLuXAlx3dxCEeJJvAnx7aoMNyYwhpg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (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) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4YSpvZ1P9gzxq6 for ; Wed, 08 Jan 2025 13:40:26 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 508DeQ1q058698 for ; Wed, 8 Jan 2025 13:40:26 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 508DeQ5v058697 for standards@FreeBSD.org; Wed, 8 Jan 2025 13:40:26 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: standards@FreeBSD.org Subject: [Bug 283917] libc failes to include stdint.h with clang>16 and -ffreestanding Date: Wed, 08 Jan 2025 13:40:26 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: standards X-Bugzilla-Version: 14.2-STABLE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: keve@keve.hu X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: standards@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Standards compliance List-Archive: https://lists.freebsd.org/archives/freebsd-standards List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-standards@freebsd.org Sender: owner-freebsd-standards@FreeBSD.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D283917 --- Comment #2 from keve@keve.hu --- Hi Konstantin,=20 thank you for looking at this. I tend to read it differently: The ISO C standard defines (in clause 4) two classes of conforming implementation. A conforming hosted implementation supports the whole stand= ard including all the library facilities; a conforming freestanding implementat= ion is only required to provide certain library facilities: those in , , , and ; since AMD1, also those in ; since C99, also those in and ; and since C11, also th= ose in and . In addition, complex types, added in C= 99, are not required for freestanding implementations. So since C99 it is ok to assume presence of and include stdint.h even with -ffreestanding. Clang starting with 17 implements C99. Also the standard says that a freestanding implementation _may_ not impleme= nt these headers, it does not say anything about it _must_ not implement them. Btw. just confirmed that NetBSD 10.1 can compile this as well. -nostdinc is unfortunately not a viable workaround. Please reconsider your assessment whether this is an issue with FreeBSD lib= c, or not. Thank you! --=20 You are receiving this mail because: You are the assignee for the bug.=