[FFmpeg-devel] [RFC] Modify the ff* tools -version output
Michael Niedermayer
michaelni
Mon Aug 11 21:38:13 CEST 2008
On Fri, Aug 08, 2008 at 09:38:48PM +0200, Stefano Sabatini wrote:
> Hi all,
>
> with the patches applied the output of the ff* tools -version option becomes:
>
> stefano at geppetto ~/s/ffmpeg> ffmpeg -version
> FFmpeg version SVN-r14667, Copyright (c) 2000-2008 Fabrice Bellard, et al.
> configuration: --prefix=/home/stefano --disable-shared --enable-libschroedinger --enable-libx264 --enable-pthreads --enable-gpl --enable-debug=3 --enable-libtheora --enable-libvorbis --enable-avfilter --enable-libamr-nb --enable-libamr-wb --enable-nonfree --enable-libfaad --enable-libfaac --enable-x11grab --enable-libmp3lame --disable-optimizations --disable-mmx
> built on Aug 8 2008 21:21:18, gcc: 4.2.3 20071014 (prerelease) (Debian 4.2.2-3)
> FFmpeg SVN-r14667
> libavutil version(C): 49.9.0
> libavutil version(L): 49.9.0
> libavcodec version(C): 51.63.0
> libavcodec version:(L) 51.63.0
> libavformat version(C): 52.20.0
> libavformat version(L): 52.20.0
> libavdevice version(C): 52.1.0
> libavdevice version(L): 52.1.0
> libavfilter version(C): 0.1.0
> libavfilter version(L): 0.1.0
libavutil a.b.c / d.e.f
...
seems a more sane way to print it
[...]
> Index: libavutil/avutil.h
> ===================================================================
> --- libavutil/avutil.h (revision 14667)
> +++ libavutil/avutil.h (working copy)
> @@ -35,7 +35,7 @@
> #define AV_VERSION(a, b, c) AV_VERSION_DOT(a, b, c)
>
> #define LIBAVUTIL_VERSION_MAJOR 49
> -#define LIBAVUTIL_VERSION_MINOR 8
> +#define LIBAVUTIL_VERSION_MINOR 9
> #define LIBAVUTIL_VERSION_MICRO 0
>
> #define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
> Index: libavutil/common.h
> ===================================================================
> --- libavutil/common.h (revision 14667)
> +++ libavutil/common.h (working copy)
> @@ -412,4 +412,9 @@
> # define NULL_IF_CONFIG_SMALL(x) x
> #endif
>
> +/**
> + * Puts in \p buf a textual representation of \p version.
> + */
> +char* av_stringify_version(char* buf, unsigned buf_size, unsigned version);
> +
> #endif /* FFMPEG_COMMON_H */
> Index: libavutil/utils.c
> ===================================================================
> --- libavutil/utils.c (revision 14667)
> +++ libavutil/utils.c (working copy)
> @@ -27,3 +27,9 @@
> {
> return LIBAVUTIL_VERSION_INT;
> }
> +
> +char* av_stringify_version(char* buf, unsigned buf_size, unsigned version)
> +{
> + snprintf(buf, buf_size, "%d.%d.%d", version >> 16, version >> 8 & 0xff, version & 0xff);
> + return buf;
> +}
am against bloating libavutil with such stuff
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I count him braver who overcomes his desires than him who conquers his
enemies for the hardest victory is over self. -- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080811/684597b4/attachment.pgp>
More information about the ffmpeg-devel
mailing list