Git Product home page Git Product logo

Comments (21)

gz83 avatar gz83 commented on July 21, 2024 2

You can try to follow the steps I gave earlier and you should not encounter any errors. If you have any other questions, please feel free to ask them here.

from thorium.

gz83 avatar gz83 commented on July 21, 2024 1

I don't mean to stop you from doing what you want to do, just a reminder.

Run 'git submodule update' in Thorium's local checkout to ensure that the submodule code is updated to the latest state.

from thorium.

gz83 avatar gz83 commented on July 21, 2024 1

Sorry for the delayed response, please follow the process below to compile the SSE4 version.

  1. Make sure you pull the full Chromium source code. And make sure you pull the thorium source code with the thorium-libjxl submodule.

  2. run git reset --hard in the thorium code checkout to hard reset the code checkout, and run git status to make sure the thorium code checkout is clean, and then run git pull && git submodule update to make sure the thorium code checkout is in the latest state.

  3. add CR_DIR to your system's environment variables and set it to /path/to/chromium/src

  4. In git bash, switch to the directory where the thorium code is being checked out, execute trunk.sh, then version.sh and setup.sh --sse4.

  5. After making sure that all the sh files from step 4 have been executed successfully (you can ignore the error of using python to download the PGO file, since python is not available in the git bash and you can download the PGO file later in cmd), continue to execute patch_ac3.sh without changing the current path.

  6. Open cmd, switch to /path/to/chromium/src and execute the following command to download the PGO file

python3 tools/update_pgo_profiles.py --target=win64 update --gs-url-base=chromium-optimization-profiles/pgo_profiles

python3 v8/tools/builtins-pgo/download_profiles.py --depot-tools=/path/to/depot_tools download

  1. After the PGO files are downloaded, do not change the current path, execute gn args out\thorium in cmd, then fill in the following args parameter and make sure the command is executed successfully

https://github.com/Alex313031/thorium/blob/main/other/SSE4.1/win_SSE4_args.gn

Set google_api and google_key as needed, and change the pgo_data_path at the bottom to the actual path of the PGO file.

  1. Without changing the current path, run

autoninja -C out\thorium thorium chromedriver clear_key_cdm thorium_shell policy_templates pack_policy_templates setup mini_installer -jxx

xx is the number of CPU threads you have, e.g. 24.

If following the above steps still doesn't compile thorium properly, let me know and I'll try to investigate, in the meantime, thorium is now available for chromium version 124, and we shouldn't need to modify any files in the thorium code checkout (including submodules).

Finally, Alex313031 is the owner as well as the main developer of the thorium browser project, and I am his collaborator.

@aberfan

from thorium.

gz83 avatar gz83 commented on July 21, 2024 1

Please don't forget to delete the out\thorium directory

@aberfan

from thorium.

gz83 avatar gz83 commented on July 21, 2024 1

Please do not change the name of this directory. If you change it, the thorium code will not be fully applied.

from thorium.

gz83 avatar gz83 commented on July 21, 2024

Please make sure that the Thorium code and libjxl submodule code you are using are up to date.

In addition, it is not recommended to build without special needs, which will limit your use of the computer and take up a lot of your time.

from thorium.

aberfan avatar aberfan commented on July 21, 2024

I'm not sure what would constitute special needs, but isn't wanting to learn and simply because I want to, a good enough reason to?

I've followed the instructions in the build document I linked in my post. Is there an additional command not included to make sure the "libjxl submodules code" I'm using is up to date?

I haven't made changes to files, beyond the few fixes in version.sh to get the python3 commands to properly execute.

from thorium.

aberfan avatar aberfan commented on July 21, 2024

Thank you for the suggestion: I've run that command in the thorium directory. There is no output from the command (no error, etc). I still receive the same error as above, though.

What can I do (information I can provide?), to find where this is breaking down?

from thorium.

gz83 avatar gz83 commented on July 21, 2024

After running the submodule update command, you need to re-execute setup.sh. In addition, can you provide the execution results of the git status command in the chromium code directory?

By the way, if it's convenient, can you roughly explain in words your entire operation process and the version you want to compile (such as AVX, AVX2, etc.)?

from thorium.

aberfan avatar aberfan commented on July 21, 2024

Execution results of the git status command in chromium code directory is very long, so I put it in pastebin: https://pastebin.com/KYkSPM61

I'm trying to specifically do sse4, so I ran setup.sh with --sse4. I also have the files on a drive that's not C, because I don't have room on my tiny OS drive... I did symlinking to the proper paths, so shouldn't be relevant(?)

My entire process is literally the windows build document, where I've been following each command in turn.

I did re-executed setup.sh --sse4 (in bash, vs cmd) after running the submodule update command, but it still does give this error (after I next, in cmd, run gn args out\thorium)

Is this module something I need or is there a way to disable?

from thorium.

gz83 avatar gz83 commented on July 21, 2024

Thank you for your cooperation in providing additional information. We have recently made changes to the compilation process. After executing setup.sh, you also need to execute patch_ac3.sh

At the same time, can you upload the contents of the files third_party/libjxl/src/lib/lib.gni and third_party/blink/renderer/platform/BUILD.gn?

from thorium.

aberfan avatar aberfan commented on July 21, 2024

Thank you for the next steps. I ran patch_ac3.sh, and that had no effect on this error.

This is the content of third_party/libjxl/src/lib/lib.gni:
jxl_lists.bzl

^ That is it, in its entirety.
third_party/blink/renderer/platform/BUILD.gn (renamed to .txt to upload to github):
BUILD.gn.txt

