Git Product home page Git Product logo

Comments (14)

codebytere avatar codebytere commented on July 22, 2024

@xyloflake are you trying to build regular chromium? We patch Electron to use an external config and so the required configs don't exist in regular Chromium. If you want to build Chromium locally, you can add the following patch:

diff --git a/DEPS b/DEPS
index 40bb9ce0f48b3..4631513d07fd7 100644
--- a/DEPS
+++ b/DEPS
@@ -905,6 +905,9 @@ deps = {
       'condition': 'checkout_ios',
   },

+  'src/third_party/engflow-reclient-configs':
+      'https://github.com/EngFlow/reclient-configs.git@955335c30a752e9ef7bff375baab5e0819b6c00d',
+
   'src/ios/third_party/webkit/src': {
       'url': Var('chromium_git') + '/external/github.com/WebKit/webkit.git' +
              '@' + Var('ios_webkit_revision'),
diff --git a/buildtools/reclient_cfgs/configure_reclient_cfgs.py b/buildtools/reclient_cfgs/configure_reclient_cfgs.py
index 06b75f487e51f4bdef42e7f26c8c803eabd2da60..c6485d888699e2bf10ab16ec2f797dd50855c0cb 100755
--- a/buildtools/reclient_cfgs/configure_reclient_cfgs.py
+++ b/buildtools/reclient_cfgs/configure_reclient_cfgs.py
@@ -329,4 +329,13 @@ def main():
 
 
 if __name__ == "__main__":
-    sys.exit(main())
+    r = main()
+    if r != 0:
+        sys.exit(r)
+
+    electron_script = os.path.join(CHROMIUM_SRC, 'third_party', 'engflow-reclient-configs', 'configure_reclient.py')
+    r = subprocess.call([sys.executable, electron_script, '--src_dir=src', '--force'])
+    if r != 0:
+        sys.exit(r)
+
+    print('done')

The files are generated by the engflow-reclient-configs dependency in a hook.

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024

@codebytere no I'm not. I'm just doing e build

from build-tools.

codebytere avatar codebytere commented on July 22, 2024

@xyloflake did you sync properly prior to building?

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024

@codebytere Yes I did, I've done it over 3 times, with 3 diff configs now

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024

Here's everything I did @codebytere

  1. npm i -g @electron/build-tools
  2. e init --root=K:/atom/electron --bootstrap testing
  3. e build

from build-tools.

codebytere avatar codebytere commented on July 22, 2024

@xyloflake and did initialization fully succeed? were all patches applied? I suggest running e sync again.

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024

@codebytere I'll try again. As far as I remember, no the initialization didn't fully succeed. It started building right away without any instruction from me.

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024

@codebytere I've tried over dozen times now, I get the same error while initiating

Downloading "https://dev-cdn.electronjs.org/reclient/credential-helper/v0.2.2/electron-rbe-credential-helper-windows-amd64.tar.gz" into C:\Users\xylo\.electron_build_tools\third_party\reclient.tar.gz
[===============================================================================================] 1.07MB/s 100% 0.0s
Running "C:\Users\xylo\.electron_build_tools\third_party\reclient\electron-rbe-credential-helper.exe login"
Please visit https://auth.notgoma.com/rbe/b325c0ab8102c3c8bbd977257d72c67c377f708b97e6529b957feeef0824c097 to obtain RBE authentication...

Authentication Status: Authenticated
Since:     2024-04-15 00:05:53 +0530 IST
Expires:   2024-04-17 00:05:53 +0530 IST
Cluster:   cas.notgoma.com
Principal: github/xyloflake
Access:    Cache Only
Running "C:\Users\xylo\.electron_build_tools\third_party\depot_tools\gn.bat gen out/Testing --args=import("//electron/build/args/testing.gn") use_remoteexec = true" in C:\Users\xylo\electron\src
C:\Users\xylo\electron\.gclient_entries missing, .gclient file in parent directory C:\Users\xylo\electron might not be the file you want to use.
gn.py: Could not find gn executable at: C:\Users\xylo\electron\src\buildtools\win\gn.exe
ERROR Error: Command failed: C:\Users\xylo\.electron_build_tools\third_party\depot_tools\gn.bat gen out/Testing --args=import("//electron/build/args/testing.gn") use_remoteexec = true
    at checkExecSyncError (node:child_process:885:11)
    at Object.execFileSync (node:child_process:921:15)
    at Object.depotExecFileSync [as execFileSync] (C:\Users\xylo\.electron_build_tools\src\utils\depot-tools.js:145:23)
    at runGNGen (C:\Users\xylo\.electron_build_tools\src\e-build.js:22:9)
    at ensureGNGen (C:\Users\xylo\.electron_build_tools\src\e-build.js:27:41)
    at runNinja (C:\Users\xylo\.electron_build_tools\src\e-build.js:62:3)
    at Command.<anonymous> (C:\Users\xylo\.electron_build_tools\src\e-build.js:127:9)
    at Command.listener [as _actionHandler] (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:480:17)
    at C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:1234:65
ERROR Error: Command failed: C:\Program Files\nodejs\node.exe C:\Users\xylo\.electron_build_tools\src\e build
    at checkExecSyncError (node:child_process:885:11)
    at Object.execFileSync (node:child_process:921:15)
    at Command.<anonymous> (C:\Users\xylo\.electron_build_tools\src\e-init.js:212:22)
    at Command.listener [as _actionHandler] (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:480:17)
    at C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:1234:65
    at Command._chainOrCall (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:1151:12)
    at Command._parseCommand (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:1234:27)
    at Command.parse (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:889:10)
    at Object.<anonymous> (C:\Users\xylo\.electron_build_tools\src\e-init.js:218:4)

It always happens at the rbe auth step, I've tried on 2 different computers with the same OS

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024

@codebytere do you know what might be causing this?

from build-tools.

codebytere avatar codebytere commented on July 22, 2024

Can you paste me the output of the failed init? The best solution here likely is that we shouldn't try to build if sync failed when running e init.

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024

The above one is the output of e init (when it fails) @codebytere

from build-tools.

xyloflake avatar xyloflake commented on July 22, 2024
Checking for build-tools updates
warning ..\package.json: No license field
fatal: detected dubious ownership in repository at 'C:/Users/xylo/.electron_build_tools'
'C:/Users/xylo/.electron_build_tools' is owned by:
        BUILTIN/Administrators (S-1-5-32-544)
but the current user is:
        XYLOFLAKE/xylo (S-1-5-21-2199669179-138158326-79340719-1001)
To add an exception for this directory, call:

        git config --global --add safe.directory C:/Users/xylo/.electron_build_tools
ERROR Error: Command failed: git rev-parse --verify HEAD
fatal: detected dubious ownership in repository at 'C:/Users/xylo/.electron_build_tools'
'C:/Users/xylo/.electron_build_tools' is owned by:
        BUILTIN/Administrators (S-1-5-32-544)
but the current user is:
        XYLOFLAKE/xylo (S-1-5-21-2199669179-138158326-79340719-1001)
To add an exception for this directory, call:

        git config --global --add safe.directory C:/Users/xylo/.electron_build_tools

    at checkExecSyncError (node:child_process:885:11)
    at Object.execSync (node:child_process:957:15)
    at git (C:\Users\xylo\.electron_build_tools\src\e-auto-update.js:107:10)
    at Command.checkForUpdates (C:\Users\xylo\.electron_build_tools\src\e-auto-update.js:112:24)
    at Command.listener [as _actionHandler] (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:480:17)
    at C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:1234:65
    at Command._chainOrCall (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:1151:12)
    at Command._parseCommand (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:1234:27)
    at Command.parse (C:\Users\xylo\.electron_build_tools\node_modules\commander\lib\command.js:889:10)
error: missing required argument 'name'

I get this now when I try e init @codebytere
I'll try to solve it

from build-tools.

codebytere avatar codebytere commented on July 22, 2024

@xyloflake you should only have run e init once. After that, you should be running e sync and e build as i noted above:

I suggest running e sync again.

At this point it probably makes sense to simply delete and restart. The gn error you're seeing can happen if runhooks failed, which can happen depending on when sync fails.

from build-tools.

codebytere avatar codebytere commented on July 22, 2024

Closing as this is not an issue with buildtools itself.

from build-tools.

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.