[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: rpmbuild problem during g++ linking - undefined references ?



On 14/11/2007, David Timms <dtimms iinet net au> wrote:
> Hi, I'm trying to build an rpm for Fedora for DVBCut. I get a fair way
> through the process, but erroring out with:
>
> g++ -o src/moc_dvbcut.o -c -O3 -Wall -D_FILE_OFFSET_BITS=64
> -D_LARGEFILE_SOURCE -DHAVE_LIB_AO -DQT_NO_DEBUG
> -I/usr/lib/qt-3.3/include -I/usr/include src/moc_dvbcut.cpp
> /usr/lib/qt-3.3/bin/moc -o src/moc_exportdialog.cpp src/exportdialog.h
>
> g++ -o src/moc_exportdialog.o -c -O3 -Wall -D_FILE_OFFSET_BITS=64
> -D_LARGEFILE_SOURCE -DHAVE_LIB_AO -DQT_NO_DEBUG
> -I/usr/lib/qt-3.3/include -I/usr/include src/moc_exportdialog.cpp
> /usr/lib/qt-3.3/bin/moc -o src/moc_progressstatusbar.cpp
> src/progressstatusbar.h
>
> g++ -o src/moc_progressstatusbar.o -c -O3 -Wall -D_FILE_OFFSET_BITS=64
> -D_LARGEFILE_SOURCE -DHAVE_LIB_AO -DQT_NO_DEBUG
> -I/usr/lib/qt-3.3/include -I/usr/include src/moc_progressstatusbar.cpp
> /usr/lib/qt-3.3/bin/moc -o src/moc_progresswindow.cpp src/progresswindow.h
>
> g++ -o src/moc_progresswindow.o -c -O3 -Wall -D_FILE_OFFSET_BITS=64
> -D_LARGEFILE_SOURCE -DHAVE_LIB_AO -DQT_NO_DEBUG
> -I/usr/lib/qt-3.3/include -I/usr/include src/moc_progresswindow.cpp
>
> g++ -o bin/dvbcut src/avframe.o src/buffer.o
> src/differenceimageprovider.o src/dvbcut.o src/eventlistitem.o
> src/exportdialog.o src/imageprovider.o src/index.o src/lavfmuxer.o
> src/logoutput.o src/main.o src/mpegmuxer.o src/mpgfile.o src/playaudio.o
> src/progressstatusbar.o src/progresswindow.o src/psfile.o src/pts.o
> src/settings.o src/streamdata.o src/tsfile.o src/uic_dvbcutbase.o
> src/moc_dvbcutbase.o src/uic_mplayererrorbase.o
> src/moc_mplayererrorbase.o src/uic_progresswindowbase.o
> src/moc_progresswindowbase.o src/uic_exportdialogbase.o
> src/moc_exportdialogbase.o src/moc_dvbcut.o src/moc_exportdialog.o
> src/moc_progressstatusbar.o src/moc_progresswindow.o
> -L/usr/lib/qt-3.3/lib -L/usr/lib -lao -lqt-mt -lavformat -lavcodec -lavutil
>
> { the two -L paths definitely contain the -l{lib}xyz so's. }
>
> src/avframe.o: In function `avframe::avframe()':
> avframe.cpp:(.text+0x2e): undefined reference to `avcodec_alloc_frame()'
> src/avframe.o: In function `avframe::avframe()':
> avframe.cpp:(.text+0x6e): undefined reference to `avcodec_alloc_frame()'
> src/avframe.o: In function `avframe::getqimage(bool, int)':
> avframe.cpp:(.text+0x13c): undefined reference to
> `avpicture_get_size(int, int, int)'
> avframe.cpp:(.text+0x16f): undefined reference to `avcodec_alloc_frame()'
> avframe.cpp:(.text+0x19d): undefined reference to
> `avpicture_fill(AVPicture*, unsigned char*, int, int, int)'
> avframe.cpp:(.text+0x1cb): undefined reference to
> `img_convert(AVPicture*, int, AVPicture const*, int, int, int)'
> avframe.cpp:(.text+0x271): undefined reference to `av_free(void*)'
> src/avframe.o: In function `avframe::avframe(AVFrame*, AVCodecContext*)':
> avframe.cpp:(.text+0x320): undefined reference to `avcodec_alloc_frame()'
>
> The app {dvbcut} website installer procedure says you need:
>      *  Qt, version 3
>      * SCons (a modern build utility, replacing automake, autoconf and make)
>      * libao (optional, for sound output)
>      * libmad and liba52 for MP2 and AC3 decoding, respectively.
>
> On a Debian system, the following packages should do the job:
> libqt3-mt-dev qt3-dev-tools scons libao-dev libmad0-dev liba52-0.7.4-dev.

Funny.  libavformat, libavcodec and libavutil are from ffmpeg and not
mentioned in your list. ffmpeg has broken interface and binary
compatibility frequently, so you may need to build with a version
that's compatible.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]