From 1287f5331a7d6ff770bac075291d69b851195b61 Mon Sep 17 00:00:00 2001 From: Era Dorta Date: Sun, 11 Jun 2023 17:41:15 +0000 Subject: [PATCH 1/5] fix(deb): Add missing libboost-chrono to debian deps --- CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index ccca6fcec60..3b689a52fdf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -902,6 +902,7 @@ elseif(UNIX) set(CPACK_DEB_COMPONENT_INSTALL ON) set(CPACK_DEBIAN_PACKAGE_DEPENDS "\ ${CPACK_DEB_PLATFORM_PACKAGE_DEPENDS} \ + libboost-chrono${Boost_VERSION}, \ libboost-filesystem${Boost_VERSION}, \ libboost-locale${Boost_VERSION}, \ libboost-log${Boost_VERSION}, \ From b5c8dc9c0d9688f846d6eadc3abf48bb02b08502 Mon Sep 17 00:00:00 2001 From: Era Dorta Date: Sun, 11 Jun 2023 18:15:05 +0000 Subject: [PATCH 2/5] Revert libboost-chrono install --- CMakeLists.txt | 1 - 1 file changed, 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3b689a52fdf..ccca6fcec60 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -902,7 +902,6 @@ elseif(UNIX) set(CPACK_DEB_COMPONENT_INSTALL ON) set(CPACK_DEBIAN_PACKAGE_DEPENDS "\ ${CPACK_DEB_PLATFORM_PACKAGE_DEPENDS} \ - libboost-chrono${Boost_VERSION}, \ libboost-filesystem${Boost_VERSION}, \ libboost-locale${Boost_VERSION}, \ libboost-log${Boost_VERSION}, \ From 27ce5eb80d551309375c65714b810045efa6a54a Mon Sep 17 00:00:00 2001 From: Era Dorta Date: Sun, 11 Jun 2023 18:15:53 +0000 Subject: [PATCH 3/5] fix(chrono): remove libboost chrono include --- src/input.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/input.cpp b/src/input.cpp index a9a38e2d91c..b041241e46d 100644 --- a/src/input.cpp +++ b/src/input.cpp @@ -10,6 +10,7 @@ extern "C" { } #include +#include #include #include "config.h" @@ -19,7 +20,6 @@ extern "C" { #include "thread_pool.h" #include "utility.h" -#include #include using namespace std::literals; @@ -738,7 +738,7 @@ namespace input { platf::gamepad(platf_input, gamepad.id, state); // Sleep for a short time to allow the input to be detected - boost::this_thread::sleep_for(boost::chrono::milliseconds(100)); + boost::this_thread::sleep_for(std::chrono::milliseconds(100)); // Release Home button state.buttonFlags &= ~platf::HOME; From 51ab250b35a3eb54a9956fb2cba9c49cff58aaf5 Mon Sep 17 00:00:00 2001 From: Era Dorta Date: Mon, 12 Jun 2023 19:58:32 +0000 Subject: [PATCH 4/5] Switch to std::thread --- src/input.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/input.cpp b/src/input.cpp index b041241e46d..91f6ab813d9 100644 --- a/src/input.cpp +++ b/src/input.cpp @@ -11,6 +11,7 @@ extern "C" { #include #include +#include #include #include "config.h" @@ -20,8 +21,6 @@ extern "C" { #include "thread_pool.h" #include "utility.h" -#include - using namespace std::literals; namespace input { @@ -738,7 +737,7 @@ namespace input { platf::gamepad(platf_input, gamepad.id, state); // Sleep for a short time to allow the input to be detected - boost::this_thread::sleep_for(std::chrono::milliseconds(100)); + std::this_thread::sleep_for(std::chrono::milliseconds(100)); // Release Home button state.buttonFlags &= ~platf::HOME; From 9da17309831954d327a495c0989773af5017db9a Mon Sep 17 00:00:00 2001 From: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com> Date: Fri, 23 Jun 2023 18:52:10 -0400 Subject: [PATCH 5/5] build(deps): remove boost-thread --- .github/workflows/CI.yml | 2 -- CMakeLists.txt | 2 -- docker/debian-bullseye.dockerfile | 1 - docker/ubuntu-20.04.dockerfile | 1 - docker/ubuntu-22.04.dockerfile | 1 - docs/source/building/linux.rst | 3 --- 6 files changed, 10 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index a2d7f99fb44..bcf9df8476d 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -285,7 +285,6 @@ jobs: libboost-locale1.71-dev \ libboost-log1.71-dev \ libboost-regex1.71-dev \ - libboost-thread1.71-dev \ libboost-program-options1.71-dev # Install cmake @@ -311,7 +310,6 @@ jobs: libboost-filesystem-dev \ libboost-locale-dev \ libboost-log-dev \ - libboost-thread-dev \ libboost-program-options-dev fi diff --git a/CMakeLists.txt b/CMakeLists.txt index ccca6fcec60..d9574c8ef8d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -906,7 +906,6 @@ elseif(UNIX) libboost-locale${Boost_VERSION}, \ libboost-log${Boost_VERSION}, \ libboost-program-options${Boost_VERSION}, \ - libboost-thread${Boost_VERSION}, \ libcap2, \ libcurl4, \ libdrm2, \ @@ -926,7 +925,6 @@ elseif(UNIX) boost-locale >= ${Boost_VERSION}, \ boost-log >= ${Boost_VERSION}, \ boost-program-options >= ${Boost_VERSION}, \ - boost-thread >= ${Boost_VERSION}, \ libcap >= 2.22, \ libcurl >= 7.0, \ libdrm >= 2.4.97, \ diff --git a/docker/debian-bullseye.dockerfile b/docker/debian-bullseye.dockerfile index 7c4396184ae..0ba3fdf0ce5 100644 --- a/docker/debian-bullseye.dockerfile +++ b/docker/debian-bullseye.dockerfile @@ -38,7 +38,6 @@ apt-get install -y --no-install-recommends \ libboost-locale-dev=1.74.* \ libboost-log-dev=1.74.* \ libboost-program-options-dev=1.74.* \ - libboost-thread-dev=1.74.* \ libcap-dev \ libcurl4-openssl-dev \ libdrm-dev \ diff --git a/docker/ubuntu-20.04.dockerfile b/docker/ubuntu-20.04.dockerfile index 5689ba7134b..3cb049ac60b 100644 --- a/docker/ubuntu-20.04.dockerfile +++ b/docker/ubuntu-20.04.dockerfile @@ -40,7 +40,6 @@ apt-get install -y --no-install-recommends \ libboost-locale-dev=1.71.* \ libboost-log-dev=1.71.* \ libboost-program-options-dev=1.71.* \ - libboost-thread-dev=1.71.* \ libcap-dev \ libcurl4-openssl-dev \ libdrm-dev \ diff --git a/docker/ubuntu-22.04.dockerfile b/docker/ubuntu-22.04.dockerfile index 143fc1e4b24..f007f26725f 100644 --- a/docker/ubuntu-22.04.dockerfile +++ b/docker/ubuntu-22.04.dockerfile @@ -39,7 +39,6 @@ apt-get install -y --no-install-recommends \ libboost-locale-dev=1.74.* \ libboost-log-dev=1.74.* \ libboost-program-options-dev=1.74.* \ - libboost-thread-dev=1.74.* \ libcap-dev \ libcurl4-openssl-dev \ libdrm-dev \ diff --git a/docs/source/building/linux.rst b/docs/source/building/linux.rst index 2f629efbb7b..80dcd81d406 100644 --- a/docs/source/building/linux.rst +++ b/docs/source/building/linux.rst @@ -19,7 +19,6 @@ Install Requirements libboost-locale-dev \ libboost-log-dev \ libboost-program-options-dev \ - libboost-thread-dev \ libcap-dev \ # KMS libcurl4-openssl-dev \ libdrm-dev \ # KMS @@ -100,7 +99,6 @@ Install Requirements libboost-filesystem-dev \ libboost-locale-dev \ libboost-log-dev \ - libboost-thread-dev \ libboost-program-options-dev \ libcap-dev \ # KMS libdrm-dev \ # KMS @@ -149,7 +147,6 @@ Install Requirements libboost-filesystem-dev \ libboost-locale-dev \ libboost-log-dev \ - libboost-thread-dev \ libboost-program-options-dev \ libcap-dev \ # KMS libdrm-dev \ # KMS