All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components
@ 2010-06-14 10:00 Luca Ceresoli
  2010-06-14 11:25 ` Peter Korsgaard
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Ceresoli @ 2010-06-14 10:00 UTC (permalink / raw)
  To: buildroot

Peter Korsgaard wrote:
> >>>>> "Luca" == Luca Ceresoli <luca@lucaceresoli.net> writes:
> 
> Hi,
> 
>  Luca> +ifneq ($(BR2_PACKAGE_FFMPEG_DECODERS),"all")
>  >> 
>  >> I would suggest you use qstrip + strip here as well, so it doesn't break if the
>  >> user accidently added extra spaces or so.
> 
>  Luca> How can foreach break with extra spaces? I've been trying things as:
>  >> BR2_PACKAGE_FFMPEG_ENCODERS="   vorbis    flac  "
>  Luca> and they work ok.
> 
> Not the foreach, but the ifneq (....,"all") would break if the user
> ended up setting it to "all " or " all" or similar.

Sorry, now I got what you mean.

Why do you say qstrip+strip anyway? qstrip does strip itself:

> # Strip quotes and then whitespaces                                                                    
> qstrip=$(strip $(subst ",,$(1)))                                                                       
> #"))

So I would do:
-ifneq ($(BR2_PACKAGE_FFMPEG_ENCODERS),"all")
+ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_ENCODERS)),all)

If that's ok, it will be in the re-submitted patches.

> 
> -- 
> Bye, Peter Korsgaard
> 

Luca

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components
  2010-06-14 10:00 [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components Luca Ceresoli
@ 2010-06-14 11:25 ` Peter Korsgaard
  0 siblings, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2010-06-14 11:25 UTC (permalink / raw)
  To: buildroot

>>>>> "Luca" == Luca Ceresoli <luca@lucaceresoli.net> writes:

Hi,

 >> Not the foreach, but the ifneq (....,"all") would break if the user
 >> ended up setting it to "all " or " all" or similar.

 Luca> Sorry, now I got what you mean.

 Luca> Why do you say qstrip+strip anyway? qstrip does strip itself:

Ahh yes, then just qstrip.

 Luca> So I would do:
 Luca> -ifneq ($(BR2_PACKAGE_FFMPEG_ENCODERS),"all")
 Luca> +ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_ENCODERS)),all)

 Luca> If that's ok, it will be in the re-submitted patches.

Yes please.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components
  2010-06-14  8:50 Luca Ceresoli
@ 2010-06-14  9:26 ` Peter Korsgaard
  0 siblings, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2010-06-14  9:26 UTC (permalink / raw)
  To: buildroot

>>>>> "Luca" == Luca Ceresoli <luca@lucaceresoli.net> writes:

Hi,

 Luca> +ifneq ($(BR2_PACKAGE_FFMPEG_DECODERS),"all")
 >> 
 >> I would suggest you use qstrip + strip here as well, so it doesn't break if the
 >> user accidently added extra spaces or so.

 Luca> How can foreach break with extra spaces? I've been trying things as:
 >> BR2_PACKAGE_FFMPEG_ENCODERS="   vorbis    flac  "
 Luca> and they work ok.

Not the foreach, but the ifneq (....,"all") would break if the user
ended up setting it to "all " or " all" or similar.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components
@ 2010-06-14  8:50 Luca Ceresoli
  2010-06-14  9:26 ` Peter Korsgaard
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Ceresoli @ 2010-06-14  8:50 UTC (permalink / raw)
  To: buildroot

Peter Korsgaard wrote:
> >>>>> "Luca" == Luca Ceresoli <luca@lucaceresoli.net> writes:
> 
>  Luca> Add the option to customize the list of decoders, encoders,
>  Luca> muxers, demuxers, parsers, protocols, bsfs and filters to be
>  Luca> built into ffmpeg, and to compile or exclude input and output
>  Luca> devices.
> 
>  Luca> +++ b/package/multimedia/ffmpeg/ffmpeg.mk
>  Luca> @@ -49,6 +49,58 @@ else
>  Luca>  FFMPEG_CONF_OPT += --disable-ffserver
>  Luca>  endif
>  
>  Luca> +ifneq ($(BR2_PACKAGE_FFMPEG_ENCODERS),"all")
>  Luca> +FFMPEG_CONF_OPT += --disable-encoders \
>  Luca> +	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_ENCODERS)),--enable-encoder=$(x))
>  Luca> +endif
>  Luca> +
>  Luca> +ifneq ($(BR2_PACKAGE_FFMPEG_DECODERS),"all")
> 
> I would suggest you use qstrip + strip here as well, so it doesn't break if the
> user accidently added extra spaces or so.

