Dominique Leuenberger 2022-06-12 15:41:36 +00:00 committed by Git OBS Bridge
commit 96fbd9bc80
7 changed files with 177 additions and 23 deletions

View File

@ -0,0 +1,107 @@
diff -Naur FreeFileSync_11.19_Source_orig/FreeFileSync/Source/base/db_file.cpp FreeFileSync_11.19_Source/FreeFileSync/Source/base/db_file.cpp
--- FreeFileSync_11.19_Source_orig/FreeFileSync/Source/base/db_file.cpp 2022-04-16 20:03:18.000000000 +0200
+++ FreeFileSync_11.19_Source/FreeFileSync/Source/base/db_file.cpp 2022-06-11 16:25:56.614662155 +0200
@@ -665,7 +665,7 @@
}
//delete removed items (= "in-sync") from database
- std::erase_if(dbFolders, [&](InSyncFolder::FolderList::value_type& v)
+ eraseIf(dbFolders, [&](InSyncFolder::FolderList::value_type& v)
{
if (auto it = toPreserve.find(v.first); it != toPreserve.end())
{
@@ -692,7 +692,7 @@
std::erase_if(dbFolder.files, [&](const InSyncFolder::FileList ::value_type& v) { return filter_.passFileFilter(parentRelPathPf + v.first); });
std::erase_if(dbFolder.symlinks, [&](const InSyncFolder::SymlinkList::value_type& v) { return filter_.passFileFilter(parentRelPathPf + v.first); });
- std::erase_if(dbFolder.folders, [&](InSyncFolder::FolderList::value_type& v)
+ eraseIf(dbFolder.folders, [&](InSyncFolder::FolderList::value_type& v)
{
const Zstring& itemRelPath = parentRelPathPf + v.first;
diff -Naur FreeFileSync_11.19_Source_orig/wx+/async_task.h FreeFileSync_11.19_Source/wx+/async_task.h
--- FreeFileSync_11.19_Source_orig/wx+/async_task.h 2022-04-16 20:03:18.000000000 +0200
+++ FreeFileSync_11.19_Source/wx+/async_task.h 2022-06-11 16:32:01.862210363 +0200
@@ -84,7 +84,7 @@
std::vector<std::unique_ptr<Task>> readyTasks; //Reentrancy; access to AsyncTasks::add is not protected! => evaluate outside eraseIf
- std::erase_if(tasks_, [&](std::unique_ptr<Task>& task)
+ eraseIf(tasks_, [&](std::unique_ptr<Task>& task)
{
if (task->resultReady())
{
diff -Naur FreeFileSync_11.19_Source_orig/zen/stl_tools.h FreeFileSync_11.19_Source/zen/stl_tools.h
--- FreeFileSync_11.19_Source_orig/zen/stl_tools.h 2022-04-16 20:03:18.000000000 +0200
+++ FreeFileSync_11.19_Source/zen/stl_tools.h 2022-06-11 16:50:12.672858637 +0200
@@ -10,6 +10,8 @@
#include <set>
#include <map>
#include <vector>
+#include <unordered_set>
+#include <unordered_map>
#include <memory>
#include <cassert>
#include <algorithm>
@@ -20,6 +22,16 @@
//enhancements for <algorithm>
namespace zen
{
+//unfortunately std::erase_if is useless garbage on GCC 12 (requires non-modifying predicate)
+template <class T, class Alloc, class Predicate>
+void eraseIf(std::vector<T, Alloc>& v, Predicate p);
+
+template <class T, class LessType, class Alloc, class Predicate>
+void eraseIf(std::set<T, LessType, Alloc>& s, Predicate p);
+
+template <class KeyType, class ValueType, class LessType, class Alloc, class Predicate>
+void eraseIf(std::map<KeyType, ValueType, LessType, Alloc>& m, Predicate p);
+
//append STL containers
template <class T, class Alloc, class C>
void append(std::vector<T, Alloc>& v, const C& c);
@@ -104,6 +116,44 @@
//######################## implementation ########################
+
+template <class T, class Alloc, class Predicate> inline
+void eraseIf(std::vector<T, Alloc>& v, Predicate p)
+{
+ v.erase(std::remove_if(v.begin(), v.end(), p), v.end());
+}
+
+
+namespace impl
+{
+template <class S, class Predicate> inline
+void setOrMapEraseIf(S& s, Predicate p)
+{
+ for (auto it = s.begin(); it != s.end();)
+ if (p(*it))
+ s.erase(it++);
+ else
+ ++it;
+}
+}
+
+
+template <class T, class LessType, class Alloc, class Predicate> inline
+void eraseIf(std::set<T, LessType, Alloc>& s, Predicate p) { impl::setOrMapEraseIf(s, p); } //don't make this any more generic! e.g. must not compile for std::vector!!!
+
+
+template <class KeyType, class ValueType, class LessType, class Alloc, class Predicate> inline
+void eraseIf(std::map<KeyType, ValueType, LessType, Alloc>& m, Predicate p) { impl::setOrMapEraseIf(m, p); }
+
+
+template <class T, class Hash, class Keyeq, class Alloc, class Predicate> inline
+void eraseIf(std::unordered_set<T, Hash, Keyeq, Alloc>& s, Predicate p) { impl::setOrMapEraseIf(s, p); }
+
+
+template <class KeyType, class ValueType, class Hash, class Keyeq, class Alloc, class Predicate> inline
+void eraseIf(std::unordered_map<KeyType, ValueType, Hash, Keyeq, Alloc>& m, Predicate p) { impl::setOrMapEraseIf(m, p); }
+
+
template <class T, class Alloc, class C> inline
void append(std::vector<T, Alloc>& v, const C& c) { v.insert(v.end(), c.begin(), c.end()); }

View File

@ -0,0 +1,14 @@
diff -Naur FreeFileSync_11.19_Source_orig/wx+/dc.h FreeFileSync_11.19_Source/wx+/dc.h
--- FreeFileSync_11.19_Source_orig/wx+/dc.h 2022-04-16 20:03:18.000000000 +0200
+++ FreeFileSync_11.19_Source/wx+/dc.h 2022-06-11 16:08:23.827967980 +0200
@@ -91,8 +91,8 @@
inline
int getDPI()
{
-#ifndef wxHAS_DPI_INDEPENDENT_PIXELS
-#error why is wxHAS_DPI_INDEPENDENT_PIXELS not defined?
+#ifndef wxHAVE_DPI_INDEPENDENT_PIXELS
+#error why is wxHAVE_DPI_INDEPENDENT_PIXELS not defined?
#endif
//GTK2 doesn't properly support high DPI: https://freefilesync.org/forum/viewtopic.php?t=6114
//=> requires general fix at wxWidgets-level

View File

@ -1,9 +1,9 @@
diff -Naur FreeFileSync_11.4_Source_orig/FreeFileSync/Source/Makefile FreeFileSync_11.4_Source/FreeFileSync/Source/Makefile
--- FreeFileSync_11.4_Source_orig/FreeFileSync/Source/Makefile 2020-12-05 14:38:38.000000000 +0100
+++ FreeFileSync_11.4_Source/FreeFileSync/Source/Makefile 2020-12-11 09:24:39.418116342 +0100
diff -Naur FreeFileSync_11.21_Source_orig/FreeFileSync/Source/Makefile FreeFileSync_11.21_Source/FreeFileSync/Source/Makefile
--- FreeFileSync_11.21_Source_orig/FreeFileSync/Source/Makefile 2022-05-17 10:02:16.000000000 +0200
+++ FreeFileSync_11.21_Source/FreeFileSync/Source/Makefile 2022-06-10 17:50:49.936634424 +0200
@@ -2,9 +2,9 @@
cxxFlags = -std=c++2a -pipe -DWXINTL_NO_GETTEXT_MACRO -I../.. -I../../zenXml -include "zen/i18n.h" -include "zen/warn_static.h" \
cxxFlags = -std=c++2b -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 \
- -O3 -DNDEBUG `wx-config --cxxflags --debug=no` -pthread
+ -O3 -DNDEBUG `wx-config --cxxflags --debug=no` -pthread -fpie
@ -26,12 +26,12 @@ diff -Naur FreeFileSync_11.4_Source_orig/FreeFileSync/Source/Makefile FreeFileSy
#support for SELinux (optional)
SELINUX_EXISTING=$(shell pkg-config --exists libselinux && echo YES)
diff -Naur FreeFileSync_11.4_Source_orig/FreeFileSync/Source/RealTimeSync/Makefile FreeFileSync_11.4_Source/FreeFileSync/Source/RealTimeSync/Makefile
--- FreeFileSync_11.4_Source_orig/FreeFileSync/Source/RealTimeSync/Makefile 2020-12-05 14:38:38.000000000 +0100
+++ FreeFileSync_11.4_Source/FreeFileSync/Source/RealTimeSync/Makefile 2020-12-11 09:19:38.287288344 +0100
diff -Naur FreeFileSync_11.21_Source_orig/FreeFileSync/Source/RealTimeSync/Makefile FreeFileSync_11.21_Source/FreeFileSync/Source/RealTimeSync/Makefile
--- FreeFileSync_11.21_Source_orig/FreeFileSync/Source/RealTimeSync/Makefile 2022-05-17 10:02:16.000000000 +0200
+++ FreeFileSync_11.21_Source/FreeFileSync/Source/RealTimeSync/Makefile 2022-06-10 17:51:33.900512197 +0200
@@ -2,14 +2,15 @@
cxxFlags = -std=c++2a -pipe -DWXINTL_NO_GETTEXT_MACRO -I../../.. -I../../../zenXml -include "zen/i18n.h" -include "zen/warn_static.h" \
cxxFlags = -std=c++2b -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 \
- -O3 -DNDEBUG `wx-config --cxxflags --debug=no` -pthread
+ -O3 -DNDEBUG `wx-config --cxxflags --debug=no` -pthread -fpie
@ -49,9 +49,9 @@ diff -Naur FreeFileSync_11.4_Source_orig/FreeFileSync/Source/RealTimeSync/Makefi
cppFiles=
cppFiles+=application.cpp
diff -Naur FreeFileSync_11.4_Source_orig/libssh2/libssh2_wrap.h FreeFileSync_11.4_Source/libssh2/libssh2_wrap.h
--- FreeFileSync_11.4_Source_orig/libssh2/libssh2_wrap.h 2020-12-05 14:38:38.000000000 +0100
+++ FreeFileSync_11.4_Source/libssh2/libssh2_wrap.h 2020-12-11 09:17:38.447774909 +0100
diff -Naur FreeFileSync_11.21_Source_orig/libssh2/libssh2_wrap.h FreeFileSync_11.21_Source/libssh2/libssh2_wrap.h
--- FreeFileSync_11.21_Source_orig/libssh2/libssh2_wrap.h 2022-05-17 10:02:16.000000000 +0200
+++ FreeFileSync_11.21_Source/libssh2/libssh2_wrap.h 2022-06-10 17:53:11.880246224 +0200
@@ -20,6 +20,22 @@
#error libssh2_sftp.h header guard changed
#endif
@ -75,9 +75,9 @@ diff -Naur FreeFileSync_11.4_Source_orig/libssh2/libssh2_wrap.h FreeFileSync_11.
//fix libssh2 64-bit warning mess: https://github.com/libssh2/libssh2/pull/96
#undef libssh2_userauth_password
inline int libssh2_userauth_password(LIBSSH2_SESSION* session, const std::string& username, const std::string& password)
diff -Naur FreeFileSync_11.4_Source_orig/zen/ring_buffer.h FreeFileSync_11.4_Source/zen/ring_buffer.h
--- FreeFileSync_11.4_Source_orig/zen/ring_buffer.h 2020-12-05 14:38:38.000000000 +0100
+++ FreeFileSync_11.4_Source/zen/ring_buffer.h 2020-12-11 09:16:43.519997924 +0100
diff -Naur FreeFileSync_11.21_Source_orig/zen/ring_buffer.h FreeFileSync_11.21_Source/zen/ring_buffer.h
--- FreeFileSync_11.21_Source_orig/zen/ring_buffer.h 2022-05-17 10:02:18.000000000 +0200
+++ FreeFileSync_11.21_Source/zen/ring_buffer.h 2022-06-10 17:54:25.040065784 +0200
@@ -8,6 +8,7 @@
#define RING_BUFFER_H_01238467085684139453534

View File

@ -1,4 +1,36 @@
-------------------------------------------------------------------
Sat Jun 11 15:06:02 UTC 2022 - Jannik Seiler <seil0@mosad.xyz>
- Update to 11.19
- Improved performance for huge exclusion filter lists: linear to constant(!) time
- Support sync with Google Drive starred folders
- - Access "My Computers" (as created by Google Backup and Sync) if starred
- Western Digital Mycloud NAS: fixed ERROR_ALREADY_EXISTS when changing case
- Added per-file progress for "copy to" function
- Have filter wildcard ? not match path separator
- Work around WBEM_E_INVALID_NAMESPACE error during installation
- Fixed login user incorrectly displayed as root (macOS)
- Save Google Drive buffer before system shutdown
- Changes from 11.18
- Add comparison time to sync log when using GUI
- Added user-configurable timeout for Google Drive
- Consider port when comparing (S)FTP paths for equality
- Fixed SFTP key file login error on OpenSSH_8.8p1
- Add error details for NSFileReadUnknownError (macOS)
- Disable new config button when already at default
- Use user language instead of region locale during installation
- Changes from 11.17
- Show per-file progress in percent when copying large files
- Log app initialization errors
- Fixed uncaught exception after installation
- Defer testing for third-party buggy DLLs until after crashing
- Consider ReFS 128-bit file ID failure states (Windows)
- Refer to volume by name: support names including brackets
- Support local installation with non-standard home (Linux)
- Add FreeFileSync-build-with-gcc12.patch to fix build with gcc12
- Add FreeFileSync-build-with-wx3.1.5.patch to fix build with wxWidgets 3.1.5
- Update FreeFileSync-build.patch for version 11.19
-------------------------------------------------------------------
Sun Jan 16 17:42:44 UTC 2022 - Jannik Seiler <seil0@mosad.xyz>
- Update to 11.16

View File

@ -17,7 +17,7 @@
Name: FreeFileSync
Version: 11.16
Version: 11.19
Release: 0
Summary: Backup software to synchronize files and folders
License: GPL-3.0-or-later
@ -33,6 +33,10 @@ Patch1: FreeFileSync-resources.patch
Patch2: FreeFileSync-icon-loader.patch
Patch3: FreeFileSync-disable-in-app-updates.patch
Patch4: FreeFileSync-openssl-1.1.1.patch
# can be droped once wx 3.1.6 is available
Patch5: FreeFileSync-build-with-wx3.1.5.patch
# can be droped with 11.21
Patch6: FreeFileSync-build-with-gcc12.patch
BuildRequires: boost-devel >= 1.54
BuildRequires: gcc-c++
BuildRequires: libcurl-devel
@ -70,11 +74,8 @@ export CXXFLAGS="%{optflags} -fabi-version=2 -fabi-compat-version=2"
export CC="gcc"
export CXX="g++"
/usr/bin/make -O -j1 V=1 VERBOSE=1 -C FreeFileSync/Source exeName=FreeFileSync
/usr/bin/make -O -j1 V=1 VERBOSE=1 -C FreeFileSync/Source/RealTimeSync exeName=RealTimeSync
#%%make_build -C %%{name}/Source exeName=FreeFileSync
#%%make_build -C %%{name}/Source/RealTimeSync exeName=RealTimeSync
%make_build -C %{name}/Source exeName=FreeFileSync
%make_build -C %{name}/Source/RealTimeSync exeName=RealTimeSync
%install
# FreeFileSync

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a02515634f7c5241f32da3484822f834ca0be4510e1e46f2be8f012520bf861f
size 2654765

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ae4b61fb8108977da9c215403c3f8e958900376874e28f3c1b25f877b98015f2
size 2664327