conda-forge / gstreamer-feedstock

A conda-smithy repository for gstreamer.
BSD 3-Clause "New" or "Revised" License
9 stars 28 forks source link

trying to build on Windows #25

Closed tjwilli58 closed 5 years ago

tjwilli58 commented 5 years ago

Issue: I'm trying to modify the recipe to build gstreamer on Windows. I'm using the pattern done by @pkgw when he modified the recipe for pygobject.

When I try to build, it looks like the environment isn't set right, because %PYTHON% is empty,, but if I try conda debug the environments do define %PYTHON% and %BUILD_PREFIX%, and running conda_build.bat ALMOST finishes.


Environment (conda list):

$ conda list
conda list
# packages in environment at C:\Users\Tim\Miniconda3\envs\gstreamer_build:
#
# Name                    Version                   Build  Channel
certifi                   2018.11.29            py36_1000    conda-forge
pip                       19.0.3                   py36_0    conda-forge
python                    3.6.6                he025d50_0    conda-forge
setuptools                40.8.0                   py36_0    conda-forge
vc                        14                            0    conda-forge
vs2015_runtime            14.0.25420                    0    conda-forge
wheel                     0.33.1                   py36_0    conda-forge
wincertstore              0.2                   py36_1002    conda-forge


Details about conda and system ( conda info ):

$ conda info

     active environment : gstreamer_build
    active env location : C:\Users\Tim\Miniconda3\envs\gstreamer_build
            shell level : 2
       user config file : C:\Users\Tim\.condarc
 populated config files : C:\Users\Tim\.condarc
          conda version : 4.6.7
    conda-build version : 3.17.8
         python version : 3.6.6.final.0
       base environment : C:\Users\Tim\Miniconda3  (writable)
           channel URLs : https://conda.anaconda.org/conda-forge/win-64
                          https://conda.anaconda.org/conda-forge/noarch
                          https://repo.anaconda.com/pkgs/main/win-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/free/win-64
                          https://repo.anaconda.com/pkgs/free/noarch
                          https://repo.anaconda.com/pkgs/r/win-64
                          https://repo.anaconda.com/pkgs/r/noarch
                          https://repo.anaconda.com/pkgs/msys2/win-64
                          https://repo.anaconda.com/pkgs/msys2/noarch
          package cache : C:\Users\Tim\Miniconda3\pkgs
                          C:\Users\Tim\.conda\pkgs
                          C:\Users\Tim\AppData\Local\conda\conda\pkgs
       envs directories : C:\Users\Tim\Miniconda3\envs
                          C:\Users\Tim\.conda\envs
                          C:\Users\Tim\AppData\Local\conda\conda\envs
               platform : win-64
             user-agent : conda/4.6.7 requests/2.21.0 CPython/3.6.6 Windows/10 Windows/10.0.17763
          administrator : False
             netrc file : None
           offline mode : False

recipe.zip

end of conda build:

(gstreamer_build) %SRC_DIR%\forgebuild>%BUILD_PREFIX%\Scripts\meson --buildtype=release --prefix=C:/Users/Tim/Miniconda3/conda-bld/gstreamer_and_plugins_1550976615934/_h_env/Library --backend=ninja -Dcairo=true -Dpython= ..
'C:\Users\Tim\Miniconda3\conda-bld\gstreamer_and_plugins_1550976615934\_h_env\Scripts\meson' is not recognized as an internal or external command,
operable program or batch file.

(gstreamer_build) %SRC_DIR%\forgebuild>if errorlevel 1 exit 1
Traceback (most recent call last):
  File "C:\Users\Tim\Miniconda3\Scripts\conda-build-script.py", line 10, in <module>
    sys.exit(main())
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\cli\main_build.py", line 456, in main
    execute(sys.argv[1:])
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\cli\main_build.py", line 447, in execute
    verify=args.verify, variants=args.variants)
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\api.py", line 208, in build
    notest=notest, need_source_download=need_source_download, variants=variants)
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\build.py", line 2314, in build_tree
    notest=notest,
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\build.py", line 1444, in build
    windows.build(m, build_file, stats=build_stats, provision_only=provision_only)
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\windows.py", line 342, in build
    check_call_env(cmd, cwd=m.config.work_dir, stats=stats, rewrite_stdout_env=rewrite_env)
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\utils.py", line 374, in check_call_env
    return _func_defaulting_env_to_os_environ('call', *popenargs, **kwargs)
  File "C:\Users\Tim\Miniconda3\lib\site-packages\conda_build\utils.py", line 354, in _func_defaulting_env_to_os_environ
    raise subprocess.CalledProcessError(proc.returncode, _args)