How can foreach break with extra spaces? I've been trying things as:
> BR2_PACKAGE_FFMPEG_ENCODERS="   vorbis    flac  "
and they work ok.

BTW, that was with GNU make. Relevant?

> 
> -- 
> Bye, Peter Korsgaard
> 

Luca

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components
  2010-06-12 16:22 ` [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components Luca Ceresoli
@ 2010-06-13 12:01   ` Peter Korsgaard
  0 siblings, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2010-06-13 12:01 UTC (permalink / raw)
  To: buildroot

>>>>> "Luca" == Luca Ceresoli <luca@lucaceresoli.net> writes:

 Luca> Add the option to customize the list of decoders, encoders,
 Luca> muxers, demuxers, parsers, protocols, bsfs and filters to be
 Luca> built into ffmpeg, and to compile or exclude input and output
 Luca> devices.

 Luca> +++ b/package/multimedia/ffmpeg/ffmpeg.mk
 Luca> @@ -49,6 +49,58 @@ else
 Luca>  FFMPEG_CONF_OPT += --disable-ffserver
 Luca>  endif
 
 Luca> +ifneq ($(BR2_PACKAGE_FFMPEG_ENCODERS),"all")
 Luca> +FFMPEG_CONF_OPT += --disable-encoders \
 Luca> +	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_ENCODERS)),--enable-encoder=$(x))
 Luca> +endif
 Luca> +
 Luca> +ifneq ($(BR2_PACKAGE_FFMPEG_DECODERS),"all")

I would suggest you use qstrip + strip here as well, so it doesn't break if the
user accidently added extra spaces or so.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components
  2010-06-12 16:22 [Buildroot] Add ffmpeg support Luca Ceresoli
@ 2010-06-12 16:22 ` Luca Ceresoli
  2010-06-13 12:01   ` Peter Korsgaard
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Ceresoli @ 2010-06-12 16:22 UTC (permalink / raw)
  To: buildroot

Add the option to customize the list of decoders, encoders, muxers, demuxers,
parsers, protocols, bsfs and filters to be built into ffmpeg, and to compile or
exclude input and output devices.

Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
---
 package/multimedia/ffmpeg/Config.in |   88 +++++++++++++++++++++++++++++++++++
 package/multimedia/ffmpeg/ffmpeg.mk |   52 ++++++++++++++++++++
 2 files changed, 140 insertions(+), 0 deletions(-)

diff --git a/package/multimedia/ffmpeg/Config.in b/package/multimedia/ffmpeg/Config.in
index 736a8ec..7530929 100644
--- a/package/multimedia/ffmpeg/Config.in
+++ b/package/multimedia/ffmpeg/Config.in
@@ -47,4 +47,92 @@ config BR2_PACKAGE_FFMPEG_FFSERVER
 	help
          FFserver is a streaming server for both audio and video.
 
+config BR2_PACKAGE_FFMPEG_ENCODERS
+	string "Enabled encoders"
+	default "all"
+	help
+	 Space-separated list of encoders to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-encoders in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_DECODERS
+	string "Enabled decoders"
+	default "all"
+	help
+	 Space-separated list of decoders to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-decoders in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_MUXERS
+	string "Enabled muxers"
+	default "all"
+	help
+	 Space-separated list of muxers to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-muxers in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_DEMUXERS
+	string "Enabled demuxers"
+	default "all"
+	help
+	 Space-separated list of demuxers to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-demuxers in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_PARSERS
+	string "Enabled parsers"
+	default "all"
+	help
+	 Space-separated list of parsers to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-parsers in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_BSFS
+	string "Enabled bitstreams"
+	default "all"
+	help
+	 Space-separated list of bitstream filters to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-bsfs in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_PROTOCOLS
+	string "Enabled protocols"
+	default "all"
+	help
+	 Space-separated list of protocols to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-protocols in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_FILTERS
+	string "Enabled filters"
+	default "all"
+	help
+	 Space-separated list of filters to build in FFmpeg,
+	 or "all" to build all of them.
+
+	 Run ./configure --list-filters in the ffmpeg sources
+	 directory to know the available options.
+
+config BR2_PACKAGE_FFMPEG_INDEVS
+	bool "Enable input devices"
+	default y
+
+config BR2_PACKAGE_FFMPEG_OUTDEVS
+	bool "Enable output devices"
+	default y
+
 endif
