Skip to content

Commit 4c061cb

Browse files
author
Marco Felsch
committed
build: build libplatsch as dedicated library
This adds the support for building platsch and libplatsch. Platsch links uses the static library to not cause any performance regression. By this commit the conversion from a standalone application into an application and library is complete. Signed-off-by: Marco Felsch <[email protected]>
1 parent c5aa598 commit 4c061cb

File tree

1 file changed

+20
-2
lines changed

1 file changed

+20
-2
lines changed

meson.build

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,28 @@ project(
1010

1111
libdrm_dep = dependency('libdrm', version : '>=2.4.112')
1212

13+
install_headers('libplatsch.h')
14+
15+
platsch_lib = both_libraries(
16+
'platsch',
17+
sources : ['libplatsch.c'],
18+
dependencies : [libdrm_dep],
19+
install : true,
20+
)
21+
22+
pkg_mod = import('pkgconfig')
23+
pkg_mod.generate(
24+
libraries : platsch_lib,
25+
version : '2024.06.0',
26+
name : 'libplatsch',
27+
filebase : 'platsch',
28+
description : 'A Library to build custom bootsplash applications.'
29+
)
30+
1331
executable(
1432
'platsch',
15-
sources : ['platsch.c', 'libplatsch.c'],
16-
dependencies : [libdrm_dep],
33+
sources : ['platsch.c'],
34+
link_with : platsch_lib.get_static_lib(),
1735
install : true,
1836
install_dir : get_option('sbindir'),
1937
)

0 commit comments

Comments
 (0)