Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue while building 124.0.6367.118-1.1 from source #345

Open
Komas19-new opened this issue May 10, 2024 · 8 comments
Open

Issue while building 124.0.6367.118-1.1 from source #345

Komas19-new opened this issue May 10, 2024 · 8 comments

Comments

@Komas19-new
Copy link

Hello, when i try building 124.0.6367.118-1.1 using https://github.com/ungoogled-software/ungoogled-chromium-windows?tab=readme-ov-file#updating-patches-and-pruning-list , i get an error:

INFO: Setting up cloning environment
INFO: Cloning chromium source: 124.0.6367.155
Cloning into 'build\src'...
remote: Counting objects: 434104, done
remote: Finding sources: 100% (434104/434104)
remote: Total 434104 (delta 87491), reused 271525 (delta 87491)
Receiving objects: 100% (434104/434104), 1.21 GiB | 10.80 MiB/s, done.
Resolving deltas: 100% (87491/87491), done.
Updating files: 100% (433030/433030), done.
INFO: Cloning depot_tools
remote: Counting objects: 741, done
remote: Finding sources: 100% (741/741)
remote: Total 741 (delta 141), reused 474 (delta 141)
Receiving objects: 100% (741/741), 1.15 MiB | 11.97 MiB/s, done.
Resolving deltas: 100% (141/141), done.
From https://chromium.googlesource.com/chromium/tools/depot_tools
 * branch            9c43bc14f1a7404fd4b6f744050d553acca557bf -> FETCH_HEAD
