Skip to content

Commit 339341b

Browse files
Leonid Bobrovnerzhul
Leonid Bobrov
authored andcommittedFeb 3, 2019
DragonFly BSD is somewhat identical to FreeBSD (#8159)
1 parent 70672e1 commit 339341b

File tree

6 files changed

+9
-9
lines changed

6 files changed

+9
-9
lines changed
 

Diff for: ‎cmake/Modules/FindGettextLib.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ find_package_handle_standard_args(GetText DEFAULT_MSG ${GETTEXT_REQUIRED_VARS})
6060

6161
if(GETTEXT_FOUND)
6262
# BSD variants require special linkage as they don't use glibc
63-
if(${CMAKE_SYSTEM_NAME} MATCHES "BSD")
63+
if(${CMAKE_SYSTEM_NAME} MATCHES "BSD|DragonFly")
6464
set(GETTEXT_LIBRARY "intl")
6565
endif()
6666

Diff for: ‎src/CMakeLists.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -719,11 +719,11 @@ else()
719719
endif()
720720

721721
set(CMAKE_CXX_FLAGS_RELEASE "-DNDEBUG ${RELEASE_WARNING_FLAGS} ${WARNING_FLAGS} ${OTHER_FLAGS} -Wall -pipe -funroll-loops")
722-
if(CMAKE_SYSTEM_NAME MATCHES "(Darwin|FreeBSD)")
722+
if(CMAKE_SYSTEM_NAME MATCHES "(Darwin|BSD|DragonFly)")
723723
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -Os")
724724
else()
725725
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O3 -ffast-math -fomit-frame-pointer")
726-
endif(CMAKE_SYSTEM_NAME MATCHES "(Darwin|FreeBSD)")
726+
endif(CMAKE_SYSTEM_NAME MATCHES "(Darwin|BSD|DragonFly)")
727727
set(CMAKE_CXX_FLAGS_SEMIDEBUG "-g -O1 -Wall -Wabi ${WARNING_FLAGS} ${OTHER_FLAGS}")
728728
set(CMAKE_CXX_FLAGS_DEBUG "-g -O0 -Wall -Wabi ${WARNING_FLAGS} ${OTHER_FLAGS}")
729729

Diff for: ‎src/gui/intlGUIEditBox.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ bool intlGUIEditBox::OnEvent(const SEvent& event)
270270
break;
271271
case EET_KEY_INPUT_EVENT:
272272
{
273-
#if (defined(__linux__) || defined(__FreeBSD__))
273+
#if (defined(__linux__) || defined(__FreeBSD__)) || defined(__DragonFly__)
274274
// ################################################################
275275
// ValkaTR:
276276
// This part is the difference from the original intlGUIEditBox

Diff for: ‎src/irrlicht_changes/irrUString.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
#define __BIG_ENDIAN 1
4949
#elif defined(__MACH__) && defined(__APPLE__)
5050
#include <machine/endian.h>
51-
#elif defined(__FreeBSD__)
51+
#elif defined(__FreeBSD__) || defined(__DragonFly__)
5252
#include <sys/endian.h>
5353
#else
5454
#include <endian.h>

Diff for: ‎src/threading/thread.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ DEALINGS IN THE SOFTWARE.
3131
// for setName
3232
#if defined(__linux__)
3333
#include <sys/prctl.h>
34-
#elif defined(__FreeBSD__) || defined(__OpenBSD__)
34+
#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
3535
#include <pthread_np.h>
3636
#elif defined(_MSC_VER)
3737
struct THREADNAME_INFO {
@@ -213,7 +213,7 @@ void Thread::setName(const std::string &name)
213213
// distributions are still runing 2.11 and previous versions.
214214
prctl(PR_SET_NAME, name.c_str());
215215

216-
#elif defined(__FreeBSD__) || defined(__OpenBSD__)
216+
#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
217217

218218
pthread_set_name_np(pthread_self(), name.c_str());
219219

@@ -273,7 +273,7 @@ bool Thread::bindToProcessor(unsigned int proc_number)
273273

274274
return SetThreadAffinityMask(pthread_gethandle(getThreadHandle()), 1 << proc_number);
275275

276-
#elif __FreeBSD_version >= 702106 || defined(__linux__)
276+
#elif __FreeBSD_version >= 702106 || defined(__linux__) || defined(__DragonFly__)
277277

278278
cpu_set_t cpuset;
279279

Diff for: ‎src/util/serialize.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
3232
#define __BIG_ENDIAN 1
3333
#elif defined(__MACH__) && defined(__APPLE__)
3434
#include <machine/endian.h>
35-
#elif defined(__FreeBSD__)
35+
#elif defined(__FreeBSD__) || defined(__DragonFly__)
3636
#include <sys/endian.h>
3737
#else
3838
#include <endian.h>

0 commit comments

Comments
 (0)
Please sign in to comment.