Compare commits
2 Commits
16bdcb2991
...
9b02b94805
| Author | SHA1 | Date | |
|---|---|---|---|
| 9b02b94805 | |||
| ab2a62458d |
@ -1,13 +0,0 @@
|
|||||||
|
|
||||||
cmake_minimum_required(VERSION 3.20)
|
|
||||||
project(wayland-cli)
|
|
||||||
|
|
||||||
add_executable(${PROJECT_NAME})
|
|
||||||
|
|
||||||
target_sources(${PROJECT_NAME} PRIVATE main.cc)
|
|
||||||
|
|
||||||
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
|
|
||||||
find_package(Wayland REQUIRED)
|
|
||||||
|
|
||||||
include_directories(${WAYLAND_INCLUDE_DIRS})
|
|
||||||
target_link_libraries(${PROJECT_NAME} ${WAYLAND_LIBRARIES})
|
|
||||||
@ -1,24 +0,0 @@
|
|||||||
# Find the Wayland package
|
|
||||||
find_path(WAYLAND_INCLUDE_DIR
|
|
||||||
NAMES wayland-client.h
|
|
||||||
PATH_SUFFIXES wayland
|
|
||||||
)
|
|
||||||
|
|
||||||
find_library(WAYLAND_LIBRARY
|
|
||||||
NAMES wayland-client
|
|
||||||
)
|
|
||||||
|
|
||||||
find_library(WAYLAND_EGL_LIBRARY
|
|
||||||
NAMES wayland-egl
|
|
||||||
)
|
|
||||||
|
|
||||||
# Handle the QUIETLY and REQUIRED arguments and set WAYLAND_FOUND to TRUE if all listed variables are TRUE
|
|
||||||
include(FindPackageHandleStandardArgs)
|
|
||||||
find_package_handle_standard_args(Wayland DEFAULT_MSG WAYLAND_LIBRARY WAYLAND_INCLUDE_DIR)
|
|
||||||
|
|
||||||
if(WAYLAND_FOUND)
|
|
||||||
set(WAYLAND_LIBRARIES ${WAYLAND_LIBRARY} ${WAYLAND_EGL_LIBRARY})
|
|
||||||
set(WAYLAND_INCLUDE_DIRS ${WAYLAND_INCLUDE_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
mark_as_advanced(WAYLAND_INCLUDE_DIR WAYLAND_LIBRARY)
|
|
||||||
2
main.cc
2
main.cc
@ -14,7 +14,5 @@ int main()
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
wl_registry* registry = wl_display_get_registry(display);
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
8
meson.build
Normal file
8
meson.build
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
project('wl-cli', 'cpp')
|
||||||
|
|
||||||
|
client = dependency('wayland-client')
|
||||||
|
egl = dependency('wayland-egl')
|
||||||
|
|
||||||
|
src = ['main.cc']
|
||||||
|
|
||||||
|
executable('wl-cli', sources : src, dependencies : [client, egl])
|
||||||
13
subprojects/wayland.wrap
Normal file
13
subprojects/wayland.wrap
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
[wrap-file]
|
||||||
|
directory = wayland-1.23.1
|
||||||
|
source_url = https://gitlab.freedesktop.org/wayland/wayland/-/releases/1.23.1/downloads/wayland-1.23.1.tar.xz
|
||||||
|
source_filename = wayland-1.23.1.tar.xz
|
||||||
|
source_hash = 864fb2a8399e2d0ec39d56e9d9b753c093775beadc6022ce81f441929a81e5ed
|
||||||
|
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/wayland_1.23.1-1/wayland-1.23.1.tar.xz
|
||||||
|
wrapdb_version = 1.23.1-1
|
||||||
|
|
||||||
|
[provide]
|
||||||
|
wayland-cursor = wayland_cursor_dep
|
||||||
|
wayland-egl = wayland_egl_dep
|
||||||
|
wayland-server = wayland_server_dep
|
||||||
|
wayland-client = wayland_client_dep
|
||||||
Loading…
x
Reference in New Issue
Block a user