From 7965f983baa91afa7ac8019574a14e4814c91cf2 Mon Sep 17 00:00:00 2001 From: raysan5 Date: Thu, 28 Dec 2017 18:14:39 +0100 Subject: Support Wayland display on Linux desktop --- src/Makefile | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/Makefile b/src/Makefile index de9a639e..2ee9f909 100644 --- a/src/Makefile +++ b/src/Makefile @@ -54,12 +54,16 @@ RAYLIB_LIBTYPE ?= STATIC # NOTE: Some programs like tools could not require audio support INCLUDE_AUDIO_MODULE ?= TRUE -# Force OpenAL Soft backend for audio +# Use OpenAL Soft backend for audio USE_OPENAL_BACKEND ?= FALSE # Use external GLFW library instead of rglfw module USE_EXTERNAL_GLFW ?= FALSE +# Use Wayland display server protocol on Linux desktop +# by default it uses X11 windowing system +USE_WAYLAND_DISPLAY ?= FALSE + # OpenAL Soft audio backend forced on HTML5 and OSX (see below) ifeq ($(PLATFORM),PLATFORM_WEB) USE_OPENAL_BACKEND = TRUE @@ -287,10 +291,20 @@ ifeq ($(RAYLIB_LIBTYPE),SHARED) CFLAGS += -fPIC -DBUILD_LIBTYPE_SHARED endif +# Use OpenAL Soft backend instead of mini_al ifeq ($(USE_OPENAL_BACKEND),TRUE) CFLAGS += -DUSE_OPENAL_BACKEND endif +# Use Wayland display on Linux desktop +ifeq ($(PLATFORM),PLATFORM_DESKTOP) + ifeq ($(PLATFORM_OS), LINUX) + ifeq ($(USE_WAYLAND_DISPLAY),TRUE) + CFLAGS += -D_GLFW_WAYLAND + endif + endif +endif + # Define include paths for required headers # NOTE: Several external required libraries (stb and others) INCLUDE_PATHS = -I. -Iexternal -Iexternal/glfw/include -- cgit v1.2.3