diff options
-rw-r--r-- | .build.yml | 1 | ||||
-rw-r--r-- | .travis.yml | 1 | ||||
-rw-r--r-- | CMake/Manpage.cmake | 56 | ||||
-rw-r--r-- | sway/CMakeLists.txt | 12 | ||||
-rw-r--r-- | sway/handlers.c | 8 | ||||
-rw-r--r-- | swaygrab/CMakeLists.txt | 4 | ||||
-rw-r--r-- | swaylock/CMakeLists.txt | 4 | ||||
-rw-r--r-- | swaymsg/CMakeLists.txt | 4 |
8 files changed, 53 insertions, 37 deletions
@@ -10,7 +10,6 @@ packages: | |||
10 | - cairo | 10 | - cairo |
11 | - wayland | 11 | - wayland |
12 | - gdk-pixbuf2 | 12 | - gdk-pixbuf2 |
13 | - asciidoc | ||
14 | sources: | 13 | sources: |
15 | - https://git.sr.ht/~sircmpwn/sway | 14 | - https://git.sr.ht/~sircmpwn/sway |
16 | tasks: | 15 | tasks: |
diff --git a/.travis.yml b/.travis.yml index 2bb17d40..69634765 100644 --- a/.travis.yml +++ b/.travis.yml | |||
@@ -10,7 +10,6 @@ arch: | |||
10 | packages: | 10 | packages: |
11 | - cmake | 11 | - cmake |
12 | - xorg-server-xwayland | 12 | - xorg-server-xwayland |
13 | - asciidoc | ||
14 | - json-c | 13 | - json-c |
15 | - wayland | 14 | - wayland |
16 | - xcb-util-image | 15 | - xcb-util-image |
diff --git a/CMake/Manpage.cmake b/CMake/Manpage.cmake index d9780bc4..cc04d710 100644 --- a/CMake/Manpage.cmake +++ b/CMake/Manpage.cmake | |||
@@ -1,31 +1,33 @@ | |||
1 | find_package(A2X REQUIRED) | 1 | find_package(A2X) |
2 | 2 | ||
3 | add_custom_target(man ALL) | 3 | if (A2X_FOUND) |
4 | add_custom_target(man ALL) | ||
4 | 5 | ||
5 | function(add_manpage name section) | 6 | function(add_manpage name section) |
6 | add_custom_command( | 7 | add_custom_command( |
7 | OUTPUT ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section} | 8 | OUTPUT ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section} |
8 | COMMAND ${A2X_COMMAND} | 9 | COMMAND ${A2X_COMMAND} |
9 | --no-xmllint | 10 | --no-xmllint |
10 | --doctype manpage | 11 | --doctype manpage |
11 | --format manpage | 12 | --format manpage |
12 | -D ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} | 13 | -D ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} |
13 | ${CMAKE_CURRENT_SOURCE_DIR}/${name}.${section}.txt | 14 | ${CMAKE_CURRENT_SOURCE_DIR}/${name}.${section}.txt |
14 | DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${name}.${section}.txt | 15 | DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${name}.${section}.txt |
15 | COMMENT Generating manpage for ${name}.${section} | 16 | COMMENT Generating manpage for ${name}.${section} |
16 | ) | 17 | ) |
17 | 18 | ||
18 | add_custom_target(man-${name}.${section} | 19 | add_custom_target(man-${name}.${section} |
19 | DEPENDS | 20 | DEPENDS |
20 | ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section} | 21 | ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section} |
21 | ) | 22 | ) |
22 | add_dependencies(man | 23 | add_dependencies(man |
23 | man-${name}.${section} | 24 | man-${name}.${section} |
24 | ) | 25 | ) |
25 | 26 | ||
26 | install( | 27 | install( |
27 | FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section} | 28 | FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${name}.${section} |
28 | DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/man/man${section} | 29 | DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/man/man${section} |
29 | COMPONENT documentation | 30 | COMPONENT documentation |
30 | ) | 31 | ) |
31 | endfunction() | 32 | endfunction() |
33 | endif() | ||
diff --git a/sway/CMakeLists.txt b/sway/CMakeLists.txt index 981f8a07..bf0b2e7f 100644 --- a/sway/CMakeLists.txt +++ b/sway/CMakeLists.txt | |||
@@ -93,8 +93,10 @@ endfunction() | |||
93 | add_config(config config sway) | 93 | add_config(config config sway) |
94 | add_config(00-defaults security.d/00-defaults sway/security.d) | 94 | add_config(00-defaults security.d/00-defaults sway/security.d) |
95 | 95 | ||
96 | add_manpage(sway 1) | 96 | if (A2X_FOUND) |
97 | add_manpage(sway 5) | 97 | add_manpage(sway 1) |
98 | add_manpage(sway-input 5) | 98 | add_manpage(sway 5) |
99 | add_manpage(sway-bar 5) | 99 | add_manpage(sway-input 5) |
100 | add_manpage(sway-security 7) | 100 | add_manpage(sway-bar 5) |
101 | add_manpage(sway-security 7) | ||
102 | endif() | ||
diff --git a/sway/handlers.c b/sway/handlers.c index 39261e3d..052789ca 100644 --- a/sway/handlers.c +++ b/sway/handlers.c | |||
@@ -1084,8 +1084,16 @@ bool handle_pointer_scroll(wlc_handle view, uint32_t time, const struct wlc_modi | |||
1084 | return EVENT_PASSTHROUGH; | 1084 | return EVENT_PASSTHROUGH; |
1085 | } | 1085 | } |
1086 | 1086 | ||
1087 | static void clip_test_cb(void *data, const char *type, int fd) { | ||
1088 | const char *str = data; | ||
1089 | write(fd, str, strlen(str)); | ||
1090 | close(fd); | ||
1091 | } | ||
1092 | |||
1087 | static void handle_wlc_ready(void) { | 1093 | static void handle_wlc_ready(void) { |
1088 | sway_log(L_DEBUG, "Compositor is ready, executing cmds in queue"); | 1094 | sway_log(L_DEBUG, "Compositor is ready, executing cmds in queue"); |
1095 | const char *type = "text/plain;charset=utf-8"; | ||
1096 | wlc_set_selection("test", &type, 1, &clip_test_cb); | ||
1089 | // Execute commands until there are none left | 1097 | // Execute commands until there are none left |
1090 | config->active = true; | 1098 | config->active = true; |
1091 | while (config->cmd_queue->length) { | 1099 | while (config->cmd_queue->length) { |
diff --git a/swaygrab/CMakeLists.txt b/swaygrab/CMakeLists.txt index a5e91e9c..42806cae 100644 --- a/swaygrab/CMakeLists.txt +++ b/swaygrab/CMakeLists.txt | |||
@@ -23,4 +23,6 @@ install( | |||
23 | COMPONENT runtime | 23 | COMPONENT runtime |
24 | ) | 24 | ) |
25 | 25 | ||
26 | add_manpage(swaygrab 1) | 26 | if (A2X_FOUND) |
27 | add_manpage(swaygrab 1) | ||
28 | endif() | ||
diff --git a/swaylock/CMakeLists.txt b/swaylock/CMakeLists.txt index 4aec6424..90b54a72 100644 --- a/swaylock/CMakeLists.txt +++ b/swaylock/CMakeLists.txt | |||
@@ -46,4 +46,6 @@ install( | |||
46 | COMPONENT data | 46 | COMPONENT data |
47 | ) | 47 | ) |
48 | 48 | ||
49 | add_manpage(swaylock 1) | 49 | if (A2X_FOUND) |
50 | add_manpage(swaylock 1) | ||
51 | endif() | ||
diff --git a/swaymsg/CMakeLists.txt b/swaymsg/CMakeLists.txt index f23919b8..b428a409 100644 --- a/swaymsg/CMakeLists.txt +++ b/swaymsg/CMakeLists.txt | |||
@@ -18,4 +18,6 @@ install( | |||
18 | COMPONENT runtime | 18 | COMPONENT runtime |
19 | ) | 19 | ) |
20 | 20 | ||
21 | add_manpage(swaymsg 1) | 21 | if (A2X_FOUND) |
22 | add_manpage(swaymsg 1) | ||
23 | endif() | ||