subprocess.CalledProcessError: Command '['cmd.exe', '/c', 'conda_build.bat']' returned non-zero exit status 1.

End of conda debug

 93/104 pipelines_simple_launch_lines           OK       2.02 s
SUCCESS: The process with PID 62316 (child process of PID 5212) has been terminated.
 94/104 pipelines_parse_launch                  TIMEOUT 180.39 s
 95/104 pipelines_cleanup                       OK       0.52 s
 96/104 tools_gstinspect                        OK       0.55 s
 97/104 elements_fakesink                       OK      11.09 s
 98/104 gst_gstbin                              OK       4.51 s
 99/104 gst_gstbus                              OK      11.71 s
100/104 gst_gstevent                            OK       2.89 s
101/104 pipelines_stress                        OK      10.59 s
102/104 generic_sinks                           OK       4.51 s
103/104 gst_gstcpp                              OK       0.44 s
104/104 libs_gstlibscpp                         OK       0.46 s

Ok:                  101
Expected Fail:         0
Fail:                  3
Unexpected Pass:       0
Skipped:               0
Timeout:               3

The output from the failed tests:

 26/104 gst_gstpad                              TIMEOUT 180.52 s

--- command ---
GST_PLUGIN_PATH_1_0='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild' GST_REGISTRY='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\tests\check/gst_gstpad.registry' GST_STATE_IGNORE_ELEMENTS='' GST_PLUGIN_LOADING_WHITELIST='gstreamer' CK_DEFAULT_TIMEOUT='20' GST_PLUGIN_SCANNER_1_0='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\libs\gst\helpers/gst-plugin-scanner' GST_PLUGIN_SYSTEM_PATH_1_0='' C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\tests\check\gst_gstpad.exe
--- stdout ---
Running suite(s): GstPad
-------

 79/104 elements_fdsrc                          TIMEOUT 180.48 s

--- command ---
GST_PLUGIN_PATH_1_0='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild' GST_STATE_IGNORE_ELEMENTS='' GST_PLUGIN_LOADING_WHITELIST='gstreamer' CK_DEFAULT_TIMEOUT='20' GST_REGISTRY='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\tests\check/elements_fdsrc.registry' GST_PLUGIN_SCANNER_1_0='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\libs\gst\helpers/gst-plugin-scanner' GST_PLUGIN_SYSTEM_PATH_1_0='' C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\tests\check\elements_fdsrc.exe
--- stdout ---
Running suite(s): fdsrc
-------

 94/104 pipelines_parse_launch                  TIMEOUT 180.39 s

--- command ---
GST_PLUGIN_PATH_1_0='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild' GST_REGISTRY='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\tests\check/pipelines_parse_launch.registry' GST_STATE_IGNORE_ELEMENTS='' GST_PLUGIN_LOADING_WHITELIST='gstreamer' CK_DEFAULT_TIMEOUT='20' GST_PLUGIN_SCANNER_1_0='C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\libs\gst\helpers/gst-plugin-scanner' GST_PLUGIN_SYSTEM_PATH_1_0='' C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\tests\check\pipelines_parse_launch.exe
--- stdout ---
Running suite(s): Parse Launch syntax
-------

Full log written to C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild\meson-logs\testlog.txt
FAILED: meson-test
"C:\\Users\\Tim\\Miniconda3\\conda-bld\\debug_1550975756803\\_h_env\\python.exe" "-u" "C:\\Users\\Tim\\Miniconda3\\conda-bld\\debug_1550975756803\\_h_env\\Scripts\\meson" "test" "--no-rebuild" "--print-errorlogs"
ninja: build stopped: subcommand failed.

(C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\_build_env) C:\Users\Tim\Miniconda3\conda-bld\debug_1550975756803\work\forgebuild>if errorlevel 1 exit 1
pkgw commented 5 years ago

How about opening a pull request against this repo with your candidate changes? It's OK if the initial version isn't fully baked. That way all of the build logs and your recipe will be accessible in the cloud, so it should be easier to identify problems and work through them.

tjwilli58 commented 5 years ago

Wiil do. I got a little further since my post by adding python, meson, and glib to build requirements for the entire project. I then realized this morning that I should have a script for each output, instead of using bld.bat for the entire menu. (Haven't tried that yet though.)

tjwilli58 commented 5 years ago

submitted PR for this