find_package(OpenGL REQUIRED)

# Make sure that X11 server and libs are present
if (CMAKE_SYSTEM_NAME STREQUAL Linux)
  find_package(X11 REQUIRED)

  if (NOT X11_Xi_FOUND)
    message(FATAL_ERROR "X11 Xi library is required")
  endif ()
endif ()

# Third party libraries
include(cmake/glad.cmake)
include(cmake/glfw.cmake)
include(cmake/stb.cmake)
include(cmake/imgui.cmake)
include(cmake/rtmidi.cmake)
