Build problem on NetBSD: can't resolve libraries to shared libraries: json-glib-1.0
When building json-glib-1.4.2 on NetBSD with glib2-2.56.2, ninja-1.8.2, and meson-0.44.1, it builds fine until the final step when it just errors out. I don't know ninja or meson well enough to get more detailed error information out.
Here's the log:
meson --prefix /usr/pkg --mandir man --buildtype=plain . output
The Meson build system
Version: 0.44.1
Source dir: /scratch/textproc/json-glib/work/json-glib-1.4.2
Build dir: /scratch/textproc/json-glib/work/json-glib-1.4.2/output
Build type: native build
Project name: json-glib
Native C compiler: gcc (gcc 6.4.0)
Appending CFLAGS from environment: '-O2 -g -D_FORTIFY_SOURCE=2 -fstack-check -I/usr/pkg/include -I/usr/pkg/include/glib/glib-2.0 -I/usr/pkg/include/glib/gio-unix-2.0 -I/usr/pkg/lib/glib-2.0/include -I/usr/include -I/usr/pkg/include/python3.7'
Appending LDFLAGS from environment: '-Wl,-z,relro -Wl,-z,now -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -L/usr/lib -Wl,-R/usr/lib'
Appending CPPFLAGS from environment: '-g -I/usr/pkg/include -I/usr/pkg/include/glib/glib-2.0 -I/usr/pkg/include/glib/gio-unix-2.0 -I/usr/pkg/lib/glib-2.0/include -I/usr/include -I/usr/pkg/include/python3.7'
Build machine cpu family: x86_64
Build machine cpu: x86_64
Found pkg-config: /scratch/textproc/json-glib/work/.tools/bin/pkg-config (1.4.1)
Native dependency gobject-2.0 found: YES 2.56.2
Native dependency gio-2.0 found: YES 2.56.2
Has header "unistd.h": YES
Compiler for C supports argument -Wcast-align: YES
Compiler for C supports argument -Wlogical-op: YES
Compiler for C supports argument -Wmissing-declarations: YES
Compiler for C supports argument -Wmissing-format-attribute: YES
Compiler for C supports argument -Wmissing-prototypes: YES
Compiler for C supports argument -Wmissing-noreturn: YES
Compiler for C supports argument -Wold-style-definition: YES
Compiler for C supports argument -Wpointer-arith: YES
Compiler for C supports argument -Wshadow: YES
Compiler for C supports argument -Wstrict-prototypes: YES
Compiler for C supports argument -Wunused: YES
Compiler for C supports argument -Wno-discarded-qualifiers: YES
Compiler for C supports argument -Wno-int-conversion: YES
Compiler for C supports argument -fno-strict-aliasing: YES
Compiler for C supports argument -Wno-uninitialized: YES
Compiler for C supports argument -Werror=address: YES
Compiler for C supports argument -Werror=array-bounds: YES
Compiler for C supports argument -Werror=empty-body: YES
Compiler for C supports argument -Werror=format=2: YES
Compiler for C supports argument -Werror=implicit: YES
Compiler for C supports argument -Werror=init-self: YES
Compiler for C supports argument -Werror=int-to-pointer-cast: YES
Compiler for C supports argument -Werror=main: YES
Compiler for C supports argument -Werror=missing-braces: YES
Compiler for C supports argument -Werror=nested-externs: YES
Compiler for C supports argument -Werror=nonnull: YES
Compiler for C supports argument -Werror=pointer-to-int-cast: YES
Compiler for C supports argument -Werror=return-type: YES
Compiler for C supports argument -Werror=sequence-point: YES
Compiler for C supports argument -Werror=trigraphs: YES
Compiler for C supports argument -Werror=undef: YES
Compiler for C supports argument -Werror=write-strings: YES
Compiler for C supports argument -fvisibility=hidden: YES
Configuring config.h using configuration
Program glib-mkenums found: YES (/usr/pkg/bin/glib-mkenums)
Configuring json-version.h using configuration
Program g-ir-scanner found: YES (/usr/pkg/bin/g-ir-scanner)
Program g-ir-scanner found: YES (/usr/pkg/bin/g-ir-scanner)
Program g-ir-compiler found: YES (/usr/pkg/bin/g-ir-compiler)
Native dependency gobject-introspection-1.0 found: YES 1.56.1
Build targets in project: 38
Found ninja-1.8.2 at /usr/pkg/bin/ninja
===> Building for json-glib-1.4.2
ninja -C output
ninja: Entering directory `output'
[68/69] Generating Json-1.0.gir with a custom command.
FAILED: json-glib/Json-1.0.gir
/usr/pkg/bin/g-ir-scanner -I/usr/pkg/include/gobject-introspection-1.0 -I/usr/pkg/include/glib/glib-2.0 -I/usr/pkg/lib/glib-2.0/include -I/usr/pkg/include -pthread --no-libtool --namespace=Json --nsversion=1.0 --warn-all --output json-glib/Json-1.0.gir --quiet --c-include=json-glib/json-glib.h -DJSON_COMPILATION -I/scratch/textproc/json-glib/work/json-glib-1.4.2/json-glib -I/scratch/textproc/json-glib/work/json-glib-1.4.2/output/json-glib -I./. -I../. --filelist=/scratch/textproc/json-glib/work/json-glib-1.4.2/output/json-glib/json-glib-1.0@sha/Json_1.0_gir_filelist --include=GObject-2.0 --include=Gio-2.0 --symbol-prefix=json --identifier-prefix=Json --pkg-export=json-glib-1.0 --cflags-begin -I./. -I../. -I/usr/pkg/include/glib/glib-2.0 -I/usr/pkg/lib/glib-2.0/include -I/usr/pkg/include -pthread --cflags-end -L/scratch/textproc/json-glib/work/json-glib-1.4.2/output/json-glib --extra-library=gobject-2.0 -L/usr/pkg/lib --extra-library=glib-2.0 --extra-library=intl --extra-library=gio-2.0 --library json-glib-1.0 ERROR: can't resolve libraries to shared libraries: json-glib-1.0
ninja: build stopped: subcommand failed.
*** Error code 1