add missing avpacket functions for old ffmpeg/libav