1 # Maintainer: BlackEagle < ike DOT devolder AT gmail DOT com >
2 # Contributors : Ralf Barth <archlinux dot org at haggy dot org>
4 # Original credits go to Edgar Hucek <gimli at dark-green dot com>
5 # for his xbmc-vdpau-vdr PKGBUILD at https://archvdr.svn.sourceforge.net/svnroot/archvdr/trunk/archvdr/xbmc-vdpau-vdr/PKGBUILD
10 pkgdesc="XBMC Media Center git Eden branch"
12 conflicts=('xbmc' 'xbmc-pulse' 'xbmc-svn' 'xbmc-git')
14 arch=('i686' 'x86_64')
16 license=('GPL' 'LGPL')
17 depends=('libpulse' 'hicolor-icon-theme' 'fribidi' 'lzo2' 'smbclient' 'libtiff' 'libva' 'libpng' 'libcdio' 'yajl' 'libmysqlclient' 'libjpeg-turbo' 'libsamplerate' 'glew' 'libssh' 'libmicrohttpd' 'libxrandr' 'sdl_mixer' 'sdl_image' 'python2' 'libass' 'libmpeg2' 'libmad' 'libmodplug' 'jasper' 'rtmpdump' 'unzip' 'mesa-demos' 'xorg-xdpyinfo' 'libbluray' 'libnfs' 'afpfs-ng')
18 makedepends=('boost' 'cmake' 'git' 'gperf' 'nasm' 'libxinerama' 'zip' 'vdpau-video' 'libcec' 'udisks' 'upower') #'xvba-video'
21 'gdb: for meaningful backtraces in case of trouble - STRONGLY RECOMMENDED'
22 'libcrystalhd: Broadcom CrystalHD kernel module'
23 'libcec: support for Pulse-Eight USB-CEC adapter'
24 'vdpau-video: accelerated video playback for nvidia cards'
25 #'xvba-video: accelerated video playback for amd cards'
26 'pulseaudio: pulseaudio support'
27 'lirc: remote controller support'
28 'udisks: automount external drives'
29 'upower: used to trigger suspend functionality'
30 'unrar: access compressed files without unpacking them'
32 install=("${pkgname}.install")
37 if [ -e .githash_${CARCH} ] ; then
38 _gitphash=$(cat .githash_${CARCH})
44 _gitroot='git://github.com/xbmc/xbmc.git'
47 if [ -d ${srcdir}/${_gitname}/.git ] ; then
48 ( cd ${srcdir}/${_gitname} && git pull origin Eden )
49 msg "The local files are updated."
51 ( git clone -b Eden --depth 1 ${_gitroot} ${_gitname} )
53 msg "GIT checkout done or server timeout"
56 if [ "${_gitphash}" = "$(git show | grep -m 1 commit | sed 's/commit //')" ]; then
57 msg "Git hash is the same as previous build"
61 msg "creating build directory"
63 [ -d ${_gitname}-build ] && rm -rf ${_gitname}-build
64 cp -a ${_gitname} ${_gitname}-build
66 msg "Starting make..."
71 # Note on external-libs:
72 # - We cannot use external python because Arch's python was built with
73 # UCS2 unicode support, whereas xbmc expects UCS4 support
74 # - According to an xbmc dev using external/system ffmpeg with xbmc is "pure stupid" :D
76 # fix lsb_release dependency
77 sed -i -e 's:/usr/bin/lsb_release -d:cat /etc/arch-release:' xbmc/utils/SystemInfo.cpp
79 msg2 "Bootstrapping XBMC"
82 # latest configure options
83 # --enable-neon enable neon passing to ffmpeg (default is no)
84 # --enable-optimizations enable optimization (default is yes)
85 # --enable-gl enable OpenGL rendering (default is yes)
86 # --enable-gles enable OpenGLES rendering (default is no)
87 # --enable-sdl enable SDL (default is auto)
88 # --enable-vdpau enable VDPAU decoding (default is auto)
89 # --enable-vaapi enable VAAPI decoding (default is auto)
90 # --enable-crystalhd enable CrystalHD decoding (default is auto)
91 # --enable-vdadecoder enable VDADecoder decoding (default is auto)
92 # --enable-vtbdecoder enable VTBDecoder decoding (default is auto)
93 # --enable-openmax enable OpenMax decoding (default is auto, requires OpenGLES)
94 # --enable-tegra enable Tegra2 arm (default is no)
95 # --enable-profiling enable gprof profiling (default is no)
96 # --enable-joystick enable SDL joystick support (default is yes)
97 # --enable-xrandr enable XRandR support (default is yes)
98 # --enable-goom enable GOOM visualisation (default is no)
99 # --enable-rsxs enable really slick X screensavers (default is yes)
100 # --enable-projectm enable ProjectM visualisation (default is yes)
101 # --enable-x11 enable x11 (default is yes) 'Linux Only'
102 # --enable-ccache enable building with ccache feature (default is auto)
103 # --enable-pulse enable PulseAudio support (default is auto)
104 # --enable-rtmp enable RTMP support via librtmp (default is auto)
105 # --disable-samba disable SAMBA support (default is enabled)
106 # --enable-nfs enable NFS support via libnfs (default is auto)
107 # --enable-afpclient enable AFP support via libafpclient (default is auto)
108 # --enable-airplay enable AirPlay support(default is auto)
109 # --enable-airtunes enable AirTunes support(default is auto)
110 # --enable-ffmpeg-libvorbis enable FFmpeg vorbis encoding (default is no)
111 # --enable-dvdcss enable DVDCSS support (default is yes)
112 # --enable-mid enable MID support (default is no)
113 # --disable-hal disable HAL support (default is enabled if hal and hal-storage is found)
114 # --disable-avahi disable Avahi support (default is enabled if libavahi-common and libavahi-client is found)
115 # --disable-non-free disable componentents with non-compliant licenses
116 # --enable-asap-codec enable ASAP ADPCM support
117 # --disable-webserver disable webserver
118 # --disable-optical-drive disable optical drive
119 # --enable-libbluray enable libbluray support
120 # --enable-texturepacker enable texturepacker support (default is yes)
121 # --enable-udev enable udev support (default is auto)
122 # --enable-libusb enable libusb support (default is auto)
123 # --enable-libcec enable libcec support (default is auto)
124 # --enable-external-libraries enable use of all supported external libraries (default is no) 'Linux only'
125 # --enable-external-ffmpeg enable use of external ffmpeg libraries (default is no) 'Linux only'
127 msg2 "Configuring XBMC"
128 export PYTHON_VERSION=2 # external python v2
129 ./configure --prefix=${_prefix} --exec-prefix=${_prefix} \
131 --enable-optimizations \
147 --enable-ffmpeg-libvorbis \
152 --enable-optical-drive \
154 --enable-texturepacker \
158 --enable-external-libraries \
159 --disable-external-ffmpeg
161 # i'll try to add these later
165 # Now (finally) build
172 msg2 "Running make install"
173 make DESTDIR=${pkgdir} install
175 # run feh with python2
176 sed -i -e 's/python/python2/g' ${pkgdir}${_prefix}/bin/xbmc
180 install -Dm755 ${srcdir}/${_gitname}-build/tools/TexturePacker/TexturePacker \
181 ${pkgdir}${_prefix}/lib/xbmc/
185 install -dm755 ${pkgdir}${_prefix}/share/licenses/${pkgname}
186 for licensef in LICENSE.GPL copying.txt; do
187 mv ${pkgdir}${_prefix}/share/doc/xbmc/${licensef} \
188 ${pkgdir}${_prefix}/share/licenses/${pkgname}
192 msg2 "cleanup unneeded files"
193 rm -rf ${pkgdir}/usr/share/xsessions
195 git show | grep -m 1 commit | sed 's/commit //' > ${startdir}/.githash_${CARCH}