Difference between revisions of "Archive:Compile Kodi on openSUSE"

From Official Kodi Wiki
Jump to: navigation, search
m (syntaxhighlight fix)
Line 17: Line 17:
 
Use YaST or zypper to install XBMC:
 
Use YaST or zypper to install XBMC:
  
<source lang=bash>$ sudo zypper in XBMC</source>
+
<syntaxhighlight lang=bash>$ sudo zypper in XBMC</syntaxhighlight>
 
'''NOTE:''' XBMC is in the Packman repository
 
'''NOTE:''' XBMC is in the Packman repository
 
'''NOTE: As of April 1st, 2012, XBMC-Eden (11.0) has not yet been uploaded to the Packman repository'''
 
'''NOTE: As of April 1st, 2012, XBMC-Eden (11.0) has not yet been uploaded to the Packman repository'''
Line 32: Line 32:
  
 
After downloading, run  
 
After downloading, run  
<source lang=bash>$ tar -xfz xbmc-11.0.tar.gz</source>
+
<syntaxhighlight lang=bash>$ tar -xfz xbmc-11.0.tar.gz</syntaxhighlight>
  
 
You can now skip to ''[[#Installing all building dependencies|Installing all building dependencies]]''
 
You can now skip to ''[[#Installing all building dependencies|Installing all building dependencies]]''
Line 41: Line 41:
 
The first time:
 
The first time:
  
<source lang=bash>$ sudo zypper in git
+
<syntaxhighlight lang=bash>$ sudo zypper in git
 
$ cd $HOME
 
$ cd $HOME
 
$ mkdir src
 
$ mkdir src
 
$ cd src
 
$ cd src
$ git clone git://github.com/xbmc/xbmc.git</source>
+
$ git clone git://github.com/xbmc/xbmc.git</syntaxhighlight>
  
  
 
In order to update the source code (and clean old make files):<br />
 
In order to update the source code (and clean old make files):<br />
<source lang=bash>$ cd $HOME/src
+
<syntaxhighlight lang=bash>$ cd $HOME/src
 
$ git pull
 
$ git pull
$ make clean</source>
+
$ make clean</syntaxhighlight>
  
  
Line 58: Line 58:
 
XBMC requires a number of external libraries to build (you may want to copy and paste):
 
XBMC requires a number of external libraries to build (you may want to copy and paste):
  
<source lang=bash>$ sudo zypper in make cmake autoconf automake gcc gcc-c++ libtool gettext-devel patch
+
<syntaxhighlight lang=bash>$ sudo zypper in make cmake autoconf automake gcc gcc-c++ libtool gettext-devel patch
 
$ sudo zypper in boost-devel glew-devel libmysqlclient-devel libass-devel libmpeg2-devel
 
$ sudo zypper in boost-devel glew-devel libmysqlclient-devel libass-devel libmpeg2-devel
 
$ sudo zypper in libmad-devel libjpeg-devel libsamplerate-devel libogg-devel libvorbis-devel
 
$ sudo zypper in libmad-devel libjpeg-devel libsamplerate-devel libogg-devel libvorbis-devel
Line 64: Line 64:
 
$ sudo zypper in libyajl-devel fribidi-devel sqlite3-devel libpng12-devel pcre-devel libcdio-devel
 
$ sudo zypper in libyajl-devel fribidi-devel sqlite3-devel libpng12-devel pcre-devel libcdio-devel
 
$ sudo zypper in libjasper-devel libSDL_mixer-devel libSDL_image-devel libmicrohttpd-devel
 
$ sudo zypper in libjasper-devel libSDL_mixer-devel libSDL_image-devel libmicrohttpd-devel
$ sudo zypper in libsmbclient-devel python-devel gperf zip nasm </source>
+
$ sudo zypper in libsmbclient-devel python-devel gperf zip nasm </syntaxhighlight>
  
 
==== Compile source ====
 
==== Compile source ====
Line 70: Line 70:
  
 
===== 32bit (i586) =====
 
===== 32bit (i586) =====
<source lang=bash>$ cd XBMC_DIRECOTRY (the directory you extracted / pull XBMC into)
+
<syntaxhighlight lang=bash>$ cd XBMC_DIRECOTRY (the directory you extracted / pull XBMC into)
 
$ ./bootstrap
 
$ ./bootstrap
 
$ ./configure --enable-mid --disable-debug --disable-pulse --prefix=/usr
 
$ ./configure --enable-mid --disable-debug --disable-pulse --prefix=/usr
 
$ make
 
$ make
$ sudo make install</source>
+
$ sudo make install</syntaxhighlight>
  
 
===== 64bit (x86_64) =====
 
===== 64bit (x86_64) =====
Line 87: Line 87:
 
than put it in your folder and type the following:
 
than put it in your folder and type the following:
  
<source lang=bash>$ cd $HOME/xbmc
+
<syntaxhighlight lang=bash>$ cd $HOME/xbmc
 
$ mv ../missing-cflags.patch .
 
$ mv ../missing-cflags.patch .
 
$ patch -p1 < missing-cflags.patch
 
$ patch -p1 < missing-cflags.patch
Line 94: Line 94:
 
$ ./configure --enable-mid --disable-debug --disable-pulse --prefix=/usr
 
$ ./configure --enable-mid --disable-debug --disable-pulse --prefix=/usr
 
$ CFLAGS="-I/usr/lib64/dbus-1.0/include -I/usr/lib64/glib-2.0/include" make
 
$ CFLAGS="-I/usr/lib64/dbus-1.0/include -I/usr/lib64/glib-2.0/include" make
$ sudo make install</source>
+
$ sudo make install</syntaxhighlight>
  
 
== Run it ==
 
== Run it ==
  
Open a shell and type <source lang=bash>xbmc</source> to launch it.
+
Open a shell and type <syntaxhighlight lang=bash>xbmc</syntaxhighlight> to launch it.
  
 
Continue with [[Media Sources|How to Add Content (Media Sources)]] to your XBMC.
 
Continue with [[Media Sources|How to Add Content (Media Sources)]] to your XBMC.

Revision as of 12:39, 10 July 2018

Home icon grey.png   ▶ Development ▶ Compiling ▶ Compile Kodi on openSUSE
Warning: This page is deprecated.
Starting with Kodi v18 "Leia", Kodi's build guides are kept alongside the code, where it is much easier to keep them up-to-date with current code.

1 Prerequisites

In order to successful install XBMC Eden, (by source or by rpms) you need the following Repositories to be added in Yast (change "12.1" to "11.4" or "11.3" if required):

  • openSUSE-12.1-Oss (this is already enabled in a standard installation)

http://download.opensuse.org/distribution/12.1/repo/oss/

  • Packman Repository

http://ftp.skynet.be/pub/packman/suse/12.1/

You can easly add them by YaST (package manager) --> repositories --> repositories manager --> add --> community repositories

2 Installation

2.1 Installation with RPMs

Use YaST or zypper to install XBMC:

$ sudo zypper in XBMC

NOTE: XBMC is in the Packman repository NOTE: As of April 1st, 2012, XBMC-Eden (11.0) has not yet been uploaded to the Packman repository

You can now skip to Run It!

2.2 Installation from source code

2.2.1 Getting the source code

2.2.1.1 Stable sources

Stable sources can be downloaded in tar.gz format from http://mirrors.kodi.tv/releases/source/

After downloading, run

$ tar -xfz xbmc-11.0.tar.gz

You can now skip to Installing all building dependencies


2.2.1.2 Development sources

If you want to build xbmc from current development snapshot: The first time:

$ sudo zypper in git
$ cd $HOME
$ mkdir src
$ cd src
$ git clone git://github.com/xbmc/xbmc.git


In order to update the source code (and clean old make files):

$ cd $HOME/src
$ git pull
$ make clean


2.2.2 Installing all building dependencies

XBMC requires a number of external libraries to build (you may want to copy and paste):

$ sudo zypper in make cmake autoconf automake gcc gcc-c++ libtool gettext-devel patch
$ sudo zypper in boost-devel glew-devel libmysqlclient-devel libass-devel libmpeg2-devel
$ sudo zypper in libmad-devel libjpeg-devel libsamplerate-devel libogg-devel libvorbis-devel
$ sudo zypper in libmodplug-devel libcurl-devel flac-devel libbz2-devel libtiff-devel lzo-devel 
$ sudo zypper in libyajl-devel fribidi-devel sqlite3-devel libpng12-devel pcre-devel libcdio-devel
$ sudo zypper in libjasper-devel libSDL_mixer-devel libSDL_image-devel libmicrohttpd-devel
$ sudo zypper in libsmbclient-devel python-devel gperf zip nasm

2.2.3 Compile source

To compile respecting openSUSE Filesystem structure please do the following:

2.2.3.1 32bit (i586)
$ cd XBMC_DIRECOTRY (the directory you extracted / pull XBMC into)
$ ./bootstrap
$ ./configure --enable-mid --disable-debug --disable-pulse --prefix=/usr
$ make
$ sudo make install
2.2.3.2 64bit (x86_64)

I doubt that all this is needed any more - I just did an x86_64 build without this stuff. I had to however install a few more dependencies.

x86_64 users need to export CFLAGS and apply a patch because a non standard libdir ( http://forum.kodi.tv/showthread.php?t=34527 ) on ubuntu (the only one supported)

create a text file called for example "missing-cflags.patch" a paste inside it the following lines:

http://pastebin.com/f22b29f07

than put it in your folder and type the following:

$ cd $HOME/xbmc
$ mv ../missing-cflags.patch .
$ patch -p1 < missing-cflags.patch
$ CFLAGS="-I/usr/lib64/dbus-1.0/include -I/usr/lib64/glib-2.0/include"
$ export CFLAGS
$ ./configure --enable-mid --disable-debug --disable-pulse --prefix=/usr
$ CFLAGS="-I/usr/lib64/dbus-1.0/include -I/usr/lib64/glib-2.0/include" make
$ sudo make install

3 Run it

Open a shell and type
xbmc
to launch it.

Continue with How to Add Content (Media Sources) to your XBMC.

Have fun Anubisg1