Giter Site home page Giter Site logo

cefsharpdockerfiles's People

Contributors

alfred-reynolds avatar mitchcapper avatar perlun avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

cefsharpdockerfiles's Issues

consistent nuget restore error in cefsharp_set_versions_and_restore.ps1

Many thanks for providing this repo.
I have successfully used it to build CefSharp 83 12 months ago.

However now I am consistently getting the following error when building via azure. I am using recommended Standard_F32s_v2 (Windows Server 1903)

Step 18/21 : RUN ./cefsharp_set_versions_and_restore.ps1
 ---> Running in 369e6974d2e3

SUCCESS: Specified value was saved.
doing C:\code\cefsharp\CefSharp\CefSharp.csproj
doing C:\code\cefsharp\CefSharp\CefSharp.netcore.csproj
doing C:\code\cefsharp\CefSharp.Core\CefSharp.Core.csproj
doing C:\code\cefsharp\CefSharp.Core\CefSharp.Core.netcore.csproj
doing C:\code\cefsharp\CefSharp.Example\CefSharp.Example.csproj
doing C:\code\cefsharp\CefSharp.Example\CefSharp.Example.netcore.csproj
doing C:\code\cefsharp\CefSharp.OffScreen\CefSharp.OffScreen.csproj
doing C:\code\cefsharp\CefSharp.OffScreen\CefSharp.OffScreen.netcore.csproj
doing C:\code\cefsharp\CefSharp.OffScreen.Example\CefSharp.OffScreen.Example.csproj
Updated C:\code\cefsharp\CefSharp.OffScreen.Example\CefSharp.OffScreen.Example.csproj
doing C:\code\cefsharp\CefSharp.OffScreen.Example\CefSharp.OffScreen.Example.netcore.csproj
doing C:\code\cefsharp\CefSharp.Test\CefSharp.Test.csproj
Updated C:\code\cefsharp\CefSharp.Test\CefSharp.Test.csproj
doing C:\code\cefsharp\CefSharp.Test\CefSharp.Test.netcore.csproj
doing C:\code\cefsharp\CefSharp.WinForms\CefSharp.WinForms.csproj
doing C:\code\cefsharp\CefSharp.WinForms\CefSharp.WinForms.netcore.csproj
doing C:\code\cefsharp\CefSharp.WinForms.Example\CefSharp.WinForms.Example.csproj
Updated C:\code\cefsharp\CefSharp.WinForms.Example\CefSharp.WinForms.Example.csproj
doing C:\code\cefsharp\CefSharp.WinForms.Example\CefSharp.WinForms.Example.netcore.csproj
doing C:\code\cefsharp\CefSharp.Wpf\CefSharp.Wpf.csproj
doing C:\code\cefsharp\CefSharp.Wpf\CefSharp.Wpf.netcore.csproj
doing C:\code\cefsharp\CefSharp.Wpf.Example\CefSharp.Wpf.Example.csproj
Updated C:\code\cefsharp\CefSharp.Wpf.Example\CefSharp.Wpf.Example.csproj
doing C:\code\cefsharp\CefSharp.Wpf.Example\CefSharp.Wpf.Example.netcore.csproj
restore failed running 'C:\code\cefsharp\.\nuget\NuGet.exe restore -source
"C:/code/cef-binary/cef-binary-master/NuGet" -FallbackSource
https://api.nuget.org/v3/index.json CefSharp3.sln' with exit code 0x1
At C:\code\cefsharp\cefsharp_set_versions_and_restore.ps1:98 char:2
+     throw ("restore failed running '$nuget $args' with exit code 0x$r ...
+     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OperationStopped: (restore failed ...h exit code
    0x1:String) [], RuntimeException
    + FullyQualifiedErrorId : restore failed running 'C:\code\cefsharp\.\nuget
   \NuGet.exe restore -source "C:/code/cef-binary/cef-binary-master/NuGet" -F
  allbackSource https://api.nuget.org/v3/index.json CefSharp3.sln' with exit
  code 0x1

The command 'powershell -Command $ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue'; ./cefsharp_set_versions_and_restore.ps1' returned a non-zero code: 1
Caught an exception: Process docker build --memory=30g --build-arg CEFSHARP_BRANCH="cefsharp/93" --build-arg CEFSHARP_VERSION="93.1.140" --build-arg CEF_VERSION_STR="auto" --build-arg CHROME_BRANCH="4577" -f Dockerfile_cefsharp -t cefsharp . exited with non zero code: 1 aborting!
        Exception Type: System.Management.Automation.RuntimeException
        Stack Trace: at RunProc, C:\CefSharpDockerfiles\functions.ps1: line 82
        at <ScriptBlock>, C:\CefSharpDockerfiles\build.ps1: line 96
        at <ScriptBlock>, <No file>: line 1

from az_create.ps1

[CmdletBinding()]
Param(
	[Parameter(Mandatory=$true)]
	[PSCredential] $admin_creds,
	[String] $shutdown_email,
	[String] $RESOURCE_GROUP="CEFTest",
	[String] $LOCATION="West Europe",
	[String] $MACHINE_SIZE="Standard_F32s_v2",
	[String] $SHUTDOWN_TIME="04:30",
	[String] $RANDOM_STR=""
)
...

from versions_src.ps1

$VAR_CHROME_BRANCH="4606";
$VAR_CEFSHARP_VERSION="94.4.110";
$VAR_CEFSHARP_BRANCH="cefsharp/94";
$VAR_BASE_DOCKER_FILE="mcr.microsoft.com/windows/servercore:1903-amd64";#mcr.microsoft.com/windows/servercore:1903-amd64
$VAR_DUAL_BUILD="0"; #set to 1 to build all arches together, mainly to speed up linking which is single threaded, note may need excess ram.
$VAR_BUILD_ARCHES="x86 x64";
$VAR_GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome";
$VAR_CEF_BUILD_MOUNT_VOL_NAME=""; #force using this volume for building, allows resuming MUST BE LOWER CASE
$VAR_GN_ARGUMENTS="--ide=vs2019 --sln=cef --filters=//cef/*";
$VAR_GYP_DEFINES="";
$VAR_CEF_BUILD_ONLY=$false;#Only build CEF do not build cefsharp or the cef-binary.
$VAR_CEF_USE_BINARY_PATH=""; #If you want to use existing CEF binaries point this to a local folder where the cef_binary*.zip files are. It will skip the long CEF build step then but still must make the VS container for the cefsharp building.  Note will copy a dockerfile into this folder.
$VAR_REMOVE_VOLUME_ON_SUCCESSFUL_BUILD=$true;
$VAR_CEF_BINARY_EXT="zip"; #Can be zip,tar.bz2, 7z Generally do not change this off of Zip unless you are supplying your own binaries using $VAR_CEF_USE_BINARY_PATH above, and they have a different extension, will try to work with the other formats however
$VAR_CEF_SAVE_SOURCES="0"; #normally sources are deleted before finishing the CEF build step.  Set to 1 to create a /code/sources.zip archive that has them (note it is left in docker image, must use docker cp to copy it out, it is also around 30GB).
$VAR_CEF_VERSION_STR="auto"; #can set to "3.3239.1723" or similar if you have multiple binaries that Docker_cefsharp might find
$VAR_HYPERV_MEMORY_ADD="--memory=30g"; #only matters if using HyperV, Note your swap file alone must be this big or able to grow to be this big, 30G is fairly safe for single build will need 60G for dual build.

I have tried running build 5 times and each time it fails on the above step.
It gives the same error when trying CefSharp 93
It looks like CEF is successfully built.

I have attached a fuller log which includes a larger tail of logging.
cefsharp_error.txt

Caught an exception: Process docker run --memory=30g -v cefbuild_lcwgb:C:/code/chromium_git --name c_cefbuild_lcwgb_tmp cef_build_env exited with non zero code: 1 aborting!

Hello all. My first attempt to do the Docker build method and the build process seemed to be going smooth for a while so I stepped away. Upon return to check status I got the below error. Not sure what it means or is related to. I'm hoping for some guidance.

My goal is to build CefSharp for WinForms with the proprietary_codecs=true option set so the browser can goto YouTube and be able to play videos there.

Traceback (most recent call last):
  File "../../build/toolchain/win/tool_wrapper.py", line 31, in <module>
    import win32file    # pylint: disable=import-error
ImportError: No module named win32file
[30/34435] CXX obj/third_party/protobuf/protobuf_full/error_listener.obj
[31/34435] CXX obj/third_party/protobuf/protobuf_full/zero_copy_stream_impl.obj
[32/34435] CXX obj/third_party/protobuf/protobuf_full/coded_stream.obj
[33/34435] CXX obj/third_party/protobuf/protobuf_full/io_win32.obj
[34/34435] CXX obj/third_party/protobuf/protobuf_full/text_format.obj
ninja: build stopped: subcommand failed.
x64 build failed with 1
At C:\code\cef_build.ps1:101 char:2
+     throw "x64 build failed with $($px64.ExitCode)";
+     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OperationStopped: (x64 build failed with 1:Strin
   g) [], RuntimeException
    + FullyQualifiedErrorId : x64 build failed with 1

Caught an exception: Process docker run --memory=30g -v cefbuild_lcwgb:C:/code/chromium_git --name c_cefbuild_lcwgb_tmp cef_build_env exited with non zero code: 1 aborting!
        Exception Type: System.Management.Automation.RuntimeException
        Stack Trace: at RunProc, C:\CefSharpDockerfiles\functions.ps1: line 82
        at <ScriptBlock>, C:\CefSharpDockerfiles\build.ps1: line 85
        at <ScriptBlock>, <No file>: line 1

My version.ps1 used

$VAR_CHROME_BRANCH="3770";
$VAR_CEFSHARP_VERSION="79.1.360";
$VAR_CEFSHARP_BRANCH="cefsharp/79";
$VAR_BASE_DOCKER_FILE="mcr.microsoft.com/windows/servercore:1903-amd64";#mcr.microsoft.com/windows/servercore:1809-amd64
$VAR_DUAL_BUILD="0"; #set to 1 to build x86 and x64 together, mainly to speed up linking which is single threaded, note may need excess ram.
$VAR_GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome";$VAR_DUAL_BUILD="0";
$VAR_CEF_BUILD_MOUNT_VOL_NAME=""; #force using this volume for building, allows resuming MUST BE LOWER CASE
$VAR_GN_ARGUMENTS="--ide=vs2019 --sln=cef --filters=//cef/*";
$VAR_GYP_DEFINES="";
$VAR_CEF_BUILD_ONLY=$false;#Only build CEF do not build cefsharp or the cef-binary.
$VAR_CEF_USE_BINARY_PATH=""; #If you want to use existing CEF binaries point this to a local folder where the cef_binary*.zip files are. It will skip the long CEF build step then but still must make the VS container for the cefsharp building.  Note will copy a dockerfile into this folder.
$VAR_REMOVE_VOLUME_ON_SUCCESSFUL_BUILD=$true;
$VAR_CEF_BINARY_EXT="zip"; #Can be zip,tar.bz2, 7z Generally do not change this off of Zip unless you are supplying your own binaries using $VAR_CEF_USE_BINARY_PATH above, and they have a different extension, will try to work with the other formats however
$VAR_CEF_SAVE_SOURCES="0"; #normally sources are deleted before finishing the CEF build step.  Set to 1 to create a /code/sources.zip archive that has them (note it is left in docker image, must use docker cp to copy it out, it is also around 30GB).
$VAR_CEF_VERSION_STR="auto"; #can set to "3.3239.1723" or similar if you have multiple binaries that Docker_cefsharp might find
$VAR_HYPERV_MEMORY_ADD="--memory=30g"; #only matters if using HyperV, Note your swap file alone must be this big or able to grow to be this big, 30G is fairly safe for single build will need 60G for dual build.
if ($false){ #Sample 65 overrides
	$VAR_CHROME_BRANCH="3770";
	$VAR_CEFSHARP_VERSION="79.1.360";
	$VAR_CEFSHARP_BRANCH="master";
}

Thank you!

Error while building latest versions

I've succesfully built version 63 of CefSharp 6 months ago, but I can't get it to work with any recent versions (tried 67, 69 and now 71). I've seen all kinds of errors on different VMs (Windows server 1709, 1803, 1809 and Windows 10 with HyperV) on AWS as well as Azure.

This is the most common error after ~2 hours in both win10 and server 2016: https://pastebin.com/Vbk5fC2k
versions.ps1: https://pastebin.com/CCh9AP5p (I've seen it called versions.ps1, version.ps1 and version_src.ps1, so they all exist and are the same)
docker config of my latest win10 build: https://pastebin.com/qZ5UQQvv

Windows Defender and UAC are disabled. I don't think there were any errors until after applying patches to cef(?).

Compiling CefSharp failed with Spotify automated builds

First of all, cudos for a great idea: I went through compiling CEF Source manually the last week, and it took me a long time to get the environment and the GN Defines right. Mainly setting up VS 2017 with the right SDK and Toolchain took a long time.

Today I tried to compile CefSharp v67.0.0 against precompiled standard builds of CEF 3.3396 and run into an error:
Error report:

Running: docker build --memory=30g -f Dockerfile_cef_create_from_binaries -t cef . in G:\CEFBinaries
10/29/2018 21:42:39 CEF Build took 1.6 secs
Running: docker build --memory=30g --build-arg BINARY_EXT="zip" -f Dockerfile_cef_binary -t cef_binary . in G:\CefSharpDockerfiles
Process docker build --memory=30g --build-arg BINARY_EXT="zip" -f Dockerfile_cef_binary -t cef_binary . exited with non zero code: 1 aborting!
At G:\CefSharpDockerfiles\functions.ps1:40 char:9
+         throw "Process $proc $opts exited with non zero code: $($p.Ex ...
+         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OperationStopped: (Process docker ...de: 1 aborting!:String) [], RuntimeException
    + FullyQualifiedErrorId : Process docker build --memory=30g --build-arg BINARY_EXT="zip" -f Dockerfile_cef_binary -t cef_binary . exited with non zero code: 1 abort 
   ing!

Versions.ps1:

$VAR_CHROME_BRANCH="3396";
$VAR_CEFSHARP_VERSION="67.0.90";
$VAR_CEFSHARP_BRANCH="cefsharp/67";
$VAR_BASE_DOCKER_FILE="microsoft/dotnet-framework:4.7.2-runtime-windowsservercore-1803"; #microsoft/dotnet-framework:4.7.1-windowsservercore-1709
$VAR_DUAL_BUILD="0"; #set to 1 to build x86 and x64 together, mainly to speed up linking which is single threaded, note may need excess ram.
$VAR_GN_DEFINES="";
$VAR_GYP_DEFINES="";
$VAR_CEF_BUILD_ONLY=$false;#Only build CEF do not build cefsharp or the cef-binary.
$VAR_CEF_USE_BINARY_PATH=".\..\CEFBinaries\"; #If you want to use existing CEF binaries point this to a local folder where the cef_binary*.zip files are. It will skip the long CEF build step then but still must make the VS container for the cefsharp building.  Note will copy a dockerfile into this folder.
$VAR_CEF_BINARY_EXT="zip"; #Do not change this off of Zip unless you are supplying your own binaries using $VAR_CEF_USE_BINARY_PATH above, and they have a different extension
$VAR_CEF_VERSION_STR="auto"; #can set to "3.3239.1723" or similar if you have multiple binaries that Docker_cefsharp might find
$VAR_HYPERV_MEMORY_ADD="--memory=30g"; #only matters if using HyperV, Note your swap file alone must be this big or able to grow to be this big, 30G is fairly safe for single build will need 60G for dual build.
if ($false){ #Sample 65 overrides
	$VAR_CHROME_BRANCH="3325";
	$VAR_CEFSHARP_VERSION="65.0.90";
	$VAR_CEFSHARP_BRANCH="master";

Docker settings:

{
  "registry-mirrors": [],
  "insecure-registries": [],
  "debug": true,
  "experimental": false,
  "data-root": "g:/docker",
  "storage-opts": [
    "size=250G"
  ]
}

Spotify standard build CEF Binaries in the G:\CEFBinaries folder :

cef_binary_3.3396.1785.ga27bbfa_windows64.zip
cef_binary_3.3396.1786.gd3e36d0_windows32.zip

I'd be grateful for suggestions what went wrong
Pete

Windows 11

Which base docker image can be used with process isolation and windows 11? Currently that is what I am running.

Build failed "Not able to find win32 file as expected"

Hi there,
I successfully build cefsharp 67 without any issue with these settings :
$VAR_CHROME_BRANCH="3396";
$VAR_CEFSHARP_VERSION="67.0.90";
$VAR_CEFSHARP_BRANCH="cefsharp/67";
$VAR_BASE_DOCKER_FILE="mcr.microsoft.com/dotnet/framework/runtime:4.7.2-windowsservercore-ltsc2016";
$VAR_DUAL_BUILD="0";
$VAR_GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome";
$VAR_GYP_DEFINES="";
$VAR_CEF_BUILD_ONLY=$false;
$VAR_CEF_USE_BINARY_PATH="";
$VAR_CEF_BINARY_EXT="zip";
$VAR_CEF_SAVE_SOURCES="0";
$VAR_CEF_VERSION_STR="auto";
$VAR_HYPERV_MEMORY_ADD="--memory=30g";

Now I try to build v 73 but it fails almost at the end :
Creating zip archive for cef_binary_73.1.13+g6e3c989+chromium-73.0.3683.75_windows64...
Creating zip archive for cef_binary_73.1.13+g6e3c989+chromium-73.0.3683.75_windows64_release_symbols...
Not able to find win32 file as expected
At C:\code\cef_build.ps1:87 char:2

  • throw "Not able to find win32 file as expected";
    
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : OperationStopped: (Not able to find win32 file a
      s expected:String) [], RuntimeException
    • FullyQualifiedErrorId : Not able to find win32 file as expected

The command 'powershell -Command $ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue'; c:/code/cef_bu
ild.ps1' returned a non-zero code: 1
Caught an exception: Process docker build --memory=30g --build-arg CEF_SAVE_SOURCES="0" --build-arg BINARY_EXT="zip" --bui
ld-arg DUAL_BUILD="0" --build-arg GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome" --bui
ld-arg GYP_DEFINES="" --build-arg CHROME_BRANCH="3683" -f Dockerfile_cef -t cef . exited with non zero code: 1 aborting!
Exception Type: System.Management.Automation.RuntimeException
Stack Trace: at RunProc, D:\CefSharpDockerfiles-master\functions.ps1: line 82
at , D:\CefSharpDockerfiles-master\build.ps1: line 71
at , : line 1

Here is my versions.ps1 :
$VAR_CHROME_BRANCH="3683";
$VAR_CEFSHARP_VERSION="73.1.130";
$VAR_CEFSHARP_BRANCH="cefsharp/73";

$VAR_BASE_DOCKER_FILE="mcr.microsoft.com/dotnet/framework/runtime:4.7.2-windowsservercore-ltsc2016";
$VAR_DUAL_BUILD="0";
$VAR_GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome";
$VAR_GYP_DEFINES="";
$VAR_CEF_BUILD_ONLY=$false;
$VAR_CEF_USE_BINARY_PATH="";
$VAR_CEF_BINARY_EXT="zip";
$VAR_CEF_SAVE_SOURCES="0";
$VAR_CEF_VERSION_STR="auto";
$VAR_HYPERV_MEMORY_ADD="--memory=30g";

Include "proprietary" audio codec flags

Include the audio codec flags so that the build will include the "proprietary" audio codecs - or at least make it an easy set option.

Additionally - who is the contact to get it licensed and how do we convince them to stop being stingy about it given how universal these codecs are in this current millenia?

In branch 3370+codecs need to install pywin32

First, your repo is awesome and helped me build cef with codecs successfully.

Problem

When trying to build with the following changes in versions.ps1:

$VAR_CHROME_BRANCH="3770"; 
$VAR_CEFSHARP_VERSION="75.1.143"; 
$VAR_CEFSHARP_BRANCH="cefsharp/75";
$VAR_GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome";
$VAR_GYP_DEFINES="target_arch=x64";

The build failed with this error:
python ImportError: No module named win32file

Possible solution

my solution was to add

RunProc -proc "c:/code/depot_tools/python.bat" -opts "-m pip install pywin32";

before the following line:
cef_build.ps1#L27.

After this, the cef build worked. Hope this will help and Thank you again!

Build fails immediately due to git changes

Hey there!

I tried running build.ps1 and it instantly failed after setting up the container with an error about uncommitted git changes in the tools repo.

I can't get a log atm since I'm out and busy but I'll try to grab it later.

Building locally on windows 11.

Thanks,
Jammerxd

Latest versions

Hey there!

Where can we find the list of the most current versions of CHROME_BRANCH and CEFSHARP_VERSION and CEFSHARP_BRANCH?

Currently Chromium is up to 108.0.5307.1 and CefSharp is up to 105.3.330.

What do we need to set in versions_src.ps1 to build on those versions?

hcsshim::ImportLayer - failed failed in Win32: The system cannot find the path specified. (0x3)

First of all, thank you for your effort.
I can see that amazing work has been done here.
Unfortunately, I'm not lucky to successfully build any version neither in Win 10 pro nor via Azure service.
I'm totally new to docker though.
Below I tried to follow the Azure auto deployment scripts as described to build CefSharp with h264 support.

How to reproduce:

  • Just follow the #Azure Auto Create Scripts
  • I had to run build.ps1 with -NoVS2019PatchCopy flag as sample_patches\cef_patch_find_vs2019_tools.diff is not found in the repo
  • Attached powershell console output is trying to compile CEF 81 version
  • I've attached all the files that I have modified in order to run:
  1. versions.ps1 changed rows:
$VAR_CHROME_BRANCH="4044";
$VAR_CEFSHARP_VERSION="81.0.90";
$VAR_CEFSHARP_BRANCH="cefsharp/81";
$VAR_BASE_DOCKER_FILE="mcr.microsoft.com/windows/servercore:1903-amd64";
  1. daemon.json changed rows:
    "data-root": "C:/docker_data"

  2. az_create.ps1
    changed rows:
    [String] $MACHINE_SIZE="Standard_F8s_v2",

Error:
hcsshim::ImportLayer - failed failed in Win32: The system cannot find the path specified. (0x3)
see PowerShellConsoleOutput

error: pathspec 'origin/3370' did not match any file(s) known to git

Thank you for sharing amazing build scripts!

It seems that 3370 branch is not found in Chromium repo for some reasons.

PS C:\build-cefsharp>> .\build.ps1
Warning when running this build command in a remote powershell session you will not see realtime output generated by commands run.  This is due to a limitation in remote powershell.  You can work around this by running the build.ps1 using remote desktop instead.  In general it is only helpful to see the output if there is an error.  The stdout and stderr will be captured and printed for remote sessions but only after a command finishes.

Confirm
Warning linking may take around 27 during linking.  Your machine may not have enough memory, make sure your page files
are working and can grow to allow it. (Disable this warning with -NoMemoryWarn flag). Do you want to proceed?
[Y] Yes  [N] No  [S] Suspend  [?] Help (default is "Y"):
11/25/2019 00:54:02 Starting took 2.6 secs
Running: docker pull mcr.microsoft.com/windows/servercore:1809-amd64 in C:\build-cefsharp
1809-amd64: Pulling from windows/servercore
Digest: sha256:64385c3c59e4c85862306505d486467d2e150174f21be373d5aab4c616a1dc72
Status: Image is up to date for mcr.microsoft.com/windows/servercore:1809-amd64
mcr.microsoft.com/windows/servercore:1809-amd64
11/25/2019 00:54:03 Pull base file took 0.4 secs
Running: docker build --memory=30g --build-arg BASE_DOCKER_FILE="mcr.microsoft.com/windows/servercore:1809-amd64" -f Dockerfile_vs -t vs . in C:\build-cefsharp
Sending build context to Docker daemon  112.6kB
Step 1/14 : FROM mcr.microsoft.com/windows/servercore:1809-amd64
 ---> 733821d00bd5
Step 2/14 : SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
 ---> Running in 9b4f1e1bfe0d
Removing intermediate container 9b4f1e1bfe0d
Step 3/14 : RUN mkdir c:\code\automate;mkdir c:\temp\;mkdir c:\code\depot_tools;
 ---> cf34ff90bc40
 ---> Running in f9a3fa441ac7
    Directory: C:\code
Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----       11/25/2019  12:54 AM                automate
    Directory: C:\
Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----       11/25/2019  12:54 AM                temp
    Directory: C:\code
Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----       11/25/2019  12:54 AM                depot_tools
Removing intermediate container f9a3fa441ac7
 ---> 2e9ff028d856
Step 4/14 : RUN Invoke-WebRequest 'https://aka.ms/vscollect.exe' -OutFile 'C:\TEMP\collect.exe';
 ---> Running in b3955bdeaafc
Removing intermediate container b3955bdeaafc
Step 5/14 : RUN Invoke-WebRequest 'https://dist.nuget.org/win-x86-commandline/v4.1.0/nuget.exe' -OutFile 'c:\code\depot_tools\;';
 ---> fde527a8c809
 ---> Running in f438273d5d4c
Removing intermediate container f438273d5d4c
 ---> cf4f80481d85
Step 6/14 : RUN Invoke-WebRequest 'https://www.7-zip.org/a/7z1801-x64.msi' -OutFile '/code/7zip.msi';
 ---> Running in 1dc4b4f81415
Removing intermediate container 1dc4b4f81415
 ---> c3ad3b125893
Step 7/14 : RUN Start-Process msiexec.exe -Wait -ArgumentList '/i c:\code\7zip.msi /quiet /norestart /L*v install.log'
 ---> Running in d68335f4522e
Removing intermediate container d68335f4522e
 ---> 4d03751f4969
Step 8/14 : WORKDIR "Program Files"
 ---> Running in f4ab8ad270b4
Removing intermediate container f4ab8ad270b4
 ---> 3ca3727297d3
Step 9/14 : RUN Remove-Item -Recurse -Force '.\WindowsPowerShell\Modules\PSReadLine'
 ---> Running in fc5d016f340f
Removing intermediate container fc5d016f340f
 ---> 970c834054f4
Step 10/14 : WORKDIR c:\\code\\depot_tools
 ---> Running in 693d873c9a14
Removing intermediate container 693d873c9a14
Step 11/14 : RUN Invoke-WebRequest https://go.microsoft.com/fwlink/?linkid=864422 -OutFile 'C:\code\winsdksetup.exe';
 ---> 6ba30aa3b619
 ---> Running in 4aea5ee8cdc1
Removing intermediate container 4aea5ee8cdc1
 ---> 31e7a0ddd04d
Step 12/14 : RUN $p = Start-Process -Wait -PassThru -FilePath C:\code\winsdksetup.exe -ArgumentList ' /features OptionId.WindowsDesktopDebuggers /quiet /Log #"%TEMP%\\winsdksetup.log /norestart'; if (($ret = $p.ExitCode) -and ($ret -ne 3010)) { throw ('Install failed with exit code 0x{0:x}' -f $ret) }
 ---> Running in 1a2f0b47f616
Removing intermediate container 1a2f0b47f616
 ---> 870258838507
Step 13/14 : RUN Invoke-WebRequest 'https://aka.ms/vs/15/release/vs_community.exe' -OutFile 'C:\code\vs_community.exe';
 ---> Running in c470434bea09
Removing intermediate container c470434bea09
 ---> 826e4564b6c9
Step 14/14 : RUN $p = Start-Process -Wait -PassThru -FilePath C:\code\vs_community.exe -ArgumentList ' --quiet --wait --norestart --nocache --add Microsoft.Net.Component.4.7.1.SDK --add Microsoft.VisualStudio.Component.Windows10SDK --add Microsoft.Net.Component.4.6.1.SDK --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Win81 --add Microsoft.VisualStudio.Component.Windows81SDK --add Microsoft.Net.Component.4.5.2.TargetingPack --add Microsoft.Net.Component.4.6.2.TargetingPack --add Microsoft.Net.Component.4.6.2.SDK --add Microsoft.VisualStudio.Component.Windows10SDK.16299.Desktop --add Microsoft.VisualStudio.Component.Windows10SDK.17134 --add Microsoft.VisualStudio.Component.Git --add Microsoft.VisualStudio.Component.Windows10SDK.15063.Desktop --add Microsoft.VisualStudio.Workload.NativeDesktop --add Microsoft.VisualStudio.Component.VC.ATLMFC --includeRecommended --remove Microsoft.VisualStudio.Component.Windows10SDK.10240 --remove Microsoft.VisualStudio.Component.Windows10SDK.10586 --remove Component.Android.NDK.R12B --remove Component.Android.SDK23.Private --remove Component.MDD.Android --remove Component.Unreal.Android --remove Component.Android.NDK.R15C --remove Component.Android.SDK19 --remove Component.Android.SDK22 --remove Component.Android.SDK23 --remove Component.Android.SDK25 --remove Component.MDD.Android --remove Component.Android.NDK.R12B --remove Component.Android.NDK.R12B_3264 --remove Component.Android.NDK.R13B --remove Component.Android.NDK.R13B_3264 --remove Component.Android.NDK.R15C_3264 --remove Component.Google.Android.Emulator.API23.V2 --remove Component.Android.SDK25 --remove Component.Google.Android.Emulator.API25 --remove Component.Android.SDK23.Private --remove Component.Google.Android.Emulator.API23.Private --remove Component.Android.Emulator --remove Component.Android.NDK.R11C --remove Component.Android.NDK.R11C_3264 --remove Microsoft.VisualStudio.Component.Windows10SDK.14393 --remove Microsoft.VisualStudio.Component.Phone.Emulator.15254 --remove Microsoft.VisualStudio.Component.Phone.Emulator.15254 --remove Microsoft.VisualStudio.Component.Phone.Emulator --remove Microsoft.VisualStudio.Component.Phone.Emulator.15063 --remove Component.Anaconda3.x64 --remove Component.Anaconda2.x64 --remove Component.Anaconda2.x86 --remove Component.Anaconda3.x86 --remove Microsoft.VisualStudio.Component.Unity --remove Component.UnityEngine.x64 --remove Component.UnityEngine.x86 --remove Component.Incredibuild --remove Component.IncredibuildMenu --remove Microsoft.VisualStudio.Component.Sharepoint.Tools --remove Microsoft.VisualStudio.Component.TeamOffice --remove Component.Cocos;'; if (($ret = $p.ExitCode) -and ($ret -ne 3010)) { C:\TEMP\collect.exe; throw ('Install failed with exit code 0x{0:x}' -f $ret) }; Remove-Item -Recurse -Force 'c:\ProgramData\Package Cache\'
 ---> Running in 95b4cc93748d
Removing intermediate container 95b4cc93748d
 ---> af3f761d5fba
[Warning] One or more build-args [BASE_DOCKER_FILE] were not consumed
Successfully built af3f761d5fba
Successfully tagged vs:latest
11/25/2019 02:06:42 VSBuild took 4359.4 secs
Running: docker build --memory=30g --build-arg CEF_SAVE_SOURCES="0" --build-arg BINARY_EXT="zip" --build-arg DUAL_BUILD="0" --build-arg GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome" --build-arg GYP_DEFINES="" --build-arg CHROME_BRANCH="3370" -f Dockerfile_cef -t cef . in C:\build-cefsharp
Sending build context to Docker daemon  112.6kB
Step 1/19 : FROM vs
 ---> af3f761d5fba
Step 2/19 : RUN $env:Path = 'c:/Program Files/Git/bin/;' + $env:Path;setx /M PATH $env:Path;
 ---> Running in 2c04ec89a541
SUCCESS: Specified value was saved.
Removing intermediate container 2c04ec89a541
 ---> 71e64eb63111
Step 3/19 : RUN Invoke-WebRequest 'https://storage.googleapis.com/chrome-infra/depot_tools.zip' -OutFile 'C:/code/depot_tools.zip';
 ---> Running in 280ed7696bc4
Removing intermediate container 280ed7696bc4
 ---> 16510ac44f49
Step 4/19 : RUN Expand-Archive C:/code/depot_tools.zip -DestinationPath "C:/code/depot_tools";
 ---> Running in 4f11e096faf2
Removing intermediate container 4f11e096faf2
Step 5/19 : RUN $env:Path = 'c:/code/depot_tools/;' + $env:Path;setx /M PATH $env:Path;
 ---> 51795efa13ba
 ---> Running in 08db973d2bf1
SUCCESS: Specified value was saved.
Removing intermediate container 08db973d2bf1
 ---> 1d61c188b252
Step 6/19 : ARG GN_DEFINES="is_debug=false"
 ---> Running in 8a7fef0b240c
Removing intermediate container 8a7fef0b240c
 ---> 1175318789da
Step 7/19 : ENV DEPOT_TOOLS_WIN_TOOLCHAIN 0
 ---> Running in a09d6e4b86ae
Removing intermediate container a09d6e4b86ae
 ---> b37572a7e392
Step 8/19 : ENV CEF_USE_GN 1
 ---> Running in 2a793ba920ec
Removing intermediate container 2a793ba920ec
 ---> 4c5382f267e8
Step 9/19 : ENV GYP_MSVS_VERSION 2017
 ---> Running in a94aa7b48b0c
Removing intermediate container a94aa7b48b0c
 ---> 7082cc4cf373
Step 10/19 : ARG DUAL_BUILD="0"
 ---> Running in 2ac0e3acbdb3
Removing intermediate container 2ac0e3acbdb3
Step 11/19 : ARG BINARY_EXT="zip"
 ---> 34574d371b62
 ---> Running in f932612e4aa7
Removing intermediate container f932612e4aa7
 ---> c30741593b92
Step 12/19 : ARG GYP_DEFINES="target_arch=x64 "
 ---> Running in 51604223ec78
Removing intermediate container 51604223ec78
Step 13/19 : RUN setX /M DEPOT_TOOLS_WIN_TOOLCHAIN 0;setX /M GYP_MSVS_VERSION 2017;setx /M GN_DEFINES "$env:GN_DEFINES";setx /M GYP_DEFINES "$env:GYP_DEFINES";setx /M DUAL_BUILD "$env:DUAL_BUILD";
 ---> 6e532256920a
 ---> Running in 43e87bf24836
SUCCESS: Specified value was saved.
SUCCESS: Specified value was saved.
SUCCESS: Specified value was saved.
ERROR: Invalid syntax.
Type "SETX /?" for usage.

SUCCESS: Specified value was saved.
Removing intermediate container 43e87bf24836
 ---> a32174d8c52b
Step 14/19 : ARG CHROME_BRANCH=3239
 ---> Running in f9360fabec46
Removing intermediate container f9360fabec46
Step 15/19 : ADD https://bitbucket.org/chromiumembedded/cef/raw/master/tools/automate/automate-git.py c:/code/automate/
 ---> 5f64b605af01
 ---> f47f8116d782
Step 16/19 : RUN cd c:/code/depot_tools/;update_depot_tools.bat;git checkout .\cipd.ps1;update_depot_tools.bat;
 ---> Running in 19dbfb1ec85d
Downloading CIPD client for windows-amd64 from https://chrome-infra-packages.appspot.com/client?platform=windows-amd64&version=git_revision:2a121dde003a3079db0fdf58195b52cbf486f6ba...
Updated 0 paths from the index
Removing intermediate container 19dbfb1ec85d
 ---> a055f12c07d1
Step 17/19 : ADD functions.ps1 cef_build.ps1 cef_patch.ps1 cef_patch_*.diff c:/code/
 ---> caf1d892bdfb
Step 18/19 : ARG CEF_SAVE_SOURCES
 ---> Running in 20bf2fed4d0a
Removing intermediate container 20bf2fed4d0a
 ---> 7b72688c69bd
Step 19/19 : RUN c:/code/cef_build.ps1
 ---> Running in f9297a4554aa
Running: c:/code/depot_tools/python.bat c:/code/automate/automate-git.py --download-dir=c:/code --branch=3370 --no-build --no-debug-build --no-distrib in C:\code\depot_tools
Cloning into 'c:\code\cef'...
Checking out files:  72% (1333/1844)
Checking out files:  73% (1347/1844)
Checking out files:  74% (1365/1844)
Checking out files:  75% (1383/1844)
Checking out files:  76% (1402/1844)
Checking out files:  77% (1420/1844)
Checking out files:  78% (1439/1844)
Checking out files:  79% (1457/1844)
Checking out files:  80% (1476/1844)
Checking out files:  81% (1494/1844)
Checking out files:  82% (1513/1844)
Checking out files:  83% (1531/1844)
Checking out files:  84% (1549/1844)
Checking out files:  85% (1568/1844)
Checking out files:  86% (1586/1844)
Checking out files:  87% (1605/1844)
Checking out files:  88% (1623/1844)
Checking out files:  89% (1642/1844)
Checking out files:  90% (1660/1844)
Checking out files:  91% (1679/1844)
Checking out files:  92% (1697/1844)
Checking out files:  93% (1715/1844)
Checking out files:  94% (1734/1844)
Checking out files:  95% (1752/1844)
Checking out files:  96% (1771/1844)
Checking out files:  97% (1789/1844)
Checking out files:  98% (1808/1844)
Checking out files:  99% (1826/1844)
Checking out files: 100% (1844/1844)
Checking out files: 100% (1844/1844), done.
error: pathspec 'origin/3370' did not match any file(s) known to git
--> Depot Tools Directory: c:\code\depot_tools
-------- Running "update_depot_tools.bat" in "c:\code\depot_tools"...
--> Updating depot_tools
--> CEF URL: https://bitbucket.org/chromiumembedded/cef.git
--> Download Directory: c:\code
--> CEF Source Directory: c:\code\cef
-------- Running "c:\code\depot_tools\git.bat rev-parse HEAD" in "c:\code\cef"...
-------- Running "c:\code\depot_tools\git.bat clone https://bitbucket.org/chromiumembedded/cef.git c:\code\cef" in "c:\code"...
--> CEF Branch: 3370
-------- Running "c:\code\depot_tools\git.bat rev-parse origin/3370" in "c:\code\cef"...
-------- Running "c:\code\depot_tools\git.bat checkout origin/3370" in "c:\code\cef"...
--> CEF Current Checkout: f9706f260aa9fd78c799c1456f0ac75d13f5e7ba
--> CEF Desired Checkout: origin/3370 (origin/3370)
  File "c:/code/automate/automate-git.py", line 1274, in <module>
Traceback (most recent call last):
    cef_dir, depot_tools_dir)
    args, cwd=working_dir, env=env, shell=(sys.platform == 'win32'))
  File "c:/code/automate/automate-git.py", line 61, in run
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['c:\\code\\depot_tools\\git.bat', 'checkout', 'origin/3370']' returned non-zero exit status 1
  File "c:\code\depot_tools\bootstrap-3_8_0b1_chromium_1_bin\python\bin\lib\subprocess.py", line 186, in check_call
