push sheeet
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s

This commit is contained in:
Dark Steveneq
2025-10-09 14:15:47 +02:00
commit 646b892680
49168 changed files with 5897842 additions and 0 deletions

View File

@@ -0,0 +1,48 @@
diff --git a/FreeFileSync/Source/Makefile b/FreeFileSync/Source/Makefile
index 9d81055..aed0f30 100644
--- a/FreeFileSync/Source/Makefile
+++ b/FreeFileSync/Source/Makefile
@@ -1,5 +1,5 @@
CXX ?= g++
-exeName = FreeFileSync_$(shell arch)
+exeName = FreeFileSync
CXXFLAGS += -std=c++23 -pipe -DWXINTL_NO_GETTEXT_MACRO -I../.. -I../../zenXml -include "zen/i18n.h" -include "zen/warn_static.h" \
-Wall -Wfatal-errors -Wmissing-include-dirs -Wswitch-enum -Wcast-align -Wnon-virtual-dtor -Wno-unused-function -Wshadow -Wno-maybe-uninitialized \
@@ -17,9 +17,10 @@ LDFLAGS += `pkg-config --libs libcurl` -lidn2
CXXFLAGS += `pkg-config --cflags libssh2`
LDFLAGS += `pkg-config --libs libssh2`
-CXXFLAGS += `pkg-config --cflags gtk+-2.0`
+CXXFLAGS += `pkg-config --cflags gtk+-3.0`
+LDFLAGS += `pkg-config --libs gtk+-3.0`
#treat as system headers so that warnings are hidden:
-CXXFLAGS += -isystem/usr/include/gtk-2.0
+CXXFLAGS += -isystem@gtk3-dev@/include/gtk-3.0
#support for SELinux (optional)
SELINUX_EXISTING=$(shell pkg-config --exists libselinux && echo YES)
diff --git a/FreeFileSync/Source/RealTimeSync/Makefile b/FreeFileSync/Source/RealTimeSync/Makefile
index 0be46c9..f510284 100644
--- a/FreeFileSync/Source/RealTimeSync/Makefile
+++ b/FreeFileSync/Source/RealTimeSync/Makefile
@@ -1,5 +1,5 @@
CXX ?= g++
-exeName = RealTimeSync_$(shell arch)
+exeName = RealTimeSync
CXXFLAGS += -std=c++23 -pipe -DWXINTL_NO_GETTEXT_MACRO -I../../.. -I../../../zenXml -include "zen/i18n.h" -include "zen/warn_static.h" \
-Wall -Wfatal-errors -Wmissing-include-dirs -Wswitch-enum -Wcast-align -Wnon-virtual-dtor -Wno-unused-function -Wshadow -Wno-maybe-uninitialized \
@@ -8,9 +8,10 @@ CXXFLAGS += -std=c++23 -pipe -DWXINTL_NO_GETTEXT_MACRO -I../../.. -I../../../zen
LDFLAGS += -s `wx-config --libs std, aui, richtext --debug=no` -pthread
-CXXFLAGS += `pkg-config --cflags gtk+-2.0`
+CXXFLAGS += `pkg-config --cflags gtk+-3.0`
+LDFLAGS += `pkg-config --libs gtk+-3.0`
#treat as system headers so that warnings are hidden:
-CXXFLAGS += -isystem/usr/include/gtk-2.0
+CXXFLAGS += -isystem@gtk3-dev@/include/gtk-3.0
cppFiles=
cppFiles+=application.cpp

View File

