From baae82bd0c006675350f4a08482258d41e7ea803 Mon Sep 17 00:00:00 2001 From: Bertrand Jacquin Date: Sun, 25 Aug 2024 15:35:13 +0100 Subject: net-p2p/monero: add 0.18.3.4, drop 0.18.3.3 --- net-p2p/monero/Manifest | 4 +- ...ro-0.18.3.3-build-remove-mcpu-march-mtune.patch | 61 ------ ...mon-support-boost-filesystem-copy_options.patch | 166 --------------- ...trib-fix-compilation-error-for-boost-1.85.patch | 21 -- ...o-0.18.3.3-translations-use-host-compiler.patch | 43 ---- ...-add-support-for-miniupnpc-API-version-18.patch | 44 ---- ...nero-0.18.3.3-upnp-drop-in-tree-miniupnpc.patch | 60 ------ .../files/monero-0.18.3.3-upnp-fix-warning.patch | 31 --- ...nero-0.18.3.3-use-gentoo-dev-libs-randomx.patch | 18 -- .../monero-0.18.3.3-use-gentoo-versioning.patch | 37 ---- ...ro-0.18.3.4-build-remove-mcpu-march-mtune.patch | 61 ++++++ ...o-0.18.3.4-translations-use-host-compiler.patch | 43 ++++ ...-add-support-for-miniupnpc-API-version-18.patch | 44 ++++ ...nero-0.18.3.4-upnp-drop-in-tree-miniupnpc.patch | 60 ++++++ .../files/monero-0.18.3.4-upnp-fix-warning.patch | 31 +++ ...nero-0.18.3.4-use-gentoo-dev-libs-randomx.patch | 18 ++ .../monero-0.18.3.4-use-gentoo-versioning.patch | 37 ++++ ...-gui-0.18.3.3-cmake-use-gentoo-versioning.patch | 33 --- ...-gui-0.18.3.4-cmake-use-gentoo-versioning.patch | 33 +++ net-p2p/monero/monero-0.18.3.3.ebuild | 227 --------------------- net-p2p/monero/monero-0.18.3.4.ebuild | 224 ++++++++++++++++++++ 21 files changed, 553 insertions(+), 743 deletions(-) delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-common-support-boost-filesystem-copy_options.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-contrib-fix-compilation-error-for-boost-1.85.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-translations-use-host-compiler.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-upnp-add-support-for-miniupnpc-API-version-18.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-upnp-drop-in-tree-miniupnpc.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-upnp-fix-warning.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-use-gentoo-dev-libs-randomx.patch delete mode 100644 net-p2p/monero/files/monero-0.18.3.3-use-gentoo-versioning.patch create mode 100644 net-p2p/monero/files/monero-0.18.3.4-build-remove-mcpu-march-mtune.patch create mode 100644 net-p2p/monero/files/monero-0.18.3.4-translations-use-host-compiler.patch create mode 100644 net-p2p/monero/files/monero-0.18.3.4-upnp-add-support-for-miniupnpc-API-version-18.patch create mode 100644 net-p2p/monero/files/monero-0.18.3.4-upnp-drop-in-tree-miniupnpc.patch create mode 100644 net-p2p/monero/files/monero-0.18.3.4-upnp-fix-warning.patch create mode 100644 net-p2p/monero/files/monero-0.18.3.4-use-gentoo-dev-libs-randomx.patch create mode 100644 net-p2p/monero/files/monero-0.18.3.4-use-gentoo-versioning.patch delete mode 100644 net-p2p/monero/files/monero-gui-0.18.3.3-cmake-use-gentoo-versioning.patch create mode 100644 net-p2p/monero/files/monero-gui-0.18.3.4-cmake-use-gentoo-versioning.patch delete mode 100644 net-p2p/monero/monero-0.18.3.3.ebuild create mode 100644 net-p2p/monero/monero-0.18.3.4.ebuild (limited to 'net-p2p/monero') diff --git a/net-p2p/monero/Manifest b/net-p2p/monero/Manifest index d432b4ec..28bb0c77 100644 --- a/net-p2p/monero/Manifest +++ b/net-p2p/monero/Manifest @@ -1,5 +1,5 @@ -DIST monero-0.18.3.3.tar.gz 14028018 BLAKE2B 07c3272175fb05645a2f5f7ce6cef4d65054ba1d80994c4dc8445ec4df13aebe2b268d5b4be49db0cdd35dcdce1bbd33874111e21503839d63fae70ea30b0dff SHA512 26aaa02be4d1109dfdae08981b9fee16a10c358030ba99ae809eb241e805c50edc8ad10b1a375cd02e3160fa3de8ae6773cca55618d39ca30614f1d6662c18e5 -DIST monero-gui-0.18.3.3.tar.gz 6705524 BLAKE2B 616a153e797a0dcf44d3528fd553fc9fc6f41e13a7d81b427a5344d455a68685e8323a26019da29d25567884390036f1779b4aebc0a9d0cc9fc32612ceb8517f SHA512 c067ddf5a8abc5b90f5c1b5c20ba5f050e6591ba93f551156f31b53e963fca13dd3e5fd14271273c81e220774cd90ae720c58bf33c19c6fafbaac2cae5e9838f +DIST monero-0.18.3.4.tar.gz 14039924 BLAKE2B cb60f1db4f482bac3b3f5fa606bf1c78103b14f927d4636e5fda4aa96dcc08a9f990355ceb1cdc8c253245a0a2a1c98cf4fd7101d13d78ac6e7d1450192fc2db SHA512 f2708bf7698410c1509ae41148c298e352b3401e1df900b7152c25cb5ceb2f5bde68274fd37b1a328e932be50bdf93fe364561c520a15e3df7de2cdbd20d1be8 +DIST monero-gui-0.18.3.4.tar.gz 7017813 BLAKE2B e6db9a4d9e0040fb68aee5262a251c156f0fcfbfb2f232a6800a52ac4dcfd3ae6a52dfe5873de57ff0c216a2dc271990ae775c926d4fae5594767e14961cec8c SHA512 edf8366b15794d5a69e68acc3c78eb502b32c68b236cf967a7760e39af42beaf558138e9e881bbb655291c1562218dbcd4313b45a90ec94221bd33c31682fd39 DIST quirc-516d91a94d880ca1006fc1d57f318bdff8411f0d.tar.gz 42163 BLAKE2B 36f07063c376c51397958321e317c9f3a8718f192a16ade546add1b652a7252abeecebcb7c850b50b85c3b59b941456c4225a80aa301cdab5eb42c04e4725698 SHA512 30eb2905e03fd070ec160ad78bfba2ed973fe24fe63ab810bdb7bcec9e52da5ef042efbb50cce19fcfae13ffa531bcfb20421325e4a868856690d696f8e89eee DIST supercop-633500ad8c8759995049ccd022107d1fa8a1bbc9.tar.gz 346604 BLAKE2B 10e48076acb2e5de5acb2efee61b2fac40fdfec3bc4037a94199d56ee2446466126e1b9dade56ee69598f4bd3c64b45d86d0810f24f461f6e09fb84c87e1ef93 SHA512 06cca8d1def31aa11bf5aa42d861c4a027786f7cc494fa3ab53a2bc4bd9d1f55b2389020ba5fd1816ed277b6e4320ad8edbb3117dcf4981fc7fba655c4bbe648 DIST trezor-common-028c9b2e95d83b4164748a12cfdc181f0dd11920.tar.gz 926880 BLAKE2B e2937f9e17fdf33e047084eec73bd4b75bb5e2a1ccb3ce03c9d731ddf2b93200f895de565c16913a0bb022e3662faa38777828912dc257124ea4196b23cc501c SHA512 d0fdc74dbcde444c852bf000123bc795d86a07993b79b18cc5cfb1535348059f3b7b5a4865892321c7ddc8a98be8f04e6cfbe224e7daae3aa292f40642afa609 diff --git a/net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch b/net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch deleted file mode 100644 index 93e43f91..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch +++ /dev/null @@ -1,61 +0,0 @@ -From 50254221d25cf7d9cd90d314d75c5d0ac732f704 Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Tue, 9 Apr 2024 21:47:47 +0100 -Subject: [PATCH] build: remove mcpu/march/mtune - -cc1plus: warning: switch '-mcpu=neoverse-n1+crc+crypto+ssbs' conflicts with '-march=armv8-a+crypto' switch ---- - CMakeLists.txt | 33 +-------------------------------- - 1 file changed, 1 insertion(+), 32 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 8fb03ba1ff02..d70d2dc8e098 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -716,32 +716,6 @@ if(MSVC) - else() - include(TestCXXAcceptsFlag) - message(STATUS "Building on ${CMAKE_SYSTEM_PROCESSOR} for ${ARCH}") -- if(ARCH STREQUAL "default") -- set(ARCH_FLAG "") -- elseif(PPC64LE) -- set(ARCH_FLAG "-mcpu=power8") -- elseif(PPC64) -- set(ARCH_FLAG "-mcpu=970") -- elseif(PPC) -- set(ARCH_FLAG "-mcpu=7400") -- elseif(IOS AND ARCH STREQUAL "arm64") -- message(STATUS "IOS: Changing arch from arm64 to armv8") -- set(ARCH_FLAG "-march=armv8") -- else() -- set(ARCH_FLAG "-march=${ARCH}") -- if(ARCH STREQUAL "native") -- check_c_compiler_flag(-march=native CC_SUPPORTS_MARCH_NATIVE) -- if (NOT CC_SUPPORTS_MARCH_NATIVE) -- check_c_compiler_flag(-mtune=native CC_SUPPORTS_MTUNE_NATIVE) -- if (CC_SUPPORTS_MTUNE_NATIVE) -- set(ARCH_FLAG "-mtune=${ARCH}") -- else() -- set(ARCH_FLAG "") -- endif() -- endif() -- endif() -- endif() -- - option(NO_AES "Explicitly disable AES support" ${NO_AES}) - - if(NO_AES) -@@ -764,12 +738,7 @@ else() - message(STATUS "AES support not available on ARMv7") - elseif(ARM8) - CHECK_CXX_ACCEPTS_FLAG("-march=${ARCH}+crypto" ARCH_PLUS_CRYPTO) -- if(ARCH_PLUS_CRYPTO) -- message(STATUS "Crypto extensions enabled for ARMv8") -- set(ARCH_FLAG "-march=${ARCH}+crypto") -- else() -- message(STATUS "Crypto extensions unavailable on your ARMv8 device") -- endif() -+ message(STATUS "${ARCH_PLUS_CRYPTO}") - else() - message(STATUS "AES support disabled") - endif() diff --git a/net-p2p/monero/files/monero-0.18.3.3-common-support-boost-filesystem-copy_options.patch b/net-p2p/monero/files/monero-0.18.3.3-common-support-boost-filesystem-copy_options.patch deleted file mode 100644 index 970c873d..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-common-support-boost-filesystem-copy_options.patch +++ /dev/null @@ -1,166 +0,0 @@ -From fcc20f5496fe97c01321963359631c4b22c4f0cf Mon Sep 17 00:00:00 2001 -From: 0xFFFC0000 <0xFFFC0000@proton.me> -Date: Tue, 30 Apr 2024 23:20:10 +0000 -Subject: [PATCH] common: support boost filesystem copy_options. - Co-authored-by: selsta - ---- - src/common/boost_serialization_helper.h | 3 ++- - src/common/util.cpp | 18 ++++++++++++++++++ - src/common/util.h | 2 ++ - src/p2p/net_peerlist.cpp | 3 ++- - src/wallet/wallet2.cpp | 4 ++-- - tests/unit_tests/wallet_storage.cpp | 13 +++++++------ - 6 files changed, 33 insertions(+), 10 deletions(-) - -diff --git a/src/common/boost_serialization_helper.h b/src/common/boost_serialization_helper.h -index 4a903107f3cb..1eca39f407b9 100644 ---- a/src/common/boost_serialization_helper.h -+++ b/src/common/boost_serialization_helper.h -@@ -35,6 +35,7 @@ - #include - #include - -+#include "common/util.h" - - namespace tools - { -@@ -110,7 +111,7 @@ namespace tools - catch(...) - { - // if failed, try reading in unportable mode -- boost::filesystem::copy_file(file_path, file_path + ".unportable", boost::filesystem::copy_option::overwrite_if_exists); -+ tools::copy_file(file_path, file_path + ".unportable"); - data_file.close(); - data_file.open( file_path, std::ios_base::binary | std::ios_base::in); - if(data_file.fail()) -diff --git a/src/common/util.cpp b/src/common/util.cpp -index 4b5e2adb8a49..d5f35ea7aed2 100644 ---- a/src/common/util.cpp -+++ b/src/common/util.cpp -@@ -115,6 +115,24 @@ static int flock_exnb(int fd) - - namespace tools - { -+ -+ void copy_file(const std::string& from, const std::string& to) -+ { -+ using boost::filesystem::path; -+ #if BOOST_VERSION < 107400 -+ // Remove this preprocessor if/else when we are bumping the boost version. -+ boost::filesystem::copy_file( -+ path(from), -+ path(to), -+ boost::filesystem::copy_option::overwrite_if_exists); -+ #else -+ boost::filesystem::copy_file( -+ path(from), -+ path(to), -+ boost::filesystem::copy_options::overwrite_existing); -+ #endif -+ } -+ - std::function signal_handler::m_handler; - - private_file::private_file() noexcept : m_handle(), m_filename() {} -diff --git a/src/common/util.h b/src/common/util.h -index f489594e8901..cfc0fb6923c4 100644 ---- a/src/common/util.h -+++ b/src/common/util.h -@@ -67,6 +67,8 @@ namespace tools - } - }; - -+ void copy_file(const std::string& from, const std::string& to); -+ - //! A file restricted to process owner AND process. Deletes file on destruction. - class private_file { - std::unique_ptr m_handle; -diff --git a/src/p2p/net_peerlist.cpp b/src/p2p/net_peerlist.cpp -index 3e132c91faef..c803b0cda695 100644 ---- a/src/p2p/net_peerlist.cpp -+++ b/src/p2p/net_peerlist.cpp -@@ -42,6 +42,7 @@ - #include - - #include "net_peerlist_boost_serialization.h" -+#include "common/util.h" - - - namespace nodetool -@@ -200,7 +201,7 @@ namespace nodetool - if (!out) - { - // if failed, try reading in unportable mode -- boost::filesystem::copy_file(path, path + ".unportable", boost::filesystem::copy_option::overwrite_if_exists); -+ tools::copy_file(path, path + ".unportable"); - src_file.close(); - src_file.open( path , std::ios_base::binary | std::ios_base::in); - if(src_file.fail()) -diff --git a/src/wallet/wallet2.cpp b/src/wallet/wallet2.cpp -index f34b1098804e..f8aea71c1a77 100644 ---- a/src/wallet/wallet2.cpp -+++ b/src/wallet/wallet2.cpp -@@ -6208,7 +6208,7 @@ void wallet2::load(const std::string& wallet_, const epee::wipeable_string& pass - catch (...) - { - LOG_PRINT_L0("Failed to open portable binary, trying unportable"); -- if (use_fs) boost::filesystem::copy_file(m_wallet_file, m_wallet_file + ".unportable", boost::filesystem::copy_option::overwrite_if_exists); -+ if (use_fs) tools::copy_file(m_wallet_file, m_wallet_file + ".unportable"); - std::stringstream iss; - iss.str(""); - iss << cache_data; -@@ -6230,7 +6230,7 @@ void wallet2::load(const std::string& wallet_, const epee::wipeable_string& pass - catch (...) - { - LOG_PRINT_L0("Failed to open portable binary, trying unportable"); -- if (use_fs) boost::filesystem::copy_file(m_wallet_file, m_wallet_file + ".unportable", boost::filesystem::copy_option::overwrite_if_exists); -+ if (use_fs) tools::copy_file(m_wallet_file, m_wallet_file + ".unportable"); - std::stringstream iss; - iss.str(""); - iss << cache_file_buf; -diff --git a/tests/unit_tests/wallet_storage.cpp b/tests/unit_tests/wallet_storage.cpp -index dacaff9602ec..bf33936ed4ab 100644 ---- a/tests/unit_tests/wallet_storage.cpp -+++ b/tests/unit_tests/wallet_storage.cpp -@@ -31,6 +31,7 @@ - - #include "file_io_utils.h" - #include "wallet/wallet2.h" -+#include "common/util.h" - - using namespace boost::filesystem; - using namespace epee::file_io_utils; -@@ -47,8 +48,8 @@ TEST(wallet_storage, store_to_file2file) - ASSERT_TRUE(is_file_exist(source_wallet_file.string())); - ASSERT_TRUE(is_file_exist(source_wallet_file.string() + ".keys")); - -- copy_file(source_wallet_file, interm_wallet_file, copy_option::overwrite_if_exists); -- copy_file(source_wallet_file.string() + ".keys", interm_wallet_file.string() + ".keys", copy_option::overwrite_if_exists); -+ tools::copy_file(source_wallet_file.string(), interm_wallet_file.string()); -+ tools::copy_file(source_wallet_file.string() + ".keys", interm_wallet_file.string() + ".keys"); - - ASSERT_TRUE(is_file_exist(interm_wallet_file.string())); - ASSERT_TRUE(is_file_exist(interm_wallet_file.string() + ".keys")); -@@ -138,8 +139,8 @@ TEST(wallet_storage, change_password_same_file) - ASSERT_TRUE(is_file_exist(source_wallet_file.string())); - ASSERT_TRUE(is_file_exist(source_wallet_file.string() + ".keys")); - -- copy_file(source_wallet_file, interm_wallet_file, copy_option::overwrite_if_exists); -- copy_file(source_wallet_file.string() + ".keys", interm_wallet_file.string() + ".keys", copy_option::overwrite_if_exists); -+ tools::copy_file(source_wallet_file.string(), interm_wallet_file.string()); -+ tools::copy_file(source_wallet_file.string() + ".keys", interm_wallet_file.string() + ".keys"); - - ASSERT_TRUE(is_file_exist(interm_wallet_file.string())); - ASSERT_TRUE(is_file_exist(interm_wallet_file.string() + ".keys")); -@@ -177,8 +178,8 @@ TEST(wallet_storage, change_password_different_file) - ASSERT_TRUE(is_file_exist(source_wallet_file.string())); - ASSERT_TRUE(is_file_exist(source_wallet_file.string() + ".keys")); - -- copy_file(source_wallet_file, interm_wallet_file, copy_option::overwrite_if_exists); -- copy_file(source_wallet_file.string() + ".keys", interm_wallet_file.string() + ".keys", copy_option::overwrite_if_exists); -+ tools::copy_file(source_wallet_file.string(), interm_wallet_file.string()); -+ tools::copy_file(source_wallet_file.string() + ".keys", interm_wallet_file.string() + ".keys"); - - ASSERT_TRUE(is_file_exist(interm_wallet_file.string())); - ASSERT_TRUE(is_file_exist(interm_wallet_file.string() + ".keys")); diff --git a/net-p2p/monero/files/monero-0.18.3.3-contrib-fix-compilation-error-for-boost-1.85.patch b/net-p2p/monero/files/monero-0.18.3.3-contrib-fix-compilation-error-for-boost-1.85.patch deleted file mode 100644 index 17de8ba3..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-contrib-fix-compilation-error-for-boost-1.85.patch +++ /dev/null @@ -1,21 +0,0 @@ -From 304dcf85701e5d57b9420722c772ce4c5a51394f Mon Sep 17 00:00:00 2001 -From: 0xFFFC0000 <0xFFFC0000@proton.me> -Date: Wed, 1 May 2024 12:29:00 +0000 -Subject: [PATCH] contrib: fix compilation error for boost 1.85 - ---- - contrib/epee/include/storages/portable_storage_val_converters.h | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/contrib/epee/include/storages/portable_storage_val_converters.h b/contrib/epee/include/storages/portable_storage_val_converters.h -index 96b0c024c53c..5eb9acffd262 100644 ---- a/contrib/epee/include/storages/portable_storage_val_converters.h -+++ b/contrib/epee/include/storages/portable_storage_val_converters.h -@@ -37,6 +37,7 @@ - #include "misc_log_ex.h" - - #include -+#include - #include - #include - diff --git a/net-p2p/monero/files/monero-0.18.3.3-translations-use-host-compiler.patch b/net-p2p/monero/files/monero-0.18.3.3-translations-use-host-compiler.patch deleted file mode 100644 index e51bef2f..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-translations-use-host-compiler.patch +++ /dev/null @@ -1,43 +0,0 @@ -From c927623016a946cddf6ba4e255cc9208929fa117 Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Sat, 30 Nov 2019 02:09:14 +0000 -Subject: [PATCH] translations: use host compiler - -Do not pass target compiler and compiler flags as -generate_translations_header need to be created using host compiler and -compiler flags ---- - CMakeLists.txt | 4 +++- - translations/CMakeLists.txt | 4 ++++ - 2 files changed, 7 insertions(+), 1 deletion(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index b05c087cf898..ef980115c9e1 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -671,7 +671,9 @@ ExternalProject_Add(generate_translations_header - SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/translations" - BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/translations" - STAMP_DIR ${LRELEASE_PATH} -- CMAKE_ARGS -DLRELEASE_PATH=${LRELEASE_PATH} -+ CMAKE_ARGS -+ -DCMAKE_TOOLCHAIN_FILE=${CMAKE_CURRENT_BINARY_DIR}/translations.cmake -+ -DLRELEASE_PATH=${LRELEASE_PATH} - INSTALL_COMMAND ${CMAKE_COMMAND} -E echo "") - include_directories("${CMAKE_CURRENT_BINARY_DIR}/translations") - add_subdirectory(external) -diff --git a/translations/CMakeLists.txt b/translations/CMakeLists.txt -index 3b43360f84c8..35fcae544a42 100644 ---- a/translations/CMakeLists.txt -+++ b/translations/CMakeLists.txt -@@ -30,6 +30,10 @@ cmake_minimum_required(VERSION 3.5) - - project(translations) - -+# Ensure LDFLAGS for target are not propagated here since target are -+# meant for host -+UNSET(ENV{LDFLAGS}) -+ - # when crosscompiling import the executable targets from a file - IF(CMAKE_CROSSCOMPILING) - message(WARNING "CrossCompiling") diff --git a/net-p2p/monero/files/monero-0.18.3.3-upnp-add-support-for-miniupnpc-API-version-18.patch b/net-p2p/monero/files/monero-0.18.3.3-upnp-add-support-for-miniupnpc-API-version-18.patch deleted file mode 100644 index 9bd84b74..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-upnp-add-support-for-miniupnpc-API-version-18.patch +++ /dev/null @@ -1,44 +0,0 @@ -From 7a6f6a175183880f0045b301af5c6ada2d416734 Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Wed, 17 Jul 2024 20:05:38 +0100 -Subject: [PATCH] upnp: add support for miniupnpc API version 18 - -miniupnpc 2.2.8 updated API to version 18, with breaking change to -UPNP_GetValidIGD(). - -See: https://github.com/miniupnp/miniupnp/commit/c0a50ce33e3b99ce8a96fd43049bb5b53ffac62f -See: http://miniupnp.free.fr/files/changelog.php?file=miniupnpc-2.2.8.tar.gz ---- - src/p2p/net_node.inl | 10 ++++++++++ - 1 file changed, 10 insertions(+) - -diff --git a/src/p2p/net_node.inl b/src/p2p/net_node.inl -index 0528e0bc7988..64772f2b1144 100644 ---- a/src/p2p/net_node.inl -+++ b/src/p2p/net_node.inl -@@ -2989,7 +2989,12 @@ namespace nodetool - UPNPUrls urls; - IGDdatas igdData; - char lanAddress[64]; -+#if MINIUPNPC_API_VERSION < 18 - result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress); -+#else -+ char wanAddress[64]; -+ result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress, wanAddress, sizeof wanAddress); -+#endif - freeUPNPDevlist(deviceList); - if (result > 0) { - if (result == 1) { -@@ -3057,7 +3062,12 @@ namespace nodetool - UPNPUrls urls; - IGDdatas igdData; - char lanAddress[64]; -+#if MINIUPNPC_API_VERSION < 18 - result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress); -+#else -+ char wanAddress[64]; -+ result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress, wanAddress, sizeof wanAddress); -+#endif - freeUPNPDevlist(deviceList); - if (result > 0) { - if (result == 1) { diff --git a/net-p2p/monero/files/monero-0.18.3.3-upnp-drop-in-tree-miniupnpc.patch b/net-p2p/monero/files/monero-0.18.3.3-upnp-drop-in-tree-miniupnpc.patch deleted file mode 100644 index e85b7430..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-upnp-drop-in-tree-miniupnpc.patch +++ /dev/null @@ -1,60 +0,0 @@ -From d2a4776ab6ce808e0333f3c21e276e5cca49b7ba Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Sun, 17 Jun 2018 22:34:11 +0100 -Subject: [PATCH] upnp: drop in-tree miniupnpc - -Since 6b8539803184 ("Build: update CMake and p2p for in-tree -miniupnp"), a hard dependency is made on miniupnpc which is a git -submodule not part of the archive available upstream. ---- - external/CMakeLists.txt | 19 +++---------------- - src/p2p/net_node.inl | 6 +++--- - 2 files changed, 6 insertions(+), 19 deletions(-) - -diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt -index 5b7f69a56843..fc40455064f4 100644 ---- a/external/CMakeLists.txt -+++ b/external/CMakeLists.txt -@@ -36,22 +36,9 @@ - # others. - - find_package(Miniupnpc REQUIRED) -- --message(STATUS "Using in-tree miniupnpc") --set(UPNPC_NO_INSTALL TRUE CACHE BOOL "Disable miniupnp installation" FORCE) --add_subdirectory(miniupnp/miniupnpc) --set_property(TARGET libminiupnpc-static PROPERTY FOLDER "external") --set_property(TARGET libminiupnpc-static PROPERTY POSITION_INDEPENDENT_CODE ON) --if(MSVC) -- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -wd4244 -wd4267") --elseif(NOT MSVC) -- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-undef -Wno-unused-result -Wno-unused-value") --endif() --if(CMAKE_SYSTEM_NAME MATCHES "NetBSD") -- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -D_NETBSD_SOURCE") --endif() -- --set(UPNP_LIBRARIES "libminiupnpc-static" PARENT_SCOPE) -+set(UPNP_STATIC false PARENT_SCOPE) -+set(UPNP_INCLUDE ${MINIUPNP_INCLUDE_DIR} PARENT_SCOPE) -+set(UPNP_LIBRARIES ${MINIUPNP_LIBRARY} PARENT_SCOPE) - - find_package(Unbound) - -diff --git a/src/p2p/net_node.inl b/src/p2p/net_node.inl -index 30e3d31b9d85..0528e0bc7988 100644 ---- a/src/p2p/net_node.inl -+++ b/src/p2p/net_node.inl -@@ -60,9 +60,9 @@ - #include "cryptonote_core/cryptonote_core.h" - #include "net/parse.h" - --#include --#include --#include -+#include -+#include -+#include - - #undef MONERO_DEFAULT_LOG_CATEGORY - #define MONERO_DEFAULT_LOG_CATEGORY "net.p2p" diff --git a/net-p2p/monero/files/monero-0.18.3.3-upnp-fix-warning.patch b/net-p2p/monero/files/monero-0.18.3.3-upnp-fix-warning.patch deleted file mode 100644 index 672123ab..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-upnp-fix-warning.patch +++ /dev/null @@ -1,31 +0,0 @@ -From cdd500a9dfcdd944d18c3a9d3715775fec7c9e48 Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Wed, 17 Jul 2024 21:03:33 +0100 -Subject: [PATCH] upnp: fix warning - - CMake Warning (dev) at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:438 (message): - The package name passed to `find_package_handle_standard_args` (MiniUPnPc) - does not match the name of the calling package (Miniupnpc). This can lead - to problems in calling code that expects `find_package` result variables - (e.g., `_FOUND`) to follow a certain pattern. - Call Stack (most recent call first): - cmake/FindMiniupnpc.cmake:39 (find_package_handle_standard_args) - external/CMakeLists.txt:38 (find_package) - This warning is for project developers. Use -Wno-dev to suppress it. ---- - cmake/FindMiniupnpc.cmake | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/cmake/FindMiniupnpc.cmake b/cmake/FindMiniupnpc.cmake -index ad2004afcca2..7f4bb6828cfb 100644 ---- a/cmake/FindMiniupnpc.cmake -+++ b/cmake/FindMiniupnpc.cmake -@@ -37,7 +37,7 @@ set(MINIUPNP_STATIC_LIBRARIES ${MINIUPNP_STATIC_LIBRARY}) - - include(FindPackageHandleStandardArgs) - find_package_handle_standard_args( -- MiniUPnPc DEFAULT_MSG -+ Miniupnpc DEFAULT_MSG - MINIUPNP_INCLUDE_DIR - MINIUPNP_LIBRARY - ) diff --git a/net-p2p/monero/files/monero-0.18.3.3-use-gentoo-dev-libs-randomx.patch b/net-p2p/monero/files/monero-0.18.3.3-use-gentoo-dev-libs-randomx.patch deleted file mode 100644 index 2579590e..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-use-gentoo-dev-libs-randomx.patch +++ /dev/null @@ -1,18 +0,0 @@ -From a007bfe93c3e71a166206abd30a91dc3637983c8 Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Wed, 6 Nov 2019 01:23:52 +0000 -Subject: [PATCH] use gentoo dev-libs/randomx - ---- - external/CMakeLists.txt | 1 - - 1 file changed, 1 deletion(-) - -diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt -index fc40455064f4..5536debe8e2b 100644 ---- a/external/CMakeLists.txt -+++ b/external/CMakeLists.txt -@@ -56,4 +56,3 @@ endif() - add_subdirectory(db_drivers) - add_subdirectory(easylogging++) - add_subdirectory(qrcodegen) --add_subdirectory(randomx EXCLUDE_FROM_ALL) diff --git a/net-p2p/monero/files/monero-0.18.3.3-use-gentoo-versioning.patch b/net-p2p/monero/files/monero-0.18.3.3-use-gentoo-versioning.patch deleted file mode 100644 index f7b6661e..00000000 --- a/net-p2p/monero/files/monero-0.18.3.3-use-gentoo-versioning.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 9e2da6c420843a4928b0fb42a41bafcfb4b95ee3 Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Sat, 15 Jun 2019 00:15:54 +0100 -Subject: [PATCH] use gentoo versioning - ---- - cmake/Version.cmake | 18 +++--------------- - 1 file changed, 3 insertions(+), 15 deletions(-) - -diff --git a/cmake/Version.cmake b/cmake/Version.cmake -index e9ed9fba159b..5df4bc1ab7f3 100644 ---- a/cmake/Version.cmake -+++ b/cmake/Version.cmake -@@ -31,20 +31,8 @@ function (write_version tag) - configure_file("${CMAKE_CURRENT_LIST_DIR}/../src/version.cpp.in" "${CMAKE_BINARY_DIR}/version.cpp") - endfunction () - --find_package(Git QUIET) --if ("$Format:$" STREQUAL "") -- # We're in a tarball; use hard-coded variables. -- set(VERSION_IS_RELEASE "true") -- write_version("release") --elseif (GIT_FOUND OR Git_FOUND) -- message(STATUS "Found Git: ${GIT_EXECUTABLE}") -- include(GitVersion) -- get_version_tag_from_git("${GIT_EXECUTABLE}") -- write_version("${VERSIONTAG}") --else() -- message(STATUS "WARNING: Git was not found!") -- set(VERSION_IS_RELEASE "false") -- write_version("unknown") --endif () -+set(VERSION_IS_RELEASE "true") -+write_version("release") -+ - add_custom_target(genversion ALL - DEPENDS "${CMAKE_BINARY_DIR}/version.cpp") diff --git a/net-p2p/monero/files/monero-0.18.3.4-build-remove-mcpu-march-mtune.patch b/net-p2p/monero/files/monero-0.18.3.4-build-remove-mcpu-march-mtune.patch new file mode 100644 index 00000000..93e43f91 --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.4-build-remove-mcpu-march-mtune.patch @@ -0,0 +1,61 @@ +From 50254221d25cf7d9cd90d314d75c5d0ac732f704 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Tue, 9 Apr 2024 21:47:47 +0100 +Subject: [PATCH] build: remove mcpu/march/mtune + +cc1plus: warning: switch '-mcpu=neoverse-n1+crc+crypto+ssbs' conflicts with '-march=armv8-a+crypto' switch +--- + CMakeLists.txt | 33 +-------------------------------- + 1 file changed, 1 insertion(+), 32 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 8fb03ba1ff02..d70d2dc8e098 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -716,32 +716,6 @@ if(MSVC) + else() + include(TestCXXAcceptsFlag) + message(STATUS "Building on ${CMAKE_SYSTEM_PROCESSOR} for ${ARCH}") +- if(ARCH STREQUAL "default") +- set(ARCH_FLAG "") +- elseif(PPC64LE) +- set(ARCH_FLAG "-mcpu=power8") +- elseif(PPC64) +- set(ARCH_FLAG "-mcpu=970") +- elseif(PPC) +- set(ARCH_FLAG "-mcpu=7400") +- elseif(IOS AND ARCH STREQUAL "arm64") +- message(STATUS "IOS: Changing arch from arm64 to armv8") +- set(ARCH_FLAG "-march=armv8") +- else() +- set(ARCH_FLAG "-march=${ARCH}") +- if(ARCH STREQUAL "native") +- check_c_compiler_flag(-march=native CC_SUPPORTS_MARCH_NATIVE) +- if (NOT CC_SUPPORTS_MARCH_NATIVE) +- check_c_compiler_flag(-mtune=native CC_SUPPORTS_MTUNE_NATIVE) +- if (CC_SUPPORTS_MTUNE_NATIVE) +- set(ARCH_FLAG "-mtune=${ARCH}") +- else() +- set(ARCH_FLAG "") +- endif() +- endif() +- endif() +- endif() +- + option(NO_AES "Explicitly disable AES support" ${NO_AES}) + + if(NO_AES) +@@ -764,12 +738,7 @@ else() + message(STATUS "AES support not available on ARMv7") + elseif(ARM8) + CHECK_CXX_ACCEPTS_FLAG("-march=${ARCH}+crypto" ARCH_PLUS_CRYPTO) +- if(ARCH_PLUS_CRYPTO) +- message(STATUS "Crypto extensions enabled for ARMv8") +- set(ARCH_FLAG "-march=${ARCH}+crypto") +- else() +- message(STATUS "Crypto extensions unavailable on your ARMv8 device") +- endif() ++ message(STATUS "${ARCH_PLUS_CRYPTO}") + else() + message(STATUS "AES support disabled") + endif() diff --git a/net-p2p/monero/files/monero-0.18.3.4-translations-use-host-compiler.patch b/net-p2p/monero/files/monero-0.18.3.4-translations-use-host-compiler.patch new file mode 100644 index 00000000..e51bef2f --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.4-translations-use-host-compiler.patch @@ -0,0 +1,43 @@ +From c927623016a946cddf6ba4e255cc9208929fa117 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Sat, 30 Nov 2019 02:09:14 +0000 +Subject: [PATCH] translations: use host compiler + +Do not pass target compiler and compiler flags as +generate_translations_header need to be created using host compiler and +compiler flags +--- + CMakeLists.txt | 4 +++- + translations/CMakeLists.txt | 4 ++++ + 2 files changed, 7 insertions(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index b05c087cf898..ef980115c9e1 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -671,7 +671,9 @@ ExternalProject_Add(generate_translations_header + SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/translations" + BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/translations" + STAMP_DIR ${LRELEASE_PATH} +- CMAKE_ARGS -DLRELEASE_PATH=${LRELEASE_PATH} ++ CMAKE_ARGS ++ -DCMAKE_TOOLCHAIN_FILE=${CMAKE_CURRENT_BINARY_DIR}/translations.cmake ++ -DLRELEASE_PATH=${LRELEASE_PATH} + INSTALL_COMMAND ${CMAKE_COMMAND} -E echo "") + include_directories("${CMAKE_CURRENT_BINARY_DIR}/translations") + add_subdirectory(external) +diff --git a/translations/CMakeLists.txt b/translations/CMakeLists.txt +index 3b43360f84c8..35fcae544a42 100644 +--- a/translations/CMakeLists.txt ++++ b/translations/CMakeLists.txt +@@ -30,6 +30,10 @@ cmake_minimum_required(VERSION 3.5) + + project(translations) + ++# Ensure LDFLAGS for target are not propagated here since target are ++# meant for host ++UNSET(ENV{LDFLAGS}) ++ + # when crosscompiling import the executable targets from a file + IF(CMAKE_CROSSCOMPILING) + message(WARNING "CrossCompiling") diff --git a/net-p2p/monero/files/monero-0.18.3.4-upnp-add-support-for-miniupnpc-API-version-18.patch b/net-p2p/monero/files/monero-0.18.3.4-upnp-add-support-for-miniupnpc-API-version-18.patch new file mode 100644 index 00000000..9bd84b74 --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.4-upnp-add-support-for-miniupnpc-API-version-18.patch @@ -0,0 +1,44 @@ +From 7a6f6a175183880f0045b301af5c6ada2d416734 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Wed, 17 Jul 2024 20:05:38 +0100 +Subject: [PATCH] upnp: add support for miniupnpc API version 18 + +miniupnpc 2.2.8 updated API to version 18, with breaking change to +UPNP_GetValidIGD(). + +See: https://github.com/miniupnp/miniupnp/commit/c0a50ce33e3b99ce8a96fd43049bb5b53ffac62f +See: http://miniupnp.free.fr/files/changelog.php?file=miniupnpc-2.2.8.tar.gz +--- + src/p2p/net_node.inl | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +diff --git a/src/p2p/net_node.inl b/src/p2p/net_node.inl +index 0528e0bc7988..64772f2b1144 100644 +--- a/src/p2p/net_node.inl ++++ b/src/p2p/net_node.inl +@@ -2989,7 +2989,12 @@ namespace nodetool + UPNPUrls urls; + IGDdatas igdData; + char lanAddress[64]; ++#if MINIUPNPC_API_VERSION < 18 + result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress); ++#else ++ char wanAddress[64]; ++ result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress, wanAddress, sizeof wanAddress); ++#endif + freeUPNPDevlist(deviceList); + if (result > 0) { + if (result == 1) { +@@ -3057,7 +3062,12 @@ namespace nodetool + UPNPUrls urls; + IGDdatas igdData; + char lanAddress[64]; ++#if MINIUPNPC_API_VERSION < 18 + result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress); ++#else ++ char wanAddress[64]; ++ result = UPNP_GetValidIGD(deviceList, &urls, &igdData, lanAddress, sizeof lanAddress, wanAddress, sizeof wanAddress); ++#endif + freeUPNPDevlist(deviceList); + if (result > 0) { + if (result == 1) { diff --git a/net-p2p/monero/files/monero-0.18.3.4-upnp-drop-in-tree-miniupnpc.patch b/net-p2p/monero/files/monero-0.18.3.4-upnp-drop-in-tree-miniupnpc.patch new file mode 100644 index 00000000..e85b7430 --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.4-upnp-drop-in-tree-miniupnpc.patch @@ -0,0 +1,60 @@ +From d2a4776ab6ce808e0333f3c21e276e5cca49b7ba Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Sun, 17 Jun 2018 22:34:11 +0100 +Subject: [PATCH] upnp: drop in-tree miniupnpc + +Since 6b8539803184 ("Build: update CMake and p2p for in-tree +miniupnp"), a hard dependency is made on miniupnpc which is a git +submodule not part of the archive available upstream. +--- + external/CMakeLists.txt | 19 +++---------------- + src/p2p/net_node.inl | 6 +++--- + 2 files changed, 6 insertions(+), 19 deletions(-) + +diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt +index 5b7f69a56843..fc40455064f4 100644 +--- a/external/CMakeLists.txt ++++ b/external/CMakeLists.txt +@@ -36,22 +36,9 @@ + # others. + + find_package(Miniupnpc REQUIRED) +- +-message(STATUS "Using in-tree miniupnpc") +-set(UPNPC_NO_INSTALL TRUE CACHE BOOL "Disable miniupnp installation" FORCE) +-add_subdirectory(miniupnp/miniupnpc) +-set_property(TARGET libminiupnpc-static PROPERTY FOLDER "external") +-set_property(TARGET libminiupnpc-static PROPERTY POSITION_INDEPENDENT_CODE ON) +-if(MSVC) +- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -wd4244 -wd4267") +-elseif(NOT MSVC) +- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-undef -Wno-unused-result -Wno-unused-value") +-endif() +-if(CMAKE_SYSTEM_NAME MATCHES "NetBSD") +- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -D_NETBSD_SOURCE") +-endif() +- +-set(UPNP_LIBRARIES "libminiupnpc-static" PARENT_SCOPE) ++set(UPNP_STATIC false PARENT_SCOPE) ++set(UPNP_INCLUDE ${MINIUPNP_INCLUDE_DIR} PARENT_SCOPE) ++set(UPNP_LIBRARIES ${MINIUPNP_LIBRARY} PARENT_SCOPE) + + find_package(Unbound) + +diff --git a/src/p2p/net_node.inl b/src/p2p/net_node.inl +index 30e3d31b9d85..0528e0bc7988 100644 +--- a/src/p2p/net_node.inl ++++ b/src/p2p/net_node.inl +@@ -60,9 +60,9 @@ + #include "cryptonote_core/cryptonote_core.h" + #include "net/parse.h" + +-#include +-#include +-#include ++#include ++#include ++#include + + #undef MONERO_DEFAULT_LOG_CATEGORY + #define MONERO_DEFAULT_LOG_CATEGORY "net.p2p" diff --git a/net-p2p/monero/files/monero-0.18.3.4-upnp-fix-warning.patch b/net-p2p/monero/files/monero-0.18.3.4-upnp-fix-warning.patch new file mode 100644 index 00000000..672123ab --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.4-upnp-fix-warning.patch @@ -0,0 +1,31 @@ +From cdd500a9dfcdd944d18c3a9d3715775fec7c9e48 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Wed, 17 Jul 2024 21:03:33 +0100 +Subject: [PATCH] upnp: fix warning + + CMake Warning (dev) at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:438 (message): + The package name passed to `find_package_handle_standard_args` (MiniUPnPc) + does not match the name of the calling package (Miniupnpc). This can lead + to problems in calling code that expects `find_package` result variables + (e.g., `_FOUND`) to follow a certain pattern. + Call Stack (most recent call first): + cmake/FindMiniupnpc.cmake:39 (find_package_handle_standard_args) + external/CMakeLists.txt:38 (find_package) + This warning is for project developers. Use -Wno-dev to suppress it. +--- + cmake/FindMiniupnpc.cmake | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/cmake/FindMiniupnpc.cmake b/cmake/FindMiniupnpc.cmake +index ad2004afcca2..7f4bb6828cfb 100644 +--- a/cmake/FindMiniupnpc.cmake ++++ b/cmake/FindMiniupnpc.cmake +@@ -37,7 +37,7 @@ set(MINIUPNP_STATIC_LIBRARIES ${MINIUPNP_STATIC_LIBRARY}) + + include(FindPackageHandleStandardArgs) + find_package_handle_standard_args( +- MiniUPnPc DEFAULT_MSG ++ Miniupnpc DEFAULT_MSG + MINIUPNP_INCLUDE_DIR + MINIUPNP_LIBRARY + ) diff --git a/net-p2p/monero/files/monero-0.18.3.4-use-gentoo-dev-libs-randomx.patch b/net-p2p/monero/files/monero-0.18.3.4-use-gentoo-dev-libs-randomx.patch new file mode 100644 index 00000000..2579590e --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.4-use-gentoo-dev-libs-randomx.patch @@ -0,0 +1,18 @@ +From a007bfe93c3e71a166206abd30a91dc3637983c8 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Wed, 6 Nov 2019 01:23:52 +0000 +Subject: [PATCH] use gentoo dev-libs/randomx + +--- + external/CMakeLists.txt | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt +index fc40455064f4..5536debe8e2b 100644 +--- a/external/CMakeLists.txt ++++ b/external/CMakeLists.txt +@@ -56,4 +56,3 @@ endif() + add_subdirectory(db_drivers) + add_subdirectory(easylogging++) + add_subdirectory(qrcodegen) +-add_subdirectory(randomx EXCLUDE_FROM_ALL) diff --git a/net-p2p/monero/files/monero-0.18.3.4-use-gentoo-versioning.patch b/net-p2p/monero/files/monero-0.18.3.4-use-gentoo-versioning.patch new file mode 100644 index 00000000..f7b6661e --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.4-use-gentoo-versioning.patch @@ -0,0 +1,37 @@ +From 9e2da6c420843a4928b0fb42a41bafcfb4b95ee3 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Sat, 15 Jun 2019 00:15:54 +0100 +Subject: [PATCH] use gentoo versioning + +--- + cmake/Version.cmake | 18 +++--------------- + 1 file changed, 3 insertions(+), 15 deletions(-) + +diff --git a/cmake/Version.cmake b/cmake/Version.cmake +index e9ed9fba159b..5df4bc1ab7f3 100644 +--- a/cmake/Version.cmake ++++ b/cmake/Version.cmake +@@ -31,20 +31,8 @@ function (write_version tag) + configure_file("${CMAKE_CURRENT_LIST_DIR}/../src/version.cpp.in" "${CMAKE_BINARY_DIR}/version.cpp") + endfunction () + +-find_package(Git QUIET) +-if ("$Format:$" STREQUAL "") +- # We're in a tarball; use hard-coded variables. +- set(VERSION_IS_RELEASE "true") +- write_version("release") +-elseif (GIT_FOUND OR Git_FOUND) +- message(STATUS "Found Git: ${GIT_EXECUTABLE}") +- include(GitVersion) +- get_version_tag_from_git("${GIT_EXECUTABLE}") +- write_version("${VERSIONTAG}") +-else() +- message(STATUS "WARNING: Git was not found!") +- set(VERSION_IS_RELEASE "false") +- write_version("unknown") +-endif () ++set(VERSION_IS_RELEASE "true") ++write_version("release") ++ + add_custom_target(genversion ALL + DEPENDS "${CMAKE_BINARY_DIR}/version.cpp") diff --git a/net-p2p/monero/files/monero-gui-0.18.3.3-cmake-use-gentoo-versioning.patch b/net-p2p/monero/files/monero-gui-0.18.3.3-cmake-use-gentoo-versioning.patch deleted file mode 100644 index 1d05fdb6..00000000 --- a/net-p2p/monero/files/monero-gui-0.18.3.3-cmake-use-gentoo-versioning.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 3a0d595e530779c37431743b73566a7f6b2543e9 Mon Sep 17 00:00:00 2001 -From: Bertrand Jacquin -Date: Sun, 18 Oct 2020 15:43:33 +0100 -Subject: [PATCH] cmake: use gentoo versioning - ---- - cmake/VersionGui.cmake | 14 ++------------ - 1 file changed, 2 insertions(+), 12 deletions(-) - -diff --git a/cmake/VersionGui.cmake b/cmake/VersionGui.cmake -index e225bf2bb3c0..1f8574e8d1e8 100644 ---- a/cmake/VersionGui.cmake -+++ b/cmake/VersionGui.cmake -@@ -31,17 +31,7 @@ function (write_static_version_header tag) - configure_file("${CMAKE_CURRENT_SOURCE_DIR}/src/version.js.in" "${CMAKE_CURRENT_SOURCE_DIR}/version.js") - endfunction () - --find_package(Git QUIET) --if ("$Format:$" STREQUAL "") -- # We're in a tarball; use hard-coded variables. -- write_static_version_header("release") --elseif (GIT_FOUND OR Git_FOUND) -- message(STATUS "Found Git: ${GIT_EXECUTABLE}") -- get_version_tag_from_git("${GIT_EXECUTABLE}") -- write_static_version_header(${VERSIONTAG}) --else() -- message(STATUS "WARNING: Git was not found!") -- write_static_version_header("unknown") --endif () -+write_static_version_header("release") -+ - add_custom_target(genversiongui ALL - DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/version.js") diff --git a/net-p2p/monero/files/monero-gui-0.18.3.4-cmake-use-gentoo-versioning.patch b/net-p2p/monero/files/monero-gui-0.18.3.4-cmake-use-gentoo-versioning.patch new file mode 100644 index 00000000..1d05fdb6 --- /dev/null +++ b/net-p2p/monero/files/monero-gui-0.18.3.4-cmake-use-gentoo-versioning.patch @@ -0,0 +1,33 @@ +From 3a0d595e530779c37431743b73566a7f6b2543e9 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Sun, 18 Oct 2020 15:43:33 +0100 +Subject: [PATCH] cmake: use gentoo versioning + +--- + cmake/VersionGui.cmake | 14 ++------------ + 1 file changed, 2 insertions(+), 12 deletions(-) + +diff --git a/cmake/VersionGui.cmake b/cmake/VersionGui.cmake +index e225bf2bb3c0..1f8574e8d1e8 100644 +--- a/cmake/VersionGui.cmake ++++ b/cmake/VersionGui.cmake +@@ -31,17 +31,7 @@ function (write_static_version_header tag) + configure_file("${CMAKE_CURRENT_SOURCE_DIR}/src/version.js.in" "${CMAKE_CURRENT_SOURCE_DIR}/version.js") + endfunction () + +-find_package(Git QUIET) +-if ("$Format:$" STREQUAL "") +- # We're in a tarball; use hard-coded variables. +- write_static_version_header("release") +-elseif (GIT_FOUND OR Git_FOUND) +- message(STATUS "Found Git: ${GIT_EXECUTABLE}") +- get_version_tag_from_git("${GIT_EXECUTABLE}") +- write_static_version_header(${VERSIONTAG}) +-else() +- message(STATUS "WARNING: Git was not found!") +- write_static_version_header("unknown") +-endif () ++write_static_version_header("release") ++ + add_custom_target(genversiongui ALL + DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/version.js") diff --git a/net-p2p/monero/monero-0.18.3.3.ebuild b/net-p2p/monero/monero-0.18.3.3.ebuild deleted file mode 100644 index 0f37bf97..00000000 --- a/net-p2p/monero/monero-0.18.3.3.ebuild +++ /dev/null @@ -1,227 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 -PYTHON_COMPAT=( python3_{11..12} ) -CMAKE_MAKEFILE_GENERATOR="emake" -inherit cmake flag-o-matic toolchain-funcs python-any-r1 systemd qmake-utils - -DESCRIPTION="Secure, private, untraceable cryptocurrency" -HOMEPAGE="https://getmonero.org" - -EGIT_COMMIT_EXTERNAL_TREZOR_COMMON="028c9b2e95d83b4164748a12cfdc181f0dd11920" -EGIT_COMMIT_EXTERNAL_SUPERCOP="633500ad8c8759995049ccd022107d1fa8a1bbc9" -EGIT_COMMIT_EXTERNAL_QUIRC="516d91a94d880ca1006fc1d57f318bdff8411f0d" -SRC_URI="https://github.com/monero-project/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz - https://github.com/trezor/trezor-common/archive/${EGIT_COMMIT_EXTERNAL_TREZOR_COMMON}.tar.gz -> trezor-common-${EGIT_COMMIT_EXTERNAL_TREZOR_COMMON}.tar.gz - https://github.com/monero-project/supercop/archive/${EGIT_COMMIT_EXTERNAL_SUPERCOP}.tar.gz -> supercop-${EGIT_COMMIT_EXTERNAL_SUPERCOP}.tar.gz - qt5? ( - https://github.com/monero-project/${PN}-gui/archive/refs/tags/v${PV}.tar.gz -> ${PN}-gui-${PV}.tar.gz - https://github.com/dlbeer/quirc/archive/${EGIT_COMMIT_EXTERNAL_QUIRC}.tar.gz -> quirc-${EGIT_COMMIT_EXTERNAL_QUIRC}.tar.gz - )" - -LICENSE="NEWLIB" -SLOT="0/${PV}" -KEYWORDS="~amd64 ~arm64" -CPU_FLAGS="cpu_flags_arm_aes cpu_flags_x86_aes" -IUSE="doc qt5 nls readline smartcard ${CPU_FLAGS}" - -RDEPEND="net-dns/unbound:=[threads] - >=dev-libs/randomx-1.1.9:= - net-libs/miniupnpc:= - dev-libs/openssl:0 - >=dev-libs/boost-1.62:=[icu,nls] - >=net-libs/zeromq-4.3:=[sodium] - dev-libs/rapidjson:= - readline? ( sys-libs/readline:= ) - smartcard? ( - >=dev-libs/hidapi-0.11.0:= - virtual/libusb:= - virtual/libudev:= - dev-libs/protobuf:= - ) - qt5? ( - dev-qt/qtconcurrent:5 - dev-qt/qtcore:5 - dev-qt/qtgui:5 - dev-qt/qtdeclarative:5 - dev-qt/qtnetwork:5 - dev-qt/qtsvg:5 - dev-qt/qtxmlpatterns:5[qml] - dev-qt/qtwidgets:5 - dev-qt/qtmultimedia:5 - dev-qt/qtquickcontrols:5 - dev-qt/qtquickcontrols2:5 - dev-qt/qtgraphicaleffects:5 - dev-libs/libgcrypt:= - media-fonts/fontawesome[ttf] - ) - acct-user/monero - acct-group/monero" -DEPEND="${RDEPEND} - nls? ( dev-qt/linguist-tools )" -BDEPEND="${PYTHON_DEPS} - doc? ( - media-gfx/graphviz - app-text/doxygen - ) - qt5? ( dev-qt/linguist-tools:5 ) - smartcard? ( $(python_gen_any_dep 'dev-python/protobuf-python[${PYTHON_USEDEP}]') )" - -PATCHES_MONERO=( - "${FILESDIR}/monero-${PV}-contrib-fix-compilation-error-for-boost-1.85.patch" - "${FILESDIR}/monero-${PV}-common-support-boost-filesystem-copy_options.patch" - - "${FILESDIR}/monero-${PV}-upnp-drop-in-tree-miniupnpc.patch" - "${FILESDIR}/monero-${PV}-upnp-add-support-for-miniupnpc-API-version-18.patch" - "${FILESDIR}/monero-${PV}-upnp-fix-warning.patch" - "${FILESDIR}/monero-${PV}-use-gentoo-versioning.patch" - "${FILESDIR}/monero-${PV}-use-gentoo-dev-libs-randomx.patch" - "${FILESDIR}/monero-${PV}-translations-use-host-compiler.patch" - "${FILESDIR}/monero-${PV}-build-remove-mcpu-march-mtune.patch" -) - -PATCHES_MONERO_GUI=( - "${FILESDIR}/monero-gui-${PV}-cmake-use-gentoo-versioning.patch" -) - -CMAKE_BUILD_TYPE=Release - -src_unpack() { - default - - rm -rf "${S}/external/trezor-common" || die - ln -snf "${WORKDIR}/trezor-common-${EGIT_COMMIT_EXTERNAL_TREZOR_COMMON}" "${S}/external/trezor-common" || die - - rm -rf "${S}/external/supercop" || die - ln -snf "${WORKDIR}/supercop-${EGIT_COMMIT_EXTERNAL_SUPERCOP}" "${S}/external/supercop" || die - - if use qt5 ; then - rm -rf "${WORKDIR}/monero-gui-${PV}/monero" || die - ln -snf "${WORKDIR}/monero-${PV}" "${WORKDIR}/monero-gui-${PV}/monero" || die - - rm -rf "${WORKDIR}/monero-gui-${PV}/external/quirc" || die - ln -snf "${WORKDIR}/quirc-${EGIT_COMMIT_EXTERNAL_QUIRC}" "${WORKDIR}/monero-gui-${PV}/external/quirc" || die - fi -} - -src_prepare() { - export AR=$(tc-getAR) - export CC=$(tc-getCC) - export CXX=$(tc-getCXX) - tc-export_build_env BUILD_C{C,XX} - - # Needed for lrelease - export PATH="${PATH}:$(qt5_get_bindir)" || die - - append-cflags -DUSE_EXTRA_EC_CERT - append-cxxflags -DUSE_EXTRA_EC_CERT - - CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" - BUILD_DIR="${WORKDIR}/monero-${PV}_build" - pushd "${CMAKE_USE_DIR}" > /dev/null || die - S="${CMAKE_USE_DIR}" PATCHES="${PATCHES_MONERO[@]}" cmake_src_prepare - popd > /dev/null || die - - if use qt5 ; then - CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" - BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" - pushd "${CMAKE_USE_DIR}" > /dev/null || die - S="${CMAKE_USE_DIR}" PATCHES="${PATCHES_MONERO_GUI[@]}" cmake_src_prepare - popd > /dev/null || die - fi -} - -src_configure() { - local mycmakeargs - local cmakeargs_monero=( - -Wno-dev - -DBUILD_TAG="$(tc-arch)" - -DUSE_CCACHE=OFF - -DPYTHON_EXECUTABLE="${PYTHON}" - -DBUILD_DOCUMENTATION="$(usex doc ON OFF)" - -DBUILD_TESTS=OFF - -DUSE_READLINE="$(usex readline ON OFF)" - -DUSE_DEVICE_TREZOR="$(usex smartcard ON OFF)" - -DBUILD_GUI_DEPS="$(usex qt5 ON OFF)" - -DSTACK_TRACE=OFF - -DBUILD_SHARED_LIBS=OFF - -DMANUAL_SUBMODULES=ON - ) - - if use cpu_flags_arm_aes || use cpu_flags_x86_aes ; then - cmakeargs_monero+=( -DNO_AES=OFF ) - else - cmakeargs_monero+=( -DNO_AES=ON ) - fi - - local cmakeargs_monerogui=( - "${cmakeargs_monero[@]}" - -DWITH_DESKTOP_ENTRY=ON - -DWITH_SCANNER=ON - -DWITH_UPDATER=OFF - -DDEV_MODE=OFF - ) - - export DATABASE="lmdb" - export DEVELOPER_LOCAL_TOOLS=0 - export DEVELOPER_LIBUNBOUND_OLD=0 - - cat > "${WORKDIR}/monero-${PV}_build/translations.cmake" <<- _EOF_ || die - SET (CMAKE_C_COMPILER "${BUILD_CC}") - SET (CMAKE_C_FLAGS "${BUILD_CFLAGS}") - SET (CMAKE_CXX_COMPILER "${BUILD_CXX}") - SET (CMAKE_CXX_FLAGS "${BUILD_CXXFLAGS}") - SET (CMAKE_EXE_LINKER_FLAGS "${BUILD_LDFLAGS}") - SET (CMAKE_MODULE_LINKER_FLAGS "${BUILD_LDFLAGS}") - SET (CMAKE_SHARED_LINKER_FLAGS "${BUILD_LDFLAGS}") -_EOF_ - - CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" - BUILD_DIR="${WORKDIR}/monero-${PV}_build" - mycmakeargs=( ${cmakeargs_monero[@]} ) - cmake_src_configure - - if use qt5 ; then - mkdir -p "${WORKDIR}/monero-gui-${PV}_build/monero" || die - cp "${WORKDIR}/monero-${PV}_build/translations.cmake" "${WORKDIR}/monero-gui-${PV}_build/monero/translations.cmake" || die - - CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" - BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" - mycmakeargs=( ${cmakeargs_monerogui[@]} ) - cmake_src_configure - fi -} - -src_compile() { - CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" - BUILD_DIR="${WORKDIR}/monero-${PV}_build" - cmake_src_compile - - if use qt5 ; then - CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" - BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" - cmake_src_compile - fi -} - -src_install() { - CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" - BUILD_DIR="${WORKDIR}/monero-${PV}_build" - cmake_src_install - - if use qt5 ; then - CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" - BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" - cmake_src_install - fi - - rm -rf "${ED}/usr/include" || die - rm -rf "${ED}/usr/lib" || die - - insinto /etc - doins utils/conf/monerod.conf - - newinitd "${FILESDIR}/monerod.initd" monerod - systemd_dounit utils/systemd/monerod.service -} diff --git a/net-p2p/monero/monero-0.18.3.4.ebuild b/net-p2p/monero/monero-0.18.3.4.ebuild new file mode 100644 index 00000000..5cf08045 --- /dev/null +++ b/net-p2p/monero/monero-0.18.3.4.ebuild @@ -0,0 +1,224 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +PYTHON_COMPAT=( python3_{11..12} ) +CMAKE_MAKEFILE_GENERATOR="emake" +inherit cmake flag-o-matic toolchain-funcs python-any-r1 systemd qmake-utils + +DESCRIPTION="Secure, private, untraceable cryptocurrency" +HOMEPAGE="https://getmonero.org" + +EGIT_COMMIT_EXTERNAL_TREZOR_COMMON="028c9b2e95d83b4164748a12cfdc181f0dd11920" +EGIT_COMMIT_EXTERNAL_SUPERCOP="633500ad8c8759995049ccd022107d1fa8a1bbc9" +EGIT_COMMIT_EXTERNAL_QUIRC="516d91a94d880ca1006fc1d57f318bdff8411f0d" +SRC_URI="https://github.com/monero-project/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz + https://github.com/trezor/trezor-common/archive/${EGIT_COMMIT_EXTERNAL_TREZOR_COMMON}.tar.gz -> trezor-common-${EGIT_COMMIT_EXTERNAL_TREZOR_COMMON}.tar.gz + https://github.com/monero-project/supercop/archive/${EGIT_COMMIT_EXTERNAL_SUPERCOP}.tar.gz -> supercop-${EGIT_COMMIT_EXTERNAL_SUPERCOP}.tar.gz + qt5? ( + https://github.com/monero-project/${PN}-gui/archive/refs/tags/v${PV}.tar.gz -> ${PN}-gui-${PV}.tar.gz + https://github.com/dlbeer/quirc/archive/${EGIT_COMMIT_EXTERNAL_QUIRC}.tar.gz -> quirc-${EGIT_COMMIT_EXTERNAL_QUIRC}.tar.gz + )" + +LICENSE="NEWLIB" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~arm64" +CPU_FLAGS="cpu_flags_arm_aes cpu_flags_x86_aes" +IUSE="doc qt5 nls readline smartcard ${CPU_FLAGS}" + +RDEPEND="net-dns/unbound:=[threads] + >=dev-libs/randomx-1.1.9:= + net-libs/miniupnpc:= + dev-libs/openssl:0 + >=dev-libs/boost-1.62:=[icu,nls] + >=net-libs/zeromq-4.3:=[sodium] + dev-libs/rapidjson:= + readline? ( sys-libs/readline:= ) + smartcard? ( + >=dev-libs/hidapi-0.11.0:= + virtual/libusb:= + virtual/libudev:= + dev-libs/protobuf:= + ) + qt5? ( + dev-qt/qtconcurrent:5 + dev-qt/qtcore:5 + dev-qt/qtgui:5 + dev-qt/qtdeclarative:5 + dev-qt/qtnetwork:5 + dev-qt/qtsvg:5 + dev-qt/qtxmlpatterns:5[qml] + dev-qt/qtwidgets:5 + dev-qt/qtmultimedia:5 + dev-qt/qtquickcontrols:5 + dev-qt/qtquickcontrols2:5 + dev-qt/qtgraphicaleffects:5 + dev-libs/libgcrypt:= + media-fonts/fontawesome[ttf] + ) + acct-user/monero + acct-group/monero" +DEPEND="${RDEPEND} + nls? ( dev-qt/linguist-tools )" +BDEPEND="${PYTHON_DEPS} + doc? ( + media-gfx/graphviz + app-text/doxygen + ) + qt5? ( dev-qt/linguist-tools:5 ) + smartcard? ( $(python_gen_any_dep 'dev-python/protobuf-python[${PYTHON_USEDEP}]') )" + +PATCHES_MONERO=( + "${FILESDIR}/monero-${PV}-upnp-drop-in-tree-miniupnpc.patch" + "${FILESDIR}/monero-${PV}-upnp-add-support-for-miniupnpc-API-version-18.patch" + "${FILESDIR}/monero-${PV}-upnp-fix-warning.patch" + "${FILESDIR}/monero-${PV}-use-gentoo-versioning.patch" + "${FILESDIR}/monero-${PV}-use-gentoo-dev-libs-randomx.patch" + "${FILESDIR}/monero-${PV}-translations-use-host-compiler.patch" + "${FILESDIR}/monero-${PV}-build-remove-mcpu-march-mtune.patch" +) + +PATCHES_MONERO_GUI=( + "${FILESDIR}/monero-gui-${PV}-cmake-use-gentoo-versioning.patch" +) + +CMAKE_BUILD_TYPE=Release + +src_unpack() { + default + + rm -rf "${S}/external/trezor-common" || die + ln -snf "${WORKDIR}/trezor-common-${EGIT_COMMIT_EXTERNAL_TREZOR_COMMON}" "${S}/external/trezor-common" || die + + rm -rf "${S}/external/supercop" || die + ln -snf "${WORKDIR}/supercop-${EGIT_COMMIT_EXTERNAL_SUPERCOP}" "${S}/external/supercop" || die + + if use qt5 ; then + rm -rf "${WORKDIR}/monero-gui-${PV}/monero" || die + ln -snf "${WORKDIR}/monero-${PV}" "${WORKDIR}/monero-gui-${PV}/monero" || die + + rm -rf "${WORKDIR}/monero-gui-${PV}/external/quirc" || die + ln -snf "${WORKDIR}/quirc-${EGIT_COMMIT_EXTERNAL_QUIRC}" "${WORKDIR}/monero-gui-${PV}/external/quirc" || die + fi +} + +src_prepare() { + export AR=$(tc-getAR) + export CC=$(tc-getCC) + export CXX=$(tc-getCXX) + tc-export_build_env BUILD_C{C,XX} + + # Needed for lrelease + export PATH="${PATH}:$(qt5_get_bindir)" || die + + append-cflags -DUSE_EXTRA_EC_CERT + append-cxxflags -DUSE_EXTRA_EC_CERT + + CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" + BUILD_DIR="${WORKDIR}/monero-${PV}_build" + pushd "${CMAKE_USE_DIR}" > /dev/null || die + S="${CMAKE_USE_DIR}" PATCHES="${PATCHES_MONERO[@]}" cmake_src_prepare + popd > /dev/null || die + + if use qt5 ; then + CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" + BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" + pushd "${CMAKE_USE_DIR}" > /dev/null || die + S="${CMAKE_USE_DIR}" PATCHES="${PATCHES_MONERO_GUI[@]}" cmake_src_prepare + popd > /dev/null || die + fi +} + +src_configure() { + local mycmakeargs + local cmakeargs_monero=( + -Wno-dev + -DBUILD_TAG="$(tc-arch)" + -DUSE_CCACHE=OFF + -DPYTHON_EXECUTABLE="${PYTHON}" + -DBUILD_DOCUMENTATION="$(usex doc ON OFF)" + -DBUILD_TESTS=OFF + -DUSE_READLINE="$(usex readline ON OFF)" + -DUSE_DEVICE_TREZOR="$(usex smartcard ON OFF)" + -DBUILD_GUI_DEPS="$(usex qt5 ON OFF)" + -DSTACK_TRACE=OFF + -DBUILD_SHARED_LIBS=OFF + -DMANUAL_SUBMODULES=ON + ) + + if use cpu_flags_arm_aes || use cpu_flags_x86_aes ; then + cmakeargs_monero+=( -DNO_AES=OFF ) + else + cmakeargs_monero+=( -DNO_AES=ON ) + fi + + local cmakeargs_monerogui=( + "${cmakeargs_monero[@]}" + -DWITH_DESKTOP_ENTRY=ON + -DWITH_SCANNER=ON + -DWITH_UPDATER=OFF + -DDEV_MODE=OFF + ) + + export DATABASE="lmdb" + export DEVELOPER_LOCAL_TOOLS=0 + export DEVELOPER_LIBUNBOUND_OLD=0 + + cat > "${WORKDIR}/monero-${PV}_build/translations.cmake" <<- _EOF_ || die + SET (CMAKE_C_COMPILER "${BUILD_CC}") + SET (CMAKE_C_FLAGS "${BUILD_CFLAGS}") + SET (CMAKE_CXX_COMPILER "${BUILD_CXX}") + SET (CMAKE_CXX_FLAGS "${BUILD_CXXFLAGS}") + SET (CMAKE_EXE_LINKER_FLAGS "${BUILD_LDFLAGS}") + SET (CMAKE_MODULE_LINKER_FLAGS "${BUILD_LDFLAGS}") + SET (CMAKE_SHARED_LINKER_FLAGS "${BUILD_LDFLAGS}") +_EOF_ + + CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" + BUILD_DIR="${WORKDIR}/monero-${PV}_build" + mycmakeargs=( ${cmakeargs_monero[@]} ) + cmake_src_configure + + if use qt5 ; then + mkdir -p "${WORKDIR}/monero-gui-${PV}_build/monero" || die + cp "${WORKDIR}/monero-${PV}_build/translations.cmake" "${WORKDIR}/monero-gui-${PV}_build/monero/translations.cmake" || die + + CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" + BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" + mycmakeargs=( ${cmakeargs_monerogui[@]} ) + cmake_src_configure + fi +} + +src_compile() { + CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" + BUILD_DIR="${WORKDIR}/monero-${PV}_build" + cmake_src_compile + + if use qt5 ; then + CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" + BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" + cmake_src_compile + fi +} + +src_install() { + CMAKE_USE_DIR="${WORKDIR}/monero-${PV}" + BUILD_DIR="${WORKDIR}/monero-${PV}_build" + cmake_src_install + + if use qt5 ; then + CMAKE_USE_DIR="${WORKDIR}/monero-gui-${PV}" + BUILD_DIR="${WORKDIR}/monero-gui-${PV}_build" + cmake_src_install + fi + + rm -rf "${ED}/usr/include" || die + rm -rf "${ED}/usr/lib" || die + + insinto /etc + doins utils/conf/monerod.conf + + newinitd "${FILESDIR}/monerod.initd" monerod + systemd_dounit utils/systemd/monerod.service +} -- cgit v1.2.3