git build of 18.5-2 on Fedora 29 not working well
#1
Hi,
I'm not sure if this is the correct tread so if it needs to be moved please tell me where it went. :-)

I thought I might try Kodi 18.5 and perhaps a bit of add-on development work so;
Rather than replace my existing 17.6, I built a new virtual machine and put the latest Fedora(29) (4.18.16-300.fc29.x86_64) on it.
Yes, I know that Fedora is not supported.

So I found the Wiki page for compiling from source at "https://kodi.wiki/view/HOW-TO:Compile_Kodi_for_Linux" and I'm trying to, loosely, follow it.
I created a directory and did a git pull
HKODI=$HOME/kodi
cd $HKODI
git clone git://github.com/xbmc/xbmc.git
cd $HKODI/xbmc
git clean -xfd
git reset --hard
git pull --rebase

Rather than:
dnf install automake autopoint bison build-essential ccache cmake curl cvs default-jre fp-compiler gawk gdc gettext git-core gperf libasound2-dev libass-dev libavcodec-dev libavfilter-dev libavformat-dev libavutil-dev libbluetooth-dev libbluray-dev libbluray1 libboost-dev libboost-thread-dev libbz2-dev libcap-dev libcdio-dev libcec-dev libcec1 libcrystalhd-dev libcrystalhd3 libcurl3 libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-dev libenca-dev libflac-dev libfontconfig-dev libfreetype6-dev libfribidi-dev libglew-dev libiso9660-dev libjasper-dev libjpeg-dev libltdl-dev liblzo2-dev libmad0-dev libmicrohttpd-dev libmodplug-dev libmp3lame-dev libmpeg2-4-dev libmpeg3-dev libmysqlclient-dev libnfs-dev libogg-dev libpcre3-dev libplist-dev libpng-dev libpostproc-dev libpulse-dev libsamplerate-dev libsdl-dev libsdl-gfx1.2-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libshairport-dev libsmbclient-dev libsqlite3-dev libssh-dev libssl-dev libswscale-dev libtiff-dev libtinyxml-dev libtool libudev-dev libusb-dev libva-dev libva-egl1 libva-tpi1 libvdpau-dev libvorbisenc2 libxml2-dev libxmu-dev libxrandr-dev libxrender-dev libxslt1-dev libxt-dev libyajl-dev mesa-utils nasm pmount python-dev python-imaging python-sqlite swig unzip yasm zip zlib1g-dev

I thought I'd try just running make and see which packages were missing.
./bootstrap
./configure  --prefix=$HOME/local
make

After changing to the $HKODI/xbmc directory I tried
./bootstrap
No bootstrap. Huh
I looked around and found what appears to be the correct file in  HKODI/xbmc/tools/depends
I saw no mention of moving out of the $HKODI/xbmc in the How-To, though it did say that build instructions were now being packaged with the source, but I didn't find that detail in with the source READMEs either and they appear to be written in HTML which may be helpful on a general purpose machine a simple txt file is easier to read in "less"

So after running ./bootstrap and ./configure I discovered that I had needed to install:
m4
autoconf
patch
automake

After running make a couple of times I found that while I had gcc, zlib and curl installed,
I needed c++ and the "devel" packages too (probably for the headers) not unusual for compiling.

gcc-c++
zlib-devel
curl-devel

I have noticed that after running make, it won't just start up where it errored out.
I need to "make clean" and start over from ./bootstrap. Is that normal?
I have used make for years and never had to continually start over. (usually do a make clean and start over after I get a complete build done just to get a nice clean complete build but to have to start from the beginning after make failed seems like make is not working correctly.


Sorry about the long winded preamble but

It seems to build a LOT of stuff and then:
(I substituted XXX for my directory path)

/usr/bin/g++ -DTARGET_POSIX -DTARGET_POSIX -DTARGET_LINUX -D_LINUX -std=c++0x -I/XXX/local/x86_64-linux-gnu-native/include  -llzo2 -ljpeg -lgif  -L/XXX/local/x86_64-linux-gnu-native/lib -lpng16 -lm -lz -lm  -static -L/XXX/local/x86_64-linux-gnu-native/lib  -o TexturePacker md5.o XBTFWriter.o TexturePacker.o DecoderManager.o decoder/PNGDecoder.o decoder/JPGDecoder.o decoder/GifHelper.o decoder/GIFDecoder.o XBTF.o  -llzo2 -ljpeg -lgif  -L/XXX/local/x86_64-linux-gnu-native/lib -lpng16 -lm -lz -lm
/usr/bin/ld: cannot find -lm
/usr/bin/ld: cannot find -lm
/usr/bin/ld: cannot find -lm
/usr/bin/ld: cannot find -lstdc++
/usr/bin/ld: cannot find -lm
/usr/bin/ld: cannot find -lc
collect2: error: ld returned 1 exit status
make[4]: *** [Makefile:420: TexturePacker] Error 1

It appears that my loader doesn't like the parms it is being passed.
Is this a "g++" issue or one for "ld"?

Any ideas?
Reply
#2
It seems that you haven't Read The Fine Manual.
I'd suggest you start by reading https://github.com/xbmc/xbmc/blob/master....Fedora.md

The build system evolved quite a lot since 17.x, there is no ./bootstrap in the root folder now, Kodi itself uses cmake,
the other bootstrap is for depends build, which shouldn't be needed in Fedora case.
Reply
#3
Thank you for pointing me to The Fine Manual
Reply
#4
Having completed RTFM, I am struck by your mention of
"The build system evolved quite a lot since 17.x, there is no ./bootstrap in the root folder now, Kodi itself uses cmake,
the other bootstrap is for depends build, which shouldn't be needed in Fedora case"

I shall have to do some Rereading to be sure but section 4. points one off to the Build Guide that I mentioned in my initial post.
and
while you tell me that ./bootstrap is no longer required I am still unable to find either a Makefile or a configure in the root folder.
Since a depends build is NOT the right place to attempt a ./configure, could you perhaps point me at the correct directory?
I am currently working my way through the dependency installs, quite a few seem to not exist (or already are installed)

Thank you for your patience
Reply
#5
Just an FYI
FC29 has no java?
I installed java-9-openjdk-headless-9.0.4.11-6.fc28.x86_64.rpm seemed to install without issue
Reply
#6
(2019-01-17, 02:54)dsime42 Wrote: I shall have to do some Rereading to be sure but section 4. points one off to the Build Guide that I mentioned in my initial post.
and
while you tell me that ./bootstrap is no longer required I am still unable to find either a Makefile or a configure in the root folder.
As I said: Kodi 18.x uses cmake build system, there is no ./configure
Section 4 points to the NEW build guide for 18.x, section 4 of which explains how to build with cmake.

Read https://github.com/xbmc/xbmc/blob/master...E.Linux.md , it _is_ different to the old guide.

Fedora guide just enumerates the prerequisite system packages.
Reply
#7
(2019-01-16, 23:18)dsime42 Wrote: I thought I might try Kodi 18.5 and perhaps a bit of add-on development work so;
Rather than replace my existing 17.6, I built a new virtual machine and put the latest Fedora(29) (4.18.16-300.fc29.x86_64) on it.
Yes, I know that Fedora is not supported.
So... why that choice of OS if your objective was to try out the later Kodi?

nb: I'm not saying it's a poor choice - I have a friend that ran Kodi on CentOS for some time - but if Kodi was the end goal, selecting one of the supported platforms may have avoided the headache. 

Also... according to the Wiki there's an RPM for Fedora
Reply

Logout Mark Read Team Forum Stats Members Help
git build of 18.5-2 on Fedora 29 not working well0