From nobody Mon Aug 21 17:13:10 2023 X-Original-To: dev-commits-ports-main@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 4RTzZb1lWHz4r33V; Mon, 21 Aug 2023 17:13:11 +0000 (UTC) (envelope-from git@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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RTzZb1D6yz4W5c; Mon, 21 Aug 2023 17:13:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692637991; 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; bh=3CexHfcceqDmB23fZKgXQC+4YaE4+4rrXaLXVC7boAM=; b=EJmzfKqzMuMOxevY9/eXnmgKA1KAJPK8RYdPB0kBpODH22MB4jQ1m9MxYjLpUUG34eZFHa DkKf1wOmnXhx9cuqNyGO6AIT71m/LQGqOxSDiey3OldlRgiNbrZqg1shKrK3Rww+kNanvc 9VRtC6aYd850SSFogP68md1/KeO/OMeIvx3ZQ+MnIruOoaimfdydCPmyHBSQNa9udVsQCE eDgzyQhUCVc5OkcoHk0LeASYq8zQ0yOiEkR77hH2eSDJISBwT9m0P9Uyjw47FnwCPFKKr6 07kVLB+YK+5sFdypKYcgUhVmIKE0HHHMP74wv8t+NUkkmb9u4AWY7x9uOe1Qwg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692637991; 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; bh=3CexHfcceqDmB23fZKgXQC+4YaE4+4rrXaLXVC7boAM=; b=Ix0fYQXCD43bYpjek6Syal36ckm0wbIUk+eisz3lOQzTGTlaf4DYNPEl6RMy5tx7/eqgX8 5IJC4LyCymH8bKuAptnsGGalSCPphRRNRPvHPI8eLIk6FeHHBxt9CEvQPTs3C1f/Vg32V4 NdQvsWPAyb771AfuZGIrlfssgINYu7sb+7fqRLSFIX4gjDCven+5NohKU9zDtRqVrztmYw kEFFu5MI7uSqMA3OZsj/Bo73ZXERPV6mHwA8/5csjeunhTzs2kCeEY5HAd2RaIEYZwL0tF OGQY09aHKpt4UM0R+b3iGBUBdASJD39fldFMjmN/ZOX8rAtqcbCV+qikJlm1DA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1692637991; a=rsa-sha256; cv=none; b=fJ0GlQHTWSIxqDSc7WGTciOjDvwqLcfOhA6ABP6ZYJOIfpTmLEwfS+veYeTPtfezqI19/B grtR0JiKq+dTV+ItL1+AGFemfLSez2FwmuXeYaMlrBMmkYs4FvWf1CjSe0v8rEd1JKTBja yqsBDgG0o4137fJGbo3+TQcBwW15QCN0qgFX5Qn6NGhhiGoshCbmy5rIgVFlTuVb3E7uKP +anZCEQejl9gsls7hvtL+5+Yv+YGlk521526ilwCWIsSvRe1/CIEjlQLLJbyjBQ8P06en1 8AHXQAydfV4dBcZ72FrkH9yZ/mcslWHCdwefWE5CUiMoAyHirv52k3/naOhoNw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 4RTzZZ740dzTth; Mon, 21 Aug 2023 17:13:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 37LHDAew097899; Mon, 21 Aug 2023 17:13:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 37LHDAfN097896; Mon, 21 Aug 2023 17:13:10 GMT (envelope-from git) Date: Mon, 21 Aug 2023 17:13:10 GMT Message-Id: <202308211713.37LHDAfN097896@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Po-Chuan Hsieh Subject: git: d19fe7ff24ed - main - audio/libfishsound: Fix build with Clang 16 and remove the workaround List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sunpoet X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d19fe7ff24ed397d90248e2588ee6c8518cf172d Auto-Submitted: auto-generated The branch main has been updated by sunpoet: URL: https://cgit.FreeBSD.org/ports/commit/?id=d19fe7ff24ed397d90248e2588ee6c8518cf172d commit d19fe7ff24ed397d90248e2588ee6c8518cf172d Author: Po-Chuan Hsieh AuthorDate: 2023-08-21 17:02:46 +0000 Commit: Po-Chuan Hsieh CommitDate: 2023-08-21 17:02:46 +0000 audio/libfishsound: Fix build with Clang 16 and remove the workaround flac.c:253:8: error: incompatible function pointer types passing 'FLAC__StreamDecoderReadStatus (const FLAC__StreamDecoder *, FLAC__byte *, unsigned int *, void *)' (aka 'FLAC__StreamDecoderReadStatus (const FLAC__StreamDecoder *, unsigned char *, unsigned int *, void *)') to parameter of type 'FLAC__StreamDecoderReadCallback' (aka 'FLAC__StreamDecoderReadStatus (*)(const FLAC__StreamDecoder *, unsigned char *, unsigned long *, void *)') [-Wincompatible-function-pointer-types] fs_flac_read_callback, ^~~~~~~~~~~~~~~~~~~~~ /usr/local/include/FLAC/stream_decoder.h:1092:34: note: passing argument to parameter 'read_callback' here FLAC__StreamDecoderReadCallback read_callback, ^ flac.c:597:8: error: incompatible function pointer types passing 'FLAC__StreamEncoderWriteStatus (const FLAC__StreamEncoder *, const FLAC__byte *, unsigned int, unsigned int, unsigned int, void *)' (aka 'FLAC__StreamEncoderWriteStatus (const FLAC__StreamEncoder *, const unsigned char *, unsigned int, unsigned int, unsigned int, void *)') to parameter of type 'FLAC__StreamEncoderWriteCallback' (aka 'FLAC__StreamEncoderWriteStatus (*)(const FLAC__StreamEncoder *, const unsigned char *, unsigned long, unsigned int, unsigned int, void *)') [-Wincompatible-function-pointer-types] fs_flac_enc_write_callback, ^~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/local/include/FLAC/stream_encoder.h:1532:136: note: passing argument to parameter 'write_callback' here FLAC_API FLAC__StreamEncoderInitStatus FLAC__stream_encoder_init_stream(FLAC__StreamEncoder *encoder, FLAC__StreamEncoderWriteCallback write_callback, FLAC__StreamEncoderSeekCallback seek_callback, FLAC__StreamEncoderTellCallback tell_callback, FLAC__StreamEncoderMetadataCallback metadata_callback, void *client_data); 16 warnings and 2 errors generated. Tested on: 14.0-CURRENT (1400093) --- audio/libfishsound/Makefile | 6 ------ .../files/patch-src-libfishsound-flac.c | 22 ++++++++++++++++++++++ 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/audio/libfishsound/Makefile b/audio/libfishsound/Makefile index 9ff7aaba0552..8f157fb7de3a 100644 --- a/audio/libfishsound/Makefile +++ b/audio/libfishsound/Makefile @@ -29,12 +29,6 @@ DOXYGEN_IMPLIES=DOCS DOXYGEN_BUILD_DEPENDS= doxygen:devel/doxygen -.include - -.if ${OPSYS} == FreeBSD && ( ${OSVERSION} >= 1400091 || ( ${OSVERSION} >= 1302507 && ${OSVERSION} < 1400000 )) -CFLAGS+= -Wno-error=incompatible-function-pointer-types -.endif - post-patch-DOCS-off: @${REINPLACE_CMD} -e '/^SUBDIRS = / s| doc||' ${WRKSRC}/Makefile.in diff --git a/audio/libfishsound/files/patch-src-libfishsound-flac.c b/audio/libfishsound/files/patch-src-libfishsound-flac.c new file mode 100644 index 000000000000..dfea5e263cfa --- /dev/null +++ b/audio/libfishsound/files/patch-src-libfishsound-flac.c @@ -0,0 +1,22 @@ +--- src/libfishsound/flac.c.orig 2010-02-03 13:34:02 UTC ++++ src/libfishsound/flac.c +@@ -106,7 +106,7 @@ fs_flac_command (FishSound * fsound, int command, void + #if FS_DECODE + static FLAC__StreamDecoderReadStatus + fs_flac_read_callback(const FLAC__StreamDecoder *decoder, +- FLAC__byte buffer[], unsigned int *bytes, ++ FLAC__byte buffer[], size_t *bytes, + void *client_data) + { + FishSound* fsound = (FishSound*)client_data; +@@ -346,8 +346,8 @@ dec_err: + #if FS_ENCODE + static FLAC__StreamEncoderWriteStatus + fs_flac_enc_write_callback(const FLAC__StreamEncoder *encoder, +- const FLAC__byte buffer[], unsigned bytes, +- unsigned samples, unsigned current_frame, ++ const FLAC__byte buffer[], size_t bytes, ++ uint32_t samples, uint32_t current_frame, + void *client_data) + { + FishSound* fsound = (FishSound*)client_data;