Updating files: 100% (682/682), done.
HEAD is now at 9c43bc1 Roll recipe dependencies (trivial).
error: patch failed: gclient.py:125
error: gclient.py: patch does not apply
error: patch failed: gclient_scm.py:844
error: gclient_scm.py: patch does not apply
error: patch failed: gsutil.py:27
error: gsutil.py: patch does not apply
Traceback (most recent call last):
  File "D:\ungoogled-chromium-windows\ungoogled-chromium\utils\clone.py", line 298, in <module>
    main()
  File "D:\ungoogled-chromium-windows\ungoogled-chromium\utils\clone.py", line 294, in main
    clone(args)
  File "D:\ungoogled-chromium-windows\ungoogled-chromium\utils\clone.py", line 108, in clone
    run(['git', 'apply'],
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 528, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['git', 'apply']' returned non-zero exit status 1.

This also happens when using the normal building step. I have tried running "git apply" manually and it seems to hang.

@teeminus
Copy link
Contributor

Seems like there is something wrong with your checkout. You say you want to build .118 but the output you pasted says .155 (on line 2).

@Komas19-new
Copy link
Author

Seems like there is something wrong with your checkout. You say you want to build .118 but the output you pasted says .155 (on line 2).

i still get the error even when building the correct build

@teeminus
Copy link
Contributor

The exact same error? Can you please post the logs of the new run? Did you remove the build folder completely before starting over?

@Nifury
Copy link
Member

Nifury commented May 10, 2024

I had a similar problem when I compiled with Python 3.12 and the clone script, and I wasn't able to locate the problem.
Building with --tarball works flawlessly.

@Komas19-new
Copy link
Author

Komas19-new commented May 11, 2024

The exact same error? Can you please post the logs of the new run? Did you remove the build folder completely before starting over?

**********************************************************************
** Visual Studio 2022 Developer Command Prompt v17.5.5
** Copyright (c) 2022 Microsoft Corporation
**********************************************************************

C:\Windows\System32>d:

D:\>git clone --recurse-submodules https://github.com/ungoogled-software/ungoogled-chromium-windows.git
Cloning into 'ungoogled-chromium-windows'...
remote: Enumerating objects: 1893, done.
remote: Counting objects: 100% (471/471), done.
remote: Compressing objects: 100% (139/139), done.
remote: Total 1893 (delta 373), reused 361 (delta 331), pack-reused 1422
Receiving objects: 100% (1893/1893), 1.51 MiB | 7.52 MiB/s, done.
Resolving deltas: 100% (1088/1088), done.
Submodule 'ungoogled-chromium' (https://github.com/Eloston/ungoogled-chromium.git) registered for path 'ungoogled-chromium'
Cloning into 'D:/ungoogled-chromium-windows/ungoogled-chromium'...
remote: Enumerating objects: 19954, done.
remote: Counting objects: 100% (2014/2014), done.
remote: Compressing objects: 100% (513/513), done.
remote: Total 19954 (delta 1668), reused 1732 (delta 1470), pack-reused 17940
Receiving objects: 100% (19954/19954), 13.97 MiB | 16.53 MiB/s, done.
Resolving deltas: 100% (13368/13368), done.
Submodule path 'ungoogled-chromium': checked out '0aacd2f7cac026f6a18695b591f69cd0985f7c7c'

D:\>cd ungoogled-chromium-windows

D:\ungoogled-chromium-windows>git checkout --recurse-submodules 124.0.6367.201-1.1
Note: switching to '124.0.6367.201-1.1'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at 2e0962e Merge pull request #346 from teeminus/update

D:\ungoogled-chromium-windows>python3 build.py
INFO: Downloading required files...
INFO: Downloading "bison-bin" to "bison-2.4.1-bin.zip" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   619    0   619    0     0   1166      0 --:--:-- --:--:-- --:--:--  1176
100   373  100   373    0     0    334      0  0:00:01  0:00:01 --:--:--   695
100  941k  100  941k    0     0   392k      0  0:00:02  0:00:02 --:--:-- 3676k
INFO: Downloading "bison-dep" to "bison-2.4.1-dep.zip" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   609    0   609    0     0   1235      0 --:--:-- --:--:-- --:--:--  1242
100   363  100   363    0     0    354      0  0:00:01  0:00:01 --:--:--   354
100  814k  100  814k    0     0   488k      0  0:00:01  0:00:01 --:--:-- 2021k
INFO: Downloading "bison-lib" to "bison-2.4.1-lib.zip" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   615    0   615    0     0   1134      0 --:--:-- --:--:-- --:--:--  1138
100   369  100   369    0     0    293      0  0:00:01  0:00:01 --:--:--   293
100  2611  100  2611    0     0   1251      0  0:00:02  0:00:02 --:--:--  3453
INFO: Downloading "esbuild" to "esbuild-windows-64-0.14.13.tgz" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 3168k  100 3168k    0     0  8570k      0 --:--:-- --:--:-- --:--:-- 8679k
INFO: Downloading "git" to "PortableGit-2.30.1-64-bit.7z.exe" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 43.1M  100 43.1M    0     0  7160k      0  0:00:06  0:00:06 --:--:-- 8268k
INFO: Downloading "gperf" to "gperf-3.0.1-bin.zip" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   617    0   617    0     0   1846      0 --:--:-- --:--:-- --:--:--  1864
100   371  100   371    0     0    432      0 --:--:-- --:--:-- --:--:--   432
100  102k  100  102k    0     0  89052      0  0:00:01  0:00:01 --:--:--  631k
INFO: Downloading "llvm" to "LLVM-18.1.1-win64.exe" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  356M  100  356M    0     0  15.3M      0  0:00:23  0:00:23 --:--:-- 11.7M
INFO: Downloading "ninja" to "ninja-win-1.10.2.zip" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  256k  100  256k    0     0   304k      0 --:--:-- --:--:-- --:--:--  304k
INFO: Downloading "nodejs" to "node-v16.17.0-win-x64.zip" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 25.7M  100 25.7M    0     0  14.4M      0  0:00:01  0:00:01 --:--:-- 14.5M
INFO: Downloading "rust-x64" to "rust-nightly-2024-02-21-x86_64-pc-windows-msvc.tar.gz" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  303M  100  303M    0     0  4989k      0  0:01:02  0:01:02 --:--:-- 6048k
INFO: Downloading "rust-x86" to "rust-nightly-2024-02-21-i686-pc-windows-msvc.tar.gz" ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  300M  100  300M    0     0  4574k      0  0:01:07  0:01:07 --:--:-- 5630k
INFO: Verifying hashes for "bison-bin" ...
INFO: Verifying hashes for "bison-dep" ...
INFO: Verifying hashes for "bison-lib" ...
INFO: Verifying hashes for "esbuild" ...
INFO: Verifying hashes for "git" ...
INFO: Verifying hashes for "gperf" ...
INFO: Verifying hashes for "llvm" ...
INFO: Verifying hashes for "ninja" ...
INFO: Verifying hashes for "nodejs" ...
INFO: Verifying hashes for "rust-x64" ...
INFO: Verifying hashes for "rust-x86" ...
INFO: Setting up cloning environment
INFO: Cloning chromium source: 124.0.6367.201
Cloning into 'build\src'...
remote: Counting objects: 434104, done
remote: Finding sources: 100% (434104/434104)
remote: Total 434104 (delta 87490), reused 271541 (delta 87490)
Receiving objects: 100% (434104/434104), 1.21 GiB | 10.57 MiB/s, done.
Resolving deltas: 100% (87490/87490), done.
Updating files: 100% (433030/433030), done.
INFO: Cloning depot_tools
remote: Counting objects: 741, done
remote: Finding sources: 100% (741/741)
remote: Total 741 (delta 141), reused 474 (delta 141)
Receiving objects: 100% (741/741), 1.15 MiB | 13.96 MiB/s, done.
Resolving deltas: 100% (141/141), done.
From https://chromium.googlesource.com/chromium/tools/depot_tools
 * branch            9c43bc14f1a7404fd4b6f744050d553acca557bf -> FETCH_HEAD
Updating files: 100% (682/682), done.
HEAD is now at 9c43bc1 Roll recipe dependencies (trivial).
error: patch failed: gclient.py:125
error: gclient.py: patch does not apply
error: patch failed: gclient_scm.py:844
error: gclient_scm.py: patch does not apply
error: patch failed: gsutil.py:27
error: gsutil.py: patch does not apply
Traceback (most recent call last):
  File "D:\ungoogled-chromium-windows\ungoogled-chromium\utils\clone.py", line 298, in <module>
    main()
  File "D:\ungoogled-chromium-windows\ungoogled-chromium\utils\clone.py", line 294, in main
    clone(args)
  File "D:\ungoogled-chromium-windows\ungoogled-chromium\utils\clone.py", line 108, in clone
    run(['git', 'apply'],
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\subprocess.py", line 524, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['git', 'apply']' returned non-zero exit status 1.
Traceback (most recent call last):
  File "D:\ungoogled-chromium-windows\build.py", line 293, in <module>
    main()
  File "D:\ungoogled-chromium-windows\build.py", line 179, in main
    subprocess.run([sys.executable, str(Path('ungoogled-chromium', 'utils', 'clone.py')), '-o', 'build\src', '-p', 'win32' if args.x86 else 'win64'], check=True)
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\subprocess.py", line 524, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['C:\\Users\\****\\AppData\\Local\\Programs\\Python\\Python310\\python3.exe', 'ungoogled-chromium\\utils\\clone.py', '-o', 'build\\src', '-p', 'win64']' returned non-zero exit status 1.

I just have the same error + another error when trying to build the latest commit of 124.0.6367.201-1.1

i can try giving some info:
Python 3.10.4
Visual Studio Community 2022
Git 2.45.0.windows.1
Windows 11 Pro Insider Preview 26120.461

I had a similar problem when I compiled with Python 3.12 and the clone script, and I wasn't able to locate the problem. Building with --tarball works flawlessly.

alright gonna try that

@Komas19-new
Copy link
Author

I had a similar problem when I compiled with Python 3.12 and the clone script, and I wasn't able to locate the problem. Building with --tarball works flawlessly.

alright so it didn't get the error, but now i got another error just after patching:

D:\ungoogled-chromium-windows\build\src>call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvars64.bat" >nul

D:\ungoogled-chromium-windows\build\src>set DEPOT_TOOLS_WIN_TOOLCHAIN=0

D:\ungoogled-chromium-windows\build\src>"C:\Users\****\AppData\Local\Programs\Python\Python310\python3.exe" "tools\gn\bootstrap\bootstrap.py" "-o" "out\Default\gn.exe" "--skip-generate-buildfiles"
ninja: Entering directory `D:\ungoogled-chromium-windows\build\src\out\Release\gn_build'
[200/200] LINK gn.exe

D:\ungoogled-chromium-windows\build\src>exit
D:\ungoogled-chromium-windows\build\src>call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvars64.bat" >nul

D:\ungoogled-chromium-windows\build\src>set DEPOT_TOOLS_WIN_TOOLCHAIN=0

D:\ungoogled-chromium-windows\build\src>"out\Default\gn.exe" "gen" "out\Default" "--fail-on-unused-args"
Traceback (most recent call last):
  File "D:\ungoogled-chromium-windows\build\src\build\compute_build_timestamp.py", line 137, in <module>
    sys.exit(main())
  File "D:\ungoogled-chromium-windows\build\src\build\compute_build_timestamp.py", line 97, in main
    if doctest.testmod()[0]:
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\doctest.py", line 1966, in testmod
    runner.run(test)
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\doctest.py", line 1479, in run
    self.debugger = _OutputRedirectingPdb(save_stdout)
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\doctest.py", line 364, in __init__
    pdb.Pdb.__init__(self, stdout=out, nosigint=True)
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\pdb.py", line 157, in __init__
    import readline
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\site-packages\readline.py", line 34, in <module>
    rl = Readline()
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\site-packages\pyreadline\rlmain.py", line 422, in __init__
    BaseReadline.__init__(self)
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\site-packages\pyreadline\rlmain.py", line 62, in __init__
    mode.init_editing_mode(None)
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\site-packages\pyreadline\modes\emacs.py", line 633, in init_editing_mode
    self._bind_key('space',       self.self_insert)
  File "C:\Users\benoi\AppData\Local\Programs\Python\Python310\lib\site-packages\pyreadline\modes\basemode.py", line 162, in _bind_key
    if not callable(func):
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\site-packages\pyreadline\py3k_compat.py", line 8, in callable
    return isinstance(x, collections.Callable)
AttributeError: module 'collections' has no attribute 'Callable'
ERROR at //build/timestamp.gni:31:19: Script returned non-zero exit code.
build_timestamp = exec_script(compute_build_timestamp,
                  ^----------
Current dir: D:/ungoogled-chromium-windows/build/src/out/Default/
Command: C:/Users/****/AppData/Local/Programs/Python/Python310/python3.exe D:/ungoogled-chromium-windows/build/src/build/compute_build_timestamp.py official
Returned 1.
See //components/policy/BUILD.gn:9:1: whence it was imported.
import("//build/timestamp.gni")
^-----------------------------
See //BUILD.gn:186:9: which caused the file to be included.
        "//components/policy:policy_templates",
        ^-------------------------------------

D:\ungoogled-chromium-windows\build\src>exit
Traceback (most recent call last):
  File "D:\ungoogled-chromium-windows\build.py", line 293, in <module>
    main()
  File "D:\ungoogled-chromium-windows\build.py", line 279, in main
    _run_build_process('out\\Default\\gn.exe', 'gen', 'out\\Default', '--fail-on-unused-args')
  File "D:\ungoogled-chromium-windows\build.py", line 67, in _run_build_process
    subprocess.run(('cmd.exe', '/k'),
  File "C:\Users\****\AppData\Local\Programs\Python\Python310\lib\subprocess.py", line 524, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '('cmd.exe', '/k')' returned non-zero exit status 1.

@Nifury
Copy link
Member

Nifury commented May 11, 2024

AttributeError: module 'collections' has no attribute 'Callable'
Looks like you installed an old library that is not compatible with Python 3.10.
pyreadline/pyreadline#73

@Komas19-new
Copy link
Author

AttributeError: module 'collections' has no attribute 'Callable' Looks like you installed an old library that is not compatible with Python 3.10. pyreadline/pyreadline#73

ok now it seems to not get that error, it is currently not finished as of right now, so we will see if it builds successfully

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants