From patchwork Sun Feb 23 12:29:45 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Hadjinlian X-Patchwork-Id: 323307 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from hemlock.osuosl.org (hemlock.osuosl.org [140.211.166.133]) by ozlabs.org (Postfix) with ESMTP id 7A3982C01AE for ; Sun, 23 Feb 2014 23:30:01 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 8D5489355B; Sun, 23 Feb 2014 12:30:00 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id r4qfRes-30Vw; Sun, 23 Feb 2014 12:29:59 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id DA277932D3; Sun, 23 Feb 2014 12:29:58 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (hemlock.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 416091CE9D2 for ; Sun, 23 Feb 2014 12:29:58 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 3CFC3932D3 for ; Sun, 23 Feb 2014 12:29:58 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bqXqdlw+4q+R for ; Sun, 23 Feb 2014 12:29:56 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wi0-f182.google.com (mail-wi0-f182.google.com [209.85.212.182]) by hemlock.osuosl.org (Postfix) with ESMTPS id 269D8932A1 for ; Sun, 23 Feb 2014 12:29:55 +0000 (UTC) Received: by mail-wi0-f182.google.com with SMTP id f8so2157341wiw.9 for ; Sun, 23 Feb 2014 04:29:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=klP0OjADi8tVYjXSGaVUqVKuK7JcQn0F1dqVJnDrq0E=; b=k70bg9a6TFzOHxcixuerK4OFzK+IxvH+0IO5pEV11wtY6L8nxTtUhjNHTnpfc4uA8M c8GOll8LjESKui5HneRgydOuTURgTPnMXU0BEzfioGDd2WNHDRgo8/XV03U+PVQ3GcgC Cqw2JvOiuQFvYLKslbiN6kXHU42l7L5IZsQ37wVSKUnrWOk+rLITsiz9Sd/m8vIdhlCd UZyyRU38ULW1R+OQtBMz1VBeGBFWTESVK/BBPcHpLRXd9vYSoyQMMTbPdmBj9E1IJJXe oOhmdwEc6onYJ+mnhjwIDsVR3FWuqXgmHfJjz53FsVT57aIpIn60YYX5Ie622mxgqIQW 4b1g== X-Received: by 10.180.206.172 with SMTP id lp12mr9928730wic.46.1393158594614; Sun, 23 Feb 2014 04:29:54 -0800 (PST) Received: from localhost (13-105-190-109.dsl.ovh.fr. [109.190.105.13]) by mx.google.com with ESMTPSA id f3sm13992342wiv.2.2014.02.23.04.29.52 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sun, 23 Feb 2014 04:29:53 -0800 (PST) From: Maxime Hadjinlian To: buildroot@buildroot.org Date: Sun, 23 Feb 2014 13:29:45 +0100 Message-Id: <1393158585-27193-1-git-send-email-maxime.hadjinlian@gmail.com> X-Mailer: git-send-email 1.8.5.3 Cc: gimli Subject: [Buildroot] [PATCH v8] xbmc: new package X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net XBMC is an award-winning free and open source (GPL) software media player and entertainment hub for digital media. This package was originally found at : https://github.com/huceke/buildroot-rbp By gimli Signed-off-by: Maxime Hadjinlian Cc: gimli --- Changes v7 -> v8: - Fix comments and dependencies on components (Thomas Petazzoni) - Change name for options (Thomas Petazzoni) - Remove depends on external toolchain (Martin Bark) - Fix various indent issues (Thomas Petazzoni) - Fix hook placement (Thomas Petazzoni) - Add host-gperf (Martin Bark) Changes v6 -> v7: - Fix various capitalization issue (Thomas De Schampheleire) - Changes depends on !uclibc to a depends on glibc (Thomas De Schampheleire) - Remove TIFF being selected twice (Jerzy Grzegorek) Changes v5 -> v6: - Fix missing depends on OpenGL (Yann E. Morin) - Remove LIBCEC_RBP Config option (Yann E. Morin) - Fix dependency that were, in the end, not optionnal (Martin Bark) - Fix OpenGL check (Martin Bark) - Uses BR2_HOST_NEEDS_JAVA (Martin Bark) Changes v4 -> v5: - Remove MAKE1, seems to work fine with parallel build. Changes v3 -> v4: - Rework init script - Add systemd startup service Changes v2 -> v3: - Fix indent - Change librtmp to rtmpdump Changes v1 -> v2: - Fix header (Yann E. Morin) - Fix comment on toolchain option (Peter Korsgaard) --- package/Config.in | 1 + package/xbmc/Config.in | 191 +++++++++++++++++++++ package/xbmc/S50xbmc | 41 +++++ package/xbmc/xbmc-0001-Fixup-include-path.patch | 81 +++++++++ .../xbmc-0002-RaspberryPi-Default-Settings.patch | 168 ++++++++++++++++++ package/xbmc/xbmc.mk | 163 ++++++++++++++++++ package/xbmc/xbmc.service | 12 ++ 7 files changed, 657 insertions(+) create mode 100644 package/xbmc/Config.in create mode 100755 package/xbmc/S50xbmc create mode 100644 package/xbmc/xbmc-0001-Fixup-include-path.patch create mode 100644 package/xbmc/xbmc-0002-RaspberryPi-Default-Settings.patch create mode 100644 package/xbmc/xbmc.mk create mode 100644 package/xbmc/xbmc.service diff --git a/package/Config.in b/package/Config.in index 087e5f4..69db17c 100644 --- a/package/Config.in +++ b/package/Config.in @@ -26,6 +26,7 @@ source "package/tstools/Config.in" source "package/vlc/Config.in" source "package/vorbis-tools/Config.in" source "package/wavpack/Config.in" +source "package/xbmc/Config.in" source "package/yavta/Config.in" endmenu diff --git a/package/xbmc/Config.in b/package/xbmc/Config.in new file mode 100644 index 0000000..c38f82b --- /dev/null +++ b/package/xbmc/Config.in @@ -0,0 +1,191 @@ +comment "xbmc requires an OpenGL ES and EGL backend" + depends on !(BR2_PACKAGE_HAS_OPENGL_EGL && BR2_PACKAGE_HAS_OPENGL_ES) + +comment "xbmc needs an (e)glibc toolchain w/ C++" + depends on !BR2_TOOLCHAIN_USES_GLIBC || !BR2_INSTALL_LIBSTDCPP + +menuconfig BR2_PACKAGE_XBMC + bool "xbmc" + select BR2_HOST_NEEDS_JAVA + select BR2_PACKAGE_BOOST + select BR2_PACKAGE_BOOST_THREAD + select BR2_PACKAGE_BZIP2 + select BR2_PACKAGE_EXPAT + select BR2_PACKAGE_FLAC + select BR2_PACKAGE_FONTCONFIG + select BR2_PACKAGE_FREETYPE + select BR2_PACKAGE_JASPER + select BR2_PACKAGE_JPEG + select BR2_PACKAGE_LIBASS + select BR2_PACKAGE_LIBCDIO + select BR2_PACKAGE_LIBCURL + select BR2_PACKAGE_LIBFRIBIDI + select BR2_PACKAGE_LIBGCRYPT + select BR2_PACKAGE_LIBID3TAG + select BR2_PACKAGE_LIBMAD + select BR2_PACKAGE_LIBMODPLUG + select BR2_PACKAGE_LIBMPEG2 + select BR2_PACKAGE_LIBOGG + select BR2_PACKAGE_LIBPLIST + select BR2_PACKAGE_LIBPNG + select BR2_PACKAGE_LIBSAMPLERATE + select BR2_PACKAGE_LIBUNGIF + select BR2_PACKAGE_LIBVORBIS + select BR2_PACKAGE_LIBXML2 + select BR2_PACKAGE_LZO + select BR2_PACKAGE_NCURSES + select BR2_PACKAGE_OPENSSL + select BR2_PACKAGE_PCRE + select BR2_PACKAGE_PYTHON + select BR2_PACKAGE_PYTHON_BSDDB + select BR2_PACKAGE_PYTHON_BZIP2 + select BR2_PACKAGE_PYTHON_CURSES + select BR2_PACKAGE_PYTHON_PYEXPAT + select BR2_PACKAGE_PYTHON_READLINE + select BR2_PACKAGE_PYTHON_SQLITE + select BR2_PACKAGE_PYTHON_SSL + select BR2_PACKAGE_PYTHON_UNICODEDATA + select BR2_PACKAGE_PYTHON_ZLIB + select BR2_PACKAGE_READLINE + select BR2_PACKAGE_SQLITE + select BR2_PACKAGE_TAGLIB + select BR2_PACKAGE_TIFF + select BR2_PACKAGE_TINYXML + select BR2_PACKAGE_YAJL + select BR2_PACKAGE_ZLIB + depends on BR2_TOOLCHAIN_USES_GLIBC && BR2_INSTALL_LIBSTDCPP + depends on BR2_PACKAGE_HAS_OPENGL_EGL || BR2_PACKAGE_HAS_OPENGL_ES + help + XBMC is an award-winning free and open source (GPL) software + media player and entertainment hub for digital media. + + http://xbmc.org + +if BR2_PACKAGE_XBMC + +config BR2_PACKAGE_XBMC_AVAHI + bool "avahi" + # libdaemon uses fork() + depends on BR2_USE_MMU + depends on BR2_TOOLCHAIN_HAS_THREADS + select BR2_PACKAGE_AVAHI + select BR2_PACKAGE_AVAHI_DAEMON + help + Enable Avahi support. + Select this if you want XBMC to support Bonjour protocol. + +comment "avahi needs a toolchain w/ threads" + depends on BR2_USE_MMU + depends on !BR2_TOOLCHAIN_HAS_THREADS + +config BR2_PACKAGE_XBMC_DBUS + bool "dbus" + depends on BR2_TOOLCHAIN_HAS_THREADS + # uses fork() + depends on BR2_USE_MMU + select BR2_PACKAGE_DBUS + help + Enable D-Bus support + +comment "dbus needs a toolchain w/ threads" + depends on BR2_USE_MMU + depends on !BR2_TOOLCHAIN_HAS_THREADS + +config BR2_PACKAGE_XBMC_LIBBLURAY + bool "blu-ray" + depends on BR2_TOOLCHAIN_HAS_THREADS + select BR2_PACKAGE_LIBBLURAY + help + Enable Blu-ray input support. + Select this if you want to play back Blu-ray content. + +comment "libbluray needs a toolchain w/ threads" + depends on !BR2_TOOLCHAIN_HAS_THREADS + +config BR2_PACKAGE_XBMC_LIBCEC + bool "hdmi cec" + select BR2_PACKAGE_LIBCEC + depends on BR2_INSTALL_LIBSTDCPP + depends on BR2_TOOLCHAIN_HAS_THREADS + help + Enable CEC (Consumer Electronics Control) support. + Select this if you want XBMC to support HDMI CEC. + +comment "libcec needs a toolchain w/ C++, threads" + depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS + +config BR2_PACKAGE_XBMC_LIBMICROHTTPD + bool "web server" + depends on BR2_TOOLCHAIN_HAS_THREADS + select BR2_PACKAGE_LIBMICROHTTPD + help + Enable webserver feature + +comment "libmicrohttpd needs a toolchain w/ threads" + depends on !BR2_TOOLCHAIN_HAS_THREADS + +config BR2_PACKAGE_XBMC_LIBNFS + bool "nfs" + select BR2_PACKAGE_LIBNFS + depends on BR2_LARGEFILE + depends on BR2_TOOLCHAIN_HAS_NATIVE_RPC + help + Enable NFS server support. + +comment "libnfs support requires a toolchain w/ largefile, RPC support" + depends on !(BR2_LARGEFILE && BR2_TOOLCHAIN_HAS_NATIVE_RPC) + +config BR2_PACKAGE_XBMC_RTMPDUMP + bool "rtmp" + select BR2_PACKAGE_RTMPDUMP + help + Enable RTMP input support. + Select this if you want to play back rtmp stream. + +config BR2_PACKAGE_XBMC_LIBSHAIRPLAY + bool "shairport" + select BR2_PACKAGE_LIBSHAIRPLAY + depends on BR2_INET_IPV6 + help + Enable Shairport support. + Select this if you want to stream content from an Apple device. + +comment "libshairport support requires a toolchain w/ IPv6 support" + depends on !BR2_INET_IPV6 + +config BR2_PACKAGE_XBMC_LIBSMBCLIENT + bool "samba" + depends on BR2_TOOLCHAIN_HAS_THREADS + depends on BR2_USE_MMU # fork() + select BR2_PACKAGE_SAMBA + select BR2_PACKAGE_SAMBA_LIBSMBCLIENT + help + Enable Samba support + +comment "libsmbclient needs a toolchain w/ threads" + depends on BR2_USE_MMU + depends on !BR2_TOOLCHAIN_HAS_THREADS + +config BR2_PACKAGE_XBMC_LIBTHEORA + bool "theora" + select BR2_PACKAGE_LIBTHEORA + help + Enable Theora input support. + Select this if you want to play back OGG/OGV files (Video). + +config BR2_PACKAGE_XBMC_LIBUSB + bool "usb" + depends on BR2_TOOLCHAIN_HAS_THREADS + select BR2_PACKAGE_LIBUSB + select BR2_PACKAGE_LIBUSB_COMPAT + help + Enable libusb support. + +config BR2_PACKAGE_XBMC_WAVPACK + bool "wavpack" + select BR2_PACKAGE_WAVPACK + help + Enable WAV input support. + Select this if you want to play back WV files. + +endif diff --git a/package/xbmc/S50xbmc b/package/xbmc/S50xbmc new file mode 100755 index 0000000..ce51f7e --- /dev/null +++ b/package/xbmc/S50xbmc @@ -0,0 +1,41 @@ +#!/bin/sh +# +# Starts XBMC. +# + +BIN_NAME=xbmc.bin +XBMC=/usr/lib/xbmc/$BIN_NAME +XBMC_ARGS="--standalone -fs -n" +PIDFILE=/var/run/xbmc.pid + +start() { + echo -n "Starting XBMC: " + start-stop-daemon -S -q -p $PIDFILE --exec $XBMC -- $XBMC_ARGS + [ $? == 0 ] && echo "OK" || echo "FAIL" +} +stop() { + echo -n "Stopping XBMC: " + start-stop-daemon -K -q -p $PIDFILE + [ $? == 0 ] && echo "OK" || echo "FAIL" +} +restart() { + stop + start +} + +case "$1" in + start) + start + ;; + stop) + stop + ;; + restart|reload) + restart + ;; + *) + echo "Usage: $0 {start|stop|restart}" + exit 1 +esac + +exit $? diff --git a/package/xbmc/xbmc-0001-Fixup-include-path.patch b/package/xbmc/xbmc-0001-Fixup-include-path.patch new file mode 100644 index 0000000..be99bd6 --- /dev/null +++ b/package/xbmc/xbmc-0001-Fixup-include-path.patch @@ -0,0 +1,81 @@ +From 63c255f1f5d68363f49193aceed343e602dc8bdf Mon Sep 17 00:00:00 2001 +From: Maxime Hadjinlian +Date: Thu, 26 Dec 2013 21:17:10 +0100 +Subject: [PATCH] Fixup include path + +Patch originally taken from : +http://repository.timesys.com/buildsources/x/xbmc/xbmc-11.0/xbmc-11.0-fixups.patch + +Signed-off-by: Maxime Hadjinlian +--- + lib/enca/configure | 3 --- + lib/enca/configure.ac | 3 --- + lib/libdvd/libdvdread/misc/dvdread-config.sh | 6 +++--- + lib/timidity/configure.in | 6 +++--- + 4 files changed, 6 insertions(+), 12 deletions(-) + +diff --git a/lib/enca/configure b/lib/enca/configure +index c839a51..7af5a09 100644 +--- a/lib/enca/configure ++++ b/lib/enca/configure +@@ -12011,9 +12011,6 @@ fi + if test "$prefix" = "NONE"; then + LDFLAGS="$LDFLAGS -L$ac_default_prefix/lib" + CPPFLAGS="$CPPFLAGS -I$ac_default_prefix/include" +-else +- LDFLAGS="$LDFLAGS -L$prefix/lib" +- CPPFLAGS="$CPPFLAGS -I$prefix/include" + fi + + +diff --git a/lib/enca/configure.ac b/lib/enca/configure.ac +index 41434df..47d5367 100644 +--- a/lib/enca/configure.ac ++++ b/lib/enca/configure.ac +@@ -100,9 +100,6 @@ dnl Dirty path hack. Helps some people with badly set up search paths. + if test "$prefix" = "NONE"; then + LDFLAGS="$LDFLAGS -L$ac_default_prefix/lib" + CPPFLAGS="$CPPFLAGS -I$ac_default_prefix/include" +-else +- LDFLAGS="$LDFLAGS -L$prefix/lib" +- CPPFLAGS="$CPPFLAGS -I$prefix/include" + fi + + dnl Checks for libraries. +diff --git a/lib/libdvd/libdvdread/misc/dvdread-config.sh b/lib/libdvd/libdvdread/misc/dvdread-config.sh +index e170c7e..25ee893 100644 +--- a/lib/libdvd/libdvdread/misc/dvdread-config.sh ++++ b/lib/libdvd/libdvdread/misc/dvdread-config.sh +@@ -48,9 +48,9 @@ if test "$echo_prefix" = "yes"; then + fi + + if test "$echo_cflags" = "yes"; then +- echo -I$prefix/include $extracflags ++ echo $extracflags + fi + + if test "$echo_libs" = "yes"; then +- echo -L$libdir $dvdreadlib +-fi ++ echo $dvdreadlib ++fi +diff --git a/lib/timidity/configure.in b/lib/timidity/configure.in +index 9f2835b..733470a 100644 +--- a/lib/timidity/configure.in ++++ b/lib/timidity/configure.in +@@ -100,9 +100,9 @@ done + + # add $prefix if specified. + if test "x$prefix" != xNONE -a "x$prefix" != "x$ac_default_prefix" -a "x$prefix" != "x/usr"; then +- LDFLAGS="-L$prefix/lib $LDFLAGS" +- SHLDFLAGS="-L$prefix/lib $SHLDFLAGS" +- CPPFLAGS="-I$prefix/include $CPPFLAGS" ++ LDFLAGS="$LDFLAGS" ++ SHLDFLAGS="$SHLDFLAGS" ++ CPPFLAGS="$CPPFLAGS" + fi + + dnl add --with-includes, --with-libraries +-- +1.8.5.2 + diff --git a/package/xbmc/xbmc-0002-RaspberryPi-Default-Settings.patch b/package/xbmc/xbmc-0002-RaspberryPi-Default-Settings.patch new file mode 100644 index 0000000..43960e6 --- /dev/null +++ b/package/xbmc/xbmc-0002-RaspberryPi-Default-Settings.patch @@ -0,0 +1,168 @@ +From 2541772a3ed71402a620466feb6a337b40f08880 Mon Sep 17 00:00:00 2001 +From: Maxime Hadjinlian +Date: Sat, 15 Dec 2012 23:41:06 +0100 +Subject: [PATCH] RaspberryPi Default Settings + +Add some default settings if the target platform is the RaspberryPi. +Avoid the fact that the user _MUST_ have an advandcedsettings.xml to be able +to use XBMC properly. + +Signed-off-by: Maxime Hadjinlian +--- + xbmc/settings/AdvancedSettings.cpp | 31 +++++++++++++++++++++++++++ + xbmc/settings/GUISettings.cpp | 8 +++---- + xbmc/settings/GUIWindowSettingsCategory.cpp | 4 ++-- + 3 files changed, 37 insertions(+), 6 deletions(-) + +diff --git a/xbmc/settings/AdvancedSettings.cpp b/xbmc/settings/AdvancedSettings.cpp +index 2cbbf98..42ccabd 100644 +--- a/xbmc/settings/AdvancedSettings.cpp ++++ b/xbmc/settings/AdvancedSettings.cpp +@@ -72,7 +72,11 @@ void CAdvancedSettings::Initialize() + m_karaokeAlwaysEmptyOnCdgs = 1; + m_karaokeUseSongSpecificBackground = 0; + ++ #if defined(TARGET_RASPBERRY_PI) ++ m_audioDefaultPlayer = "omxplayer"; ++ #else + m_audioDefaultPlayer = "paplayer"; ++ #endif + m_audioPlayCountMinimumPercent = 90.0f; + m_audioHost = "default"; + +@@ -93,8 +97,14 @@ void CAdvancedSettings::Initialize() + m_videoBlackBarColour = 0; + m_videoPPFFmpegDeint = "linblenddeint"; + m_videoPPFFmpegPostProc = "ha:128:7,va,dr"; ++ ++ #if defined(TARGET_RASPBERRY_PI) ++ m_videoDefaultPlayer = "omxplayer"; ++ m_videoDefaultDVDPlayer = "omxplayer"; ++ #else + m_videoDefaultPlayer = "dvdplayer"; + m_videoDefaultDVDPlayer = "dvdplayer"; ++ #endif + m_videoIgnoreSecondsAtStart = 3*60; + m_videoIgnorePercentAtEnd = 8.0f; + m_videoPlayCountMinimumPercent = 90.0f; +@@ -287,7 +297,11 @@ void CAdvancedSettings::Initialize() + m_alwaysOnTop = false; + #endif + ++ #if defined(TARGET_RASPBERRY_PI) ++ m_bgInfoLoaderMaxThreads = 2; ++ #else + m_bgInfoLoaderMaxThreads = 5; ++ #endif + + m_iPVRTimeCorrection = 0; + m_iPVRInfoToggleInterval = 3000; +@@ -299,7 +313,12 @@ void CAdvancedSettings::Initialize() + + m_measureRefreshrate = false; + ++ #if defined(TARGET_RASPBERRY_PI) ++ m_cacheMemBufferSize = 1024 * 1024 * 10; ++ #else + m_cacheMemBufferSize = 1024 * 1024 * 20; ++ #endif ++ + m_addonPackageFolderSize = 200; + + m_jsonOutputCompact = true; +@@ -509,11 +528,17 @@ void CAdvancedSettings::ParseSettingsFile(const CStdString &file) + RefreshOverride override = {0}; + + float fps; ++ #if defined(TARGET_RASPBERRY_PI) ++ fps = 23.976; ++ override.fpsmin = fps - 0.01f; ++ override.fpsmax = fps + 0.01f; ++ #else + if (XMLUtils::GetFloat(pRefreshOverride, "fps", fps)) + { + override.fpsmin = fps - 0.01f; + override.fpsmax = fps + 0.01f; + } ++ #endif + + float fpsmin, fpsmax; + if (XMLUtils::GetFloat(pRefreshOverride, "fpsmin", fpsmin) && +@@ -524,11 +549,17 @@ void CAdvancedSettings::ParseSettingsFile(const CStdString &file) + } + + float refresh; ++ #if defined(TARGET_RASPBERRY_PI) ++ refresh = 24.0; ++ override.refreshmin = refresh - 0.01f; ++ override.refreshmax = refresh + 0.01f; ++ #else + if (XMLUtils::GetFloat(pRefreshOverride, "refresh", refresh)) + { + override.refreshmin = refresh - 0.01f; + override.refreshmax = refresh + 0.01f; + } ++ #endif + + float refreshmin, refreshmax; + if (XMLUtils::GetFloat(pRefreshOverride, "refreshmin", refreshmin) && +diff --git a/xbmc/settings/GUISettings.cpp b/xbmc/settings/GUISettings.cpp +index c1820a7..c00fb18 100644 +--- a/xbmc/settings/GUISettings.cpp ++++ b/xbmc/settings/GUISettings.cpp +@@ -537,11 +537,11 @@ void CGUISettings::Initialize() + AddInt(NULL, "input.appleremotesequencetime", 13603, 500, 50, 50, 1000, SPIN_CONTROL_INT_PLUS, MASK_MS, TEXT_OFF); + AddSeparator(in, "input.sep1"); + #endif +- AddBool(in, "input.remoteaskeyboard", 21449, false); ++ AddBool(in, "input.remoteaskeyboard", 21449, true); + #if defined(TARGET_DARWIN_IOS) + AddBool(NULL, "input.enablemouse", 21369, true); + #else +- AddBool(in, "input.enablemouse", 21369, true); ++ AddBool(in, "input.enablemouse", 21369, false); + #endif + #if defined(HAS_SDL_JOYSTICK) + AddBool(in, "input.enablejoystick", 35100, true); +@@ -831,7 +831,7 @@ void CGUISettings::Initialize() + + #ifdef HAS_WEB_SERVER + CSettingsCategory* srvWeb = AddCategory(SETTINGS_SERVICE, "webserver", 33101); +- AddBool(srvWeb, "services.webserver", 263, false); ++ AddBool(srvWeb, "services.webserver", 263, true); + AddString(srvWeb,"services.webserverport", 730, CUtil::CanBindPrivileged()?"80":"8080", EDIT_CONTROL_NUMBER_INPUT, false, 730); + AddString(srvWeb,"services.webserverusername",1048, "xbmc", EDIT_CONTROL_INPUT); + AddString(srvWeb,"services.webserverpassword",733, "", EDIT_CONTROL_HIDDEN_INPUT, true, 733); +@@ -881,7 +881,7 @@ void CGUISettings::Initialize() + AddInt(laf, "lookandfeel.startupwindow",512,1, WINDOW_HOME, 1, WINDOW_PYTHON_END, SPIN_CONTROL_TEXT); + AddString(laf, "lookandfeel.soundskin",15108,"SKINDEFAULT", SPIN_CONTROL_TEXT); + AddSeparator(laf, "lookandfeel.sep2"); +- AddBool(laf, "lookandfeel.enablerssfeeds",13305, true); ++ AddBool(laf, "lookandfeel.enablerssfeeds",13305, false); + AddString(laf, "lookandfeel.rssedit", 21450, "", BUTTON_CONTROL_STANDARD); + + CSettingsCategory* loc = AddCategory(SETTINGS_APPEARANCE, "locale", 14090); +diff --git a/xbmc/settings/GUIWindowSettingsCategory.cpp b/xbmc/settings/GUIWindowSettingsCategory.cpp +index b4cee69..a9bcb7a 100644 +--- a/xbmc/settings/GUIWindowSettingsCategory.cpp ++++ b/xbmc/settings/GUIWindowSettingsCategory.cpp +@@ -1271,7 +1271,7 @@ void CGUIWindowSettingsCategory::OnSettingChanged(CBaseSettingControl *pSettingC + if (!g_application.StartWebServer()) + { + CGUIDialogOK::ShowAndGetInput(g_localizeStrings.Get(33101), "", g_localizeStrings.Get(33100), ""); +- g_guiSettings.SetBool("services.webserver", false); ++ g_guiSettings.SetBool("services.webserver", true); + } + } + else if (strSetting.Equals("services.webserverusername") || strSetting.Equals("services.webserverpassword")) +@@ -1292,7 +1292,7 @@ void CGUIWindowSettingsCategory::OnSettingChanged(CBaseSettingControl *pSettingC + else + { + g_application.StopAirplayServer(true); +- g_guiSettings.SetBool("services.airplay", false); ++ g_guiSettings.SetBool("services.airplay", true); + CZeroconf::GetInstance()->Stop(); + } + #endif +-- +1.7.10.4 diff --git a/package/xbmc/xbmc.mk b/package/xbmc/xbmc.mk new file mode 100644 index 0000000..d05c2f5 --- /dev/null +++ b/package/xbmc/xbmc.mk @@ -0,0 +1,163 @@ +################################################################################ +# +# xbmc +# +################################################################################ + +XBMC_VERSION = 12.3-Frodo +XBMC_SITE = $(call github,xbmc,xbmc,$(XBMC_VERSION)) +XBMC_LICENSE = GPLv2 +XBMC_LICENSE_FILES = LICENSE.GPL +XBMC_DEPENDENCIES = host-gperf host-lzo host-sdl_image host-swig +XBMC_DEPENDENCIES += boost bzip2 expat flac fontconfig freetype jasper jpeg \ + libass libcdio libcurl libfribidi libgcrypt libmad libmodplug libmpeg2 \ + libogg libplist libpng libsamplerate libungif libvorbis libxml2 lzo ncurses \ + openssl pcre python readline sqlite taglib tiff tinyxml yajl zlib + +XBMC_CONF_ENV = \ + PYTHON_VERSION="$(PYTHON_VERSION_MAJOR)" \ + PYTHON_LDFLAGS="-lpython$(PYTHON_VERSION_MAJOR) -lpthread -ldl -lutil -lm" \ + PYTHON_CPPFLAGS="-I$(STAGING_DIR)/usr/include/python$(PYTHON_VERSION_MAJOR)" \ + PYTHON_SITE_PKG="$(STAGING_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages" \ + PYTHON_NOVERSIONCHECK="no-check" \ + TEXTUREPACKER_NATIVE_ROOT="$(HOST_DIR)/usr" + +XBMC_CONF_OPT += \ + --disable-alsa \ + --disable-crystalhd \ + --disable-debug \ + --disable-dvdcss \ + --disable-gl \ + --disable-hal \ + --disable-joystick \ + --disable-mysql \ + --disable-openmax \ + --disable-optical-drive \ + --disable-projectm \ + --disable-pulse \ + --disable-sdl \ + --disable-ssh \ + --disable-vaapi \ + --disable-vdpau \ + --disable-vtbdecoder \ + --disable-x11 \ + --disable-xrandr \ + --enable-gles \ + --enable-optimizations + +ifeq ($(BR2_PACKAGE_RPI_USERLAND),y) +XBMC_DEPENDENCIES += rpi-userland +XBMC_CONF_OPT += --with-platform=raspberry-pi --enable-player=omxplayer +XBMC_CONF_ENV += INCLUDES="-I$(STAGING_DIR)/usr/include/interface/vcos/pthreads \ + -I$(STAGING_DIR)/usr/include/interface/vmcs_host/linux" +endif + +ifeq ($(BR2_PACKAGE_DBUS),y) +XBMC_DEPENDENCIES += dbus +endif + +ifeq ($(BR2_PACKAGE_XBMC_LIBUSB),y) +XBMC_DEPENDENCIES += libusb-compat +XBMC_CONF_OPT += --enable-libusb +else +XBMC_CONF_OPT += --disable-libusb +endif + +ifeq ($(BR2_PACKAGE_XBMC_LIBMICROHTTPD),y) +XBMC_DEPENDENCIES += libmicrohttpd +XBMC_CONF_OPT += --enable-webserver +else +XBMC_CONF_OPT += --disable-webserver +endif + +ifeq ($(BR2_PACKAGE_XBMC_LIBSMBCLIENT),y) +XBMC_DEPENDENCIES += samba +XBMC_CONF_OPT += --enable-samba +else +XBMC_CONF_OPT += --disable-samba +endif + +ifeq ($(BR2_PACKAGE_XBMC_LIBNFS),y) +XBMC_DEPENDENCIES += libnfs +XBMC_CONF_OPT += --enable-nfs +else +XBMC_CONF_OPT += --disable-nfs +endif + +ifeq ($(BR2_PACKAGE_XBMC_RTMPDUMP),y) +XBMC_DEPENDENCIES += rtmpdump +XBMC_CONF_OPT += --enable-rtmp +else +XBMC_CONF_OPT += --disable-rtmp +endif + +ifeq ($(BR2_PACKAGE_XBMC_LIBBLURAY),y) +XBMC_DEPENDENCIES += libbluray +XBMC_CONF_OPT += --enable-libbluray +else +XBMC_CONF_OPT += --disable-libbluray +endif + +ifeq ($(BR2_PACKAGE_XBMC_LIBSHAIRPLAY),y) +XBMC_DEPENDENCIES += libshairplay +XBMC_CONF_OPT += --enable-airplay +else +XBMC_CONF_OPT += --disable-airplay +endif + +ifeq ($(BR2_PACKAGE_XBMC_AVAHI),y) +XBMC_DEPENDENCIES += avahi +XBMC_CONF_OPT += --enable-avahi +else +XBMC_CONF_OPT += --disable-avahi +endif + +ifeq ($(BR2_PACKAGE_XBMC_LIBCEC),y) +XBMC_DEPENDENCIES += libcec +XBMC_CONF_OPT += --enable-libcec +else +XBMC_CONF_OPT += --disable-libcec +endif + +ifeq ($(BR2_PACKAGE_XBMC_WAVPACK),y) +XBMC_DEPENDENCIES += wavpack +endif + +# Add HOST_DIR to PATH for codegenerator.mk to find swig +define XBMC_BOOTSTRAP + cd $(@D) && PATH=$(HOST_PATH) ./bootstrap +endef +XBMC_PRE_CONFIGURE_HOOKS += XBMC_BOOTSTRAP + +define XBMC_CLEAN_UNUSED_ADDONS + rm -Rf $(TARGET_DIR)/usr/share/xbmc/addons/screensaver.rsxs.plasma + rm -Rf $(TARGET_DIR)/usr/share/xbmc/addons/visualization.milkdrop + rm -Rf $(TARGET_DIR)/usr/share/xbmc/addons/visualization.projectm + rm -Rf $(TARGET_DIR)/usr/share/xbmc/addons/visualization.itunes +endef +XBMC_POST_INSTALL_TARGET_HOOKS += XBMC_CLEAN_UNUSED_ADDONS + +define XBMC_CLEAN_CONFLUENCE_SKIN + find $(TARGET_DIR)/usr/share/xbmc/addons/skin.confluence/media -name *.png -delete + find $(TARGET_DIR)/usr/share/xbmc/addons/skin.confluence/media -name *.jpg -delete +endef +XBMC_POST_INSTALL_TARGET_HOOKS += XBMC_CLEAN_CONFLUENCE_SKIN + +define XBMC_INSTALL_INIT_SYSV + [ -f $(TARGET_DIR)/etc/init.d/S50xbmc ] || \ + $(INSTALL) -D -m 755 package/xbmc/S50xbmc \ + $(TARGET_DIR)/etc/init.d/S50xbmc +endef + +define XBMC_INSTALL_INIT_SYSTEMD + [ -f $(TARGET_DIR)/etc/systemd/system/xbmc.service ] || \ + $(INSTALL) -D -m 644 package/xbmc/xbmc.service \ + $(TARGET_DIR)/etc/systemd/system/xbmc.service + + mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants + + ln -fs ../xbmc.service \ + $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/xbmc.service +endef + +$(eval $(autotools-package)) diff --git a/package/xbmc/xbmc.service b/package/xbmc/xbmc.service new file mode 100644 index 0000000..3fe5895 --- /dev/null +++ b/package/xbmc/xbmc.service @@ -0,0 +1,12 @@ +[Unit] +Description = XBMC media center +After = network.target + +[Service] +Type = simple +ExecStart = /usr/lib/xbmc/xbmc.bin --standalone -fs -n +Restart = on-failure + +[Install] +WantedBy = multi-user.target +