summaryrefslogtreecommitdiff
path: root/src/porting.h
diff options
context:
space:
mode:
authorest31 <MTest31@outlook.com>2016-12-22 23:16:00 +0100
committerest31 <MTest31@outlook.com>2016-12-22 23:16:00 +0100
commit81d56b94919dceb7b2e51d70b21a7ca22f852bd5 (patch)
tree1e9ef1be1b3295a8673d6e4f0bdeb4c2d3a6015f /src/porting.h
parent8077612dcb48221281e726a60eb97bf73fde462b (diff)
parent231ac33d34dfaaddf292c5f31b1eae43eeefba2d (diff)
downloadminetest-81d56b94919dceb7b2e51d70b21a7ca22f852bd5.tar.gz
minetest-81d56b94919dceb7b2e51d70b21a7ca22f852bd5.tar.bz2
minetest-81d56b94919dceb7b2e51d70b21a7ca22f852bd5.zip
Merge 0.4.15 changes into stable-0.4
0.4.15 release!
Diffstat (limited to 'src/porting.h')
-rw-r--r--src/porting.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/porting.h b/src/porting.h
index 4d51c5058..f5c7efcb2 100644
--- a/src/porting.h
+++ b/src/porting.h
@@ -60,7 +60,11 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include <unistd.h>
#include <stdint.h> //for uintptr_t
- #if (defined(linux) || defined(__linux) || defined(__GNU__)) && !defined(_GNU_SOURCE)
+ // Use standard Posix macro for Linux
+ #if (defined(linux) || defined(__linux)) && !defined(__linux__)
+ #define __linux__
+ #endif
+ #if (defined(__linux__) || defined(__GNU__)) && !defined(_GNU_SOURCE)
#define _GNU_SOURCE
#endif
@@ -321,7 +325,7 @@ inline const char *getPlatformName()
return
#if defined(ANDROID)
"Android"
-#elif defined(linux) || defined(__linux) || defined(__linux__)
+#elif defined(__linux__)
"Linux"
#elif defined(_WIN32) || defined(_WIN64)
"Windows"
@@ -363,6 +367,11 @@ inline const char *getPlatformName()
void setXorgClassHint(const video::SExposedVideoData &video_data,
const std::string &name);
+bool setXorgWindowIcon(IrrlichtDevice *device);
+
+bool setXorgWindowIconFromPath(IrrlichtDevice *device,
+ const std::string &icon_file);
+
// This only needs to be called at the start of execution, since all future
// threads in the process inherit this exception handler
void setWin32ExceptionHandler();