# Could NOT find Wayland when building OBS in Linux



## JanisE (Feb 17, 2021)

Hello!

I'm trying to build OBS Studio on Linux Mint 20.1 by "Debian-based Build Directions" on https://obsproject.com/wiki/install-instructions .

When I run cmake, the process ends with an error "Could NOT find Wayland (missing: WAYLAND_LIBRARIES WAYLAND_INCLUDE_DIRS)".

How can this be solved?


```
obs-studio/build$ cmake -DUNIX_STRUCTURE=1 -DCMAKE_INSTALL_PREFIX=/usr ..
-- The C compiler identification is GNU 9.3.0
-- The CXX compiler identification is GNU 9.3.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- OBS_VERSION: 26.1.2-196-g7a4844e2f
-- Found OpenGL: /usr/lib/x86_64-linux-gnu/libOpenGL.so   
-- Found X11: /usr/include   
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1") 
-- Checking for module 'egl'
--   Found egl, version 1.5
-- Found EGL: /usr/include  
-- Found FFmpeg: /usr/sbin/../lib64/libavcodec.so (found version "58.54.100") found components: avcodec avdevice avutil avformat 
-- Found Libcurl: /usr/sbin/../lib64/libcurl.so  
-- Scripting: Luajit supported
-- Scripting: Python 3 supported
-- Found SWIG: /usr/bin/swig4.0 (found suitable version "4.0.1", minimum required is "2") 
-- Using system Jansson library
-- XCB[XCB]: Found component XCB
-- Found XCB: /usr/lib/x86_64-linux-gnu/libxcb.so  found components: XCB 
-- Found X11_XCB: /usr/lib/x86_64-linux-gnu/libX11-xcb.so  
CMake Error at /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message):
  Could NOT find Wayland (missing: WAYLAND_LIBRARIES WAYLAND_INCLUDE_DIRS)
Call Stack (most recent call first):
  /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:393 (_FPHSA_FAILURE_MESSAGE)
  cmake/Modules/FindWayland.cmake:76 (find_package_handle_standard_args)
  libobs-opengl/CMakeLists.txt:55 (find_package)
```


----------



## Tuna (Feb 17, 2021)

The Wayland support is pretty new. So the documentation may be outdated for that. Probably you want to install "libwayland-dev" package.


----------



## JanisE (Feb 17, 2021)

Thank you! It worked.


----------

