aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPřemysl Eric Janouch <p@janouch.name>2023-06-23 16:45:26 +0200
committerPřemysl Eric Janouch <p@janouch.name>2023-06-23 16:48:32 +0200
commitc2e8b65d0f77e7b93c4676df74bb0cf706e5665b (patch)
treeec151f436788dcfc73da3f46c19c7769d789ae05
parent4f57070e272f506731557b35b484429a968c7dd2 (diff)
downloadfiv-c2e8b65d0f77e7b93c4676df74bb0cf706e5665b.tar.gz
fiv-c2e8b65d0f77e7b93c4676df74bb0cf706e5665b.tar.xz
fiv-c2e8b65d0f77e7b93c4676df74bb0cf706e5665b.zip
Don't rebuild fiv-io.c several times
-rw-r--r--meson.build14
1 files changed, 9 insertions, 5 deletions
diff --git a/meson.build b/meson.build
index 50daf3d..459600b 100644
--- a/meson.build
+++ b/meson.build
@@ -161,11 +161,14 @@ tiff_tables = custom_target('tiff-tables.h',
)
desktops = ['fiv.desktop', 'fiv-browse.desktop']
-exe = executable('fiv', 'fiv.c', 'fiv-view.c', 'fiv-io.c', 'fiv-context-menu.c',
+iolib = static_library('fiv-io', 'fiv-io.c', 'xdg.c', tiff_tables,
+ dependencies : dependencies).extract_all_objects(recursive : true)
+exe = executable('fiv', 'fiv.c', 'fiv-view.c', 'fiv-context-menu.c',
'fiv-browser.c', 'fiv-sidebar.c', 'fiv-thumbnail.c', 'fiv-collection.c',
- 'fiv-io-model.c', 'xdg.c', tiff_tables, gresources, rc, config,
- install : true,
+ 'fiv-io-model.c', gresources, rc, config,
+ objects : iolib,
dependencies : dependencies,
+ install : true,
win_subsystem : 'windows',
)
@@ -193,8 +196,9 @@ if get_option('tools').enabled()
endforeach
if gdkpixbuf.found()
- executable('benchmark-io', 'tools/benchmark-io.c', 'fiv-io.c', 'xdg.c',
- tiff_tables, dependencies : [dependencies, gdkpixbuf])
+ executable('benchmark-io', 'tools/benchmark-io.c',
+ objects : iolib,
+ dependencies : [dependencies, gdkpixbuf])
endif
endif