meson: don't compile import sources four times
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 7 Dec 2021 14:39:43 +0000 (15:39 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 16 Dec 2021 09:54:46 +0000 (10:54 +0100)
commitb93f018f574a92c680669c35fea37be8d8f73c3f
tree926663dac1b7b0e2828138f3b61ecddcc684c674
parentaf3b864d76cf916a026b7877099791811b348fdf
meson: don't compile import sources four times

Use a 'convenience library' to do the compilation once and then link the
objects into all the files that need it. Those files are small, so this probably
doesn't matter too much for speed, but has the advantage that we don't get the
same error four times if something goes wrong.

The library is conditionalized in the same way importd itself, because we
cannot build it without the deps.
meson.build
src/import/meson.build