Edit: lib.gni seems to have broken syntax. From other posts here, gz83, it seems you're the maintainer?

from thorium.

aberfan avatar aberfan commented on July 21, 2024

Hello and thank you for the response. I think maybe I'm not communicating well, because there seems to be a bug in this process; I've followed the build instructions as written, and I've done these. I'm doing them again now...

  1. run git reset --hard in the thorium code checkout to hard reset the code checkout, and run git status to make sure the thorium code checkout is clean, and then run git pull && git submodule update to make sure the thorium code checkout is in the latest state.
MINGW64 /l/dev/thorium (main)
$ git status
On branch main
Your branch is up to date with 'origin/main'.

nothing to commit, working tree clean

MINGW64 /l/dev/thorium (main)
$ git reset --hard
HEAD is now at dbb97b38  update toolchain

MINGW64 /l/dev/thorium (main)
$ git status
On branch main
Your branch is up to date with 'origin/main'.

nothing to commit, working tree clean

MINGW64 /l/dev/thorium (main)
$ git pull && git submodule update
Already up to date.
  1. add CR_DIR to your system's environment variables and set it to /path/to/chromium/src
MINGW64 /l/dev/thorium (main)
$ echo $CR_DIR
/l/dev/chromium/src/
  1. In git bash, switch to the directory where the thorium code is being checked out, execute trunk.sh, then version.sh and setup.sh --sse4.

I'm working on going through this again now.

Having manually fixed the broken file noted above, here is how far I was able to get today:

../../chrome/common/net/net_resource_provider.cc(39,34): error: use of undeclared identifier 'IDS_DIRECTORY_LISTING_PARSING_ERROR_BOX_TEXT'
   39 |         l10n_util::GetStringUTF8(IDS_DIRECTORY_LISTING_PARSING_ERROR_BOX_TEXT));
      |                                  ^
1 error generated.
[50924/68226] CXX obj/chrome/common/profiler/profiler/main_thread_stack_sampling_profiler.obj
ninja: build stopped: subcommand failed.

from thorium.

gz83 avatar gz83 commented on July 21, 2024

I think you still have problems during the execution of the setup.sh script and your current chromium codebase may be in a state of disarray.

And it seems that you have not fully applied the patch provided by thorium to chromium.

from thorium.

aberfan avatar aberfan commented on July 21, 2024

I think you still have problems during the execution of the setup.sh script and your current chromium codebase may be in a state of disarray.

Hopefully there's a way to figure that out, and if so, why, so to fix the instructions for other idiots like me. ;)

trunk.sh:
https://pastebin.com/cg5ifzfe

version.sh:
https://pastebin.com/TqwvUcvb

setup.sh --sse4:
https://pastebin.com/ffJuDCut

$./patch_ac3.sh --> Applied patch ffmpeg_generated.gni cleanly.

L:\dev\chromium\src>python3 tools/update_pgo_profiles.py --target=win64 update --gs-url-base=chromium-optimization-profiles/pgo_profiles

L:\dev\chromium\src>python3 v8/tools/builtins-pgo/download_profiles.py --depot-tools=../../depot_tools download

from thorium.

aberfan avatar aberfan commented on July 21, 2024

Please don't forget to delete the out\thorium directory

I didn't know to, but will now. When I get to that stage, will it harm anything to call it out/thorium_sse4 vs simply out/thorium ?

from thorium.

aberfan avatar aberfan commented on July 21, 2024

Thanks; I thought that name was arbitrary, so wanted to note which setup I was using; I'm at that point; I'm pasting the outputs of the commands in the above post. (I'm really not sure what the best way with github is, and I appreciate your patience with me!)

from thorium.

aberfan avatar aberfan commented on July 21, 2024

Thank you.
However, this results in the exact same error:

L:\dev\chromium\src>gn args out\thorium
Waiting for editor on "L:\dev\chromium\src\out\thorium\args.gn"...
Generating files...
ERROR at //third_party/libjxl/src/lib/lib.gni:1:11: Expecting assignment or function call.
jxl_lists.bzl
          ^--
See //third_party/blink/renderer/platform/BUILD.gn:1847:15: which caused the file to be included.
    deps += [ "//third_party/libjxl:libjxl" ]
              ^----------------------------

And the reason is because lib.gni only has jxl_lists.bzl. If I edit it to be
import("jxl_lists.bzl"), it then works to go past that error.

Where is the source of that file, and what is the contents supposed to be, from your system? (As you can see from the above output, I followed every command as directed; I'm not modifying anything I shouldn't, as far as I know!)

Edit: Also, what is the correct command supposed to be?

L:\dev\chromium\src>autoninja -C out\thorium thorium chromedriver clear_key_cdm thorium_shell policy_templates pack_policy_templates setup in cmd mini_installer -j8
ninja: error: unknown target 'in', did you mean 'id'?

from thorium.

gz83 avatar gz83 commented on July 21, 2024

It may be that the sse4 parameter of the setup.sh script is not handling all files correctly, I think I need Alex to confirm the details.

@Alex313031

from thorium.

SifcaeIT avatar SifcaeIT commented on July 21, 2024

Hello I am in the same build process for windows using AVX2. and I get the same error! is there any way to fix it?

from thorium.

gz83 avatar gz83 commented on July 21, 2024

https://m.me/cm/AbahbdO9g8OC3d1V/?send_source=cm%3Acopy_invite_link

I would like to ask if you two still encounter those errors now. If you still encounter them, please join the above Messager Community and I will try to help you solve the problem in more depth.

@aberfan @SifcaeIT

from thorium.

Related Issues (20)

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.