macro definition in meson.build are not correct
I think that some macro definitions are not correct in the meson.build.
For example,
stable = (gimp_app_version_minor % 2 == 0)
conf.set10('GIMP_UNSTABLE', not stable)
will give, for stable release,
#define GIMP_UNSTABLE 0
But, in the code you use #ifdef GIMP_UNSTABLE
. In this case, GIMP_UNSTABLE will be defined either it is equal to 0 or 1.
With autotools it was something commented like:
/* undef GIMP_UNSTABLE */
I think you need to check other macros if I'm not wrong.
Something like
if not stable
conf_data.set('GIMP_UNSTABLE', 1)
endif
should be ok.