Skip to content

New Compilation issue #15

@JesseYang-CQ

Description

@JesseYang-CQ

Hi Xavier,
when i update my gcc version, and run the "make" the problem happens, i tried to add the extern “C” in the writer and reader.cpp, but still does work? would you help me to have a look at what's wrong?

../LibAvWrapper/libLibAvWrapper.a(VideoWriter.cpp.o): In function IMT::LibAv::VideoWriter::EncodeAndWrite(AVFrame*, int)': VideoWriter.cpp:(.text+0x116): undefined reference to avcodec_send_frame'
VideoWriter.cpp:(.text+0x1b8): undefined reference to av_packet_unref' VideoWriter.cpp:(.text+0x1e5): undefined reference to avcodec_receive_packet'
VideoWriter.cpp:(.text+0x1f7): undefined reference to av_packet_unref' VideoWriter.cpp:(.text+0x206): undefined reference to av_frame_unref'
VideoWriter.cpp:(.text+0x21a): undefined reference to av_frame_free' ../LibAvWrapper/libLibAvWrapper.a(VideoWriter.cpp.o): In function IMT::LibAv::VideoWriter::EncodeAndWrite(cv::Mat const&, int)':
VideoWriter.cpp:(.text+0x2b9): undefined reference to av_frame_alloc' ../LibAvWrapper/libLibAvWrapper.a(VideoReader.cpp.o): In function ToMat(AVCodecContext*, AVFrame*)':
VideoReader.cpp:(.text+0x8de): undefined reference to av_frame_alloc' VideoReader.cpp:(.text+0xc8d): undefined reference to av_frame_unref'
VideoReader.cpp:(.text+0xc97): undefined reference to av_frame_free' ../LibAvWrapper/libLibAvWrapper.a(VideoReader.cpp.o): In function IMT::LibAv::VideoReader::DecodeNextStep()':
VideoReader.cpp:(.text+0x109b): undefined reference to av_frame_alloc' VideoReader.cpp:(.text+0x10c4): undefined reference to avcodec_send_packet'
VideoReader.cpp:(.text+0x10e1): undefined reference to avcodec_receive_frame' VideoReader.cpp:(.text+0x126d): undefined reference to av_frame_unref'
VideoReader.cpp:(.text+0x12d9): undefined reference to av_frame_free' VideoReader.cpp:(.text+0x12e3): undefined reference to av_packet_unref'
VideoReader.cpp:(.text+0x133f): undefined reference to avcodec_send_packet' VideoReader.cpp:(.text+0x135c): undefined reference to av_frame_alloc'
VideoReader.cpp:(.text+0x1418): undefined reference to avcodec_receive_frame' VideoReader.cpp:(.text+0x1479): undefined reference to av_frame_free'
VideoReader.cpp:(.text+0x153d): undefined reference to `av_frame_unref'
collect2: error: ld returned 1 exit status
make[2]: *** [MainProject/trans] Error 1
make[1]: *** [MainProject/CMakeFiles/trans.dir/all] Error 2
make: *** [all] Error 2

jesse

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions