kodi-pvr / pvr.iptvsimple

IPTV Simple client for Kodi PVR
GNU General Public License v2.0
773 stars 372 forks source link

Isolate xz-utils version 5.2.4 #843

Closed thexai closed 6 months ago

thexai commented 7 months ago

UWP fails to build (when build all add-ons at time) due xz-utils "version conflict".

This add-on is use older version than others and cmake not detects properly.

Without this (or other solution) pvr.iptvsimple will not be included on Xbox v21 RC1 installer:

Captura de pantalla 2024-03-03 175945

https://jenkins.kodi.tv/view/Windows/job/WIN-UWP-64/24993/

Building pvr.iptvsimple...
[ 25%] Built target zlib
[ 50%] Built target pugixml
[ 75%] Built target xz-utils
[ 75%] Creating directories for 'pvr.iptvsimple'
[ 75%] No download step for 'pvr.iptvsimple'
[ 75%] No update step for 'pvr.iptvsimple'
[ 75%] No patch step for 'pvr.iptvsimple'
[ 75%] Performing configure step for 'pvr.iptvsimple'
CMake Warning:
  Ignoring extra path from command line:

   "C:/jenkins-workspace/workspace/WIN-UWP-64/project/Win32BuildSetup/BUILD_WIN32/addons"

CMake Warning:
  Ignoring extra path from command line:

   "C:/jenkins-workspace/workspace/WIN-UWP-64/project/Win32BuildSetup/BUILD_WIN32/addons"

-- The C compiler identification is MSVC 19.34.31937.0
-- The CXX compiler identification is MSVC 19.34.31937.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.34.31933/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.34.31933/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Checking to see if CXX compiler accepts flag -flto
-- Checking to see if CXX compiler accepts flag -flto - yes
-- Found pugixml: C:/jenkins-workspace/workspace/WIN-UWP-64/cmake/addons/output/include  
-- Found ZLIB: C:/jenkins-workspace/workspace/WIN-UWP-64/cmake/addons/output/lib/zlib.lib (found version "1.3.#define ZLIB_VERSION "1.3"")  
CMake Error at C:/Program Files/CMake/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find lzma (missing: LZMA_LIBRARIES)
Call Stack (most recent call first):
  C:/Program Files/CMake/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:600 (_FPHSA_FAILURE_MESSAGE)
  Findlzma.cmake:12 (find_package_handle_standard_args)
  CMakeLists.txt:9 (find_package)

-- Configuring incomplete, errors occurred!
NMAKE : fatal error U1077: 'echo' : return code '0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\bin\HostX64\x64\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\bin\HostX64\x64\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\bin\HostX64\x64\nmake.exe"' : return code '0x2'
Stop.

Latest installer that includes binary add-on in is: Kodi-20240204-99d8703b-master-x64.msix

thexai commented 7 months ago

I have reproduced locally and build fine with this PR, not sure if current failure in azure pipelines is related or not...

CD "V:\kodi\tools\buildsteps\windows\x64-uwp"

make-addons.bat inputstream.ffmpegdirect pvr.iptvsimple

Maybe better fix is update xz-utils to 5.4.3 same as inputstream.ffmpegdirect

ping @phunkyfish and @AlwinEsch

phunkyfish commented 7 months ago

Probably better to keep them the same. Why not update both addons to the same latest version?

Also, don’t forget that you need to update the sha256 hash too.

thexai commented 6 months ago

Why not update both addons to the same latest version?

Tested locally and "not works" or is not too simple. Needs more changes in CMakeLists, etc. this is out of my area...

If it helps this was working fine until some weeks ago (2024-02-04). then the breakage is due some recent change in this repo, others binary addons repos or the build system updates/changes.

thexai commented 6 months ago

Tested this PR locally build ALL UWP-64 / Xbox binary add-ons:

Fix consists in isolate xz-utils 5.2.4 version then is forced to build specifically for this addon and can coexists with 5.4.3 version in ..\kodi\cmake\addons\build (the other version not has version in folder name)

xz

All addons seems are build successfully for UWP-64 using kodi\tools\buildsteps\windows\x64-uwp\make-addons.bat script:

pvr

phunkyfish commented 6 months ago

Ok, I’ll take a look later this week.

phunkyfish commented 6 months ago

Ok, as it turns out ffmpedirect uses a much newer version and means we can delete all that cmake code and use a single depends config for all platforms, so a nice bit of tech debt removed. I also updated the other deps to match ffmpegdirect.

https://github.com/kodi-pvr/pvr.iptvsimple/pull/844

phunkyfish commented 6 months ago

Correction, in the end I couldn't remove the extra CMake config for xz-utils, but the versions now match ffmpegfdirect. So closing this PR.