happy package accident

Place to discuss Fedora and/or Red Hat
Post Reply
Posts: 668
Joined: Sun Jun 13, 2004 6:38 pm
Location: Hawaii

happy package accident

Post by worker201 » Fri May 13, 2005 7:55 pm

I was trying to determine what version of ffmpeg I had installed, so I tried typing the trusty standby "ffmpeg --version" into the terminal, which has produced the desired result with other programs. Instead, I got this:

Code: Select all

ffmpeg version 0.4.9-pre1, build 4753, Copyright (c) 2000-2004 Fabrice Bellard
  configuration:  --build=i686-redhat-linux-gnu --host=i686-redhat-linux-gnu --target=i386-redhat-linux-gnu --program-prefix= --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man --infodir=/usr/share/info --enable-mp3lame --enable-libogg --enable-vorbis --enable-faad --enable-faac --enable-xvid --enable-a52 --enable-a52bin --enable-pp --enable-shared-pp --enable-shared --enable-gpl --disable-opts --disable-strip
  built on May  5 2005 07:44:24, gcc: 3.4.3 20050227 (Red Hat 3.4.3-22.fc3)
ffmpeg: unrecognized option '--version'
Now this is darn nifty information to have, and I suspect it was only a strange accident that I got it.

This material ought to be available somewhere for every package on my machine. Let's say I wanted to find this info for transcode. What command would produce it? "transcode --version" produces a one-liner giving the version, like it ought to. Following Void's example from another post, the command "rpm -qif /usr/bin/transcode" gives some information, but not as much as I would like.

Does anyone know how to get this extremely valuable information -- on purpose??!!??

User avatar
Void Main
Site Admin
Site Admin
Posts: 5712
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA

Post by Void Main » Fri May 13, 2005 8:13 pm

That is something the author of ffmpeg wrote into his program and not something done automatically. There is not some secret way to get this information out of other programs by running them with some specific command line option. If you look at the ffmpeg source you will see that if you enter an unknown parameter the "show_banner()" function is called:

Code: Select all

static void show_banner(void)
    fprintf(stderr, "ffmpeg version " FFMPEG_VERSION ", build %d, Copyright (c) 2000-2004 Fabrice Bellard\n",
    fprintf(stderr, "  configuration: %s\n", FFMPEG_CONFIGURATION);
    fprintf(stderr, "  built on " __DATE__ " " __TIME__);
#ifdef __GNUC__
    fprintf(stderr, ", gcc: %s\n", __VERSION__);
    fprintf(stderr, ", using a non-gcc compiler\n");
For RPM packages the only sure fire way to see what configure/compile options were used to build the programs is to look at the *.spec file found in the SRPM for that package. I talked about that in your other thread about ffmpeg.

Post Reply