Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
* [FFmpeg-devel] [PATCH] lavc/audiotoolbox: fix build failure on osx 10.5
@ 2023-07-11 14:10 Pavel Koshevoy
  2023-07-14 23:50 ` Pavel Koshevoy
  2023-07-15  1:34 ` James Almer
  0 siblings, 2 replies; 4+ messages in thread
From: Pavel Koshevoy @ 2023-07-11 14:10 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Pavel Koshevoy

---
 libavcodec/audiotoolboxdec.c | 2 ++
 libavcodec/audiotoolboxenc.c | 4 ++++
 2 files changed, 6 insertions(+)

diff --git a/libavcodec/audiotoolboxdec.c b/libavcodec/audiotoolboxdec.c
index 82babe3d31..7b33cdf87d 100644
--- a/libavcodec/audiotoolboxdec.c
+++ b/libavcodec/audiotoolboxdec.c
@@ -71,10 +71,12 @@ static UInt32 ffat_get_format_id(enum AVCodecID codec, int profile)
         return kAudioFormatAMR;
     case AV_CODEC_ID_EAC3:
         return kAudioFormatEnhancedAC3;
+#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
     case AV_CODEC_ID_GSM_MS:
         return kAudioFormatMicrosoftGSM;
     case AV_CODEC_ID_ILBC:
         return kAudioFormatiLBC;
+#endif
     case AV_CODEC_ID_MP1:
         return kAudioFormatMPEGLayer1;
     case AV_CODEC_ID_MP2:
diff --git a/libavcodec/audiotoolboxenc.c b/libavcodec/audiotoolboxenc.c
index 1ccfda4d20..f652836018 100644
--- a/libavcodec/audiotoolboxenc.c
+++ b/libavcodec/audiotoolboxenc.c
@@ -69,15 +69,19 @@ static UInt32 ffat_get_format_id(enum AVCodecID codec, int profile)
             return kAudioFormatMPEG4AAC_HE_V2;
         case FF_PROFILE_AAC_LD:
             return kAudioFormatMPEG4AAC_LD;
+#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
         case FF_PROFILE_AAC_ELD:
             return kAudioFormatMPEG4AAC_ELD;
+#endif
         }
     case AV_CODEC_ID_ADPCM_IMA_QT:
         return kAudioFormatAppleIMA4;
     case AV_CODEC_ID_ALAC:
         return kAudioFormatAppleLossless;
+#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
     case AV_CODEC_ID_ILBC:
         return kAudioFormatiLBC;
+#endif
     case AV_CODEC_ID_PCM_ALAW:
         return kAudioFormatALaw;
     case AV_CODEC_ID_PCM_MULAW:
-- 
2.35.3

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

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

* Re: [FFmpeg-devel] [PATCH] lavc/audiotoolbox: fix build failure on osx 10.5
  2023-07-11 14:10 [FFmpeg-devel] [PATCH] lavc/audiotoolbox: fix build failure on osx 10.5 Pavel Koshevoy
@ 2023-07-14 23:50 ` Pavel Koshevoy
  2023-07-15  1:34 ` James Almer
  1 sibling, 0 replies; 4+ messages in thread
From: Pavel Koshevoy @ 2023-07-14 23:50 UTC (permalink / raw)
  To: ffmpeg-devel

ping ... could someone review this please

On Tue, Jul 11, 2023 at 8:10 AM Pavel Koshevoy <pkoshevoy@gmail.com> wrote:

> ---
>  libavcodec/audiotoolboxdec.c | 2 ++
>  libavcodec/audiotoolboxenc.c | 4 ++++
>  2 files changed, 6 insertions(+)
>
> diff --git a/libavcodec/audiotoolboxdec.c b/libavcodec/audiotoolboxdec.c
> index 82babe3d31..7b33cdf87d 100644
> --- a/libavcodec/audiotoolboxdec.c
> +++ b/libavcodec/audiotoolboxdec.c
> @@ -71,10 +71,12 @@ static UInt32 ffat_get_format_id(enum AVCodecID codec,
> int profile)
>          return kAudioFormatAMR;
>      case AV_CODEC_ID_EAC3:
>          return kAudioFormatEnhancedAC3;
> +#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
>      case AV_CODEC_ID_GSM_MS:
>          return kAudioFormatMicrosoftGSM;
>      case AV_CODEC_ID_ILBC:
>          return kAudioFormatiLBC;
> +#endif
>      case AV_CODEC_ID_MP1:
>          return kAudioFormatMPEGLayer1;
>      case AV_CODEC_ID_MP2:
> diff --git a/libavcodec/audiotoolboxenc.c b/libavcodec/audiotoolboxenc.c
> index 1ccfda4d20..f652836018 100644
> --- a/libavcodec/audiotoolboxenc.c
> +++ b/libavcodec/audiotoolboxenc.c
> @@ -69,15 +69,19 @@ static UInt32 ffat_get_format_id(enum AVCodecID codec,
> int profile)
>              return kAudioFormatMPEG4AAC_HE_V2;
>          case FF_PROFILE_AAC_LD:
>              return kAudioFormatMPEG4AAC_LD;
> +#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
>          case FF_PROFILE_AAC_ELD:
>              return kAudioFormatMPEG4AAC_ELD;
> +#endif
>          }
>      case AV_CODEC_ID_ADPCM_IMA_QT:
>          return kAudioFormatAppleIMA4;
>      case AV_CODEC_ID_ALAC:
>          return kAudioFormatAppleLossless;
> +#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
>      case AV_CODEC_ID_ILBC:
>          return kAudioFormatiLBC;
> +#endif
>      case AV_CODEC_ID_PCM_ALAW:
>          return kAudioFormatALaw;
>      case AV_CODEC_ID_PCM_MULAW:
> --
> 2.35.3
>
>
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

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

