aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorfuzzard <fuzzard@users.noreply.github.com>2023-11-05 15:21:42 +1000
committerGitHub <noreply@github.com>2023-11-05 15:21:42 +1000
commit757bd86acc632add94dd5a5ac169a99d62c5bcdd (patch)
tree6c22258936f342ada464d4595b5b6d34d1ede3c1 /tools
parente5490023e0046c6bd4dd5c849106cde5152e33dc (diff)
parentc3c9972ae01ac167de7f9f7cc40b12943ce2755e (diff)
Merge pull request #21585 from fuzzard/cmake_libcec
[Cmake] enable_internal_cec
Diffstat (limited to 'tools')
-rw-r--r--tools/depends/target/Makefile7
-rw-r--r--tools/depends/target/cec/001-all-cmakelists.patch40
-rw-r--r--tools/depends/target/cec/002-all-libceccmakelists.patch42
-rw-r--r--tools/depends/target/cec/003-all-remove_git_info.patch (renamed from tools/depends/target/libcec/remove_git_info.patch)2
-rw-r--r--tools/depends/target/cec/004-win-remove_32bit_timet.patch10
-rw-r--r--tools/depends/target/cec/005-win-pdbstatic.patch58
-rw-r--r--tools/depends/target/cec/CEC-VERSION6
-rw-r--r--tools/depends/target/cec/Makefile47
-rw-r--r--tools/depends/target/libcec/Makefile45
-rw-r--r--tools/depends/target/p8-platform/001-all-fix-c++17-support.patch (renamed from tools/depends/target/p8-platform/0001-fix-c++17-support.patch)0
-rw-r--r--tools/depends/target/p8-platform/002-all-fixcmakeinstall.patch29
-rw-r--r--tools/depends/target/p8-platform/003-all-cmake_tweakversion.patch21
-rw-r--r--tools/depends/target/p8-platform/Makefile23
-rw-r--r--tools/depends/target/p8-platform/P8-PLATFORM-VERSION6
14 files changed, 272 insertions, 64 deletions
diff --git a/tools/depends/target/Makefile b/tools/depends/target/Makefile
index 5e9f307e62..825888d00a 100644
--- a/tools/depends/target/Makefile
+++ b/tools/depends/target/Makefile
@@ -23,7 +23,6 @@ DEPENDS = \
harfbuzz \
libass \
libbluray \
- libcec \
libffi \
libgcrypt \
libgpg-error \
@@ -40,7 +39,6 @@ DEPENDS = \
nettle \
nghttp2 \
openssl \
- p8-platform \
python3 \
pythonmodule-pil \
pythonmodule-pycryptodome \
@@ -57,7 +55,7 @@ else
endif
ifeq ($(OS),darwin_embedded)
- EXCLUDED_DEPENDS = libcec libusb gtest
+ EXCLUDED_DEPENDS = libusb gtest
ifeq ($(TARGET_PLATFORM),appletvos)
EXCLUDED_DEPENDS += libshairplay libplist
endif
@@ -70,7 +68,7 @@ ifeq ($(OS),osx)
endif
ifeq ($(OS),android)
- EXCLUDED_DEPENDS = libcec libusb gtest
+ EXCLUDED_DEPENDS = libusb gtest
DEPENDS += dummy-libxbmc libdovi libuuid
PYMODULE_DEPS = dummy-libxbmc
LIBUUID = libuuid
@@ -164,7 +162,6 @@ libass: fontconfig fribidi harfbuzz libpng freetype2 expat $(ICONV)
libbluray: fontconfig freetype2 $(ICONV) udfread libxml2
libcdio-gplv3: $(ICONV)
libcdio: $(ICONV)
-libcec: p8-platform
libdisplay-info: hwdata
libevdev: libudev
libgcrypt: libgpg-error
diff --git a/tools/depends/target/cec/001-all-cmakelists.patch b/tools/depends/target/cec/001-all-cmakelists.patch
new file mode 100644
index 0000000000..370c3a0fe1
--- /dev/null
+++ b/tools/depends/target/cec/001-all-cmakelists.patch
@@ -0,0 +1,40 @@
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -6,6 +6,7 @@
+ set(LIBCEC_VERSION_PATCH 7)
+
+ # cec-client
++if(ENABLE_CLIENT)
+ add_subdirectory(src/cec-client)
+ add_dependencies(cec-client cec)
+
+@@ -15,6 +16,7 @@
+
+ # pyCecClient
+ add_subdirectory(src/pyCecClient)
++endif()
+
+ # libCEC
+ add_subdirectory(src/libcec)
+@@ -25,6 +27,7 @@
+
+ # windows specific files
+ if(WIN32)
++if(ENABLE_CLIENT)
+ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/project/nsis/libcec-version.nsh.in
+ ${CMAKE_CURRENT_SOURCE_DIR}/project/nsis/libcec-version.nsh)
+ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/src/dotnetlib/LibCecSharp/LibCecSharp.rc.in
+@@ -40,3 +43,13 @@
+ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/src/dotnet/src/CecSharpTester/netfx/CecSharpTester.csproj.in
+ ${CMAKE_CURRENT_SOURCE_DIR}/src/dotnet/src/CecSharpTester/netfx/CecSharpTester.csproj)
+ endif()
++endif()
++
++# handle version file
++include(CMakePackageConfigHelpers)
++write_basic_package_version_file(${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config-version.cmake
++ VERSION "${LIBCEC_VERSION_MAJOR}.${LIBCEC_VERSION_MINOR}.${LIBCEC_VERSION_PATCH}"
++ COMPATIBILITY AnyNewerVersion)
++
++install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config-version.cmake
++ DESTINATION lib/cmake/${PROJECT_NAME})
diff --git a/tools/depends/target/cec/002-all-libceccmakelists.patch b/tools/depends/target/cec/002-all-libceccmakelists.patch
new file mode 100644
index 0000000000..a5b44a6db0
--- /dev/null
+++ b/tools/depends/target/cec/002-all-libceccmakelists.patch
@@ -0,0 +1,42 @@
+--- a/src/libcec/CMakeLists.txt
++++ b/src/libcec/CMakeLists.txt
+@@ -175,7 +175,7 @@
+ ${CMAKE_INSTALL_PREFIX}/include)
+
+ install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/libcec.pc
+- DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
++ DESTINATION lib/pkgconfig)
+ endif()
+
+ # install headers
+@@ -193,11 +193,25 @@
+ # libCEC shared target
+ add_library(cec SHARED ${CEC_SOURCES})
+ install(TARGETS cec
+- DESTINATION ${LIB_DESTINATION})
++ EXPORT libcec
++ RUNTIME DESTINATION bin
++ ARCHIVE DESTINATION lib
++ LIBRARY DESTINATION lib)
++
++install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/cmake/libcec-config.cmake
++ DESTINATION lib/cmake/libcec)
++
+ set_target_properties(cec PROPERTIES VERSION ${LIBCEC_VERSION_MAJOR}.${LIBCEC_VERSION_MINOR}.${LIBCEC_VERSION_PATCH}
+ SOVERSION ${LIBCEC_VERSION_MAJOR})
+ target_link_libraries(cec ${cec_depends})
+
++install(EXPORT libcec
++ NAMESPACE
++ libcec::
++ DESTINATION
++ lib/cmake/libcec
++)
++
+ if (MSVC)
+ # generate pdb in release mode too
+ set_target_properties(cec
+--- /dev/null
++++ b/src/libcec/cmake/libcec-config.cmake
+@@ -0,0 +1 @@
++include(${CMAKE_CURRENT_LIST_DIR}/libcec.cmake)
diff --git a/tools/depends/target/libcec/remove_git_info.patch b/tools/depends/target/cec/003-all-remove_git_info.patch
index 4ade84bba4..5927552edb 100644
--- a/tools/depends/target/libcec/remove_git_info.patch
+++ b/tools/depends/target/cec/003-all-remove_git_info.patch
@@ -15,4 +15,4 @@
+ endif()
# add compilation date to compile info
- find_program(HAVE_DATE_BIN date /bin /usr/bin /usr/local/bin)
+ STRING(TIMESTAMP BUILD_DATE "%Y-%m-%d %H:%M:%S" UTC)
diff --git a/tools/depends/target/cec/004-win-remove_32bit_timet.patch b/tools/depends/target/cec/004-win-remove_32bit_timet.patch
new file mode 100644
index 0000000000..4fe2a2f5db
--- /dev/null
+++ b/tools/depends/target/cec/004-win-remove_32bit_timet.patch
@@ -0,0 +1,10 @@
+--- a/src/libcec/cmake/CheckPlatformSupport.cmake
++++ b/src/libcec/cmake/CheckPlatformSupport.cmake
+@@ -49,7 +49,6 @@
+
+ if("${MSVC_C_ARCHITECTURE_ID}" STREQUAL "X86")
+ set(LIB_INFO "${LIB_INFO} (x86)")
+- add_definitions(-D_USE_32BIT_TIME_T)
+ # force python2 for eventghost
+ set(PYTHON_USE_VERSION 2)
+ elseif("${MSVC_C_ARCHITECTURE_ID}" STREQUAL "x64")
diff --git a/tools/depends/target/cec/005-win-pdbstatic.patch b/tools/depends/target/cec/005-win-pdbstatic.patch
new file mode 100644
index 0000000000..9dfdc17c66
--- /dev/null
+++ b/tools/depends/target/cec/005-win-pdbstatic.patch
@@ -0,0 +1,58 @@
+--- a/src/libcec/CMakeLists.txt
++++ b/src/libcec/CMakeLists.txt
+@@ -213,15 +213,26 @@
+
+ if (MSVC)
+ # generate pdb in release mode too
++ # Tell linker to include symbol data
++ target_compile_options(cec PRIVATE $<$<CONFIG:RELEASE>:/Zi>)
++
++ # Tell linker to include symbol data
++ set_target_properties(cec PROPERTIES
++ LINK_FLAGS_RELEASE "/INCREMENTAL:NO /DEBUG /OPT:REF /OPT:ICF"
++ )
+ set_target_properties(cec
+ PROPERTIES
+ COMPILE_PDB_NAME_DEBUG cec${CMAKE_DEBUG_POSTFIX}
+ COMPILE_PDB_NAME_RELEASE cec
+ COMPILE_PDB_NAME_MINSIZEREL cec
+ COMPILE_PDB_NAME_RELWITHDEBINFO cec)
++
++ # install generated pdb
++ install(FILES $<TARGET_PDB_FILE:cec> DESTINATION lib)
+ endif(MSVC)
+
+ if(WIN32)
++if(ENABLE_STATIC)
+ # libCEC static target used by .net wrappers
+ add_library(cec-static STATIC ${CEC_SOURCES})
+ install(TARGETS cec-static
+@@ -243,6 +243,12 @@
+
+ if (MSVC)
+ # generate pdb in release mode too
++ target_compile_options(cec-static PRIVATE $<$<CONFIG:RELEASE>:/Zi>)
++
++ # Tell linker to include symbol data
++ set_target_properties(cec-static PROPERTIES
++ LINK_FLAGS_RELEASE "/INCREMENTAL:NO /DEBUG /OPT:REF /OPT:ICF"
++ )
+ set_target_properties(cec-static
+ PROPERTIES
+ COMPILE_PDB_NAME_DEBUG cec-static${CMAKE_DEBUG_POSTFIX}
+@@ -256,12 +256,10 @@
+ COMPILE_PDB_NAME_MINSIZEREL cec-static
+ COMPILE_PDB_NAME_RELWITHDEBINFO cec-static)
+
+- # install generated pdb
+- install(FILES $<TARGET_FILE_DIR:cec>/cec.pdb
+- DESTINATION "${CMAKE_INSTALL_LIBDIR}")
+- install(FILES $<TARGET_FILE_DIR:cec-static>/cec-static.pdb
+- DESTINATION "${CMAKE_INSTALL_LIBDIR}")
++ install(FILES $<TARGET_PDB_FILE:cec-static>
++ DESTINATION lib)
+ endif(MSVC)
++endif()
+ endif(WIN32)
+
+ include(cmake/DisplayPlatformSupport.cmake)
diff --git a/tools/depends/target/cec/CEC-VERSION b/tools/depends/target/cec/CEC-VERSION
new file mode 100644
index 0000000000..1a726d3bfe
--- /dev/null
+++ b/tools/depends/target/cec/CEC-VERSION
@@ -0,0 +1,6 @@
+LIBNAME=libcec
+VERSION=4.0.7
+ARCHIVE=$(LIBNAME)-$(VERSION).tar.gz
+SHA512=424540a45f9cae3d5dcccc615d487c45033f9cdeb665b8176832495597e2cd58ef7681e13b52f6a32f8a40e1146c04a1a383f5785ea1e731c5c517a9a7843a81
+BYPRODUCT=libcec.so
+BYPRODUCT_WIN=cec.lib
diff --git a/tools/depends/target/cec/Makefile b/tools/depends/target/cec/Makefile
new file mode 100644
index 0000000000..403f4f03f1
--- /dev/null
+++ b/tools/depends/target/cec/Makefile
@@ -0,0 +1,47 @@
+include ../../Makefile.include CEC-VERSION ../../download-files.include
+DEPS = ../../Makefile.include Makefile CEC-VERSION ../../download-files.include \
+ 001-all-cmakelists.patch \
+ 002-all-libceccmakelists.patch \
+ 003-all-remove_git_info.patch \
+ 004-win-remove_32bit_timet.patch \
+ 005-win-pdbstatic.patch
+
+LIBDYLIB=$(PLATFORM)/build/src/$(LIBNAME)/$(BYPRODUCT)
+ifeq (darwin, $(findstring darwin, $(HOST)))
+ LIBDYLIB=$(PLATFORM)/build/src/$(LIBNAME)/$(BYPRODUCT_MAC)
+endif
+
+CMAKE_OPTIONS=-DBUILD_SHARED_LIBS=1 \
+ -DSKIP_PYTHON_WRAPPER:STRING=1 \
+ -DCMAKE_PLATFORM_NO_VERSIONED_SONAME=1 \
+ -DCMAKE_INSTALL_PREFIX=$(PREFIX) \
+ -DCMAKE_BUILD_TYPE=Debug
+
+all: .installed-$(PLATFORM)
+
+$(PLATFORM): $(TARBALLS_LOCATION)/$(ARCHIVE).$(HASH_TYPE) $(DEPS)
+ rm -rf $(PLATFORM); mkdir -p $(PLATFORM)/build
+ cd $(PLATFORM); $(ARCHIVE_TOOL) $(ARCHIVE_TOOL_FLAGS) $(TARBALLS_LOCATION)/$(ARCHIVE)
+ cd $(PLATFORM); patch -p1 -i ../001-all-cmakelists.patch
+ cd $(PLATFORM); patch -p1 -i ../002-all-libceccmakelists.patch
+ cd $(PLATFORM); patch -p1 -i ../003-all-remove_git_info.patch
+ cd $(PLATFORM); patch -p1 -i ../004-win-remove_32bit_timet.patch
+ cd $(PLATFORM); patch -p1 -i ../005-win-pdbstatic.patch
+ cd $(PLATFORM)/build; $(CMAKE) ${CMAKE_OPTIONS} ..
+
+$(LIBDYLIB): $(PLATFORM)
+ $(MAKE) -C $(PLATFORM)/build
+
+.installed-$(PLATFORM): $(LIBDYLIB)
+ $(MAKE) -C $(PLATFORM)/build install
+ifeq (darwin, $(findstring darwin, $(HOST)))
+ install_name_tool -id $(PREFIX)/lib/$(LIBNAME).dylib $(PREFIX)/lib/$(LIBNAME).dylib
+endif
+ touch $@
+
+clean:
+ rm -rf $(PLATFORM) .installed-$(PLATFORM)
+
+distclean::
+ rm -rf $(PLATFORM) .installed-$(PLATFORM)
+
diff --git a/tools/depends/target/libcec/Makefile b/tools/depends/target/libcec/Makefile
deleted file mode 100644
index 884e9bf1f5..0000000000
--- a/tools/depends/target/libcec/Makefile
+++ /dev/null
@@ -1,45 +0,0 @@
-include ../../Makefile.include
-DEPS = ../../Makefile.include Makefile remove_git_info.patch ../../download-files.include
-
-# lib name, version
-LIBNAME=libcec
-VERSION_MAJOR=4
-VERSION_MINOR=0
-VERSION_PATCH=7
-
-VERSION=$(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_PATCH)
-SOURCE=$(LIBNAME)-$(VERSION)
-ARCHIVE=$(SOURCE).tar.gz
-SHA512=424540a45f9cae3d5dcccc615d487c45033f9cdeb665b8176832495597e2cd58ef7681e13b52f6a32f8a40e1146c04a1a383f5785ea1e731c5c517a9a7843a81
-include ../../download-files.include
-
-LIBDYLIB=$(PLATFORM)/build/src/$(LIBNAME)/$(LIBNAME).so
-ifeq (darwin, $(findstring darwin, $(HOST)))
- LIBDYLIB=$(PLATFORM)/build/src/$(LIBNAME)/$(LIBNAME).dylib
-endif
-
-all: .installed-$(PLATFORM)
-
-
-$(PLATFORM): $(DEPS) | $(TARBALLS_LOCATION)/$(ARCHIVE).$(HASH_TYPE)
- rm -rf $(PLATFORM); mkdir -p $(PLATFORM)/build
- cd $(PLATFORM); $(ARCHIVE_TOOL) $(ARCHIVE_TOOL_FLAGS) $(TARBALLS_LOCATION)/$(ARCHIVE)
- cd $(PLATFORM); patch -p1 -i ../remove_git_info.patch
- cd $(PLATFORM)/build; $(CMAKE) -DBUILD_SHARED_LIBS=1 -DSKIP_PYTHON_WRAPPER:STRING=1 -DCMAKE_INSTALL_LIBDIR=$(PREFIX)/lib -DCMAKE_PLATFORM_NO_VERSIONED_SONAME=1 ..
-
-$(LIBDYLIB): $(PLATFORM)
- $(MAKE) -C $(PLATFORM)/build
-
-.installed-$(PLATFORM): $(LIBDYLIB)
- $(MAKE) -C $(PLATFORM)/build install
-ifeq (darwin, $(findstring darwin, $(HOST)))
- install_name_tool -id $(PREFIX)/lib/$(LIBNAME).dylib $(PREFIX)/lib/$(LIBNAME).dylib
-endif
- touch $@
-
-clean:
- rm -rf $(PLATFORM) .installed-$(PLATFORM)
-
-distclean::
- rm -rf $(PLATFORM) .installed-$(PLATFORM)
-
diff --git a/tools/depends/target/p8-platform/0001-fix-c++17-support.patch b/tools/depends/target/p8-platform/001-all-fix-c++17-support.patch
index 25fbe483fe..25fbe483fe 100644
--- a/tools/depends/target/p8-platform/0001-fix-c++17-support.patch
+++ b/tools/depends/target/p8-platform/001-all-fix-c++17-support.patch
diff --git a/tools/depends/target/p8-platform/002-all-fixcmakeinstall.patch b/tools/depends/target/p8-platform/002-all-fixcmakeinstall.patch
new file mode 100644
index 0000000000..be22576415
--- /dev/null
+++ b/tools/depends/target/p8-platform/002-all-fixcmakeinstall.patch
@@ -0,0 +1,29 @@
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -41,7 +41,10 @@
+ set_target_properties(p8-platform PROPERTIES VERSION ${p8-platform_VERSION_MAJOR}.${p8-platform_VERSION_MINOR}.${p8-platform_VERSION_PATCH}
+ SOVERSION ${p8-platform_VERSION_MAJOR})
+
+-install(TARGETS p8-platform DESTINATION ${CMAKE_INSTALL_LIBDIR})
++install(TARGETS p8-platform
++ RUNTIME DESTINATION bin
++ ARCHIVE DESTINATION lib
++ LIBRARY DESTINATION lib)
+ install(FILES src/os.h DESTINATION include/p8-platform)
+ IF(WIN32)
+ INSTALL(FILES src/windows/dlfcn-win32.h
+@@ -74,12 +77,12 @@
+ IF(NOT WIN32)
+ configure_file(p8-platform.pc.in p8-platform.pc @ONLY)
+ install(FILES ${CMAKE_BINARY_DIR}/p8-platform.pc
+- DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
++ DESTINATION lib/pkgconfig)
+ ENDIF(NOT WIN32)
+
+ # config mode
+ configure_file (p8-platform-config.cmake.in
+ p8-platform-config.cmake @ONLY)
+ install(FILES ${CMAKE_BINARY_DIR}/p8-platform-config.cmake
+- DESTINATION ${CMAKE_INSTALL_LIBDIR}/p8-platform)
++ DESTINATION lib/cmake/p8-platform)
+
diff --git a/tools/depends/target/p8-platform/003-all-cmake_tweakversion.patch b/tools/depends/target/p8-platform/003-all-cmake_tweakversion.patch
new file mode 100644
index 0000000000..24b9a65654
--- /dev/null
+++ b/tools/depends/target/p8-platform/003-all-cmake_tweakversion.patch
@@ -0,0 +1,21 @@
+--- a/p8-platform-config.cmake.in
++++ b/p8-platform-config.cmake.in
+@@ -9,7 +9,7 @@
+ # p8-platform_LIBRARY_DIRS - directories in which the libraries are situated
+ #
+ # propagate these properties from one build system to the other
+-set (p8-platform_VERSION "@p8-platform_VERSION_MAJOR@.@p8-platform_VERSION_MINOR@")
++set (p8-platform_VERSION "@p8-platform_VERSION_MAJOR@.@p8-platform_VERSION_MINOR@.@p8-platform_VERSION_PATCH@.@p8-platform_VERSION_TWEAK@")
+ set (p8-platform_INCLUDE_DIRS @p8-platform_INCLUDE_DIRS@ @CMAKE_INSTALL_PREFIX@/include)
+ set (p8-platform_LIBRARY_DIRS "@CMAKE_LIBRARY_OUTPUT_DIRECTORY@")
+ set (p8-platform_LINKER_FLAGS "@p8-platform_LINKER_FLAGS@")
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -14,6 +14,7 @@
+ set(p8-platform_VERSION_MAJOR 2)
+ set(p8-platform_VERSION_MINOR 1)
+ set(p8-platform_VERSION_PATCH 0)
++set(p8-platform_VERSION_TWEAK 1)
+
+ set(CMAKE_POSITION_INDEPENDENT_CODE on)
+
diff --git a/tools/depends/target/p8-platform/Makefile b/tools/depends/target/p8-platform/Makefile
index 649c638b9a..4d3fd00cb4 100644
--- a/tools/depends/target/p8-platform/Makefile
+++ b/tools/depends/target/p8-platform/Makefile
@@ -1,15 +1,10 @@
-include ../../Makefile.include
-DEPS = ../../Makefile.include Makefile 0001-fix-c++17-support.patch ../../download-files.include
+include ../../Makefile.include P8-PLATFORM-VERSION ../../download-files.include
+DEPS = ../../Makefile.include Makefile P8-PLATFORM-VERSION ../../download-files.include \
+ 001-all-fix-c++17-support.patch \
+ 002-all-fixcmakeinstall.patch \
+ 003-all-cmake_tweakversion.patch
-# lib name, version
-LIBNAME=p8-platform
-VERSION=2.1.0.1
-SOURCE=$(LIBNAME)-$(VERSION)
-ARCHIVE=$(SOURCE).tar.gz
-SHA512=10f8e3ca8ea7a48923a4cc57d47015b56b4bdbf78997ba77abd9fc2f929198fda16dfb869ba69eec393ab4b635be916c3ed9a07d6989bf8265aa055794e84bf7
-include ../../download-files.include
-
-LIBDYLIB=$(PLATFORM)/build/lib$(LIBNAME).a
+LIBDYLIB=$(PLATFORM)/build/$(BYPRODUCT)
all: .installed-$(PLATFORM)
@@ -17,8 +12,10 @@ all: .installed-$(PLATFORM)
$(PLATFORM): $(DEPS) | $(TARBALLS_LOCATION)/$(ARCHIVE).$(HASH_TYPE)
rm -rf $(PLATFORM); mkdir -p $(PLATFORM)/build
cd $(PLATFORM); $(ARCHIVE_TOOL) $(ARCHIVE_TOOL_FLAGS) $(TARBALLS_LOCATION)/$(ARCHIVE)
- cd $(PLATFORM); patch -p1 -i ../0001-fix-c++17-support.patch
- cd $(PLATFORM)/build; $(CMAKE) -DBUILD_SHARED_LIBS=0 -DCMAKE_INSTALL_LIBDIR=$(PREFIX)/lib ..
+ cd $(PLATFORM); patch -p1 -i ../001-all-fix-c++17-support.patch
+ cd $(PLATFORM); patch -p1 -i ../002-all-fixcmakeinstall.patch
+ cd $(PLATFORM); patch -p1 -i ../003-all-cmake_tweakversion.patch
+ cd $(PLATFORM)/build; $(CMAKE) -DBUILD_SHARED_LIBS=0 ..
$(LIBDYLIB): $(PLATFORM)
$(MAKE) -C $(PLATFORM)/build
diff --git a/tools/depends/target/p8-platform/P8-PLATFORM-VERSION b/tools/depends/target/p8-platform/P8-PLATFORM-VERSION
new file mode 100644
index 0000000000..f9ac55968e
--- /dev/null
+++ b/tools/depends/target/p8-platform/P8-PLATFORM-VERSION
@@ -0,0 +1,6 @@
+LIBNAME=p8-platform
+VERSION=2.1.0.1
+ARCHIVE=$(LIBNAME)-$(VERSION).tar.gz
+SHA512=10f8e3ca8ea7a48923a4cc57d47015b56b4bdbf78997ba77abd9fc2f929198fda16dfb869ba69eec393ab4b635be916c3ed9a07d6989bf8265aa055794e84bf7
+BYPRODUCT=libp8-platform.a
+BYPRODUCT_WIN=p8-platform.lib