diff options
author | Alastair Poole <netstar@gmail.com> | 2020-04-21 18:19:36 +0100 |
---|---|---|
committer | Alastair Poole <netstar@gmail.com> | 2020-04-21 18:19:36 +0100 |
commit | 53044bf10749ce5456df6cf1398834fc9ab3de84 (patch) | |
tree | 2a8aa35a524764a3c737eb21e8217d6456c2acb8 | |
parent | 5115f824e90b07338d98c0efb6968a809cb827eb (diff) | |
download | efl-53044bf10749ce5456df6cf1398834fc9ab3de84.tar.gz |
ecore_wl2: EFL Wayland Build on FreeBSD
This enables a user to build EFL with wayland support enabled
on FreeBSD. It is NOT functioning, but everything starts at
some point.
This requires also linking against -lepoll-shim.
Meson arguments:
-Deeze=false -Dv4l2=false -Dfb=false -Ddrm=false -Dwl=true \
-Dsystemd=false
@fix T8659
-rw-r--r-- | src/lib/ecore_wl2/ecore_wl2_buffer.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/lib/ecore_wl2/ecore_wl2_buffer.c b/src/lib/ecore_wl2/ecore_wl2_buffer.c index faa811a447..92df71c786 100644 --- a/src/lib/ecore_wl2/ecore_wl2_buffer.c +++ b/src/lib/ecore_wl2/ecore_wl2_buffer.c @@ -17,7 +17,26 @@ #include <sys/mman.h> #include <sys/ioctl.h> +#if defined(__linux__) #include <linux/dma-buf.h> +#elif defined(__FreeBSD__) +/* begin/end dma-buf functions used for userspace mmap. */ +struct dma_buf_sync { + __u64 flags; +}; + +#define DMA_BUF_SYNC_READ (1 << 0) +#define DMA_BUF_SYNC_WRITE (2 << 0) +#define DMA_BUF_SYNC_RW (DMA_BUF_SYNC_READ | DMA_BUF_SYNC_WRITE) +#define DMA_BUF_SYNC_START (0 << 2) +#define DMA_BUF_SYNC_END (1 << 2) +#define DMA_BUF_SYNC_VALID_FLAGS_MASK \ + (DMA_BUF_SYNC_RW | DMA_BUF_SYNC_END) + +#define DMA_BUF_BASE 'b' +#define DMA_BUF_IOCTL_SYNC _IOW(DMA_BUF_BASE, 0, struct dma_buf_sync) +#endif + #include "linux-dmabuf-unstable-v1-client-protocol.h" #define SYM(lib, xx) \ |