* Re: [FFmpeg-devel] [PATCH] lavc/audiotoolbox: fix build failure on osx 10.5
  2023-07-11 14:10 [FFmpeg-devel] [PATCH] lavc/audiotoolbox: fix build failure on osx 10.5 Pavel Koshevoy
  2023-07-14 23:50 ` Pavel Koshevoy
@ 2023-07-15  1:34 ` James Almer
  2023-07-15 15:42   ` Pavel Koshevoy
  1 sibling, 1 reply; 4+ messages in thread
From: James Almer @ 2023-07-15  1:34 UTC (permalink / raw)
  To: ffmpeg-devel

On 7/11/2023 11:10 AM, Pavel Koshevoy wrote:
> ---
>   libavcodec/audiotoolboxdec.c | 2 ++
>   libavcodec/audiotoolboxenc.c | 4 ++++
>   2 files changed, 6 insertions(+)
> 
> diff --git a/libavcodec/audiotoolboxdec.c b/libavcodec/audiotoolboxdec.c
> index 82babe3d31..7b33cdf87d 100644
> --- a/libavcodec/audiotoolboxdec.c
> +++ b/libavcodec/audiotoolboxdec.c
> @@ -71,10 +71,12 @@ static UInt32 ffat_get_format_id(enum AVCodecID codec, int profile)
>           return kAudioFormatAMR;
>       case AV_CODEC_ID_EAC3:
>           return kAudioFormatEnhancedAC3;
> +#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058

Wouldn't it be better to do >= with the actual version where all this is 
first available?

>       case AV_CODEC_ID_GSM_MS:
>           return kAudioFormatMicrosoftGSM;
>       case AV_CODEC_ID_ILBC:
>           return kAudioFormatiLBC;
> +#endif
>       case AV_CODEC_ID_MP1:
>           return kAudioFormatMPEGLayer1;
>       case AV_CODEC_ID_MP2:
> diff --git a/libavcodec/audiotoolboxenc.c b/libavcodec/audiotoolboxenc.c
> index 1ccfda4d20..f652836018 100644
> --- a/libavcodec/audiotoolboxenc.c
> +++ b/libavcodec/audiotoolboxenc.c
> @@ -69,15 +69,19 @@ static UInt32 ffat_get_format_id(enum AVCodecID codec, int profile)
>               return kAudioFormatMPEG4AAC_HE_V2;
>           case FF_PROFILE_AAC_LD:
>               return kAudioFormatMPEG4AAC_LD;
> +#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
>           case FF_PROFILE_AAC_ELD:
>               return kAudioFormatMPEG4AAC_ELD;
> +#endif
>           }
>       case AV_CODEC_ID_ADPCM_IMA_QT:
>           return kAudioFormatAppleIMA4;
>       case AV_CODEC_ID_ALAC:
>           return kAudioFormatAppleLossless;
> +#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
>       case AV_CODEC_ID_ILBC:
>           return kAudioFormatiLBC;
> +#endif
>       case AV_CODEC_ID_PCM_ALAW:
>           return kAudioFormatALaw;
>       case AV_CODEC_ID_PCM_MULAW:
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

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

* Re: [FFmpeg-devel] [PATCH] lavc/audiotoolbox: fix build failure on osx 10.5
  2023-07-15  1:34 ` James Almer
@ 2023-07-15 15:42   ` Pavel Koshevoy
  0 siblings, 0 replies; 4+ messages in thread
From: Pavel Koshevoy @ 2023-07-15 15:42 UTC (permalink / raw)
  To: FFmpeg development discussions and patches

On Fri, Jul 14, 2023 at 7:34 PM James Almer <jamrial@gmail.com> wrote:

> On 7/11/2023 11:10 AM, Pavel Koshevoy wrote:
> > ---
> >   libavcodec/audiotoolboxdec.c | 2 ++
> >   libavcodec/audiotoolboxenc.c | 4 ++++
> >   2 files changed, 6 insertions(+)
> >
> > diff --git a/libavcodec/audiotoolboxdec.c b/libavcodec/audiotoolboxdec.c
> > index 82babe3d31..7b33cdf87d 100644
> > --- a/libavcodec/audiotoolboxdec.c
> > +++ b/libavcodec/audiotoolboxdec.c
> > @@ -71,10 +71,12 @@ static UInt32 ffat_get_format_id(enum AVCodecID
> codec, int profile)
> >           return kAudioFormatAMR;
> >       case AV_CODEC_ID_EAC3:
> >           return kAudioFormatEnhancedAC3;
> > +#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1058
>
> Wouldn't it be better to do >= with the actual version where all this is
> first available?
>


I suppose... I've submitted a 2nd version of the patch.

Thank you,
    Pavel.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

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

end of thread, other threads:[~2023-07-15 15:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-11 14:10 [FFmpeg-devel] [PATCH] lavc/audiotoolbox: fix build failure on osx 10.5 Pavel Koshevoy
2023-07-14 23:50 ` Pavel Koshevoy
2023-07-15  1:34 ` James Almer
2023-07-15 15:42   ` Pavel Koshevoy

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git