@@ -0,0 +1,152 @@
{
lib,
stdenv,
fetchurl,
replaceVars,
fetchDebianPatch,
copyDesktopItems,
pkg-config,
wrapGAppsHook3,
unzip,
curl,
glib,
gtk3,
libidn2,
libssh2,
openssl,
wxwidgets_3_3,
makeDesktopItem,
}:
let
wxwidgets_3_3' = wxwidgets_3_3.overrideAttrs (
finalAttrs: previousAttrs: {
patches = [
./wxcolorhook.patch
];
}
);
in
stdenv.mkDerivation (finalAttrs: {
pname = "freefilesync";
version = "14.5";
src = fetchurl {
url = "https://freefilesync.org/download/FreeFileSync_${finalAttrs.version}_Source.zip";
# The URL only redirects to the file on the second attempt
postFetch = ''
rm -f "$out"
tryDownload "$url" "$out"
'';
hash = "sha256-+qfj1zf3V5xxtvXgCa0QDDRhEPQ3Qzii5eKiMySuUUY=";
};
sourceRoot = ".";
patches = [
# Disable loading of the missing Animal.dat
./skip-missing-Animal.dat.patch
# Fix build with GTK 3
(replaceVars ./Makefile.patch {
gtk3-dev = lib.getDev gtk3;
})
# Fix build with vanilla wxWidgets
(fetchDebianPatch {
pname = "freefilesync";
version = "13.7";
debianRevision = "1";
patch = "Disable_wxWidgets_uncaught_exception_handling.patch";
hash = "sha256-Fem7eDDKSqPFU/t12Jco8OmYC8FM9JgB4/QVy/ouvbI=";
})
];
nativeBuildInputs = [
copyDesktopItems
pkg-config
wrapGAppsHook3
unzip
];
buildInputs = [
curl
glib
gtk3
libidn2
libssh2
openssl
wxwidgets_3_3'
];
env.NIX_CFLAGS_COMPILE = toString [
# Undef g_object_ref on GLib 2.56+
"-DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_54"
"-DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_2_54"
# Define libssh2 constants
"-DMAX_SFTP_READ_SIZE=30000"
"-DMAX_SFTP_OUTGOING_SIZE=30000"
];
buildPhase = ''
runHook preBuild
chmod +w FreeFileSync/Build
cd FreeFileSync/Source
make -j$NIX_BUILD_CORES
cd RealTimeSync
make -j$NIX_BUILD_CORES
cd ../../..
runHook postBuild
'';
installPhase = ''
runHook preInstall
mkdir -p $out
cp -R FreeFileSync/Build/* $out
mv $out/{Bin,bin}
mkdir -p $out/share/pixmaps
unzip -j $out/Resources/Icons.zip '*Sync.png' -d $out/share/pixmaps
runHook postInstall
'';
desktopItems = [
(makeDesktopItem rec {
name = "FreeFileSync";
desktopName = name;
genericName = "Folder Comparison and Synchronization";
icon = name;
exec = name;
categories = [
"Utility"
"FileTools"
];
})
(makeDesktopItem rec {
name = "RealTimeSync";
desktopName = name;
genericName = "Automated Synchronization";
icon = name;
exec = name;
categories = [
"Utility"
"FileTools"
];
})
];
meta = with lib; {
description = "Open Source File Synchronization & Backup Software";
homepage = "https://freefilesync.org";
license = [
licenses.gpl3Only
licenses.openssl
licenses.curl
licenses.bsd3
];
maintainers = with maintainers; [ wegank ];
platforms = platforms.linux;
};
})

View File

@@ -0,0 +1,57 @@
diff --git a/FreeFileSync/Source/ui/gui_generated.cpp b/FreeFileSync/Source/ui/gui_generated.cpp
index a40eea3..23ec896 100644
--- a/FreeFileSync/Source/ui/gui_generated.cpp
+++ b/FreeFileSync/Source/ui/gui_generated.cpp
@@ -5573,8 +5573,6 @@ AboutDlgGenerated::AboutDlgGenerated( wxWindow* parent, wxWindowID id, const wxS
wxBoxSizer* bSizer183;
bSizer183 = new wxBoxSizer( wxHORIZONTAL );
- m_bitmapAnimalSmall = new wxStaticBitmap( m_panelDonate, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, 0 );
- bSizer183->Add( m_bitmapAnimalSmall, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
wxPanel* m_panel39;
m_panel39 = new wxPanel( m_panelDonate, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
@@ -5587,13 +5585,11 @@ AboutDlgGenerated::AboutDlgGenerated( wxWindow* parent, wxWindowID id, const wxS
m_staticTextDonate->Wrap( -1 );
m_staticTextDonate->SetForegroundColour( wxColour( 0, 0, 0 ) );
- bSizer184->Add( m_staticTextDonate, 0, wxALIGN_CENTER_HORIZONTAL|wxLEFT|wxALIGN_CENTER_VERTICAL, 10 );
m_panel39->SetSizer( bSizer184 );
m_panel39->Layout();
bSizer184->Fit( m_panel39 );
- bSizer183->Add( m_panel39, 1, wxTOP|wxBOTTOM|wxRIGHT|wxEXPAND, 5 );
m_panelDonate->SetSizer( bSizer183 );
diff --git a/FreeFileSync/Source/ui/small_dlgs.cpp b/FreeFileSync/Source/ui/small_dlgs.cpp
index 933fe81..734201f 100644
--- a/FreeFileSync/Source/ui/small_dlgs.cpp
+++ b/FreeFileSync/Source/ui/small_dlgs.cpp
@@ -137,9 +137,6 @@ AboutDlg::AboutDlg(wxWindow* parent) : AboutDlgGenerated(parent)
wxImage::AddHandler(new wxJPEGHandler /*ownership passed*/); //activate support for .jpg files
- wxImage animalImg(utfTo<wxString>(appendPath(getResourceDirPath(), Zstr("Animal.dat"))), wxBITMAP_TYPE_JPEG);
- convertToVanillaImage(animalImg);
- assert(animalImg.IsOk());
//--------------------------------------------------------------------------
//have animal + text match *final* dialog width
@@ -150,13 +147,11 @@ AboutDlg::AboutDlg(wxWindow* parent) : AboutDlgGenerated(parent)
#endif
{
- const int imageWidth = (m_panelDonate->GetSize().GetWidth() - 5 - 5 - 5 /* grey border*/) / 2;
- const int textWidth = m_panelDonate->GetSize().GetWidth() - 5 - 5 - 5 - imageWidth;
+ const int textWidth = m_panelDonate->GetSize().GetWidth();
- setImage(*m_bitmapAnimalSmall, shrinkImage(animalImg, wxsizeToScreen(imageWidth), -1 /*maxHeight*/));
m_staticTextDonate->Show();
- m_staticTextDonate->Wrap(textWidth - 10 /*left gap*/); //wrap *after* changing font size
+ m_staticTextDonate->Wrap(textWidth - 20); //wrap *after* changing font size
}
//--------------------------------------------------------------------------

View File

@@ -0,0 +1,50 @@
diff --git a/include/wx/settings.h b/include/wx/settings.h
index 3967b98b46..8d7f3d2870 100644
--- a/include/wx/settings.h
+++ b/include/wx/settings.h
@@ -13,6 +13,8 @@
#include "wx/colour.h"
#include "wx/font.h"
+#include <memory>
+
class WXDLLIMPEXP_FWD_CORE wxWindow;
// possible values for wxSystemSettings::GetFont() parameter
@@ -241,9 +243,28 @@ public:
// include the declaration of the real platform-dependent class
// ----------------------------------------------------------------------------
+struct wxColorHook
+{
+ virtual ~wxColorHook() {}
+ virtual wxColor getColor(wxSystemColour index) const = 0;
+};
+WXDLLIMPEXP_CORE inline std::unique_ptr<wxColorHook>& refGlobalColorHook()
+{
+ static std::unique_ptr<wxColorHook> globalColorHook;
+ return globalColorHook;
+}
+
class WXDLLIMPEXP_CORE wxSystemSettings : public wxSystemSettingsNative
{
public:
+ static wxColour GetColour(wxSystemColour index)
+ {
+ if (refGlobalColorHook())
+ return refGlobalColorHook()->getColor(index);
+
+ return wxSystemSettingsNative::GetColour(index);
+ }
+
#ifdef __WXUNIVERSAL__
// in wxUniversal we want to use the theme standard colours instead of the
// system ones, otherwise wxSystemSettings is just the same as
@@ -264,7 +285,6 @@ public:
// Value
static wxSystemScreenType ms_screen;
-
};
#endif