From a9109060d6a01faaf9dd6cfd25b1404767c8a8d7 Mon Sep 17 00:00:00 2001 From: defnax Date: Tue, 22 Jul 2025 20:55:58 +0200 Subject: [PATCH 01/13] Fix qt6 with cmake --- retroshare-gui/CMakeLists.txt | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/retroshare-gui/CMakeLists.txt b/retroshare-gui/CMakeLists.txt index 314edf1ab..ba732914f 100644 --- a/retroshare-gui/CMakeLists.txt +++ b/retroshare-gui/CMakeLists.txt @@ -77,14 +77,24 @@ set(CMAKE_AUTOMOC ON) set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) -find_package( Qt5 COMPONENTS Core REQUIRED) -find_package( Qt5 COMPONENTS Widgets REQUIRED) -find_package( Qt5 COMPONENTS Xml REQUIRED) -find_package( Qt5 COMPONENTS Network REQUIRED) -find_package( Qt5 COMPONENTS Multimedia REQUIRED) -find_package( Qt5 COMPONENTS PrintSupport REQUIRED) +find_package( Qt6 COMPONENTS Core REQUIRED) +find_package( Qt6 COMPONENTS Widgets REQUIRED) +find_package( Qt6 COMPONENTS Xml REQUIRED) +find_package( Qt6 COMPONENTS Network REQUIRED) +find_package( Qt6 COMPONENTS Multimedia REQUIRED) +find_package( Qt6 COMPONENTS PrintSupport REQUIRED) -list( APPEND RS_LINK_LIBRARIES Qt5::Multimedia Qt5::Widgets Qt5::Xml Qt5::Network Qt5::PrintSupport) +list( APPEND RS_LINK_LIBRARIES Qt6::Multimedia Qt6::Widgets Qt6::Xml Qt6::Network Qt6::PrintSupport) +if (NOT Qt6_FOUND) + find_package( Qt5 COMPONENTS Core REQUIRED) + find_package( Qt5 COMPONENTS Widgets REQUIRED) + find_package( Qt5 COMPONENTS Xml REQUIRED) + find_package( Qt5 COMPONENTS Network REQUIRED) + find_package( Qt5 COMPONENTS Multimedia REQUIRED) + find_package( Qt5 COMPONENTS PrintSupport REQUIRED) + + list( APPEND RS_LINK_LIBRARIES Qt5::Multimedia Qt5::Widgets Qt5::Xml Qt5::Network Qt5::PrintSupport) +endif() ################################################################################ From 58681981810bfa2789c47e81fca9d125fc332a22 Mon Sep 17 00:00:00 2001 From: defnax Date: Tue, 22 Jul 2025 21:29:32 +0200 Subject: [PATCH 02/13] Update CMakeLists.txt --- retroshare-gui/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/retroshare-gui/CMakeLists.txt b/retroshare-gui/CMakeLists.txt index ba732914f..9b5240e17 100644 --- a/retroshare-gui/CMakeLists.txt +++ b/retroshare-gui/CMakeLists.txt @@ -114,7 +114,10 @@ endif(RS_DEVELOPMENT_BUILD) include(src/CMakeLists.txt) -qt5_wrap_ui(RS_UI_HEADERS ${RS_GUI_FORMS}) +qt_wrap_ui(RS_UI_HEADERS ${RS_GUI_FORMS}) +if (NOT Qt6_FOUND) + qt5_wrap_ui(RS_UI_HEADERS ${RS_GUI_FORMS}) +endif() add_executable(${PROJECT_NAME} ${RS_GUI_SOURCES} ${RS_UI_HEADERS} ${RS_GUI_QTRESOURCES}) install(TARGETS ${PROJECT_NAME} DESTINATION ${RS_BIN_INSTALL_DIR}) From 28653ad92c8b8f7401e0ee0c8bac3648721029e3 Mon Sep 17 00:00:00 2001 From: redDwarf03 Date: Fri, 25 Apr 2025 21:07:38 +0200 Subject: [PATCH 03/13] Updates for macos sequoia to run retroshare-service origin redDwarf03 --- retroshare-service/CMakeLists.txt | 45 +++++++++++++++++++ retroshare-service/src/retroshare-service.pro | 7 +++ 2 files changed, 52 insertions(+) diff --git a/retroshare-service/CMakeLists.txt b/retroshare-service/CMakeLists.txt index 97562c91e..261158923 100644 --- a/retroshare-service/CMakeLists.txt +++ b/retroshare-service/CMakeLists.txt @@ -61,6 +61,21 @@ cmake_dependent_option( set(FETCHCONTENT_QUIET OFF) include(FetchContent) +# Find required dependencies +# find_package for Botan and json-c failed to populate variables, remove them. +# find_package(Botan 3 REQUIRED) +# message(STATUS "Botan_FOUND=${Botan_FOUND}") +# message(STATUS "BOTAN_LIBRARIES=${BOTAN_LIBRARIES}") +# message(STATUS "BOTAN_INCLUDE_DIRS=${BOTAN_INCLUDE_DIRS}") +# +# find_package(json-c REQUIRED) +# message(STATUS "json-c_FOUND=${json-c_FOUND}") +# message(STATUS "JSON-C_LIBRARIES=${JSON-C_LIBRARIES}") +# message(STATUS "JSON-C_INCLUDE_DIRS=${JSON-C_INCLUDE_DIRS}") + +find_package(ZLIB REQUIRED) +find_package(BZip2 REQUIRED) + find_package(Git REQUIRED) ################################################################################ @@ -113,6 +128,36 @@ target_link_libraries(${PROJECT_NAME} PRIVATE retroshare) ################################################################################ +# Add RNP build directories to linker search path +target_link_directories(${PROJECT_NAME} PRIVATE + ${PROJECT_SOURCE_DIR}/../../supportlibs/librnp/Build/src/lib + ${PROJECT_SOURCE_DIR}/../../supportlibs/librnp/Build/src/libsexpp +) + +# Link libraries by name, including RNP libs and dependencies first +target_link_libraries(${PROJECT_NAME} PRIVATE + rnp # Link by name + sexpp + botan-3 + json-c + bz2 + z + retroshare +) + +################################################################################ + +# Add include directories from found packages +# target_include_directories(${PROJECT_NAME} PRIVATE +# ${Botan_INCLUDE_DIRS} +# ${JSONC_INCLUDE_DIRS} +# ) + +# Link only libretroshare, it should handle its own dependencies now +target_link_libraries(${PROJECT_NAME} PRIVATE retroshare) + +################################################################################ + if(RS_SERVICE_DESKTOP) if(UNIX AND NOT APPLE) install( diff --git a/retroshare-service/src/retroshare-service.pro b/retroshare-service/src/retroshare-service.pro index 275f868cc..95589673e 100644 --- a/retroshare-service/src/retroshare-service.pro +++ b/retroshare-service/src/retroshare-service.pro @@ -67,6 +67,7 @@ unix { macx { # ENABLE THIS OPTION FOR Univeral Binary BUILD. #CONFIG += ppc x86 + QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.13 #QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.4 LIBS += -lz #LIBS += -lssl -lcrypto -lz -lgpgme -lgpg-error -lassuan @@ -81,6 +82,12 @@ macx { LIBS += -framework Security LIBS += -framework Carbon + # Explicitly add RNP libs here for the service target + LIBRNP_BUILD_PATH = $$clean_path($${OUT_PWD}/../../supportlibs/librnp/Build) + LIBS += -L$$clean_path($${LIBRNP_BUILD_PATH}/src/lib) -lrnp + LIBS += -L$$clean_path($${LIBRNP_BUILD_PATH}/src/libsexpp) -lsexpp + LIBS += -lbz2 -lz -ljson-c -lbotan-3 + for(lib, LIB_DIR):LIBS += -L"$$lib" for(bin, BIN_DIR):LIBS += -L"$$bin" From 4fd67b276d974e041efe9af8b93cb1ece43cc4b5 Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Sun, 3 Aug 2025 22:57:23 +0200 Subject: [PATCH 04/13] retroshare.pri add macos targets --- retroshare.pri | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/retroshare.pri b/retroshare.pri index 98226c686..9db02d144 100644 --- a/retroshare.pri +++ b/retroshare.pri @@ -132,7 +132,7 @@ use_dht_stunner_ext_ip:CONFIG -= no_use_dht_stunner_ext_ip # To select your MacOsX version append the following assignation to qmake # command line "CONFIG+=rs_macos10.11" where 10.11 depends your version -macx:CONFIG *= rs_macos11.1 +macx:CONFIG *= rs_macos10.11 rs_macos10.8:CONFIG -= rs_macos10.11 rs_macos10.9:CONFIG -= rs_macos10.11 rs_macos10.10:CONFIG -= rs_macos10.11 @@ -141,6 +141,9 @@ rs_macos10.13:CONFIG -= rs_macos10.11 rs_macos10.14:CONFIG -= rs_macos10.11 rs_macos10.15:CONFIG -= rs_macos10.11 rs_macos11.1:CONFIG -= rs_macos10.11 +rs_macos14.5:CONFIG -= rs_macos10.11 +rs_macos15.2:CONFIG -= rs_macos10.11 +rs_macos15.5:CONFIG -= rs_macos10.11 # To enable JSON API append the following assignation to qmake command line # "CONFIG+=rs_jsonapi" @@ -855,6 +858,27 @@ macx-* { QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness } + rs_macos14.5 { + message(***retroshare.pri: Set Target and SDK to MacOS 14.5 ) + QMAKE_MACOSX_DEPLOYMENT_TARGET=14.5 + QMAKE_MAC_SDK = macosx10.13 + QMAKE_CXXFLAGS += -Wno-nullability-completeness + QMAKE_CFLAGS += -Wno-nullability-completeness + } + rs_macos15.2 { + message(***retroshare.pri: Set Target and SDK to MacOS 15.2 ) + QMAKE_MACOSX_DEPLOYMENT_TARGET=15.2 + QMAKE_MAC_SDK = macosx10.13 + QMAKE_CXXFLAGS += -Wno-nullability-completeness + QMAKE_CFLAGS += -Wno-nullability-completeness + } + rs_macos15.5 { + message(***retroshare.pri: Set Target and SDK to MacOS 15.5 ) + QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 + QMAKE_MAC_SDK = macosx15.5 + QMAKE_CXXFLAGS += -Wno-nullability-completeness + QMAKE_CFLAGS += -Wno-nullability-completeness + } From be39fd075c6bebe1c1030bb957ef6c7c4f4f65bf Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Mon, 4 Aug 2025 13:53:09 +0200 Subject: [PATCH 05/13] set QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 --- retroshare.pri | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/retroshare.pri b/retroshare.pri index 9db02d144..1a4c5955e 100644 --- a/retroshare.pri +++ b/retroshare.pri @@ -860,14 +860,14 @@ macx-* { } rs_macos14.5 { message(***retroshare.pri: Set Target and SDK to MacOS 14.5 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=14.5 + QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 QMAKE_MAC_SDK = macosx10.13 QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness } rs_macos15.2 { message(***retroshare.pri: Set Target and SDK to MacOS 15.2 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=15.2 + QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 QMAKE_MAC_SDK = macosx10.13 QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness From 7d0aa67b970b97c8324fecf85ebd349fe7a1cc6b Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Mon, 4 Aug 2025 13:58:49 +0200 Subject: [PATCH 06/13] fix QMAKE_MAC_SDK --- retroshare.pri | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/retroshare.pri b/retroshare.pri index 1a4c5955e..fb4759049 100644 --- a/retroshare.pri +++ b/retroshare.pri @@ -861,14 +861,14 @@ macx-* { rs_macos14.5 { message(***retroshare.pri: Set Target and SDK to MacOS 14.5 ) QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 - QMAKE_MAC_SDK = macosx10.13 + QMAKE_MAC_SDK = macosx14.5 QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness } rs_macos15.2 { message(***retroshare.pri: Set Target and SDK to MacOS 15.2 ) QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 - QMAKE_MAC_SDK = macosx10.13 + QMAKE_MAC_SDK = macosx15.2 QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness } From 14b758cb02abbcb2172bcf3aae50bf73173c95ab Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Mon, 4 Aug 2025 18:20:38 +0200 Subject: [PATCH 07/13] botan-2 instead of botan-3 --- retroshare-service/src/retroshare-service.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/retroshare-service/src/retroshare-service.pro b/retroshare-service/src/retroshare-service.pro index 95589673e..c514ef607 100644 --- a/retroshare-service/src/retroshare-service.pro +++ b/retroshare-service/src/retroshare-service.pro @@ -86,7 +86,7 @@ macx { LIBRNP_BUILD_PATH = $$clean_path($${OUT_PWD}/../../supportlibs/librnp/Build) LIBS += -L$$clean_path($${LIBRNP_BUILD_PATH}/src/lib) -lrnp LIBS += -L$$clean_path($${LIBRNP_BUILD_PATH}/src/libsexpp) -lsexpp - LIBS += -lbz2 -lz -ljson-c -lbotan-3 + LIBS += -lbz2 -lz -ljson-c -lbotan-2 for(lib, LIB_DIR):LIBS += -L"$$lib" for(bin, BIN_DIR):LIBS += -L"$$bin" From 71a61666b7966a4613ed36e782432920dc9e9b4b Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Sun, 10 Aug 2025 12:40:36 +0200 Subject: [PATCH 08/13] remove unsupported macos < 10.13 --- retroshare.pri | 45 +++++---------------------------------------- 1 file changed, 5 insertions(+), 40 deletions(-) diff --git a/retroshare.pri b/retroshare.pri index fb4759049..9e13e8044 100644 --- a/retroshare.pri +++ b/retroshare.pri @@ -131,12 +131,8 @@ CONFIG *= no_use_dht_stunner_ext_ip use_dht_stunner_ext_ip:CONFIG -= no_use_dht_stunner_ext_ip # To select your MacOsX version append the following assignation to qmake -# command line "CONFIG+=rs_macos10.11" where 10.11 depends your version -macx:CONFIG *= rs_macos10.11 -rs_macos10.8:CONFIG -= rs_macos10.11 -rs_macos10.9:CONFIG -= rs_macos10.11 -rs_macos10.10:CONFIG -= rs_macos10.11 -rs_macos10.12:CONFIG -= rs_macos10.11 +# command line "CONFIG+=rs_macos10.13" where 10.13 depends your version +macx:CONFIG *= rs_macos10.13 rs_macos10.13:CONFIG -= rs_macos10.11 rs_macos10.14:CONFIG -= rs_macos10.11 rs_macos10.15:CONFIG -= rs_macos10.11 @@ -799,37 +795,6 @@ win32-clang-g++ { } macx-* { - rs_macos10.8 { - message(***retroshare.pri: Set Target and SDK to MacOS 10.8 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=10.8 - QMAKE_MAC_SDK = macosx10.8 - } - - rs_macos10.9 { - message(***retroshare.pri: Set Target and SDK to MacOS 10.9 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=10.9 - QMAKE_MAC_SDK = macosx10.9 - } - - rs_macos10.10 { - message(***retroshare.pri: Set Target and SDK to MacOS 10.10 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=10.10 - QMAKE_MAC_SDK = macosx10.10 - } - - rs_macos10.11 { - message(***retroshare.pri: Set Target and SDK to MacOS 10.11 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=10.11 - QMAKE_MAC_SDK = macosx10.11 - } - - rs_macos10.12 { - message(***retroshare.pri: Set Target and SDK to MacOS 10.12 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=10.12 - QMAKE_MAC_SDK = macosx10.12 - QMAKE_CXXFLAGS += -Wno-nullability-completeness - QMAKE_CFLAGS += -Wno-nullability-completeness - } rs_macos10.13 { message(***retroshare.pri: Set Target and SDK to MacOS 10.13 ) QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 @@ -839,21 +804,21 @@ macx-* { } rs_macos10.14 { message(***retroshare.pri: Set Target and SDK to MacOS 10.14 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=10.14 + QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 QMAKE_MAC_SDK = macosx10.14 QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness } rs_macos10.15 { message(***retroshare.pri: Set Target and SDK to MacOS 10.15 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=10.15 + QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 QMAKE_MAC_SDK = macosx10.15 QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness } rs_macos11.1 { message(***retroshare.pri: Set Target and SDK to MacOS 11.1 ) - QMAKE_MACOSX_DEPLOYMENT_TARGET=11.1 + QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 QMAKE_MAC_SDK = macosx11.1 QMAKE_CXXFLAGS += -Wno-nullability-completeness QMAKE_CFLAGS += -Wno-nullability-completeness From 361fc39f7c5543660e769e8abc9009c1fb10361e Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Thu, 17 Jul 2025 13:07:38 +0200 Subject: [PATCH 09/13] ADD: storage and sync time 3 and 5 years --- .../gui/Posted/PostedListWidgetWithModel.cpp | 16 ++++++---- .../src/gui/gxs/GxsGroupFrameDialog.cpp | 32 +++++++++++-------- .../GxsChannelPostsWidgetWithModel.cpp | 2 ++ .../gui/gxsforums/GxsForumThreadWidget.cpp | 16 ++++++---- 4 files changed, 38 insertions(+), 28 deletions(-) diff --git a/retroshare-gui/src/gui/Posted/PostedListWidgetWithModel.cpp b/retroshare-gui/src/gui/Posted/PostedListWidgetWithModel.cpp index 2284e66ed..1cd7884c5 100644 --- a/retroshare-gui/src/gui/Posted/PostedListWidgetWithModel.cpp +++ b/retroshare-gui/src/gui/Posted/PostedListWidgetWithModel.cpp @@ -877,13 +877,15 @@ void PostedListWidgetWithModel::insertBoardDetails(const RsPostedGroup& group) QString sync_string; switch(current_sync_time) { - case 5: sync_string = tr("5 days"); break; - case 15: sync_string = tr("2 weeks"); break; - case 30: sync_string = tr("1 month"); break; - case 90: sync_string = tr("3 months"); break; - case 180: sync_string = tr("6 months"); break; - case 365: sync_string = tr("1 year"); break; - case 0: sync_string = tr("indefinitly"); break; + case 5: sync_string = tr("5 days"); break; + case 15: sync_string = tr("2 weeks"); break; + case 30: sync_string = tr("1 month"); break; + case 90: sync_string = tr("3 months"); break; + case 180: sync_string = tr("6 months"); break; + case 365: sync_string = tr("1 year"); break; + case 1095: sync_string = tr("3 years"); break; + case 1825: sync_string = tr("5 years"); break; + case 0: sync_string = tr("indefinitly"); break; default: sync_string = tr("Unknown"); } diff --git a/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp b/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp index 622725140..9098675f9 100644 --- a/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp +++ b/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp @@ -473,23 +473,27 @@ void GxsGroupFrameDialog::groupTreeCustomPopupMenu(QPoint point) QAction *actnn = NULL; QMenu *ctxMenu2 = contextMnu.addMenu(tr("Synchronise posts of last...")) ; - actnn = ctxMenu2->addAction(tr(" 5 days" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_sync_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 2 weeks" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_sync_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 month" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_sync_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 3 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_sync_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 6 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(180)) ; if(current_sync_time ==180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 year " ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(365)) ; if(current_sync_time ==365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" Indefinitly"),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 0)) ; if(current_sync_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 5 days" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_sync_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 2 weeks" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_sync_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 1 month" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_sync_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 3 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_sync_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 6 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 180)) ; if(current_sync_time ==180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 1 year " ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 365)) ; if(current_sync_time ==365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 3 years " ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(1095)) ; if(current_sync_time ==1095) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 5 years " ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(1825)) ; if(current_store_time ==1825) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" Indefinitly"),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 0)) ; if(current_store_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} ctxMenu2->setEnabled(isSubscribed); ctxMenu2 = contextMnu.addMenu(tr("Store posts for at most...")) ; - actnn = ctxMenu2->addAction(tr(" 5 days" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_store_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 2 weeks" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_store_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 month" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_store_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 3 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_store_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 6 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(180)) ; if(current_store_time ==180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 year " ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(365)) ; if(current_store_time ==365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" Indefinitly"),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 0)) ; if(current_store_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 5 days" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_store_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 2 weeks" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_store_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 1 month" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_store_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 3 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_store_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 6 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 180)) ; if(current_store_time ==180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 1 year " ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 365)) ; if(current_store_time ==365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 3 years " ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(1095)) ; if(current_store_time ==1095) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" 5 years " ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(1825)) ; if(current_store_time ==1825) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr(" Indefinitly"),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 0)) ; if(current_store_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} ctxMenu2->setEnabled(isSubscribed); if (shareKeyType()) { diff --git a/retroshare-gui/src/gui/gxschannels/GxsChannelPostsWidgetWithModel.cpp b/retroshare-gui/src/gui/gxschannels/GxsChannelPostsWidgetWithModel.cpp index a0d3ed95e..13a189fb1 100644 --- a/retroshare-gui/src/gui/gxschannels/GxsChannelPostsWidgetWithModel.cpp +++ b/retroshare-gui/src/gui/gxschannels/GxsChannelPostsWidgetWithModel.cpp @@ -1297,6 +1297,8 @@ void GxsChannelPostsWidgetWithModel::insertChannelDetails(const RsGxsChannelGrou case 90: sync_string = tr("3 months"); break; case 180: sync_string = tr("6 months"); break; case 365: sync_string = tr("1 year"); break; + case 1095: sync_string = tr("3 years") ; break; + case 1825: sync_string = tr("5 years") ; break; case 0: sync_string = tr("indefinitly"); break; default: sync_string = tr("Unknown"); diff --git a/retroshare-gui/src/gui/gxsforums/GxsForumThreadWidget.cpp b/retroshare-gui/src/gui/gxsforums/GxsForumThreadWidget.cpp index c6e6339a5..b8545b077 100644 --- a/retroshare-gui/src/gui/gxsforums/GxsForumThreadWidget.cpp +++ b/retroshare-gui/src/gui/gxsforums/GxsForumThreadWidget.cpp @@ -970,13 +970,15 @@ static QString getDurationString(uint32_t days) { switch(days) { - case 0: return QObject::tr("Indefinitely") ; - case 5: return QObject::tr("5 days") ; - case 15: return QObject::tr("2 weeks") ; - case 30: return QObject::tr("1 month") ; - case 60: return QObject::tr("2 month") ; - case 180: return QObject::tr("6 month") ; - case 365: return QObject::tr("1 year") ; + case 0: return QObject::tr("Indefinitely") ; break; + case 5: return QObject::tr("5 days") ; break; + case 15: return QObject::tr("2 weeks") ; break; + case 30: return QObject::tr("1 month") ; break; + case 60: return QObject::tr("2 month") ; break; + case 180: return QObject::tr("6 month") ; break; + case 365: return QObject::tr("1 year") ; break; + case 1095: return QObject::tr("3 years") ; break; + case 1825: return QObject::tr("5 years") ; break; default: return QString::number(days)+" " + QObject::tr("days") ; } From 9f34b871af05c2dd355d07e5d960560b81af3540 Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Thu, 17 Jul 2025 13:46:22 +0200 Subject: [PATCH 10/13] CHANGE: remove spaces in tr string; use correct function --- .../src/gui/gxs/GxsGroupFrameDialog.cpp | 36 +++++++++---------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp b/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp index 9098675f9..bfa7b63b3 100644 --- a/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp +++ b/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp @@ -473,27 +473,27 @@ void GxsGroupFrameDialog::groupTreeCustomPopupMenu(QPoint point) QAction *actnn = NULL; QMenu *ctxMenu2 = contextMnu.addMenu(tr("Synchronise posts of last...")) ; - actnn = ctxMenu2->addAction(tr(" 5 days" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_sync_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 2 weeks" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_sync_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 month" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_sync_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 3 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_sync_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 6 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 180)) ; if(current_sync_time ==180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 year " ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 365)) ; if(current_sync_time ==365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 3 years " ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(1095)) ; if(current_sync_time ==1095) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 5 years " ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(1825)) ; if(current_store_time ==1825) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" Indefinitly"),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 0)) ; if(current_store_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("5 days" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_sync_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("2 weeks" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_sync_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("1 month" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_sync_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("3 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_sync_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("6 months" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 180)) ; if(current_sync_time == 180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("1 year" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant( 365)) ; if(current_sync_time == 365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("3 years" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(1095)) ; if(current_sync_time ==1095) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("5 years" ),this,SLOT(setSyncPostsDelay())) ; actnn->setData(QVariant(1825)) ; if(current_sync_time ==1825) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("Indefinitly"),this,SLOT(setStorePostsDelay())); actnn->setData(QVariant( 0)) ; if(current_store_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} ctxMenu2->setEnabled(isSubscribed); ctxMenu2 = contextMnu.addMenu(tr("Store posts for at most...")) ; - actnn = ctxMenu2->addAction(tr(" 5 days" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_store_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 2 weeks" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_store_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 month" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_store_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 3 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_store_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 6 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 180)) ; if(current_store_time ==180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 1 year " ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 365)) ; if(current_store_time ==365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 3 years " ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(1095)) ; if(current_store_time ==1095) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" 5 years " ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(1825)) ; if(current_store_time ==1825) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} - actnn = ctxMenu2->addAction(tr(" Indefinitly"),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 0)) ; if(current_store_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("5 days" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 5)) ; if(current_store_time == 5) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("2 weeks" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 15)) ; if(current_store_time == 15) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("1 month" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 30)) ; if(current_store_time == 30) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("3 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 90)) ; if(current_store_time == 90) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("6 months" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 180)) ; if(current_store_time == 180) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("1 year" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 365)) ; if(current_store_time == 365) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("3 years" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(1095)) ; if(current_store_time ==1095) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("5 years" ),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant(1825)) ; if(current_store_time ==1825) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} + actnn = ctxMenu2->addAction(tr("Indefinitly"),this,SLOT(setStorePostsDelay())) ; actnn->setData(QVariant( 0)) ; if(current_store_time == 0) { actnn->setEnabled(false);actnn->setIcon(FilesDefs::getIconFromQtResourcePath(":/images/start.png"));} ctxMenu2->setEnabled(isSubscribed); if (shareKeyType()) { From 1cb21fd2ae01a84ac5d7d55e40adda7b6dfdd9f8 Mon Sep 17 00:00:00 2001 From: Christoph Johannes Kleine Date: Thu, 17 Jul 2025 14:45:17 +0200 Subject: [PATCH 11/13] ADD: new values to checkDeleay() --- retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp b/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp index bfa7b63b3..eb0b15010 100644 --- a/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp +++ b/retroshare-gui/src/gui/gxs/GxsGroupFrameDialog.cpp @@ -404,8 +404,11 @@ uint32_t GxsGroupFrameDialog::checkDelay(uint32_t time_in_secs) return 90 * 86400; if(time_in_secs <= 250 * 86400) return 180 * 86400; - - return 365 * 86400; + if(time_in_secs <= 400 * 86400) + return 365 * 86400; + if(time_in_secs <= 1200 * 86400) + return 1095 * 86400; + return 1825 * 86400; } void GxsGroupFrameDialog::groupTreeCustomPopupMenu(QPoint point) From 772069a4a678ce295f1d0d81da7124332fec1fd5 Mon Sep 17 00:00:00 2001 From: defnax Date: Sat, 6 Sep 2025 22:17:03 +0200 Subject: [PATCH 12/13] Added rnp define --- retroshare-service/CMakeLists.txt | 37 ++++++++++++++++++------------- 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/retroshare-service/CMakeLists.txt b/retroshare-service/CMakeLists.txt index 261158923..2c8bb2e80 100644 --- a/retroshare-service/CMakeLists.txt +++ b/retroshare-service/CMakeLists.txt @@ -27,6 +27,11 @@ option( just for development purposes, not suitable for library usage" OFF ) +option( + RS_RNPLIB + "Enable use RNP lib for PGP" + OFF ) + option( RS_JSON_API "Use restbed to expose libretroshare as JSON API via HTTP" @@ -128,22 +133,24 @@ target_link_libraries(${PROJECT_NAME} PRIVATE retroshare) ################################################################################ -# Add RNP build directories to linker search path -target_link_directories(${PROJECT_NAME} PRIVATE - ${PROJECT_SOURCE_DIR}/../../supportlibs/librnp/Build/src/lib - ${PROJECT_SOURCE_DIR}/../../supportlibs/librnp/Build/src/libsexpp -) +if(RS_RNPLIB) + # Add RNP build directories to linker search path + target_link_directories(${PROJECT_NAME} PRIVATE + ${PROJECT_SOURCE_DIR}/../../supportlibs/librnp/Build/src/lib + ${PROJECT_SOURCE_DIR}/../../supportlibs/librnp/Build/src/libsexpp + ) -# Link libraries by name, including RNP libs and dependencies first -target_link_libraries(${PROJECT_NAME} PRIVATE - rnp # Link by name - sexpp - botan-3 - json-c - bz2 - z - retroshare -) + # Link libraries by name, including RNP libs and dependencies first + target_link_libraries(${PROJECT_NAME} PRIVATE + rnp # Link by name + sexpp + botan-3 + json-c + bz2 + z + retroshare + ) +endif(RS_RNPLIB) ################################################################################ From ad481bbbc07c0edadd433a2f4dccb8e2bf52573b Mon Sep 17 00:00:00 2001 From: defnax Date: Wed, 17 Sep 2025 21:43:51 +0200 Subject: [PATCH 13/13] Fix & improve guide --- README.md | 4 ++- .../Debian+Ubuntu/Linux_InstallGuide.md | 31 +++++++++---------- .../Linux_RedHat_InstallGuide.md | 15 ++++----- 3 files changed, 26 insertions(+), 24 deletions(-) diff --git a/README.md b/README.md index ccbfb54f8..217121af3 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,9 @@ in the aim of creating packages for the supported platforms (and more) in the [build_scripts](https://github.com/RetroShare/RetroShare/tree/master/build_scripts) directory of this repository. ## Compilation on Windows -Follow this file : [WindowsMSys2_InstallGuide.md](https://github.com/RetroShare/RetroShare/blob/master/build_scripts/Windows-msys2/WindowsMSys2_InstallGuide.md) +Follow this file : [WindowsMSys2_InstallGuide](https://github.com/RetroShare/RetroShare/blob/master/build_scripts/Windows-msys2/WindowsMSys2_InstallGuide.md) + +With QtCreator : [Windows-QtCreator-InstallGuide](https://github.com/RetroShare/RetroShare/blob/master/build_scripts/Windows/Windows-QtCreator-InstallGuide.md) ## Compilation on MacOSX diff --git a/build_scripts/Debian+Ubuntu/Linux_InstallGuide.md b/build_scripts/Debian+Ubuntu/Linux_InstallGuide.md index 873c34d21..b1591d9e9 100644 --- a/build_scripts/Debian+Ubuntu/Linux_InstallGuide.md +++ b/build_scripts/Debian+Ubuntu/Linux_InstallGuide.md @@ -3,15 +3,15 @@ ### Install package dependencies: -#### Debian/Ubuntu +#### Debian / Ubuntu / Linux Mint ```bash - sudo apt-get install g++ cmake libbz2-dev libjson-c-dev libssl-dev libsqlcipher-dev \ - libupnp-dev libxss-dev rapidjson-dev libbotan-2-dev libasio-dev + sudo apt-get install git g++ cmake libbz2-dev libjson-c-dev libssl-dev libsqlcipher-dev \ + libupnp-dev doxygen libxss-dev rapidjson-dev libbotan-2-dev libasio-dev ``` To compile with Qt5: ```bash - sudo apt-get install qt5-qmake qtmultimedia5-dev qt6-5compat-dev libqt5x11extras5-dev + sudo apt-get install qt5-qmake qtmultimedia5-dev libqt5x11extras5-dev ``` To compile with Qt6: @@ -54,17 +54,15 @@ Additional dependencies for plugins: libxslt-devel speex-devel speexdsp-devel ``` -#### Linux Mint +#### Arch Linux / Manjaro / EndeavourOS ```bash - sudo apt-get install git g++ cmake qt5-qmake qtmultimedia5-dev \ - libqt5x11extras5-dev libupnp-dev libxss-dev libssl-dev libsqlcipher-dev \ - rapidjson-dev doxygen libbz2-dev libjson-c-dev libbotan-2-dev libasio-dev + sudo pacman -S base-devel libgnome-keyring cmake qt5-tools qt5-multimedia qt5-x11extras \ + rapidjson doxygen libupnp libxslt libxss sqlcipher botan2 bzip2 json-c ``` -#### Arch Linux +To compile with Qt6: ```bash - pacman -S base-devel libgnome-keyring cmake qt5-tools qt5-multimedia qt5-x11extras \ - rapidjson libupnp libxslt libxss sqlcipher botan2 bzip2 json-c + sudo pacman -S qt6-base qt6-multimedia qt6-5compat ``` ### Checkout the source code @@ -88,7 +86,7 @@ Additional dependencies for plugins: The executable produced will be: ```bash - ./retroshare-gui/src/retroshare + ./retroshare-gui/src/retroshare ``` ### Install @@ -98,7 +96,7 @@ The executable produced will be: The executable produced will be: ```bash - ~/usr/bin/RetroShare + ~/usr/bin/RetroShare ``` ### For packagers @@ -135,6 +133,8 @@ You need to place sqlcipher so that the hierarchy is: ### Build infos +Note: If you installed Qt6 you need to use `qmake6` on the command line. + For the `FeedReader` it is required to append the config option `CONFIG+=retroshare_plugins`. Make sure `plugins/plugins.pro` contains `FeedReader` in the list of plugins to compile. @@ -162,10 +162,9 @@ For `Autologin` it is required to append the config option `CONFIG+=rs_autologin * rs_deep_files_index: build with deep file indexing support * "CONFIG+=..." enable other extra compile time features, you can find the almost complete list in file *<sourcefolder>\retroshare.pri* -Example: +### Examples: ```batch -qmake CONFIG-=debug CONFIG+=release CONFIG+=rs_use_native_dialog CONFIG+=rs_gui_cmark +qmake CONFIG+=debug CONFIG+=release CONFIG+=rs_use_native_dialog CONFIG+=rs_gui_cmark qmake CONFIG+=rs_jsonapi CONFIG+=rs_webui CONFIG+=rs_autologin -qmake CONFIG+=rs_deep_channels_index CONFIG += gxsthewire CONFIG += wikipoos ``` \ No newline at end of file diff --git a/build_scripts/RedHat+Fedora/Linux_RedHat_InstallGuide.md b/build_scripts/RedHat+Fedora/Linux_RedHat_InstallGuide.md index 757b94a2f..12c365804 100644 --- a/build_scripts/RedHat+Fedora/Linux_RedHat_InstallGuide.md +++ b/build_scripts/RedHat+Fedora/Linux_RedHat_InstallGuide.md @@ -5,9 +5,9 @@ ### Install package dependencies: #### RedHat/Fedora ```bash - sudo dnf install mesa-libGL-devel gcc cmake rapidjson-devel \ - libupnp openssl sqlcipher sqlcipher-devel \ - botan2 botan2-devel json-c-devel bzip2-devel asio-devel libsecret libXScrnSaver-devel + sudo dnf install mesa-libGL-devel gcc cmake rapidjson-devel \ + libupnp openssl sqlcipher sqlcipher-devel \ + botan2 botan2-devel json-c-devel bzip2-devel asio-devel libsecret libXScrnSaver-devel ``` To compile with Qt5: @@ -46,7 +46,7 @@ Additional dependencies for Feedreader plugin: The executable produced will be: ```bash - ./retroshare-gui/src/retroshare + ./retroshare-gui/src/retroshare ``` ### Install @@ -56,7 +56,7 @@ The executable produced will be: The executable produced will be: ```bash - ~/usr/bin/RetroShare + ~/usr/bin/RetroShare ``` ### For packagers @@ -92,6 +92,8 @@ You need to place sqlcipher so that the hierarchy is: ### Build infos +Note: If you installed Qt6 you need to use `qmake6` on the command line. + For the `FeedReader` it is required to append the config option `CONFIG+=retroshare_plugins`. Make sure `plugins/plugins.pro` contains `FeedReader` in the list of plugins to compile. @@ -122,7 +124,6 @@ For `Autologin` it is required to append the config option `CONFIG+=rs_autologin Example: ```batch -qmake CONFIG-=debug CONFIG+=release CONFIG+=rs_use_native_dialog CONFIG+=rs_gui_cmark +qmake CONFIG+=debug CONFIG+=release CONFIG+=rs_use_native_dialog CONFIG+=rs_gui_cmark qmake CONFIG+=rs_jsonapi CONFIG+=rs_webui CONFIG+=rs_autologin -qmake CONFIG+=rs_deep_channels_index CONFIG += gxsthewire CONFIG += wikipoos ``` \ No newline at end of file