Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build failure with ffmpeg on Ubuntu 14.04 #9

Open
HenkPoley opened this issue Nov 11, 2015 · 2 comments
Open

Build failure with ffmpeg on Ubuntu 14.04 #9

HenkPoley opened this issue Nov 11, 2015 · 2 comments

Comments

@HenkPoley
Copy link

Just come kind of error message in ./configure that this a too old version or something, would be fine by me.

Install development libs

henk@henk-qemu-desktop:/media/henk/VMs/dsp$ sudo apt-get install libavcodec-dev libavformat-dev libavutil-dev
[sudo] password for henk: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Suggested packages:
  libdc1394-22-dev libgsm1-dev libraw1394-dev libschroedinger-dev
  libtheora-dev
The following NEW packages will be installed:
  libavcodec-dev libavformat-dev libavutil-dev
0 upgraded, 3 newly installed, 0 to remove and 15 not upgraded.
Need to get 3287 kB of archives.
After this operation, 12,3 MB of additional disk space will be used.
Get:1 http://nl.archive.ubuntu.com/ubuntu/ trusty-updates/universe libavutil-dev amd64 6:9.18-0ubuntu0.14.04.1 [111 kB]
Get:2 http://nl.archive.ubuntu.com/ubuntu/ trusty-updates/universe libavcodec-dev amd64 6:9.18-0ubuntu0.14.04.1 [2601 kB]
Get:3 http://nl.archive.ubuntu.com/ubuntu/ trusty-updates/universe libavformat-dev amd64 6:9.18-0ubuntu0.14.04.1 [575 kB]
Fetched 3287 kB in 2s (1284 kB/s)       
Selecting previously unselected package libavutil-dev.
(Reading database ... 361017 files and directories currently installed.)
Preparing to unpack .../libavutil-dev_6%3a9.18-0ubuntu0.14.04.1_amd64.deb ...
Unpacking libavutil-dev (6:9.18-0ubuntu0.14.04.1) ...
Selecting previously unselected package libavcodec-dev.
Preparing to unpack .../libavcodec-dev_6%3a9.18-0ubuntu0.14.04.1_amd64.deb ...
Unpacking libavcodec-dev (6:9.18-0ubuntu0.14.04.1) ...
Selecting previously unselected package libavformat-dev.
Preparing to unpack .../libavformat-dev_6%3a9.18-0ubuntu0.14.04.1_amd64.deb ...
Unpacking libavformat-dev (6:9.18-0ubuntu0.14.04.1) ...
Setting up libavutil-dev (6:9.18-0ubuntu0.14.04.1) ...
Setting up libavcodec-dev (6:9.18-0ubuntu0.14.04.1) ...
Setting up libavformat-dev (6:9.18-0ubuntu0.14.04.1) ...

Opaque Debian/Ubuntu releases, from version.h:

  • libavcodec = 54.35.0, most recent upstream would be 56.60.100
  • libavformat = 54.20.4, upstream: 56.40.101
  • libavutil = 52.3.0, upstream: 54.32.100

FFMPEG's own PPA (ppa:mc3man/trusty-media) does not appear to include the header (*-dev) packages.

Clean DSP source:

henk@henk-qemu-desktop:/media/henk/VMs/dsp$ make clean
rm -f dsp ladspa_dsp.so obj/dsp/dsp.o obj/dsp/effect.o obj/dsp/codec.o obj/dsp/sampleconv.o obj/dsp/util.o obj/dsp/biquad.o obj/dsp/gain.o obj/dsp/crossfeed.o obj/dsp/remix.o obj/dsp/delay.o obj/dsp/noise.o obj/dsp/compress.o obj/dsp/stats.o obj/dsp/null.o obj/dsp/pcm.o obj/dsp/sndfile.o obj/dsp/resample.o obj/dsp/fir.o obj/dsp/alsa.o obj/dsp/mp3.o obj/dsp/pulse.o obj/ladspa_dsp/ladspa_dsp.o obj/ladspa_dsp/effect.o obj/ladspa_dsp/util.o obj/ladspa_dsp/biquad.o obj/ladspa_dsp/gain.o obj/ladspa_dsp/crossfeed.o obj/ladspa_dsp/remix.o obj/ladspa_dsp/delay.o obj/ladspa_dsp/noise.o obj/ladspa_dsp/compress.o obj/ladspa_dsp/stats.o obj/ladspa_dsp/fir.o obj/ladspa_dsp/codec.o obj/ladspa_dsp/null.o obj/ladspa_dsp/pcm.o obj/ladspa_dsp/sampleconv.o obj/ladspa_dsp/sndfile.o obj/ladspa_dsp/mp3.o

Configure:

henk@henk-qemu-desktop:/media/henk/VMs/dsp$ ./configure 
enabled dsp
[dsp] enabled sndfile.o (sndfile)
[dsp] enabled ffmpeg.o (libavcodec libavformat libavutil)
[dsp] enabled resample.o fir.o (fftw3)
[dsp] enabled alsa.o (alsa)
[dsp] disabled ao.o (ao)
[dsp] enabled mp3.o (mad)
[dsp] enabled pulse.o (libpulse-simple)
enabled ladspa_dsp
[ladspa_dsp] enabled fir.o (fftw3)
[ladspa_dsp] enabled sndfile.o (sndfile)
[ladspa_dsp] enabled ffmpeg.o (libavcodec libavformat libavutil)
[ladspa_dsp] enabled mp3.o (mad)

Build DSP:

