freefilesync: some progress, still doesn't build

master
Thomas Klausner 2024-01-28 14:52:48 +01:00
parent cb8cdf4352
commit f0c3f31421
6 changed files with 82 additions and 0 deletions

View File

@ -1,6 +1,7 @@
# $NetBSD$
DISTNAME= FreeFileSync_13.3_Source
PKGNAME= freefilesync-13.3
CATEGORIES= sysutils
MASTER_SITES= https://freefilesync.org/download/
EXTRACT_SUFX= .zip

View File

@ -3,3 +3,7 @@ $NetBSD$
BLAKE2s (FreeFileSync_13.3_Source.zip) = 87a8f21885e35484b9c9c278da49b6a6ce939656de0c4ac9e035c365003f5173
SHA512 (FreeFileSync_13.3_Source.zip) = 0c9a30fca42722ea37a303b0e3cb27fb61cb8586ed075cd6758df27f2687b2e39669c23c76985e3e72c98586bee17be2e31f5c644371cf566c3ebfad4e4800bd
Size (FreeFileSync_13.3_Source.zip) = 2756885 bytes
SHA1 (patch-.._.._zen_guid.h) = 69038b3c58315421e8fd4c6047814d2da47591c9
SHA1 (patch-.._.._zen_serialize.h) = a688aa376f1a532d1c81fb0329cea848a1b3c4ff
SHA1 (patch-.._.._zen_socket.h) = 202f1f6eecbb78a24ca3c1a29f3f53520304a5c9
SHA1 (patch-application.cpp) = 099b2d1f632553b8646efbfbd277c9f619eecffd

View File

@ -0,0 +1,15 @@
$NetBSD$
Support non-glibc. getentropy exists on NetBSD.
--- ../../zen/guid.h.orig 2024-01-28 13:48:13.764500122 +0000
+++ ../../zen/guid.h
@@ -21,7 +21,7 @@ std::string generateGUID() //creates a 1
std::string guid(16, '\0');
#ifndef __GLIBC_PREREQ
-#error Where is Glibc?
+#define __GLIBC_PREREQ(x, y) 1
#endif
#if __GLIBC_PREREQ(2, 25) //getentropy() requires Glibc 2.25 (ldd --version) PS: CentOS 7 is on 2.17

View File

@ -0,0 +1,14 @@
$NetBSD$
Add missing header for sysconf(3).
--- ../../zen/serialize.h.orig 2024-01-28 13:49:07.264863552 +0000
+++ ../../zen/serialize.h
@@ -8,6 +8,7 @@
#define SERIALIZE_H_839405783574356
#include <functional>
+#include <unistd.h>
#include "sys_error.h"
//keep header clean from specific stream implementations! (e.g.file_io.h)! used by abstract.h!

View File

@ -0,0 +1,31 @@
$NetBSD$
Check for symbol existence before using them.
--- ../../zen/socket.h.orig 2024-01-07 18:25:42.000000000 +0000
+++ ../../zen/socket.h
@@ -44,12 +44,24 @@ std::wstring formatGaiErrorCode(int ec)
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_SOCKTYPE);
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_SYSTEM);
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_OVERFLOW);
+#ifdef EAI_INPROGRESS
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_INPROGRESS);
+#endif
+#ifdef EAI_CANCELED
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_CANCELED);
+#endif
+#ifdef EAI_NOTCANCELED
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_NOTCANCELED);
+#endif
+#ifdef EAI_ALLDONE
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_ALLDONE);
+#endif
+#ifdef EAI_INTR
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_INTR);
+#endif
+#ifdef EAI_IDN_ENCODE
ZEN_CHECK_CASE_FOR_CONSTANT(EAI_IDN_ENCODE);
+#endif
default:
return replaceCpy(_("Error code %x"), L"%x", numberTo<std::wstring>(ec));
}

View File

@ -0,0 +1,17 @@
$NetBSD$
Allow exceptions for now.
--- application.cpp.orig 2024-01-07 18:25:42.000000000 +0000
+++ application.cpp
@@ -243,10 +243,6 @@ wxLayoutDirection Application::GetLayout
int Application::OnRun()
{
-#if wxUSE_EXCEPTIONS
-#error why is wxWidgets uncaught exception handling enabled!?
-#endif
-
//exception => Windows: let it crash and create mini dump!!! Linux/macOS: std::exception::what() logged to console
[[maybe_unused]] const int rc = wxApp::OnRun();
return static_cast<int>(exitCode_);