Cannot Patch tif_ojpeg in order to Install XBMC
#1
Question 
Hi,

I'm following a blog post (http://blog.1407.org/2009/06/11/xbmc-for-fedora-11/) to install XBMC on my Fedora 11 x86_64. I've gotten through ./configure, but I'm stuck at MAKE. I get an error about tif_jpeg (as stated on the blog) and I'm trying to run patch, but when I run it... nothing happens. Where should this file go and am I doing it right?

Code:
[marc@fergatron XBMC]$ locate tif_ojpeg
/home/marc/svn/xbmc/XBMC/xbmc/lib/cximage-6.0/tiff/tif_ojpeg.c
/home/marc/svn/xbmc/XBMC/xbmc/lib/cximage-6.0/tiff/tif_ojpeg.d
/usr/share/XBMC/xbmc/lib/cximage-6.0/tiff/tif_ojpeg.c
[marc@fergatron XBMC]$ cd xbmc/lib/cximage-6.0/tiff/
[marc@fergatron tiff]$ patch -p0 fix_tif_ojpeg.patch
^C
[marc@fergatron tiff]$ ^C
[marc@fergatron tiff]$
Reply
#2
patch -p0 < fix_tif_ojpeg.patch
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#3
"man patch" too
Reply
#4
Thanks. Is that the correct path? Should I have it in the root folder of xbmc? It failed btw. Someone said I could patch it manually, but I looked at the contents and I'm not certain where to put it.
Code:
[marc@fergatron tiff]$ patch -p0 < fix_tif_ojpeg.patch
patching file tif_ojpeg.c
Hunk #1 FAILED at 31.
1 out of 1 hunk FAILED -- saving rejects to file tif_ojpeg.c.rej
[marc@fergatron tiff]$
Reply
#5
Look at the header in the patch file, you may need to strip some directories off the path (-p, see the manpage).
Reply
#6
I wasn't able to run the patch file Sad, but I did figure out what needed to be removed. Wink

Code:
#endif
#define JPEG_INTERNALS /* Include "jpegint.h" for "DSTATE_*" symbols */
#undef INLINE
-#ifdef _LINUX
-#include <jpeglib.h>
-#else
#include "../jpeg/jpeglib.h"
-#endif
#undef JPEG_INTERNALS
For future reference on any other newbs coming to this thread (like me) Laugh. You simply remove the lines of code that have the "-" character in front of it in the file ~/svn/xbmc/XBMC/xbmc/lib/cximage-6.0/tiff/tif_ojpeg.c (or where ever you saved the svn files).

Another Note
On another note... I did get past that error and ran into a dbus error because I'm running an x86_64 system. That was easily fixed with doing a symbolic link.
planetvortex Wrote:ln -s /usr/lib64/dbus-1.0/include/dbus/dbus-arch-deps.h /usr/include/dbus-1.0/dbus
./configure --libdir=/lib64
...but now I'm running into another error. What I find really confusing is I don't see any threads about these errors on your forums. As if the only folks, in the Linux community, running this software is on Ubuntu or well off enough to know how to get arounds these compile-quirks.

So; right now I'm getting a 'dvdnav.o' error and I'm considering starting another thread just so external/internal searches will pick up this kind of thing. What do you think?

Code:
creating csstest
make[4]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdcss/test'
Making all in doc
make[4]: Entering directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdcss/doc'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdcss/doc'
make[4]: Entering directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdcss'
make[4]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdcss'
make[3]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdcss'
make[2]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdcss'
make -C libdvdread
make[2]: Entering directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdread'
sh "/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdread"/version.sh "/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdread" "4.1.3"
cd obj && ar rc libdvdread.a dvd_input.o dvd_reader.o dvd_udf.o ifo_print.o ifo_read.o md5.o nav_print.o nav_read.o bitreader.o
cd obj && ranlib libdvdread.a
sed -e 's,@prefix@,/usr/local,' -e 's,@exec_prefix@,/usr/local,' -e 's,@libdir@,/usr/local/lib,' -e 's,@includedir@,/usr/local/include,' -e 's,@VERSION@,4.1.3,' misc/dvdread.pc.in > obj/dvdread.pc
make[2]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdread'
make -C libdvdnav
make[2]: Entering directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdnav'
sh "/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdnav"/version.sh "/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdnav" "4.1.3"
make[2]: *** No rule to make target `/usr/lib/gcc/x86_64-redhat-linux/4.4.0/include/stddef.h', needed by `dvdnav.o'.  Stop.
make[2]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd/libdvdnav'
make[1]: *** [libdvdnav] Error 2
make[1]: Leaving directory `/home/marc/svn/xbmc/XBMC/xbmc/cores/dvdplayer/Codecs/libdvd'
make: *** [dvdpcodecs] Error 2
[marc@fergatron XBMC]$ ^C
[marc@fergatron XBMC]$
Reply
#7
Rather than trying to build all the libraries why don't you install the precompiled packages through you?

Code:
sudo yum install libdvdnav-devel libdvdcss-devel libdvdread-devel libpng-devel libjpeg-devel

and so on
Reply
#8
I wasn't aware I could do that. Your suggestion makes sense though. Unfortunately; it seems I already have them installed. Oh brother! :-D
Code:
[marc@fergatron ~]$ sudo yum install libdvdnav-devel libdvdcss-devel libdvdread-devel libpng-devel libjpeg-devel
Loaded plugins: refresh-packagekit
Setting up Install Process
Package libdvdnav-devel-4.1.3-2.fc11.x86_64 already installed and latest version
No package libdvdcss-devel available.
Package libdvdread-devel-4.1.3-2.fc11.x86_64 already installed and latest version
Package 2:libpng-devel-1.2.37-1.fc11.x86_64 already installed and latest version
Package libjpeg-devel-6b-45.fc11.x86_64 already installed and latest version
Nothing to do
[marc@fergatron ~]$
Reply
#9
the libtiff usage of jpegint.h issue is tracked at http://trac.xbmc.org/ticket/7096

I believe the proper solution is to externalize libtiff in the same way libjpeg was externalized. I have a patch attached to that ticket, and any testing (and further help) would be great.
Reply

Logout Mark Read Team Forum Stats Members Help
Cannot Patch tif_ojpeg in order to Install XBMC0