henk@henk-qemu-desktop:/media/henk/VMs/dsp$ make
cc -c -o obj/dsp/dsp.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    dsp.c
cc -c -o obj/dsp/effect.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    effect.c
cc -c -o obj/dsp/codec.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    codec.c
cc -c -o obj/dsp/sampleconv.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    sampleconv.c
cc -c -o obj/dsp/util.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    util.c
cc -c -o obj/dsp/biquad.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    biquad.c
cc -c -o obj/dsp/gain.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    gain.c
cc -c -o obj/dsp/crossfeed.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    crossfeed.c
cc -c -o obj/dsp/remix.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    remix.c
cc -c -o obj/dsp/delay.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    delay.c
cc -c -o obj/dsp/noise.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    noise.c
cc -c -o obj/dsp/compress.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    compress.c
cc -c -o obj/dsp/stats.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    stats.c
cc -c -o obj/dsp/null.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    null.c
cc -c -o obj/dsp/pcm.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    pcm.c
cc -c -o obj/dsp/sndfile.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    sndfile.c
cc -c -o obj/dsp/ffmpeg.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    ffmpeg.c
ffmpeg.c: In function ‘ffmpeg_read’:
ffmpeg.c:104:5: warning: implicit declaration of function ‘av_frame_unref’ [-Wimplicit-function-declaration]
     av_frame_unref(state->frame);
     ^
ffmpeg.c: In function ‘ffmpeg_destroy’:
ffmpeg.c:177:2: warning: implicit declaration of function ‘av_frame_free’ [-Wimplicit-function-declaration]
  av_frame_free(&state->frame);
  ^
ffmpeg.c: In function ‘ffmpeg_codec_init’:
ffmpeg.c:203:3: warning: implicit declaration of function ‘av_err2str’ [-Wimplicit-function-declaration]
   LOG(LL_OPEN_ERROR, "dsp: ffmpeg: error: failed to open %s: %s: %s\n",
   ^
ffmpeg.c:203:3: warning: format ‘%s’ expects argument of type ‘char *’, but argument 5 has type ‘int’ [-Wformat=]
ffmpeg.c:208:3: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘int’ [-Wformat=]
   LOG(LL_ERROR, "dsp: ffmpeg: error: could not find stream info: %s\n", av_err2str(err));
   ^
ffmpeg.c:223:3: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘int’ [-Wformat=]
   LOG(LL_ERROR, "dsp: ffmpeg: error: could not open required decoder: %s\n", av_err2str(err));
   ^
ffmpeg.c:226:2: warning: implicit declaration of function ‘av_frame_alloc’ [-Wimplicit-function-declaration]
  state->frame = av_frame_alloc();
  ^
ffmpeg.c:226:15: warning: assignment makes pointer from integer without a cast [enabled by default]
  state->frame = av_frame_alloc();
               ^
cc -c -o obj/dsp/resample.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    resample.c
cc -c -o obj/dsp/fir.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    fir.c
cc -c -o obj/dsp/alsa.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    alsa.c
cc -c -o obj/dsp/mp3.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    mp3.c
cc -c -o obj/dsp/pulse.o -Os -Wall -std=gnu99 -D__HAVE_SNDFILE__ -D__HAVE_FFMPEG__ -D__HAVE_FFTW3__ -D__HAVE_ALSA__ -D__HAVE_MAD__ -D__HAVE_PULSE__ -D_REENTRANT -I/usr/local/include -I/usr/include/alsa    pulse.c
cc -o dsp   obj/dsp/dsp.o obj/dsp/effect.o obj/dsp/codec.o obj/dsp/sampleconv.o obj/dsp/util.o obj/dsp/biquad.o obj/dsp/gain.o obj/dsp/crossfeed.o obj/dsp/remix.o obj/dsp/delay.o obj/dsp/noise.o obj/dsp/compress.o obj/dsp/stats.o obj/dsp/null.o obj/dsp/pcm.o obj/dsp/sndfile.o obj/dsp/ffmpeg.o obj/dsp/resample.o obj/dsp/fir.o obj/dsp/alsa.o obj/dsp/mp3.o obj/dsp/pulse.o -L/usr/local/lib -lsndfile -lavcodec -lavformat -lavutil -lfftw3 -lasound -lmad -lpulse-simple -lpulse   -lm
obj/dsp/ffmpeg.o: In function `ffmpeg_read':
ffmpeg.c:(.text+0x348): undefined reference to `av_frame_unref'
obj/dsp/ffmpeg.o: In function `ffmpeg_destroy':
ffmpeg.c:(.text+0x4f4): undefined reference to `av_frame_free'
obj/dsp/ffmpeg.o: In function `ffmpeg_codec_init':
ffmpeg.c:(.text+0x58e): undefined reference to `av_err2str'
ffmpeg.c:(.text+0x5e8): undefined reference to `av_err2str'
ffmpeg.c:(.text+0x67c): undefined reference to `av_err2str'
ffmpeg.c:(.text+0x6a2): undefined reference to `av_frame_alloc'
ffmpeg.c:(.text+0x8bf): undefined reference to `av_frame_free'
collect2: error: ld returned 1 exit status
make: *** [dsp] Error 1
@bmc0
Copy link
Owner

bmc0 commented Nov 11, 2015

This is because 14.04 uses libav instead of "real" ffmpeg, which doesn't appear to have some of the functions I use. Since libav seems to be on its way out (Debian and Ubuntu are now switching back to ffmpeg), I have to say I'm not that interested in supporting it.

@HenkPoley
Copy link
Author

That is good enough for me at the moment.

Just posted this, so you know what happens. Might be have been a different problem with an easy fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants