diff --git configure.ac configure.ac
index 0e1b741..58562ef 100644
|
|
else
|
109 | 109 | mac=0 |
110 | 110 | fi |
111 | 111 | |
| 112 | # Check if we're on OpenBSD |
| 113 | if echo $host_os | grep 'openbsd' > /dev/null 2>&1; then |
| 114 | openbsd=1 |
| 115 | else |
| 116 | openbsd=0 |
| 117 | fi |
| 118 | |
112 | 119 | # If neither, we're Unix(-like) |
113 | | if test "$mac" = "0" && test "$windows" = "0"; then |
| 120 | if test "$mac" = "0" && test "$windows" = "0" && test "$openbsd" = "0"; then |
114 | 121 | unix=1 |
115 | 122 | else |
116 | 123 | unix=0 |
… |
… |
AC_SUBST(LIBFILEZILLA_LINGUAS_MO)
|
364 | 371 | |
365 | 372 | AM_CONDITIONAL(FZ_WINDOWS, test "$windows" = "1") |
366 | 373 | AM_CONDITIONAL(FZ_MAC, test "$mac" = "1") |
| 374 | AM_CONDITIONAL(FZ_OPENBSD, test "$openbsd" = "1") |
367 | 375 | AM_CONDITIONAL(FZ_UNIX, test "$unix" = "1") |
368 | 376 | AM_CONDITIONAL(HAVE_CPPUNIT, [test "$have_cppunit" = "yes"]) |
369 | 377 | AM_CONDITIONAL([LOCALES_ONLY], [test "$localesonly" = "yes"]) |
diff --git lib/libfilezilla/libfilezilla.hpp lib/libfilezilla/libfilezilla.hpp
index 13c7819..f25c84a 100644
|
|
|
24 | 24 | /// This macro is defined if libfilezilla has been compiled for OS X. |
25 | 25 | #define FZ_MAC |
26 | 26 | |
27 | | /// This macro is defined if libfilezilla has been compiled Unix(-like) platforms, but excluding OS X. |
| 27 | /// This macro is defined if libfilezilla has been compiled for OpenBSD. |
| 28 | #define FZ_OPENBSD |
| 29 | |
| 30 | /// This macro is defined if libfilezilla has been compiled Unix(-like) platforms, but excluding OS X and OpenBSD |
28 | 31 | #define FZ_UNIX |
29 | 32 | |
30 | 33 | |
diff --git lib/libfilezilla/private/defs.hpp lib/libfilezilla/private/defs.hpp
index 8286233..05524d1 100644
|
|
|
12 | 12 | #endif |
13 | 13 | |
14 | 14 | // Set some mandatory defines which are used to select platform implementations |
15 | | #if !defined(FZ_WINDOWS) && !defined(FZ_MAC) && !defined(FZ_UNIX) |
| 15 | #if !defined(FZ_WINDOWS) && !defined(FZ_MAC) && !defined(FZ_UNIX) && !defined(FZ_OPENBSD) |
16 | 16 | #if defined(_WIN32) || defined(_WIN64) |
17 | 17 | #define FZ_WINDOWS 1 |
18 | 18 | #elif defined(__APPLE__) |
19 | 19 | #define FZ_MAC 1 |
| 20 | #elif defined(__OpenBSD__) |
| 21 | #define FZ_OPENBSD 1 |
20 | 22 | #else |
21 | 23 | #define FZ_UNIX 1 |
22 | 24 | #endif |
diff --git lib/libfilezilla/string.hpp lib/libfilezilla/string.hpp
index 6a9b5e8..57b92d7 100644
|
|
namespace fz {
|
33 | 33 | typedef std::wstring native_string; |
34 | 34 | typedef std::wstring_view native_string_view; |
35 | 35 | #endif |
36 | | #if defined(FZ_UNIX) || defined(FZ_MAC) |
| 36 | #if defined(FZ_UNIX) || defined(FZ_MAC) || defined(FZ_OPENBSD) |
37 | 37 | typedef std::string native_string; |
38 | 38 | typedef std::string_view native_string_view; |
39 | 39 | #endif |
diff --git lib/libfilezilla/time.hpp lib/libfilezilla/time.hpp
index 6d49f51..61634b4 100644
|
|
public:
|
172 | 172 | bool set(SYSTEMTIME const& ft, accuracy a, zone z); |
173 | 173 | #endif |
174 | 174 | |
175 | | #if defined(FZ_UNIX) || defined(FZ_MAC) |
| 175 | #if defined(FZ_UNIX) || defined(FZ_MAC) || defined(FZ_OPENBSD) |
176 | 176 | /** Sets timestamp from struct tm. |
177 | 177 | * \note Not available on Windows. |
178 | 178 | * \warning modifies passed structure |