Fix #1004, 1005: Various meson problems
[geeqie.git] / src / meson.build
1 # This file is a part of Geeqie project (https://www.geeqie.org/).
2 # Copyright (C) 2008 - 2022 The Geeqie Team
3 #
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 2 of the License, or
7 # (at your option) any later version.
8 #
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13
14 main_sources = files('advanced_exif.c',
15 'advanced_exif.h',
16 'bar.c',
17 'bar_comment.c',
18 'bar_comment.h',
19 'bar_exif.c',
20 'bar_exif.h',
21 'bar_gps.c',
22 'bar_gps.h',
23 'bar.h',
24 'bar_histogram.c',
25 'bar_histogram.h',
26 'bar_keywords.c',
27 'bar_keywords.h',
28 'bar_rating.c',
29 'bar_rating.h',
30 'bar_sort.c',
31 'bar_sort.h',
32 'cache.c',
33 'cache.h',
34 'cache-loader.c',
35 'cache-loader.h',
36 'cache_maint.c',
37 'cache_maint.h',
38 'cellrenderericon.c',
39 'cellrenderericon.h',
40 'collect.c',
41 'collect-dlg.c',
42 'collect-dlg.h',
43 'collect.h',
44 'collect-io.c',
45 'collect-io.h',
46 'collect-table.c',
47 'collect-table.h',
48 'color-man.c',
49 'color-man.h',
50 'compat.c',
51 'compat.h',
52 'debug.c',
53 'debug.h',
54 'desktop_file.c',
55 'desktop_file.h',
56 'dnd.c',
57 'dnd.h',
58 'dupe.c',
59 'dupe.h',
60 'editors.c',
61 'editors.h',
62 'exif.c',
63 'exif-common.c',
64 'exif.h',
65 'exif-int.h',
66 'exiv2.cc',
67 'filecache.c',
68 'filecache.h',
69 'filedata.c',
70 'filedata.h',
71 'filefilter.c',
72 'filefilter.h',
73 'format_canon.c',
74 'format_canon.h',
75 'format_fuji.c',
76 'format_fuji.h',
77 'format_nikon.c',
78 'format_nikon.h',
79 'format_olympus.c',
80 'format_olympus.h',
81 'format_raw.c',
82 'format_raw.h',
83 'fullscreen.c',
84 'fullscreen.h',
85 'glua.h',
86 'histogram.c',
87 'histogram.h',
88 'history_list.c',
89 'history_list.h',
90 'image.c',
91 'image.h',
92 'image-load.c',
93 'image_load_collection.c',
94 'image_load_collection.h',
95 'image_load_cr3.c',
96 'image_load_cr3.h',
97 'image_load_dds.c',
98 'image_load_dds.h',
99 'image_load_djvu.c',
100 'image_load_djvu.h',
101 'image_load_external.c',
102 'image_load_external.h',
103 'image_load_ffmpegthumbnailer.c',
104 'image_load_ffmpegthumbnailer.h',
105 'image_load_gdk.c',
106 'image_load_gdk.h',
107 'image-load.h',
108 'image_load_heif.c',
109 'image_load_heif.h',
110 'image_load_j2k.c',
111 'image_load_j2k.h',
112 'image_load_jpeg.c',
113 'image_load_jpeg.h',
114 'image_load_jpegxl.c',
115 'image_load_jpegxl.h',
116 'image_load_libraw.c',
117 'image_load_libraw.h',
118 'image_load_pdf.c',
119 'image_load_pdf.h',
120 'image_load_psd.c',
121 'image_load_psd.h',
122 'image_load_svgz.c',
123 'image_load_svgz.h',
124 'image_load_tiff.c',
125 'image_load_tiff.h',
126 'image_load_webp.c',
127 'image_load_webp.h',
128 'image_load_zxscr.c',
129 'image_load_zxscr.h',
130 'image-overlay.c',
131 'image-overlay.h',
132 'img-view.c',
133 'img-view.h',
134 'intl.h',
135 'jpeg_parser.c',
136 'jpeg_parser.h',
137 'keymap_template.c',
138 'keymap_template.h',
139 'layout.c',
140 'layout_config.c',
141 'layout_config.h',
142 'layout.h',
143 'layout_image.c',
144 'layout_image.h',
145 'layout_util.c',
146 'layout_util.h',
147 'logwindow.c',
148 'logwindow.h',
149 'lua.c',
150 'main.c',
151 'main.h',
152 'md5-util.c',
153 'md5-util.h',
154 'menu.c',
155 'menu.h',
156 'metadata.c',
157 'metadata.h',
158 'misc.c',
159 'misc.h',
160 'options.c',
161 'options.h',
162 'osd.c',
163 'osd.h',
164 'pan-view.h',
165 'pixbuf-renderer.c',
166 'pixbuf-renderer.h',
167 'pixbuf_util.c',
168 'pixbuf_util.h',
169 'preferences.c',
170 'preferences.h',
171 'print.c',
172 'print.h',
173 'rcfile.c',
174 'rcfile.h',
175 'remote.c',
176 'remote.h',
177 'renderer-tiles.c',
178 'renderer-tiles.h',
179 'search_and_run.c',
180 'search_and_run.h',
181 'search.c',
182 'search.h',
183 'secure_save.c',
184 'secure_save.h',
185 'shortcuts.c',
186 'shortcuts.h',
187 'similar.c',
188 'similar.h',
189 'slideshow.c',
190 'slideshow.h',
191 'thumb.c',
192 'thumb.h',
193 'thumb_standard.c',
194 'thumb_standard.h',
195 'toolbar.c',
196 'toolbar.h',
197 'trash.c',
198 'trash.h',
199 'typedefs.h',
200 'ui_bookmark.c',
201 'ui_bookmark.h',
202 'ui_fileops.c',
203 'ui_fileops.h',
204 'ui_help.c',
205 'ui_help.h',
206 'ui_menu.c',
207 'ui_menu.h',
208 'ui_misc.c',
209 'ui_misc.h',
210 'ui_pathsel.c',
211 'ui_pathsel.h',
212 'ui_spinner.c',
213 'ui_spinner.h',
214 'ui_tabcomp.c',
215 'ui_tabcomp.h',
216 'ui_tree_edit.c',
217 'ui_tree_edit.h',
218 'ui_utildlg.c',
219 'ui_utildlg.h',
220 'uri_utils.c',
221 'uri_utils.h',
222 'utilops.c',
223 'utilops.h',
224 'view_dir.c',
225 'view_dir.h',
226 'view_dir_list.c',
227 'view_dir_list.h',
228 'view_dir_tree.c',
229 'view_dir_tree.h',
230 'view_file.h',
231 'whereami.c',
232 'whereami.h',
233 'window.c',
234 'window.h',
235 'zonedetect.c',
236 'zonedetect.h')
237
238 project_sources += main_sources
239
240 subdir('icons')
241 subdir('pan-view')
242 subdir('view_file')
243
244 gqmarshal = gnome.genmarshal('gq-marshal', prefix : 'gq_marshal', sources : 'gq-marshal.list')
245 project_sources += gqmarshal[0]
246 project_sources += gqmarshal[1]
247
248 icon_pairs = [
249 'icon_spinner', files('ui_spinner.png'),
250 'icon_tabcomp', files('ui_tabcomp.png'),
251 ]
252
253 ui_icons_h = custom_target('ui_icons', output : 'ui_icons.h',
254                 command : [gdk_pixbuf_csource, '--raw', '--extern', '--build-list', icon_pairs],
255                 capture : true)
256
257 project_sources += ui_icons_h
258
259 xxd = find_program('generate-ClayRGB1998-icc-h.sh', dirs : join_paths(meson.source_root(), 'scripts'))
260
261 ClayRGB1998_icc_h = custom_target('ClayRGB1998',
262                     output : 'ClayRGB1998_icc.h',
263                     command : [xxd, join_paths(meson.current_source_dir(), 'ClayRGB1998.icc')],
264                     capture : true)
265
266 project_sources += ClayRGB1998_icc_h
267
268 executable('geeqie', project_sources,
269 dependencies : [
270 champlain_dep,
271 champlain_gtk_dep,
272 clutter_dep,
273 clutter_gtk_dep,
274 ddjvuapi_dep,
275 exiv2_dep,
276 glib_dep,
277 gspell_dep,
278 gtk_dep,
279 lcms_dep,
280 libarchive_dep,
281 libffmpegthumbnailer_dep,
282 libheif_dep,
283 libjpeg_dep,
284 libjxl_dep,
285 libopenjp2_dep,
286 libraw_dep,
287 libwebp_dep,
288 lua_dep,
289 poppler_glib_dep,
290 thread_dep,
291 tiff_dep
292 ],
293 include_directories : [configuration_inc], install : true)