From 5c105209db00b2a414a6796d2aef539dc963a310 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Mon, 8 Dec 2014 00:20:34 -0600 Subject: fix startup issues with kodi --- package/kodi/Makefile | 20 ++++---- package/kodi/files/kodi.init | 9 +++- package/kodi/patches/patch-configure_in | 6 +-- package/kodi/patches/patch-tools_Linux_kodi_sh_in | 39 ++++++++++++++++ package/kodi/patches/patch-xbmc_Application_cpp | 14 ++++++ ..._cores_dvdplayer_DVDDemuxers_DVDDemuxFFmpeg_cpp | 8 ++-- .../kodi/patches/patch-xbmc_utils_SystemInfo_cpp | 53 +++++++++++++++++++--- 7 files changed, 125 insertions(+), 24 deletions(-) create mode 100644 package/kodi/patches/patch-tools_Linux_kodi_sh_in create mode 100644 package/kodi/patches/patch-xbmc_Application_cpp (limited to 'package') diff --git a/package/kodi/Makefile b/package/kodi/Makefile index 08b230cc9..3be758227 100644 --- a/package/kodi/Makefile +++ b/package/kodi/Makefile @@ -174,23 +174,25 @@ CONFIGURE_ARGS+= --disable-x11 \ endif pre-configure: - (cd $(WRKBUILD)/lib/cpluff && env PATH=$(AUTOTOOL_PATH) ./autogen.sh) + (cd $(WRKBUILD)/lib/cpluff && env PATH='$(AUTOTOOL_PATH)' ./autogen.sh) pre-build: - PATH=$(HOST_PATH) \ + PATH='$(HOST_PATH)' \ make CXX="${HOST_CXX}" CC="${HOST_CC}" CFLAGS="${HOST_CFLAGS}" \ CXXFLAGS="${HOST_CXXFLAGS}" LDFLAGS="${HOST_LDFLAGS}" \ -C $(WRKBUILD)/tools/depends/native/JsonSchemaBuilder kodi-install: - $(INSTALL_DIR) $(IDIR_KODI)/usr/lib/xbmc/addons - $(CP) $(WRKINST)/usr/lib/xbmc/* \ - $(IDIR_KODI)/usr/lib/xbmc - $(INSTALL_DIR) $(IDIR_KODI)/usr/share/xbmc - $(CP) $(WRKINST)/usr/share/xbmc/* \ - $(IDIR_KODI)/usr/share/xbmc + $(INSTALL_DIR) $(IDIR_KODI)/usr/lib/kodi/addons + $(CP) $(WRKINST)/usr/lib/kodi/* \ + $(IDIR_KODI)/usr/lib/kodi + $(INSTALL_DIR) $(IDIR_KODI)/usr/share/kodi + $(CP) $(WRKINST)/usr/share/kodi/* \ + $(IDIR_KODI)/usr/share/kodi $(INSTALL_DIR) $(IDIR_KODI)/usr/bin - $(INSTALL_BIN) $(WRKINST)/usr/bin/xbmc \ + $(INSTALL_BIN) $(WRKINST)/usr/bin/kodi-standalone \ + $(IDIR_KODI)/usr/bin + $(INSTALL_BIN) $(WRKINST)/usr/bin/kodi \ $(IDIR_KODI)/usr/bin include ${ADK_TOPDIR}/mk/pkg-bottom.mk diff --git a/package/kodi/files/kodi.init b/package/kodi/files/kodi.init index b15b1d6d4..3f2345538 100644 --- a/package/kodi/files/kodi.init +++ b/package/kodi/files/kodi.init @@ -13,10 +13,15 @@ autostart) ;; start) export LD_LIBRARY_PATH=/opt/vc/lib - xbmc & + mkdir -p /data/kodi/temp + if [ $? -ne 0 ]; then + echo "/data not writable" + exit 1 + fi + kodi & ;; stop) - kill $(pgrep -f /usr/lib/xbmc/xbmc.bin) + kill $(pgrep -f /usr/lib/kodi/kodi.bin) ;; restart) sh $0 stop diff --git a/package/kodi/patches/patch-configure_in b/package/kodi/patches/patch-configure_in index 3db5985c7..aab2c5057 100644 --- a/package/kodi/patches/patch-configure_in +++ b/package/kodi/patches/patch-configure_in @@ -1,6 +1,6 @@ ---- kodi-14.0alpha4.orig/configure.in 2014-10-06 11:34:24.000000000 -0500 -+++ kodi-14.0alpha4/configure.in 2014-10-08 01:40:53.444436000 -0500 -@@ -1011,7 +1011,7 @@ if test "$use_gles" = "yes"; then +--- kodi-14.0rc2.orig/configure.in 2014-12-05 19:38:42.000000000 -0600 ++++ kodi-14.0rc2/configure.in 2014-12-07 03:43:25.212418001 -0600 +@@ -1008,7 +1008,7 @@ if test "$use_gles" = "yes"; then AC_DEFINE([HAVE_LIBEGL],[1],["Define to 1 if you have the `EGL' library (-lEGL)."]) AC_DEFINE([HAVE_LIBGLESV2],[1],["Define to 1 if you have the `GLESv2' library (-lGLESv2)."]) AC_MSG_RESULT(== WARNING: OpenGLES support is assumed.) diff --git a/package/kodi/patches/patch-tools_Linux_kodi_sh_in b/package/kodi/patches/patch-tools_Linux_kodi_sh_in new file mode 100644 index 000000000..2d0e188d1 --- /dev/null +++ b/package/kodi/patches/patch-tools_Linux_kodi_sh_in @@ -0,0 +1,39 @@ +--- kodi-14.0rc2.orig/tools/Linux/kodi.sh.in 2014-12-05 19:38:43.000000000 -0600 ++++ kodi-14.0rc2/tools/Linux/kodi.sh.in 2014-12-07 08:33:01.128418001 -0600 +@@ -86,15 +86,7 @@ print_crash_report() + echo -n " Kernel: " >> $FILE + uname -rvs >> $FILE + echo -n " Release: " >> $FILE +- if [ -f /etc/os-release ]; then +- . /etc/os-release +- echo $NAME $VERSION >> $FILE +- elif command_exists lsb_release; then +- echo >> $FILE +- lsb_release -a 2> /dev/null | sed -e 's/^/ /' >> $FILE +- else +- echo "lsb_release not available" >> $FILE +- fi ++ echo OpenADK >> $FILE + echo "############## END SYSTEM INFO ##############" >> $FILE + echo >> $FILE + echo "############### STACK TRACE #################" >> $FILE +@@ -138,19 +130,6 @@ print_crash_report() + } + + migrate_home +-python @datadir@/${bin_name}/FEH.py $SAVED_ARGS +-RET=$? +-if [ $RET -ne 0 ]; then +- exit $RET +-fi +- +-if command_exists gdb; then +- # Output warning in case ulimit is unsupported by shell +- eval ulimit -c unlimited +- if [ ! $? = "0" ]; then +- echo "${bin_name}: ulimit is unsupported by this shell" 1>&2 +- fi +-fi + + LOOP=1 + while [ $(( $LOOP )) = "1" ] diff --git a/package/kodi/patches/patch-xbmc_Application_cpp b/package/kodi/patches/patch-xbmc_Application_cpp new file mode 100644 index 000000000..2235d9f8b --- /dev/null +++ b/package/kodi/patches/patch-xbmc_Application_cpp @@ -0,0 +1,14 @@ +--- kodi-14.0rc2.orig/xbmc/Application.cpp 2014-12-05 19:38:44.000000000 -0600 ++++ kodi-14.0rc2/xbmc/Application.cpp 2014-12-07 10:16:27.900418001 -0600 +@@ -1076,10 +1076,7 @@ bool CApplication::InitDirectoriesLinux( + userName = "root"; + + std::string userHome; +- if (getenv("HOME")) +- userHome = getenv("HOME"); +- else +- userHome = "/root"; ++ userHome = "/data/kodi"; + + std::string appBinPath, appPath; + std::string appName = CCompileInfo::GetAppName(); diff --git a/package/kodi/patches/patch-xbmc_cores_dvdplayer_DVDDemuxers_DVDDemuxFFmpeg_cpp b/package/kodi/patches/patch-xbmc_cores_dvdplayer_DVDDemuxers_DVDDemuxFFmpeg_cpp index 0be4452a8..1660c5a36 100644 --- a/package/kodi/patches/patch-xbmc_cores_dvdplayer_DVDDemuxers_DVDDemuxFFmpeg_cpp +++ b/package/kodi/patches/patch-xbmc_cores_dvdplayer_DVDDemuxers_DVDDemuxFFmpeg_cpp @@ -1,6 +1,6 @@ ---- kodi-14.0alpha4.orig/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.cpp 2014-09-05 14:09:59.000000000 +0200 -+++ kodi-14.0alpha4/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.cpp 2014-09-05 15:53:47.432904545 +0200 -@@ -490,8 +490,8 @@ void CDVDDemuxFFmpeg::Reset() +--- kodi-14.0rc2.orig/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.cpp 2014-12-05 19:38:44.000000000 -0600 ++++ kodi-14.0rc2/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.cpp 2014-12-07 03:43:25.308418001 -0600 +@@ -520,8 +520,8 @@ void CDVDDemuxFFmpeg::Reset() void CDVDDemuxFFmpeg::Flush() { // naughty usage of an internal ffmpeg function @@ -9,5 +9,5 @@ + //if (m_pFormatContext) + // av_read_frame_flush(m_pFormatContext); - m_iCurrentPts = DVD_NOPTS_VALUE; + m_currentPts = DVD_NOPTS_VALUE; diff --git a/package/kodi/patches/patch-xbmc_utils_SystemInfo_cpp b/package/kodi/patches/patch-xbmc_utils_SystemInfo_cpp index e5131b7ec..1fddf255f 100644 --- a/package/kodi/patches/patch-xbmc_utils_SystemInfo_cpp +++ b/package/kodi/patches/patch-xbmc_utils_SystemInfo_cpp @@ -1,11 +1,52 @@ ---- kodi-14.0alpha4.orig/xbmc/utils/SystemInfo.cpp 2014-10-10 15:03:29.000000000 -0500 -+++ kodi-14.0alpha4/xbmc/utils/SystemInfo.cpp 2014-10-29 20:29:31.614352000 -0500 -@@ -618,7 +618,7 @@ std::string CSysInfo::GetOsName(bool emp - #elif defined (TARGET_ANDROID) +--- kodi-14.0rc2.orig/xbmc/utils/SystemInfo.cpp 2014-12-05 19:38:44.000000000 -0600 ++++ kodi-14.0rc2/xbmc/utils/SystemInfo.cpp 2014-12-07 23:48:19.332418001 -0600 +@@ -615,16 +615,11 @@ std::string CSysInfo::GetOsName(bool emp + osName = "iOS"; + #elif defined(TARGET_DARWIN_OSX) + osName = "OS X"; +-#elif defined (TARGET_ANDROID) ++#elif defined(TARGET_ANDROID) osName = "Android"; #elif defined(TARGET_LINUX) - osName = getValueFromOs_release("NAME"); +- if (osName.empty()) +- osName = getValueFromLsb_release(lsb_rel_distributor); +- if (osName.empty()) +- osName = getValueFromOs_release("ID"); +-#endif // defined(TARGET_LINUX) +- + osName = "OpenADK"; ++#endif if (osName.empty()) - osName = getValueFromLsb_release(lsb_rel_distributor); - if (osName.empty()) + osName = "Unknown OS"; + } +@@ -665,7 +660,7 @@ std::string CSysInfo::GetOsVersion(void) + #elif defined(TARGET_LINUX) + osVersion = getValueFromOs_release("VERSION_ID"); + if (osVersion.empty()) +- osVersion = getValueFromLsb_release(lsb_rel_release); ++ osVersion = "1.0"; + #endif // defined(TARGET_LINUX) + + if (osVersion.empty()) +@@ -737,19 +732,7 @@ std::string CSysInfo::GetOsPrettyNameWit + #elif defined(TARGET_ANDROID) + osNameVer = GetOsName() + " " + GetOsVersion() + " API level " + StringUtils::Format("%d", CJNIBuild::SDK_INT); + #elif defined(TARGET_LINUX) +- osNameVer = getValueFromOs_release("PRETTY_NAME"); +- if (osNameVer.empty()) +- { +- osNameVer = getValueFromLsb_release(lsb_rel_description); +- std::string osName(GetOsName(true)); +- if (!osName.empty() && osNameVer.find(osName) == std::string::npos) +- osNameVer = osName + osNameVer; +- if (osNameVer.empty()) +- osNameVer = "Unknown Linux Distribution"; +- } +- +- if (osNameVer.find(GetOsVersion()) == std::string::npos) +- osNameVer += " " + GetOsVersion(); ++ osNameVer = GetOsName() + " " + GetOsVersion(); + #endif // defined(TARGET_LINUX) + + if (osNameVer.empty()) -- cgit v1.2.3 From 86bcc78d0d03a84b4de26db90603f7d66e6c3d2e Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Tue, 9 Dec 2014 12:05:23 -0600 Subject: update to rc3, kodi now works on cubox-i --- package/firmware-imx/Makefile | 12 ++++++------ package/imx-lib/Makefile | 4 ++-- package/imx-vpu/Makefile | 4 ++-- package/kodi/Makefile | 4 ++-- package/kodi/files/kodi.init | 6 ------ 5 files changed, 12 insertions(+), 18 deletions(-) (limited to 'package') diff --git a/package/firmware-imx/Makefile b/package/firmware-imx/Makefile index 741926d1d..97eae9e58 100644 --- a/package/firmware-imx/Makefile +++ b/package/firmware-imx/Makefile @@ -4,10 +4,10 @@ include $(ADK_TOPDIR)/rules.mk PKG_NAME:= firmware-imx -PKG_VERSION:= 3.10.17-1.0.0 +PKG_VERSION:= 3.10.31-1.1.0-beta PKG_RELEASE:= 1 -PKG_MD5SUM:= 29a54f6e5bf889a00cd8ca85080af223 -PKG_DESCR:= IMX firmware (Freescale) +PKG_MD5SUM:= 4e102affc4273f424da4cec9f46adae8 +PKG_DESCR:= IMX VPU firmware (Freescale) PKG_SECTION:= sys/firmware PKG_URL:= http://www.freescale.com/ PKG_SITES:= http://www.freescale.com/lgfiles/NMG/MAD/YOCTO/ @@ -25,8 +25,8 @@ BUILD_STYLE:= manual INSTALL_STYLE:= manual firmware-imx-install: - $(INSTALL_DIR) $(IDIR_FIRMWARE_IMX)/lib/firmware - ${CP} ${WRKBUILD}/firmware/{sdma,vpu} \ - $(IDIR_FIRMWARE_IMX)/lib/firmware + $(INSTALL_DIR) $(IDIR_FIRMWARE_IMX)/lib/firmware/vpu + ${CP} ${WRKBUILD}/firmware/vpu/vpu_fw_imx6* \ + $(IDIR_FIRMWARE_IMX)/lib/firmware/vpu include ${ADK_TOPDIR}/mk/pkg-bottom.mk diff --git a/package/imx-lib/Makefile b/package/imx-lib/Makefile index 10566a5fb..eacee4a01 100644 --- a/package/imx-lib/Makefile +++ b/package/imx-lib/Makefile @@ -4,9 +4,9 @@ include $(ADK_TOPDIR)/rules.mk PKG_NAME:= imx-lib -PKG_VERSION:= 3.10.17-1.0.0 +PKG_VERSION:= 3.10.31-1.1.0-beta PKG_RELEASE:= 1 -PKG_MD5SUM:= 8e3346d5f33b5aa5f915a0dd8aa99cc9 +PKG_MD5SUM:= 0485e457eafe5a10274d171b3af79e2f PKG_DESCR:= IMX library (Freescale) PKG_SECTION:= libs/video PKG_URL:= http://www.freescale.com/ diff --git a/package/imx-vpu/Makefile b/package/imx-vpu/Makefile index 48337994d..bac6292bc 100644 --- a/package/imx-vpu/Makefile +++ b/package/imx-vpu/Makefile @@ -4,9 +4,9 @@ include $(ADK_TOPDIR)/rules.mk PKG_NAME:= imx-vpu -PKG_VERSION:= 3.10.17-1.0.0 +PKG_VERSION:= 3.10.31-1.1.0-beta PKG_RELEASE:= 1 -PKG_MD5SUM:= 71ea1b803864101ebf88a1bab45514d2 +PKG_MD5SUM:= ab76e7395b6a178a8538a6d5beb87656 PKG_DESCR:= IMX VPU library (Freescale) PKG_DEPENDS:= firmware-imx PKG_SECTION:= libs/video diff --git a/package/kodi/Makefile b/package/kodi/Makefile index 3be758227..c0e1866a9 100644 --- a/package/kodi/Makefile +++ b/package/kodi/Makefile @@ -4,9 +4,9 @@ include $(ADK_TOPDIR)/rules.mk PKG_NAME:= kodi -PKG_VERSION:= 14.0rc2 +PKG_VERSION:= 14.0rc3 PKG_RELEASE:= 1 -PKG_MD5SUM:= f56aeb81db6878fcac6631f6a3e2c702 +PKG_MD5SUM:= ab161aa0dee4ca77b977d3ca2f4ebdd5 PKG_DESCR:= software media player PKG_SECTION:= mm/video PKG_DEPENDS:= boost python2 libstdcxx glibc-gconv diff --git a/package/kodi/files/kodi.init b/package/kodi/files/kodi.init index 3f2345538..6dddfd421 100644 --- a/package/kodi/files/kodi.init +++ b/package/kodi/files/kodi.init @@ -12,12 +12,6 @@ autostart) exec sh $0 start ;; start) - export LD_LIBRARY_PATH=/opt/vc/lib - mkdir -p /data/kodi/temp - if [ $? -ne 0 ]; then - echo "/data not writable" - exit 1 - fi kodi & ;; stop) -- cgit v1.2.3