1
Set-Location : Cannot find path 'C:\code\chromium\src\cef' because it does not
exist.
At C:\code\cef_build.ps1:28 char:1
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ Set-Location -Path c:/code/chromium/src/cef;
   ) [Set-Location], ItemNotFoundException
    + CategoryInfo          : ObjectNotFound: (C:\code\chromium\src\cef:String
    + FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.SetLo
   cationCommand


The command 'powershell -Command $ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue'; c:/code/cef_build.ps1' returned a non-zero code: 1
Caught an exception: Process docker build --memory=30g --build-arg CEF_SAVE_SOURCES="0" --build-arg BINARY_EXT="zip" --build-arg DUAL_BUILD="0" --build-arg GN_DEFINES="is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome" --build-arg GYP_DEFINES="" --build-arg CHROME_BRANCH="3370" -f Dockerfile_cef -t cef . exited with non zero code: 1 aborting!
        Exception Type: System.Management.Automation.RuntimeException
        Stack Trace: at RunProc, C:\build-cefsharp\functions.ps1: line 82
        at <ScriptBlock>, C:\build-cefsharp\build.ps1: line 70
        at <ScriptBlock>, <No file>: line 1
        at confirm, C:\build-cefsharp\functions.ps1: line 106
        at <ScriptBlock>, C:\build-cefsharp\build.ps1: line 43
        at <ScriptBlock>, <No file>: line 1
PS C:\build-cefsharp>>

Building CEF image fails

When I tried to build the current CefSharp branch with proprietary codecs the script failed building the CEF environment:
CEF.Build1.txt

versions.ps1:
versions.ps1.txt

I tried these steps to track the issue down:

  1. used a fresh installation of Win10x64 1803 to eliminate environment issues

  2. commented out 'RUN c:/code/cef_build.ps1' in dockerfile_cef
    Attached to cef container with remote powershell:
    Checked environment variables: ok
    Called 'c:/code/depot_tools/python.bat c:/code/automate/automate-git.py --download-dir=c:/code --branch=3396 --no-build --no-debug-build --no-distrib'
    --> automate-git.py failed in update_depot_tools
    Seems for some reason this is the culprit.

  3. As a workaround I disabled the update as of here: https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding#markdown-header-legacy-release-branches-unsupported
    by adding following lin to dockerfile_cef: ENV DEPOT_TOOLS_UPDATE 0

This builds the CEF image, but depot_tools are probably unsynced now to the correct branch: 3396

Chromium sources are currently loading, will take awhile.
[sry for editing: did have formatting problems]

Error compressing CEF build in VAR_CEF_BUILD_ONLY mode

When running the build in CEF only mode using process isolation mode locally I get an error:
Unable to find image 'powershell:latest' locally
when running this step in build.ps1
RunProc -proc "docker" -redirect_output:$redirect_output -opts "run --name cef powershell Compress-Archive -Path C:/code/binaries/*.zip -CompressionLevel Fastest -DestinationPath /packages_cef"
I'm a docker for windows newbie but I think there is a missing "cef" here in the run command, so it can reference the cef container that was just created. It should be
RunProc -proc "docker" -redirect_output:$redirect_output -opts "run --name cef cef powershell Compress-Archive -Path C:/code/binaries/*.zip -CompressionLevel Fastest -DestinationPath /packages_cef"
I'll attach a PR to this bug shortly with the suggested change.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.