diff --git a/package/multimedia/ffmpeg/ffmpeg.mk b/package/multimedia/ffmpeg/ffmpeg.mk
index 0af08e5..3fc4990 100644
--- a/package/multimedia/ffmpeg/ffmpeg.mk
+++ b/package/multimedia/ffmpeg/ffmpeg.mk
@@ -49,6 +49,58 @@ else
 FFMPEG_CONF_OPT += --disable-ffserver
 endif
 
+ifneq ($(BR2_PACKAGE_FFMPEG_ENCODERS),"all")
+FFMPEG_CONF_OPT += --disable-encoders \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_ENCODERS)),--enable-encoder=$(x))
+endif
+
+ifneq ($(BR2_PACKAGE_FFMPEG_DECODERS),"all")
+FFMPEG_CONF_OPT += --disable-decoders \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_DECODERS)),--enable-decoder=$(x))
+endif
+
+ifneq ($(BR2_PACKAGE_FFMPEG_MUXERS),"all")
+FFMPEG_CONF_OPT += --disable-muxers \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_MUXERS)),--enable-muxer=$(x))
+endif
+
+ifneq ($(BR2_PACKAGE_FFMPEG_DEMUXERS),"all")
+FFMPEG_CONF_OPT += --disable-demuxers \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_DEMUXERS)),--enable-demuxer=$(x))
+endif
+
+ifneq ($(BR2_PACKAGE_FFMPEG_PARSERS),"all")
+FFMPEG_CONF_OPT += --disable-parsers \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_PARSERS)),--enable-parser=$(x))
+endif
+
+ifneq ($(BR2_PACKAGE_FFMPEG_BSFS),"all")
+FFMPEG_CONF_OPT += --disable-bsfs \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_BSFS)),--enable-bsf=$(x))
+endif
+
+ifneq ($(BR2_PACKAGE_FFMPEG_PROTOCOLS),"all")
+FFMPEG_CONF_OPT += --disable-protocols \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_PROTOCOLS)),--enable-protocol=$(x))
+endif
+
+ifneq ($(BR2_PACKAGE_FFMPEG_FILTERS),"all")
+FFMPEG_CONF_OPT += --disable-filters \
+	$(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_FILTERS)),--enable-filter=$(x))
+endif
+
+ifeq ($(BR2_PACKAGE_FFMPEG_INDEVS),y)
+FFMPEG_CONF_OPT += --enable-indevs
+else
+FFMPEG_CONF_OPT += --disable-indevs
+endif
+
+ifeq ($(BR2_PACKAGE_FFMPEG_OUTDEVS),y)
+FFMPEG_CONF_OPT += --enable-outdevs
+else
+FFMPEG_CONF_OPT += --disable-outdevs
+endif
+
 ifeq ($(BR2_PTHREADS_NONE),y)
 FFMPEG_CONF_OPT += --disable-pthreads
 else
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-06-14 11:25 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-14 10:00 [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components Luca Ceresoli
2010-06-14 11:25 ` Peter Korsgaard
  -- strict thread matches above, loose matches on Subject: below --
2010-06-14  8:50 Luca Ceresoli
2010-06-14  9:26 ` Peter Korsgaard
2010-06-12 16:22 [Buildroot] Add ffmpeg support Luca Ceresoli
2010-06-12 16:22 ` [Buildroot] [PATCH 3/4] ffmpeg: allow customization of codecs, (de)muxers and other components Luca Ceresoli
2010-06-13 12:01   ` Peter Korsgaard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.