After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 797274 - json-glib fails to build
json-glib fails to build
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: cerbero
git master
Other Windows
: Normal normal
: 1.15.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2018-10-11 01:12 UTC by Ray Tiley
Modified: 2018-10-11 14:28 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Ray Tiley 2018-10-11 01:12:10 UTC
Trying to compile gstreamer master on windows 10 and can't get past a failure in json-glib.

Here is the console output of the failure.

[(74/82) json-glib -> compile ]
Running command 'ninja -v'
[1/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=path" "--outdir=json-glib/tests" "--outfile=path.test"
[2/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=node" "--outdir=json-glib/tests" "--outfile=node.test"
[3/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=object" "--outdir=json-glib/tests" "--outfile=object.test"
[4/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=parser" "--outdir=json-glib/tests" "--outfile=parser.test"
[5/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=generator" "--outdir=json-glib/tests" "--outfile=generator.test"
[6/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=array" "--outdir=json-glib/tests" "--outfile=array.test"
[7/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=builder" "--outdir=json-glib/tests" "--outfile=builder.test"
[8/68] "c:/Python3/python.exe" "c:/code/cerbero/build/build-tools/Scripts/meson.py" "--internal" "exe" "c:/code/cerbero/build/sources/windows_x86_64/json-glib-1.4.4/_builddir/meson-private/meson_exe_python_1e3ca5497a7754eebd2f00cb4d4f0124bd5d2f0b.dat"
FAILED: json-glib/json-enum-types.h
"c:/Python3/python.exe" "c:/code/cerbero/build/build-tools/Scripts/meson.py" "--internal" "exe" "c:/code/cerbero/build/sources/windows_x86_64/json-glib-1.4.4/_builddir/meson-private/meson_exe_python_1e3ca5497a7754eebd2f00cb4d4f0124bd5d2f0b.dat"
Traceback (most recent call last):
  • File "c:/code/cerbero/build/build-tools/Scripts/meson.py", line 4 in <module>
    __import__('pkg_resources').run_script('meson==0.47.2', 'meson.py')
  • File "c:\Python3\lib\site-packages\pkg_resources\__init__.py", line 658 in run_script
    self.require(requires)[0].run_script(script_name, ns)
  • File "c:\Python3\lib\site-packages\pkg_resources\__init__.py", line 1438 in run_script
    exec(code, namespace, namespace)
  • File "c:\code\cerbero\build\build-tools\lib\site-packages\meson-0.47.2-py3.7.egg\EGG-INFO\scripts\meson.py", line 29 in <module>
    sys.exit(mesonmain.main())
  • File "c:\code\cerbero\build\build-tools\Lib\site-packages\meson-0.47.2-py3.7.egg\mesonbuild\mesonmain.py", line 379 in main
    return run(sys.argv[1:], launcher)
  • File "c:\code\cerbero\build\build-tools\Lib\site-packages\meson-0.47.2-py3.7.egg\mesonbuild\mesonmain.py", line 316 in run
    sys.exit(run_script_command(args[1:]))
  • File "c:\code\cerbero\build\build-tools\Lib\site-packages\meson-0.47.2-py3.7.egg\mesonbuild\mesonmain.py", line 232 in run_script_command
    return cmdfunc(cmdargs)
  • File "c:\code\cerbero\build\build-tools\Lib\site-packages\meson-0.47.2-py3.7.egg\mesonbuild\scripts\meson_exe.py", line 91 in run
    return run_exe(exe)
  • File "c:\code\cerbero\build\build-tools\Lib\site-packages\meson-0.47.2-py3.7.egg\mesonbuild\scripts\meson_exe.py", line 73 in run_exe
    stderr=subprocess.PIPE)
  • File "c:\Python3\lib\subprocess.py", line 756 in __init__
    restore_signals, start_new_session)
  • File "c:\Python3\lib\subprocess.py", line 1155 in _execute_child
    startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified
[9/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=boxed" "--outdir=json-glib/tests" "--outfile=boxed.test"
[10/68] "c:/Python3/python.exe" "../build-aux/gen-installed-test.py" "--testdir=c:/code/cerbero/build/dist/windows_x86_64/libexec/installed-tests/json-glib-1.0" "--testname=gvariant" "--outdir=json-glib/tests" "--outfile=gvariant.test"
ninja: build stopped: subcommand failed.

Recipe 'json-glib' failed at the build step 'compile'
Select an action to proceed:
[0] Enter the shell
[1] Rebuild the recipe from scratch
[2] Rebuild starting from the failed step
[3] Skip recipe
[4] Abort

Below is the meson log for json-glib

# Pastebin XuKc9WiV
Build started at 2018-10-09T16:36:45.388500
Main binary: c:\Python3\python.exe
Python system: Windows
The Meson build system
Version: 0.47.2
Source dir: c:\code\cerbero\build\sources\windows_x86_64\json-glib-1.4.4
Build dir: c:\code\cerbero\build\sources\windows_x86_64\json-glib-1.4.4\_builddir
Build type: native build
Project name: json-glib
Project version: 1.4.4
Sanity testing C compiler: cl
Is cross compiler: False.
Sanity check compiler command line: cl c:\code\cerbero\build\sources\windows_x86_64\json-glib-1.4.4\_builddir\meson-private\sanitycheckc.c /Fec:\code\cerbero\build\sources\windows_x86_64\json-glib-1.4.4\_builddir\meson-private\sanitycheckc.exe
Sanity check compile stdout:
sanitycheckc.c
Microsoft (R) Incremental Linker Version 14.10.25027.0
Copyright (C) Microsoft Corporation.  All rights reserved.

/out:c:\code\cerbero\build\sources\windows_x86_64\json-glib-1.4.4\_builddir\meson-private\sanitycheckc.exe 
sanitycheckc.obj 

-----
Sanity check compile stderr:
Microsoft (R) C/C++ Optimizing Compiler Version 19.10.25027 for x64
Copyright (C) Microsoft Corporation.  All rights reserved.


-----
Running test binary command: c:\code\cerbero\build\sources\windows_x86_64\json-glib-1.4.4\_builddir\meson-private\sanitycheckc.exe
Native C compiler: cl (msvc 19.10.25027)
Build machine cpu family: x86_64
Build machine cpu: x86_64
Found pkg-config: c:/code/cerbero/build/build-tools/bin/pkg-config.exe (0.29.2)
Determining dependency 'gobject-2.0' with pkg-config executable 'c:/code/cerbero/build/build-tools/bin/pkg-config.exe'
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe --modversion gobject-2.0` -> 0
2.56.1
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe --cflags gobject-2.0` -> 0
-Ic:/code/cerbero/build/dist/windows_x86_64/lib/libffi-3.99999/include -Ic:/code/cerbero/build/dist/windows_x86_64/include/glib-2.0 -Ic:/code/cerbero/build/dist/windows_x86_64/lib/glib-2.0/include
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe gobject-2.0 --libs` -> 0
-Lc:/code/cerbero/build/dist/windows_x86_64/lib -lgobject-2.0 -lglib-2.0 -lintl
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe gobject-2.0 --libs` -> 0
-Lc:/code/cerbero/build/dist/windows_x86_64/lib -lgobject-2.0 -lglib-2.0 -lintl
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpalqlw04_
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpalqlw04_\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpalqlw04_\output.obj /Od --print-search-dirs 

Code:
 
Compiler stdout:
 testfile.c

Compiler stderr:
 cl : Command line warning D9002 : ignoring unknown option '--print-search-dirs'

Native dependency gobject-2.0 found: YES 2.56.1
Determining dependency 'gio-2.0' with pkg-config executable 'c:/code/cerbero/build/build-tools/bin/pkg-config.exe'
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe --modversion gio-2.0` -> 0
2.56.1
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe --cflags gio-2.0` -> 0
-Ic:/code/cerbero/build/dist/windows_x86_64/lib/libffi-3.99999/include -Ic:/code/cerbero/build/dist/windows_x86_64/include/glib-2.0 -Ic:/code/cerbero/build/dist/windows_x86_64/lib/glib-2.0/include
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe gio-2.0 --libs` -> 0
-Lc:/code/cerbero/build/dist/windows_x86_64/lib -lgio-2.0 -lgobject-2.0 -lglib-2.0 -lintl
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe gio-2.0 --libs` -> 0
-Lc:/code/cerbero/build/dist/windows_x86_64/lib -lgio-2.0 -lgobject-2.0 -lglib-2.0 -lintl
Native dependency gio-2.0 found: YES 2.56.1
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmp77ftitrz
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmp77ftitrz\testfile.c /nologo /showIncludes /EP /Od kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib 

Code:
 
        #ifdef __has_include
         #if !__has_include("unistd.h")
          #error "Header 'unistd.h' could not be found"
         #endif
        #else
         #include <unistd.h>
        #endif
Compiler stdout:
 

        




         
Compiler stderr:
 cl : Command line warning D9027 : source file 'kernel32.lib' ignored
cl : Command line warning D9027 : source file 'user32.lib' ignored
cl : Command line warning D9027 : source file 'gdi32.lib' ignored
cl : Command line warning D9027 : source file 'winspool.lib' ignored
cl : Command line warning D9027 : source file 'shell32.lib' ignored
cl : Command line warning D9027 : source file 'ole32.lib' ignored
cl : Command line warning D9027 : source file 'oleaut32.lib' ignored
cl : Command line warning D9027 : source file 'uuid.lib' ignored
cl : Command line warning D9027 : source file 'comdlg32.lib' ignored
cl : Command line warning D9027 : source file 'advapi32.lib' ignored
testfile.c
C:\Users\ADMINI~1\AppData\Local\Temp\tmp77ftitrz\testfile.c(7): fatal error C1083: Cannot open include file: 'unistd.h': No such file or directory

Has header "unistd.h": NO
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpf762ja7o
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpf762ja7o\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpf762ja7o\output.obj /Od -we4002 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4002: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpvcq0croi
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpvcq0croi\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpvcq0croi\output.obj /Od -we4003 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4003: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpgm8yrgbr
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpgm8yrgbr\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpgm8yrgbr\output.obj /Od -w14010 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -w14010: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpw4za824_
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpw4za824_\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpw4za824_\output.obj /Od -we4013 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4013: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmp0va_nesn
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmp0va_nesn\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmp0va_nesn\output.obj /Od -w14016 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -w14016: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmprehnsxfx
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmprehnsxfx\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmprehnsxfx\output.obj /Od -we4020 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4020: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmp2z8jnpqt
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmp2z8jnpqt\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmp2z8jnpqt\output.obj /Od -we4021 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4021: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmp838tan2f
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmp838tan2f\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmp838tan2f\output.obj /Od -we4027 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4027: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpss_ibbkr
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpss_ibbkr\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpss_ibbkr\output.obj /Od -we4029 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4029: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpa16kiwdx
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpa16kiwdx\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpa16kiwdx\output.obj /Od -we4033 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4033: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpzoqs64eh
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpzoqs64eh\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpzoqs64eh\output.obj /Od -we4035 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4035: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmppg565_a9
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmppg565_a9\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmppg565_a9\output.obj /Od -we4045 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4045: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmp5rf6isbs
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmp5rf6isbs\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmp5rf6isbs\output.obj /Od -we4047 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4047: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmp9a7w33h6
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmp9a7w33h6\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmp9a7w33h6\output.obj /Od -we4049 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4049: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpxlhvb8ah
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpxlhvb8ah\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpxlhvb8ah\output.obj /Od -we4053 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4053: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpwib0uvvh
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpwib0uvvh\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpwib0uvvh\output.obj /Od -we4071 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4071: YES
Running compile:
Working directory:  C:\Users\ADMINI~1\AppData\Local\Temp\tmpp0kyji9g
Command line:  cl C:\Users\ADMINI~1\AppData\Local\Temp\tmpp0kyji9g\testfile.c /nologo /showIncludes /c /FoC:\Users\ADMINI~1\AppData\Local\Temp\tmpp0kyji9g\output.obj /Od -we4819 

Code:
 int i;

Compiler stdout:
 testfile.c

Compiler stderr:
 
Compiler for C supports arguments -we4819: YES
Configuring config.h using configuration
Configuring json-version.h using configuration
WARNING: Project targetting '>= 0.40.1' but tried to use feature introduced in '0.46.0': both_libraries
Program g-ir-scanner found: NO
Adding test "array"
Adding test "boxed"
Adding test "builder"
Adding test "generator"
Adding test "gvariant"
Adding test "invalid"
Adding test "node"
Adding test "object"
Adding test "parser"
Adding test "path"
Adding test "reader"
Adding test "serialize-simple"
Adding test "serialize-complex"
Adding test "serialize-full"
Configuring gtkdocentities.ent using configuration
Determining dependency 'glib-2.0' with pkg-config executable 'c:/code/cerbero/build/build-tools/bin/pkg-config.exe'
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe --modversion glib-2.0` -> 0
2.56.1
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe --cflags glib-2.0` -> 0
-Ic:/code/cerbero/build/dist/windows_x86_64/include/glib-2.0 -Ic:/code/cerbero/build/dist/windows_x86_64/lib/glib-2.0/include
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe glib-2.0 --libs` -> 0
-Lc:/code/cerbero/build/dist/windows_x86_64/lib -lglib-2.0 -lintl
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe glib-2.0 --libs` -> 0
-Lc:/code/cerbero/build/dist/windows_x86_64/lib -lglib-2.0 -lintl
Native dependency glib-2.0 found: YES 2.56.1
Called `c:/code/cerbero/build/build-tools/bin/pkg-config.exe --variable=prefix glib-2.0` -> 0
c:/code/cerbero/build/dist/windows_x86_64
Got pkgconfig variable prefix : c:/code/cerbero/build/dist/windows_x86_64
Program xsltproc found: NO
Build targets in project: 37
WARNING: Project specifies a minimum meson_version '>= 0.40.1' but uses features which were added in newer versions:
 * 0.46.0: {'both_libraries'}
Option buildtype is: debug [default: debugoptimized]
Found ninja-1.8.2 at 'c:\code\cerbero\build\build-tools\bin\ninja.EXE'
Comment 1 Nirbheek Chauhan 2018-10-11 14:28:00 UTC
Fixed with:

commit 57ee182e00d1cbf147c1d85c55122dc71cba5859
Author: Nirbheek Chauhan <nirbheek@centricular.com>
Date:   Thu Oct 11 19:47:10 2018 +0530

    cerbero: Properly fetch the value of PATH from MSVC

    We were accidentally using the full value of PATH set in the VS command
    prompt as the PATH value that contains Visual Studio paths. Only
    a subset of that value contains Visual Studio paths.

    As a part of this, now the rest of the code prepends PATH fetched from
    VS to the existing PATH value and uses the other env vars as-is by
    overwriting.

Thanks for reporting!