From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from conssluserg-02.nifty.com (conssluserg-02.nifty.com [210.131.2.81]) by sourceware.org (Postfix) with ESMTPS id 703113858D1E for ; Mon, 6 Feb 2023 13:53:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 703113858D1E Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=nifty.ne.jp Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=nifty.ne.jp Received: from HP-Z230 (aj135041.dynamic.ppp.asahi-net.or.jp [220.150.135.41]) (authenticated) by conssluserg-02.nifty.com with ESMTP id 316DrDp5001547 for ; Mon, 6 Feb 2023 22:53:13 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-02.nifty.com 316DrDp5001547 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.ne.jp; s=dec2015msa; t=1675691593; bh=T9QsZ8duw4AVyO+E1pX4BuI/Vzf2foNxmKdgEC3+kGM=; h=Date:From:To:Subject:In-Reply-To:References:From; b=BY3QE7cqJmPr5p1gnKzdgEFOpe57H6L9ikM0DOMn0lUggeguVyKN5MdcXBylq/Z8V kRNt4Bywnriuvu3HzW7WtutBNCaASzqwmmlWJuySWDArqjpK3KNTd9Gl3KuMRPeQpU nh8FxhFdAmv353euxwoIMrYj1/hvMryUrA16guHdAISJppgEubxBzvpgHtaxLLdabC 5hah5Z7noRMkH68Lw/a8vTyLl+RsSc78SHoGNSvZp/pHyQ9zybUsEeCCOEUHfE/UGS Dd3kYmNGcqTzXACm9xpZcQ03aFamotP+t2ST8k7z+uT7nsYbKZFchDWAeiWKmTw2rj MRt5GUziZGt+w== X-Nifty-SrcIP: [220.150.135.41] Date: Mon, 6 Feb 2023 22:53:13 +0900 From: Takashi Yano To: cygwin-apps@cygwin.com Subject: Re: [ITP] ffmpeg (5.1.2) Message-Id: <20230206225313.755d5cc007ae62721997b1da@nifty.ne.jp> In-Reply-To: <20230205174018.e3b9b3dde9d21555af07861d@nifty.ne.jp> References: <20230120193540.a32d7180d8fa690f886ef625@nifty.ne.jp> <5afd1512-3f5f-ab90-50b4-1e00100ea68c@dronecode.org.uk> <20230122212559.815a8c2f08bb127d926ec1ce@nifty.ne.jp> <20230124122850.acbc1fb3135d376122783d05@nifty.ne.jp> <20230205174018.e3b9b3dde9d21555af07861d@nifty.ne.jp> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.30; i686-pc-mingw32) Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="Multipart=_Mon__6_Feb_2023_22_53_13_+0900_c/7KQlN8z84_N35=" X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: This is a multi-part message in MIME format. --Multipart=_Mon__6_Feb_2023_22_53_13_+0900_c/7KQlN8z84_N35= Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Sun, 5 Feb 2023 17:40:18 +0900 Takashi Yano wrote: > On Sat, 4 Feb 2023 16:45:13 +0000 > Jon Turney wrote: > > On 24/01/2023 03:28, Takashi Yano via Cygwin-apps wrote: > > >>> Thanks! > > >>> > > >>> For a long time, ffmpeg was not included in Fedora, due to concerns > > >>> about codec patents, but those issues seem to have been resolved. > > >>> > > >>> Can you please investigate what configuration is used in Fedora, and > > >>> what the effects of matching that would be? > > >> > > >> Thanks. I will check the configuration of fedora. > > > > > > I have checked the configuration of ffmpeg in fedora. > > > It seems that most of codecs are disabled in fedora > > > by default unless 'all_codecs' flag is specified. > > > https://src.fedoraproject.org/rpms/ffmpeg/blob/f37/f/ffmpeg.spec > > > > > > I have built a ffmpeg package using the configuration > > > almost imitated fedora. > > > https://tyan0.yr32.net/cygwin/x86_64/release/ffmpeg-free/ > > > > > > You would find this ffmpeg of the above configuration is > > > almost unuseful... > > > aac, h264, hevc, mpeg4, wma, wmv, etc. are not supported. > > > > > > I also imitated the configuration with 'all_codecs' flag > > > and have built another ffmpeg package. > > > https://tyan0.yr32.net/cygwin/x86_64/release/ffmpeg-all_codecs/ > > > > > > This is almost common with the major ports of ffmpeg. > > > > > > Could you please review them? > > > > Thanks for looking into this. The packaging looks fine from a technical > > standpoint. > > > > The concern here is that we have an informal policy to only accept > > packages which is would be allowed in Fedora (by it's policies on > > content and being free of legal encumbrances (e.g. license, patent and > > trademark issues)) > > > > After some discussions, it seems that policy should be formal. I've > > amended [1] to state that. > > > > I'm sorry to cause you more trouble, but given that, can you package > > this based on the codec set in Fedora's ffmpeg-free? > > Thank you for your consideration. I have re-arranged the ffmpeg > package basend on Fedora's ffmpeg-free package. > > https://tyan0.yr32.net/cygwin/x86_64/release/ffmpeg/ > > > If you don't think the package is useful under those constraints, don't > > let this discourage you from offering either the cygport for interested > > people to build it themselves, or the packages via an overlay package > > server [2] > > As I mentioned in IRC, the Fedora approved numerous of codecs for > ffmpeg recently. As a result, ffmpeg-free package becomes much more > useful compared to the past. > > As far as using for ffmpeg-plugin of moc (Music player), it has > almost enough codecs. > > ffmpeg itself might be somewhat weak (e.g., no x264, x265), > however, it whold be much better than nothing. > > > [1] https://cygwin.com/packaging-contributors-guide.html#submitting > > [2] https://cygwin.com/package-server.html#overlay I revised the cygport file as attached. -- Takashi Yano --Multipart=_Mon__6_Feb_2023_22_53_13_+0900_c/7KQlN8z84_N35= Content-Type: text/plain; name="ffmpeg.cygport" Content-Disposition: attachment; filename="ffmpeg.cygport" Content-Transfer-Encoding: 7bit NAME="ffmpeg" VERSION=5.1.2 RELEASE=1 CATEGORY="Audio Video" SUMMARY="A complete solution to record, convert and stream audio and video." DESCRIPTION="FFmpeg is the leading multimedia framework, able to decode, encode, transcode, mux, demux, stream and filter pretty much anything that humans and machines have created. It supports the most obscure ancient formats up to the cutting edge." HOMEPAGE="https://ffmpeg.org/" LICENSE="GPL-3.0-or-later" SRC_URI="http://ffmpeg.org/releases/${NAME}-${VERSION}.tar.xz" PATCH_URI=" https://src.fedoraproject.org/rpms/ffmpeg/raw/rawhide/f/ffmpeg-codec-choice.patch https://src.fedoraproject.org/rpms/ffmpeg/raw/rawhide/f/ffmpeg-new-coder-errors.patch https://src.fedoraproject.org/rpms/ffmpeg/raw/rawhide/f/ffmpeg-allow-fdk-aac-free.patch https://src.fedoraproject.org/rpms/ffmpeg/raw/rawhide/f/ffmpeg-dlopen-openh264.patch " all_codecs="no" # Set to "yes" if you want to enable all codecs. if [ ${all_codecs} = "yes" ] then cat << _EOF_ > ffmpeg-wchar.patch --- origsrc/ffmpeg-5.1.2/libavcodec/mf_utils.h 2022-07-23 02:58:39.000000000 +0900 +++ src/ffmpeg-5.1.2/libavcodec/mf_utils.h 2023-01-26 12:33:12.745550400 +0900 @@ -29,6 +29,7 @@ // mf*.h headers below indirectly include strmif.h.) #include #else +#include #define NO_DSHOW_STRSAFE #include // Older versions of mingw-w64 need codecapi.h explicitly included, while newer _EOF_ PATCH_URI+=" ffmpeg-wchar.patch" else SRC_URI+=" ffmpeg_free_sources enable_decoders enable_encoders" fi CYGPORT_USE_UNSTABLE_API=1 src_unpack_hook() { rm -f libavcodec/libopenh264_dlopen.{c,h} if [ ${all_codecs} = "yes" ] then # restore original sources pushd .. pushd ../.. rm ${NAME}-${VERSION}.tar.xz wget http://ffmpeg.org/releases/${NAME}-${VERSION}.tar.xz popd tar xf ../../${NAME}-${VERSION}.tar.xz popd else # make tarball which has only free sources pushd .. free_sources=$(sed "s%^%${NAME}-${VERSION}/%" ../../ffmpeg_free_sources) free_sources_tarball="../../${NAME}-${VERSION}.tar.xz" tar acf ${free_sources_tarball} ${free_sources} rm -rf ${NAME}-${VERSION} tar xf ${free_sources_tarball} popd fi } PKG_NAMES="ffmpeg libffmpeg5 libffmpeg-devel ffmpeg-doc" ffmpeg_CONTENTS="--exclude=usr/share/ffmpeg/examples usr/bin/*.exe usr/share/ffmpeg usr/share/man/man1" libffmpeg5_CATEGORY="Audio Video Libs" libffmpeg5_SUMMARY="FFmpeg runtime libraries." libffmpeg5_CONTENTS="usr/bin/*.dll" libffmpeg_devel_CATEGORY="Audio Video Devel" libffmpeg_devel_SUMMARY="FFmpeg development package." libffmpeg_devel_CONTENTS="usr/include usr/lib usr/share/ffmpeg/examples usr/share/man/man3" ffmpeg_doc_CATEGORY="Audio Video" ffmpeg_doc_SUMMARY="FFmpeg documentation" ffmpeg_doc_CONTENTS="usr/share/doc" conf_args="--prefix=/usr --enable-pic --disable-stripping --enable-shared --disable-static --enable-gpl --enable-version3 --disable-openssl --enable-bzlib --enable-gcrypt --enable-gnutls --enable-ladspa --disable-cuda-sdk --enable-libaom --enable-libass --enable-libbs2b --enable-libfdk-aac --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libmfx --enable-libmodplug --enable-libmp3lame --enable-libopenh264-dlopen --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libxml2 --enable-libxvid --enable-libzmq --enable-openal --enable-opencl --enable-opengl --enable-pthreads" if [ ${all_codecs} = "yes" ] then conf_args+=" --pkg-config-flags=--static --enable-libx264 --enable-libx265" else conf_args+=" --enable-muxers --enable-demuxers --enable-hwaccels --disable-encoders --disable-decoders --disable-decoder=h264,hevc,vc1 --enable-encoder=$(perl -pe 's{^(\w*).*}{$1,}gs' < enable_encoders) --enable-decoder=$(perl -pe 's{^(\w*).*}{$1,}gs' < enable_decoders)" fi src_compile() { cd ${B} ${S}/configure ${conf_args} cygmake } BUILD_REQUIRES="libiconv-devel liblzma-devel libzstd-devel libbz2-devel libxcb-shm-devel libSDL2-devel libgnutls-devel ladspa-sdk cygwin-devel libass-devel libbs2b-devel libmp3lame-devel libopenjpeg-devel libopenmpt-devel librsvg2-devel libsnappy-devel libsoxr-devel speex-devel libssh-devel libtheora-devel libtwolame-devel libvorbis-devel libvpx-devel libwebp-devel libxml2-devel libzmq-devel libfribidi-devel libmodplug-devel libgsm-devel libopenjp2-devel libgcrypt-devel libfontconfig-devel libfreetype-devel libopenal-devel libOpenCL-devel libfdk-aac-devel xvidcore libopenh264-headers nv-codec-headers AMF libmfx-devel libaom-devel" --Multipart=_Mon__6_Feb_2023_22_53_13_+0900_c/7KQlN8z84_N35=--