mirror of
https://codeberg.org/dnkl/yambar.git
synced 2025-06-24 11:05:39 +02:00
particles: compile as shared libraries (plugins)
This commit is contained in:
parent
7b98ea2b7c
commit
47018104da
13 changed files with 89 additions and 130 deletions
24
particles/CMakeLists.txt
Normal file
24
particles/CMakeLists.txt
Normal file
|
@ -0,0 +1,24 @@
|
|||
cmake_minimum_required(VERSION 3.13)
|
||||
|
||||
add_library(particle-sdk INTERFACE)
|
||||
target_compile_definitions(particle-sdk INTERFACE _GNU_SOURCE)
|
||||
target_compile_options(particle-sdk INTERFACE ${CAIRO_CFLAGS_OTHER})
|
||||
target_include_directories(particle-sdk INTERFACE ${CAIRO_INCLUDE_DIRS})
|
||||
|
||||
add_library(empty MODULE empty.c empty.h)
|
||||
target_link_libraries(empty particle-sdk)
|
||||
|
||||
add_library(list MODULE list.c list.h)
|
||||
target_link_libraries(list particle-sdk)
|
||||
|
||||
add_library(map MODULE map.c map.h)
|
||||
target_link_libraries(map particle-sdk)
|
||||
|
||||
add_library(progress-bar MODULE progress-bar.c progress-bar.h)
|
||||
target_link_libraries(progress-bar particle-sdk)
|
||||
|
||||
add_library(ramp MODULE ramp.c ramp.h)
|
||||
target_link_libraries(ramp particle-sdk)
|
||||
|
||||
add_library(string MODULE string.c string.h)
|
||||
target_link_libraries(string particle-sdk)
|
|
@ -48,7 +48,7 @@ from_conf(const struct yml_node *node, const struct font *parent_font,
|
|||
return empty_new(left_margin, right_margin, on_click_template);
|
||||
}
|
||||
|
||||
const struct particle_info particle_empty = {
|
||||
const struct particle_info plugin_info = {
|
||||
.from_conf = &from_conf,
|
||||
.attr_count = PARTICLE_COMMON_ATTRS_COUNT + 0,
|
||||
.attrs = {
|
||||
|
|
|
@ -198,7 +198,7 @@ from_conf(const struct yml_node *node, const struct font *parent_font,
|
|||
on_click_template);
|
||||
}
|
||||
|
||||
const struct particle_info particle_list = {
|
||||
const struct particle_info plugin_info = {
|
||||
.from_conf = &from_conf,
|
||||
.attr_count = PARTICLE_COMMON_ATTRS_COUNT + 4,
|
||||
.attrs = {
|
||||
|
|
|
@ -228,7 +228,7 @@ from_conf(const struct yml_node *node, const struct font *parent_font,
|
|||
default_particle, left_margin, right_margin, on_click_template);
|
||||
}
|
||||
|
||||
const struct particle_info particle_map = {
|
||||
const struct particle_info plugin_info = {
|
||||
.from_conf = &from_conf,
|
||||
.attr_count = PARTICLE_COMMON_ATTRS_COUNT + 3,
|
||||
.attrs = {
|
||||
|
|
|
@ -257,7 +257,7 @@ from_conf(const struct yml_node *node, const struct font *parent_font,
|
|||
left_margin, right_margin, on_click_template);
|
||||
}
|
||||
|
||||
const struct particle_info particle_progress_bar = {
|
||||
const struct particle_info plugin_info = {
|
||||
.from_conf = &from_conf,
|
||||
.attr_count = PARTICLE_COMMON_ATTRS_COUNT + 7,
|
||||
.attrs = {
|
||||
|
|
|
@ -178,7 +178,7 @@ from_conf(const struct yml_node *node, const struct font *parent_font,
|
|||
on_click_template);
|
||||
}
|
||||
|
||||
const struct particle_info particle_ramp = {
|
||||
const struct particle_info plugin_info = {
|
||||
.from_conf = &from_conf,
|
||||
.attr_count = PARTICLE_COMMON_ATTRS_COUNT + 2,
|
||||
.attrs = {
|
||||
|
|
|
@ -171,7 +171,7 @@ from_conf(const struct yml_node *node, const struct font *parent_font,
|
|||
fg_color, left_margin, right_margin, on_click_template);
|
||||
}
|
||||
|
||||
const struct particle_info particle_string = {
|
||||
const struct particle_info plugin_info = {
|
||||
.from_conf = &from_conf,
|
||||
.attr_count = PARTICLE_COMMON_ATTRS_COUNT + 5,
|
||||
.attrs = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue