1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253
|
common_plugins_list = [
{ 'name': 'align-layers', },
{ 'name': 'animation-optimize', },
{ 'name': 'animation-play', },
{ 'name': 'blinds', },
{ 'name': 'border-average', },
{ 'name': 'busy-dialog', },
{ 'name': 'checkerboard', },
{ 'name': 'cml-explorer', },
{ 'name': 'colormap-remap', },
{ 'name': 'compose', },
{ 'name': 'contrast-retinex', },
{ 'name': 'crop-zealous',
'deps': [ gtk3, gegl, gdk_pixbuf, cairo, ],
},
{ 'name': 'curve-bend', },
{ 'name': 'decompose', },
{ 'name': 'depth-merge', },
{ 'name': 'despeckle', },
{ 'name': 'destripe', },
{ 'name': 'file-cel', },
{ 'name': 'file-compressor',
'deps': [ gegl, gdk_pixbuf, cairo, gio, liblzma, pango, bz2, zlib, ],
},
{ 'name': 'file-csource', },
{ 'name': 'file-desktop-link',
'deps': [ gtk3, gegl, gdk_pixbuf, cairo, ],
},
{ 'name': 'file-dicom', },
{ 'name': 'file-farbfeld', },
{ 'name': 'file-gbr', },
{ 'name': 'file-gegl', },
{ 'name': 'file-gif-load',
'deps': [ gtk3, gegl, gdk_pixbuf, cairo, ],
},
{ 'name': 'file-gif-export', },
{ 'name': 'file-gih', },
{ 'name': 'file-glob',
'deps': [ gtk3, gegl, gdk_pixbuf, cairo, ],
},
{ 'name': 'file-header', },
{ 'name': 'file-html-table', },
{ 'name': 'file-pat', },
{ 'name': 'file-pcx', },
{ 'name': 'file-pdf-load',
'deps': [ gtk3, gegl, gdk_pixbuf, poppler ],
},
{ 'name': 'file-pix', },
{ 'name': 'file-png',
'deps': [ gtk3, gegl, libpng, lcms ],
},
{ 'name': 'file-pnm', },
{ 'name': 'file-psp',
'deps': [ gtk3, gegl, zlib, ],
},
{ 'name': 'file-raw-data', },
{ 'name': 'file-sunras', },
{ 'name': 'file-svg',
'deps': [ gtk3, gegl, rsvg, ],
},
{ 'name': 'file-tga', },
{ 'name': 'file-wbmp', },
{ 'name': 'file-xbm', },
{ 'name': 'file-xwd', },
{ 'name': 'film', },
{ 'name': 'gradient-map', },
{ 'name': 'grid', },
{ 'name': 'guillotine', },
{ 'name': 'hot', },
{ 'name': 'jigsaw', },
{ 'name': 'nl-filter', },
{ 'name': 'plugin-browser', },
{ 'name': 'procedure-browser', },
{ 'name': 'qbist', },
{ 'name': 'sample-colorize', },
{ 'name': 'smooth-palette', },
{ 'name': 'sparkle', },
{ 'name': 'sphere-designer', },
{ 'name': 'tile-small', },
{ 'name': 'tile', },
{ 'name': 'unit-editor', },
{ 'name': 'van-gogh-lic', },
{ 'name': 'warp', },
{ 'name': 'wavelet-decompose', },
{ 'name': 'web-browser', },
]
if libaa.found()
common_plugins_list += {
'name': 'file-aa',
'deps': [ gtk3, gegl, gdk_pixbuf, libaa, ],
}
endif
if have_heif
common_plugins_list += { 'name': 'file-heif',
'deps': [ gtk3, gegl, libheif, gexiv2, lcms, ],
}
endif
if openjpeg.found()
common_plugins_list += { 'name': 'file-jp2-load',
'deps': [ gtk3, gegl, gdk_pixbuf, openjpeg, ],
}
endif
if libjxl.found() and libjxl_threads.found()
common_plugins_list += {
'name': 'file-jpegxl',
'deps': [ gtk3, gegl, gexiv2, libjxl, libjxl_threads, ],
}
endif
if libmng.found()
mng_cflags = []
if platform_windows
mng_cflags = [ '-DMNG_USE_DLL' ]
endif
common_plugins_list += { 'name': 'file-mng',
'deps': [ gtk3, gegl, libmng, libpng, ],
'cflags': mng_cflags,
}
endif
if cairopdf.found()
common_plugins_list += { 'name': 'file-pdf-export',
'deps': [ gtk3, gegl, gdk_pixbuf, poppler, cairo, cairopdf ],
}
endif
if ghostscript.found()
common_plugins_list += { 'name': 'file-ps',
'deps': [ gtk3, gegl, gdk_pixbuf, ghostscript, ],
}
endif
if wmf.found()
common_plugins_list += { 'name': 'file-wmf',
'deps': [ gtk3, gegl, wmf, ],
}
endif
if xmc.found()
common_plugins_list += { 'name': 'file-xmc',
'deps': [ gtk3, gegl, xmc, ],
}
endif
if libxpm.found()
common_plugins_list += { 'name': 'file-xpm',
'deps': [ gtk3, gegl, libxpm, ],
}
endif
if have_qoi
common_plugins_list += {
'name': 'file-qoi',
'deps': [ gtk3, gegl, ],
}
endif
if libiff.found() and libilbm.found()
common_plugins_list += {
'name': 'file-iff',
'deps': [ gtk3, gegl, libiff, libilbm, ],
}
elif have_ilbm
common_plugins_list += {
'name': 'file-iff',
'deps': [ gtk3, gegl, ],
}
endif
if platform_windows
common_plugins_list += { 'name': 'file-lnk', }
endif
if not platform_windows
common_plugins_list += { 'name': 'mail', }
endif
if get_option('webkit-unmaintained')
common_plugins_list += { 'name': 'web-page',
'deps': [ gtk3, gegl, gdk_pixbuf, webkit, ],
}
endif
foreach plugin : common_plugins_list
plugin_name = plugin.get('name')
plugin_sources = [ plugin.get('sources', plugin_name + '.c') ]
plugin_deps = plugin.get('deps', [ gtk3, gegl, gdk_pixbuf, ])
plugin_cflags = plugin.get('cflags', [])
if platform_windows
plugin_rc = configure_file(
input : gimp_plugins_rc.full_path(),
output: plugin_name + '.rc',
copy: true,
)
# See https://gitlab.gnome.org/GNOME/gimp/-/issues/8537
if generate_version_h
compile_resources_depfiles = []
compile_resources_depends = [ gitversion_h ]
else
compile_resources_depfiles = [ gitversion_h ]
compile_resources_depends = []
endif
plugin_sources += windows.compile_resources(
plugin_rc,
args: [
'--define', 'ORIGINALFILENAME_STR="@0@"'.format(plugin_name+'.exe'),
'--define', 'INTERNALNAME_STR="@0@"' .format(plugin_name),
'--define', 'TOP_SRCDIR="@0@"' .format(meson.project_source_root()),
],
include_directories: [
rootInclude, appInclude,
],
depend_files: compile_resources_depfiles,
depends: compile_resources_depends
)
endif
plugin_exe = executable(plugin_name,
plugin_sources,
include_directories: [ rootInclude, ],
link_with : [
libgimp,
libgimpbase,
libgimpcolor,
libgimpconfig,
libgimpmath,
libgimpui,
libgimpwidgets,
],
dependencies: [ plugin_deps, math ],
c_args: plugin_cflags,
win_subsystem: 'windows',
install: true,
install_dir: gimpplugindir / 'plug-ins' / plugin_name)
# Ugly trick to copy executables into subfolders so that we can run GIMP from
# the build directory without installing it.
custom_target('test-' + plugin_name,
input: [ plugin_exe ],
output: [ plugin_name + '.dummy' ],
command: [ python, meson.project_source_root() / 'build/meson/cp-plug-in-subfolder.py',
plugin_exe, meson.current_build_dir() / 'test-plug-ins' / plugin_name,
'@OUTPUT@' ],
build_by_default: true)
plugin_executables += [meson.current_build_dir() / 'test-plug-ins' / plugin_name / fs.name(plugin_exe.full_path())]
endforeach
|