From nobody Mon Mar 27 12:59:08 2023 X-Original-To: freebsd-current@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 4PlXvX2ysyz42F8w for ; Mon, 27 Mar 2023 12:59:20 +0000 (UTC) (envelope-from eduardo@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PlXvX1y4tz3pl4 for ; Mon, 27 Mar 2023 12:59:20 +0000 (UTC) (envelope-from eduardo@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1679921960; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=z4VexPiEcd7TqK1JS63JQSfWim026ky5XGoqq1wQWpo=; b=NN5FhkPXFsHkQtp5p9PaWk2lk8YOELUXKH9lbV2VW7IOrKIuJYWbNViaVRs/l/zGqbtQqU elmccp0p0dYymKCTvifDbWJ6XnKo5j+0TdRZ9r7kTgMkxUokQCMwgrqNKOTInAyypXZlm+ 1U+/clLk0pgox1I2wMnjEZKDsjHXn9Mt/7d1NqUUC2LFCLBJsJUMIlAe8Ow0vyoG7sIkO1 nVf7v3eNBPethALhUdYAq2s3xnZTdJ3FxVdVt/SefG2WgJ4kpZQCo1bGo0xLBOK9NAXu53 CPsdCeY2Rk5UVYgb9s4VKsDVzg5ftzmn+4XdwcVhDi7ewYfLU4c6Lnb8Ikq1xA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1679921960; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=z4VexPiEcd7TqK1JS63JQSfWim026ky5XGoqq1wQWpo=; b=QVeXU1OJKbOzFGaG4SEsKTzeP7/uyNPJs5EHKVnSHl4Ig0JWqt5kgNWaP+hqi9Ki6YorGU XdT55WwQyQ+HzMw2NlVb1cPX0Bc12EY49UFBwhQAb5rdUgYfVdbIjFNfuvb+izYF2qaXHz JUJ+NWX4UdOfOTgoP2Mi2MzmxPuq/KwFO/1P5chQvfURPwE5roDdROHoSDRksWNMZSR6ZX cyZXUsEK1LuZxJEsrvGYHU+OPmMg89t9CIpkiirPWOy2l/V/AspwRgvt6o4qJKU4dGJ5XZ 5vjW5hO6rZC569A8aiD5cWzLgMPKxhEarg8pA7P5UOlmt4EpgupaXqq6+axc0Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1679921960; a=rsa-sha256; cv=none; b=B8FoyDrlTR91OsP+GUiKFsxusCKycrDDwGC0xsttfT0iqPPUVOtcngctVNEey5HvY5xlqT oDUJGHpy6nQLeUL4iefgqGKGLnq6ey6xN+IAo40C+C4cb0podTuCW3HR/q7Peu6y5m8iUi y9F0JwYdcQHa80QwpQ6JiOhMayH66yAfdLHqgg/rDr+y5KhAfgjM08wo9IwGZcR7QqVAmJ 7gmmQTGVResEfVEoir77X/sQJxAgb9IyG5PK3XeCxDg6Luj32huZliLi/1Y1TTeVEphC1f VeGdD0tpK9A8uFw5AWVX8CtSYPCZJUJfT8I5yMOpHt4UYIfra4WJMmX+KROFBg== Received: from mail-ua1-f47.google.com (mail-ua1-f47.google.com [209.85.222.47]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) (Authenticated sender: eduardo) by smtp.freebsd.org (Postfix) with ESMTPSA id 4PlXvX0gLJz1QL0 for ; Mon, 27 Mar 2023 12:59:20 +0000 (UTC) (envelope-from eduardo@freebsd.org) Received: by mail-ua1-f47.google.com with SMTP id h34so6247987uag.4 for ; Mon, 27 Mar 2023 05:59:20 -0700 (PDT) X-Gm-Message-State: AAQBX9fsnWsW2ZDsE2wRJVQ3AWRw/j85C6ZvUAFM0+3d4W+UuW9keLCO SJ0d6XdhcLonXhBzE/+kCjFiOlMgkpAKxEjOSBg= X-Google-Smtp-Source: AKy350YkZvJJPovW+MNKiStwUv7L2t+az25DsaD3rC1igEx/uSaJYVcOWt+aqi2tPOV53Dfg5vsY7O3aQSGCfDYr3Ug= X-Received: by 2002:a05:6130:122:b0:764:a9a0:9a55 with SMTP id h34-20020a056130012200b00764a9a09a55mr7243824uag.0.1679921959657; Mon, 27 Mar 2023 05:59:19 -0700 (PDT) List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@freebsd.org MIME-Version: 1.0 References: <13BBF767-6CBB-41D5-AD93-6ADD9C417811@FreeBSD.org> <1aa553c9-79b9-30a0-e4ca-95b1057f1d80@gmail.com> In-Reply-To: From: Nuno Teixeira Date: Mon, 27 Mar 2023 13:59:08 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: byteswap.h not found on 12 and 13 To: Warner Losh Cc: "Floyd, Paul" , freebsd-current@freebsd.org Content-Type: multipart/alternative; boundary="000000000000a7e86505f7e14f0d" X-ThisMailContainsUnwantedMimeParts: N --000000000000a7e86505f7e14f0d Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Fixed at https://cgit.freebsd.org/ports/commit/?id=3Dfb22e1c2e3653558065ffa0509c3c02= 0834723db Thanks all, Nuno Teixeira escreveu no dia sexta, 24/03/2023 =C3= =A0(s) 11:15: > I'm thinking in the best plan to patch port. > What about patch it for OSVERSION < 14 that will fix 12 and 13 and when > 13.2 is out patching it only for 12. > > Any thoughts? > > Warner Losh escreveu no dia sexta, 24/03/2023 =C3=A0(s) = 09:37: > >> >> >> On Fri, Mar 24, 2023 at 3:23=E2=80=AFAM Floyd, Paul wrote: >> >>> >>> A modern and standard solution is std::byteswap. >>> >>> https://en.cppreference.com/w/cpp/numeric/byteswap >>> >>> According to this >>> >>> https://en.cppreference.com/w/cpp/compiler_support#C.2B.2B23_library_fe= atures >>> >>> you will need llvm 14 for that. >>> >> >> Which doesn't help OP since they needed 12 and 13 support for existing >> software. >> Also, that's C++ only, which I don't think helps either. >> >> I'm glad to see some articulated standards here because when I did >> endian.h >> and byteswap.h, it was a minefield of what can or can't be defined in th= e >> face >> of existing use. >> >> Warner >> >> >>> A+ >>> >>> Paul >>> >>> >>> >>> >>> > > -- > Nuno Teixeira > FreeBSD Committer (ports) > --=20 Nuno Teixeira FreeBSD Committer (ports) --000000000000a7e86505f7e14f0d Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks all,

=
Nuno Teixeira <eduardo@freebsd.org> escreveu no dia sexta, 24/0= 3/2023 =C3=A0(s) 11:15:
I'm thinking in the best plan to patch po= rt.
What about patch it for OSVERSION < 14 that will fix 12 an= d 13 and when 13.2 is out patching it only for 12.

Any thoughts?

Warner Losh <imp@bsdimp.com> escreveu no dia sexta, 24/03/2023 = =C3=A0(s) 09:37:


On Fri, Mar 24, 2023 at 3:23=E2=80= =AFAM Floyd, Paul <paulf2718@gmail.com> wrote:

A modern and standard solution is std::byteswap.

https://en.cppreference.com/w/cpp/numeric/byteswap=

According to this
https://en.cppreference= .com/w/cpp/compiler_support#C.2B.2B23_library_features

you will need llvm 14 for that.

Which d= oesn't help OP since they needed 12 and 13 support for existing softwar= e.
Also, that's C++ only, which I don't think helps eithe= r.

I'm glad to see some articulated standards = here because when I did endian.h
and byteswap.h, it was a minefie= ld of what can or can't be defined in the face
of existing us= e.

Warner
=C2=A0
A+

Paul






--
Nuno TeixeiraFreeBSD Committer (ports)


--
Nuno Teixeira
FreeBSD Committ= er (ports)
--000000000000a7e86505f7e14f0d--