summaryrefslogtreecommitdiff
path: root/src/modules/evas
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2019-08-19 09:55:12 -0400
committerMike Blumenkrantz <zmike@samsung.com>2019-08-19 09:55:13 -0400
commit01b987df59154f87a5ed8688c272f0a04bc8c4c9 (patch)
treefb8f8fa042ab81e824db5a4c0fbda1614fb3056d /src/modules/evas
parentce3d1ec7e7c5574651dbf5c278356308528e2ea9 (diff)
make mman.h private
Summary: integrate mman.h to make Evil private to the EFL, as mman.h does not exist on Windows. After a discussion with raster, i include sys/mman.h only on non Windows platform. One issue, though, is that src/modules/emotion/generic/Emotion_Generic_Plugin.h has inlined functions using mmap() Test Plan: compilation on Windows Reviewers: cedric, raster, zmike Subscribers: #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9542
Diffstat (limited to '')
-rw-r--r--src/modules/evas/engines/software_generic/evas_native_dmabuf.c8
-rw-r--r--src/modules/evas/image_loaders/generic/evas_image_load_generic.c7
2 files changed, 11 insertions, 4 deletions
diff --git a/src/modules/evas/engines/software_generic/evas_native_dmabuf.c b/src/modules/evas/engines/software_generic/evas_native_dmabuf.c
index c71e1b2276..e7c2e162aa 100644
--- a/src/modules/evas/engines/software_generic/evas_native_dmabuf.c
+++ b/src/modules/evas/engines/software_generic/evas_native_dmabuf.c
@@ -2,15 +2,17 @@
2#include "evas_private.h" 2#include "evas_private.h"
3#include "evas_native_common.h" 3#include "evas_native_common.h"
4 4
5#if defined HAVE_DLSYM && ! defined _WIN32 5#if defined HAVE_DLSYM
6# include <dlfcn.h> /* dlopen,dlclose,etc */ 6# include <dlfcn.h> /* dlopen,dlclose,etc */
7#elif _WIN32 7#elif _WIN32
8# include <evil_private.h> /* dlopen dlclose dlsym */ 8# include <evil_private.h> /* dlopen dlclose dlsym mmap */
9#else 9#else
10# warning native_dmabuf should not get compiled if dlsym is not found on the system! 10# warning native_dmabuf should not get compiled if dlsym is not found on the system!
11#endif 11#endif
12 12
13#include <sys/mman.h> 13#ifndef _WIN32
14# include <sys/mman.h>
15#endif
14 16
15#define DRM_FORMAT_ARGB8888 0x34325241 17#define DRM_FORMAT_ARGB8888 0x34325241
16#define DRM_FORMAT_XRGB8888 0x34325258 18#define DRM_FORMAT_XRGB8888 0x34325258
diff --git a/src/modules/evas/image_loaders/generic/evas_image_load_generic.c b/src/modules/evas/image_loaders/generic/evas_image_load_generic.c
index 7d0c8e3609..94b935bc20 100644
--- a/src/modules/evas/image_loaders/generic/evas_image_load_generic.c
+++ b/src/modules/evas/image_loaders/generic/evas_image_load_generic.c
@@ -7,11 +7,16 @@
7 7
8#include <stdio.h> 8#include <stdio.h>
9#include <sys/types.h> 9#include <sys/types.h>
10#include <sys/mman.h>
11#include <sys/stat.h> 10#include <sys/stat.h>
12#include <fcntl.h> 11#include <fcntl.h>
13#include <ctype.h> 12#include <ctype.h>
14 13
14#ifdef _WIN32
15# include <evil_private.h> /* mmap */
16#else
17# include <sys/mman.h>
18#endif
19
15#ifndef O_BINARY 20#ifndef O_BINARY
16# define O_BINARY 0 21# define O_BINARY 0
17#endif 22#endif