aboutsummaryrefslogtreecommitdiffhomepage
path: root/meson.build
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2026-08-02 01:36:33 +0200
committerdec05eba <dec05eba@protonmail.com>2026-08-02 01:36:33 +0200
commitf547fcc354671c672fffb20092e72d231e6ed1e4 (patch)
tree1d23aff0c7d5268089b688cae8626c97c79233c4 /meson.build
parent9b799f6e45c5e7a44432824f69d9632ff5848e6c (diff)
Add gsr-cli program that sends ipc commands to gpu-screen-recorder
gsr-cli sends a command to the ipc socket of a running GPU Screen Recorder and exits with 0 when it replied with ok, printing the reason to stderr when it didn't, which means the commands don't have to be sent blindly like signals are. The status command checks if GPU Screen Recorder is running by connecting to the socket without sending a command, so it's also correct when a killed instance left the socket behind. The json helpers moved into src/json.c to be shared between the two programs.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build4
1 files changed, 3 insertions, 1 deletions
diff --git a/meson.build b/meson.build
index bddfc02..7b0c14e 100644
--- a/meson.build
+++ b/meson.build
@@ -31,6 +31,7 @@ src = [
'src/replay_buffer/replay_buffer_ram.c',
'src/replay_buffer/replay_buffer_disk.c',
'src/log.c',
+ 'src/json.c',
'src/ffmpeg_utils.c',
'src/recorder/audio_codec.c',
'src/recorder/video_codec.c',
@@ -131,10 +132,11 @@ endif
add_project_arguments('-DGSR_VERSION="' + meson.project_version() + '"', language: 'c')
executable('gsr-kms-server', 'kms/server/kms_server.c', dependencies : dependency('libdrm'), c_args : '-fstack-protector-all', install : true)
+executable('gsr-cli', ['src/gsr_cli/main.c', 'src/json.c', 'src/log.c'], install : true)
executable('gpu-screen-recorder', src, dependencies : dep, install : true)
install_headers('plugin/plugin.h', install_dir : 'include/gsr')
-install_man('gpu-screen-recorder.1', 'gsr-kms-server.1')
+install_man('gpu-screen-recorder.1', 'gsr-cli.1', 'gsr-kms-server.1')
install_subdir('scripts', install_dir: 'share/gpu-screen-recorder')
if get_option('systemd') == true