Working with old servers

So I thought the simple installation of HandBrake would go smoothly on a Linux server I was working on. All I needed to do was download the pre-compiled binary and it would work since it was compiled for Intel and the server was a quad core Intel right? Not so, since the server was running an old version of Red Hate Enterprise Server, version 4 to be exact, there were library issues all over the place. Simply put, there was no way to get HandBrake on there unless I was compiling it from source.

I thought that would go smoothly, but again problems abound. Required packages like yasm and nasm were missing, and when I installed them with up2date the compile still failed! The error I encountered was this mess:

 

   ./configure –prefix=$CONTRIB –enable-gpl –enable-pthreads –enable-swscale \

        –disable-shared –enable-static –disable-encoders \
        –enable-encoder=mpeg4 –enable-encoder=ac3 –enable-encoder=snow \
        –enable-libfaad –disable-ffmpeg –disable-ffserver \
        –disable-muxers –enable-muxer=ipod –disable-bsfs \
        –extra-cflags=”-I$CONTRIB/include” \
        –extra-ldflags=”-L$CONTRIB/lib”  &&
    make && make install &&
    strip -S $CONTRIB/lib/libavcodec.a

…failed LibAvCodec ./lib/libavcodec.a …
…skipped ./lib/libavutil.a for lack of ./lib/libavcodec.a…
…skipped ./lib/libavformat.a for lack of ./lib/libavcodec.a…
…skipped ./lib/libswscale.a for lack of ./lib/libavcodec.a…
…failed updating 2 target(s)…
…skipped 3 target(s)…
make[1]: *** [.contrib] Error 1
make: *** [contrib/.contrib] Error 2

 

Turns out this was another problem with library incompadability with Red Hat Enterprise Server 4, this time with how FFmpeg works with Video4Linux. The solution, thank you Google was simply to disable Video4Linux support on this particular build of FFmpeg within HandBrake. Here lies another problem, each time HandBrake was compiled from source with the “make” command, it extracts a fresh copy from a downloaded archive and compiles that. Making changes to the configure file of the extracted version doesn’t do anything because it gets overwritten on the next build. I had to track down the command with the help of the grep command by help of a friend tutorial. The offending file was in contribs/Jamfile – at line 112 insert “–disable-demuxer=v4l –disable-demuxer=v4l2”. Run “make” again, and bang, I get my own copy of HandBrakeCLI for the server. After getting my video file in and setting the profile to produce a video file that will play on my Palm Centro (here is the command line for those interested – “-t 1 -c 1 -f mp4 -w 320 -e ffmpeg -b 256 -2  -a 1 -E faac -B 80 -R 44.1 -6 stereo -D 1 -v”) I hit the enter key and prepare myself to bask in the glory of a video file encoding on a quad-core hyper-threading server.

 

Instead all I get at the end is a long dump of:

 

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

[NULL @ 0x1173c80]insufficient thread locking around avcodec_open/close()

[02:45:09] reader: first SCR 0

[NULL @ 0x1166860]insufficient thread locking around avcodec_open/close()

Segmentation fault

Further research on HandBrake’s website leads me to this link where its a known bug, and there is currently no workaround. I hate it when this happens.

You may also like

Leave a Reply

Your email address will not be published. Required fields are marked *