When compiling glibd-2.1.0 with host version glib 2.62.0 it fails due to missing support for function-macro in GirPackage.
The Meson build system
Version: 0.51.2
Source dir: /build/glibd/src/GlibD-2.1.0
Build dir: /build/glibd/src/GlibD-2.1.0/build
Build type: native build
Project name: GlibD
Project version: 2.1.0
Appending LDFLAGS from environment: '-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'
Appending LDFLAGS from environment: '-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'
D compiler for the host machine: ldc (llvm 1.17.0 "LDC - the LLVM D compiler (1.17.0):")
Build machine cpu family: x86_64
Build machine cpu: x86_64
Found pkg-config: /usr/bin/pkg-config (1.6.3)
Run-time dependency glib-2.0 found: YES 2.62.0
Run-time dependency gmodule-2.0 found: YES 2.62.0
Run-time dependency gobject-2.0 found: YES 2.62.0
Run-time dependency gio-2.0 found: YES 2.62.0
Run-time dependency gobject-introspection-1.0 found: YES 1.62.0
Program girtod found: YES (/usr/bin/girtod)
Message: Generating D interfaces from GIR...
meson.build:37:4: ERROR: Problem encountered: Unable to build D intefaces from GIR:
Error /usr/share/gir-1.0/GLib-2.0.gir(143): Unexpected tag: function-macro in GirPackage: glib
The part of the .gir file it fails on:
<function-macro name="ALIGNOF"
c:identifier="G_ALIGNOF"
version="2.60"
introspectable="0">
<doc xml:space="preserve"
filename="gmacros.h"
line="873">Return the minimal alignment required by the platform ABI for values of >
type. The address of a variable or struct member of the given type must always be
a multiple of this alignment. For example, most platforms require int variables
to be aligned at a 4-byte boundary, so `G_ALIGNOF (int)` is 4 on most platforms.
Note this is not necessarily the same as the value returned by GCC’s
`__alignof__` operator, which returns the preferred alignment for a type.
The preferred alignment may be a stricter alignment than the minimal
alignment.</doc>
<source-position filename="gmacros.h" line="870"/>
<parameters>
<parameter name="type">
<doc xml:space="preserve"
filename="gmacros.h"
line="875">a type-name</doc>
</parameter>
</parameters>
</function-macro>
When compiling glibd-2.1.0 with host version glib 2.62.0 it fails due to missing support for function-macro in GirPackage.
The part of the .gir file it fails on: