Comments (10)
Can someone please provide the proper version of liboqs I should be using with Chromium, as well as the correct patch ?
Everything as documented is current and works. The (age of the) patch is related to (the age of) the supported chromium release and works fine with any liboqs
release.
ERROR at //third_party/boringssl/BUILD.gn:48:46: Undefined identifier
all_headers = crypto_headers + ssl_headers + oqs_headers
This error typically occurs if python src/util/generate_build_files.py gn
not been run (or failed). The rest are logical follow-on errors from the above noted error (to introduce OQS headers to the chromium build tree).
We just build Chromium again based on liboqs 0.7.0
two days ago and everything worked: You may want to download the chromium build and try that before building everything from scratch.
from oqs-demos.
Thanks for your reply. I will try one more time. But I have already done it twice on different VMs.
I need a debug build, so I don't think I can use the build you are pointing me to, can I ?
from oqs-demos.
Would you happen to have any build scripts that are known to work ? I have tried creating my own, but so far failed.
"generate_build_files.py gn" ran without any error, though.
from oqs-demos.
I need a debug build, so I don't think I can use the build you are pointing me to, can I ?
Well, the published build does provide some debugging output, but no full gdb
-ready setup.
Would you happen to have any build scripts that are known to work ?
I once tried doing that (a Dockerfile, actually) -- but as a single test run takes way more than a day to execute I had to abandon that.
The best I can offer is ask (further) questions/ascertain the correctness of your setup; for this, would you please post output of the following commands after entering the directory CHROMIUM_ROOT
as documented: Posting below what would be expected. In case of differences, we'd need to investigate:
> cd third_party/boringssl
> git status
Refresh index: 100% (322699/322699), done.
HEAD detached at 85.0.4161.2
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: ../../net/cert/internal/simple_path_builder_delegate.cc
modified: BUILD.generated.gni
modified: BUILD.generated_tests.gni
modified: BUILD.gn
> cd src
git status
On branch oqs-bssl-master
Your branch is up to date with 'oqs-bssl/master'.
nothing to commit, working tree clean
> ls
API-CONVENTIONS.md CMakeLists.txt INCORPORATING.md README SANDBOXING.md codereview.settings fuzz oqs sources.cmake tool
BREAKING-CHANGES.md CONTRIBUTING.md LICENSE README.md STYLE.md crypto go.mod oqs_scripts ssl util
BUILDING.md FUZZING.md PORTING.md RELEASE.md build decrepit include oqs_template third_party
> cd ../../..
> ./build/install-build-deps.sh
[lots of output, should end with]
No missing packages, and the packages are up to date.
Installing Chrome OS fonts.
Chrome OS fonts already up to date in /usr/local/share/fonts/chromeos.
Installing locales.
Locales already up-to-date.
> gclient sync --force
Syncing projects: 100% (129/129), done.
Running hooks: 100% (112/112), done.
[numbers may differ based on your architecture/setup]
> gn gen out/Test
Done. Made 13309 targets from 2331 files in 3461ms
[numbers may differ based on your architecture/setup]
> autoninja -C out/Test chrome
ninja: Entering directory `out/Test'
[245/44903] CXX obj/base/base/string_piece.o^C
The last command should deliver chrome
in out/Test
after several hours.
from oqs-demos.
Thanks. I need the gdb-ready build. This is helpful. I'm making some progress. Indeed, it takes a very long time for one attempt. A whole day on my beefy home PC with virtualbox. . Much less than a full day on an Amazon EC2 instance I have access to. I already have scripts that work for the non-PQC version. Hoping to have scripts that work for pqc version also soon.
This is what I have at the moment :
more *.sh
::::::::::::::
apply_patch.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT
wget https://raw.githubusercontent.com/open-quantum-safe/oqs-demos/main/chromium/oqs-mods.patch
git apply ./oqs-mods.patch
::::::::::::::
build_chromium.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT
autoninja -C out/Default chrome
ubuntu@ip-172-31-39-87:~/scripts/oqs2$ more *.sh |cat
::::::::::::::
apply_patch.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT
wget https://raw.githubusercontent.com/open-quantum-safe/oqs-demos/main/chromium/oqs-mods.patch
git apply ./oqs-mods.patch
::::::::::::::
build_chromium.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT
autoninja -C out/Default chrome
::::::::::::::
build_liboqs.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $PROJECT
git clone --branch main https://github.com/open-quantum-safe/liboqs.git
cd liboqs && mkdir build && cd build
cmake .. -G"Ninja" -DCMAKE_INSTALL_PREFIX=$CHROMIUM_ROOT/third_party/boringssl/src/oqs -DOQS_USE_OPENSSL=OFF
ninja && ninja install
::::::::::::::
build_options.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT
gn gen out/Default --enable_nacl=false --use_debug_fission=false --is_clang=false --blink_symbol_level=0 --CCACHE_BASEDIR=/home/madbrain
::::::::::::::
gen_build_files.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT/third_party/boringssl
python src/util/generate_build_files.py gn
::::::::::::::
getpqc.sh
::::::::::::::
#!/bin/bash
mkdir -p $PROJECT
cd $PROJECT
time fetch --nohooks chromium
cd src
git checkout 85.0.4161.2
time gclient sync -D
::::::::::::::
install_deps.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT
./build/install-build-deps.sh
::::::::::::::
run_hooks.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT
gclient runhooks
::::::::::::::
set_root.sh
::::::::::::::
#!/bin/bash
export CHROMIUM_ROOT=$PROJECT/src
::::::::::::::
switch_boringssl.sh
::::::::::::::
#!/bin/bash
source set_root.sh
cd $CHROMIUM_ROOT/third_party/boringssl/src
git remote add oqs-bssl https://github.com/open-quantum-safe/boringssl
git fetch oqs-bssl
git checkout -b oqs-bssl-master oqs-bssl/master
I will contribute them to the project if I can get them to finally work.
from oqs-demos.
I will contribute them to the project if I can get them to finally work.
Sounds great. FYI, we have #98 pending moving to a new Chromium version, so you may want to make the version a variable, too.
And Yes, a serious multi core (AWS or so) VM makes building much less "coffee consuming" (or whatever you do while waiting :-)
from oqs-demos.
I have completed the scripts, but I'm waiting for permission for my employer to publish them in full.
I'm also trying to build liboqs on Windows. I guess that is a separate issue. I'm doing this at the command-line. I installed cmake and Visual Studio 2019 . CMAKE apparently needs some environment to be setup.
@echo off
mkdir %PROJECT%
cd %PROJECT%
call git clone --branch main https://github.com/open-quantum-safe/liboqs.git
cd liboqs
mkdir build
cd build
cmake .. -G"Ninja" -DCMAKE_INSTALL_PREFIX=%CHROMIUM_ROOT%\third_party\boringssl\src\oqs -DOQS_USE_OPENSSL=OFF
ninja && ninja install
D:\chromium\pqc>build_liboqs.bat
Cloning into 'liboqs'...
remote: Enumerating objects: 24320, done.
remote: Counting objects: 100% (1680/1680), done.
remote: Compressing objects: 100% (918/918), done.
Rremote: Total 24320 (delta 1025), reused 1237 (delta 742), pack-reused 22640
Receiving objects: 100% (24320/24320), 132.88 MiB | 15.80 MiB/s, done.
Resolving deltas: 100% (17198/17198), done.
Updating files: 100% (4955/4955), done.
-- The C compiler identification is MSVC 19.29.30133.0
-- The ASM compiler identification is MSVC
-- Found assembler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - failed
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe - broken
CMake Error at C:/Program Files/CMake/share/cmake-3.21/Modules/CMakeTestCCompiler.cmake:69 (message):
The C compiler
"C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: D:/liboqs/liboqs/build/CMakeFiles/CMakeTmp
Run Build Command(s):C:/depot_tools/ninja.exe cmTC_4d685 && [1/2] Building C object CMakeFiles\cmTC_4d685.dir\testCCompiler.c.obj
[2/2] Linking C executable cmTC_4d685.exe
FAILED: cmTC_4d685.exe
cmd.exe /C "cd . && "C:\Program Files\CMake\bin\cmake.exe" -E vs_link_exe --intdir=CMakeFiles\cmTC_4d685.dir --rc=rc --mt=CMAKE_MT-NOTFOUND --manifests -- C:\PROGRA~2\MICROS~4\2019\COMMUN~1\VC\Tools\MSVC\1429~1.301\bin\Hostx64\x64\link.exe /nologo CMakeFiles\cmTC_4d685.dir\testCCompiler.c.obj /out:cmTC_4d685.exe /implib:cmTC_4d685.lib /pdb:cmTC_4d685.pdb /version:0.0 /machine:x64 /debug /INCREMENTAL /subsystem:console kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib && cd ."
RC Pass 1: command "rc /fo CMakeFiles\cmTC_4d685.dir/manifest.res CMakeFiles\cmTC_4d685.dir/manifest.rc" failed (exit code 0) with the following output:
The system cannot find the file specified
ninja: build stopped: subcommand failed.
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:15 (project)
-- Configuring incomplete, errors occurred!
See also "D:/liboqs/liboqs/build/CMakeFiles/CMakeOutput.log".
See also "D:/liboqs/liboqs/build/CMakeFiles/CMakeError.log".
ninja: error: loading 'build.ninja': The system cannot find the file specified.
Press any key to continue . . .
Any idea what I should do to fix this ?
I setup the environment as follows :
d:\chromium\pqc>type set_env.bat
@echo off
path c:\depot_tools;C:\Program Files (x86)\Resource Kit;c:\Program Files\Cmake\bin;%path%;C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30133\bin\Hostx64\x64
set DEPOT_TOOLS_WIN_TOOLCHAIN=0
set vs2019_install=C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
d:\chromium\pqc>notepad set_env.bat
d:\chromium\pqc>type set_root.bat
@echo off
set CHROMIUM_ROOT=%PROJECT%\src
d:\chromium\pqc>
My Windows batches are fine as far as the non-PQC build goes, but I'm stuck at liboqs build at the moment.
from oqs-demos.
I guess that is a separate issue.
It definitely is. Could you please create an issue here after checking the Windows CI scripts (e.g., https://github.com/open-quantum-safe/liboqs/blob/main/appveyor_build.bat) and platform specific build hints for guidance?
Sorry to be of no more help but I had only very limited exposure to building "stuff" on Windows, surely none with Chromium :-(
from oqs-demos.
@madbrain76 : Do you have an ubuntu version working OK? Any success with Windows? I tend to suggest closing this issue (or relabel it to be a Windows-only issue).
from oqs-demos.
Closing due to inactivity. Feel free to re-open when new information surfaces.
from oqs-demos.
Related Issues (20)
- unable to pull the chrome file from server HOT 1
- Cannot switch off OQS_HAVE_GETENTROPY, OQS_HAVE_EXPLICIT_BZERO HOT 3
- Fix integrations to specific commits?
- OQS Chromium(117.0.5863.0) : ERR_SSL_VERSION_OR_CIPHER_MISMATCH HOT 15
- curl --write-out time_appconnect for SSL/TLS Handshake variable is faulty HOT 4
- Failed to build oqs-nginx on Mac M1
- Failed to build httpd on Mac M1 HOT 1
- ee key too small has occured in nginx with debian:bookworm-slim HOT 5
- https://test.openquantumsafe.org:6000 does not accept `x25519_kyber768`
- Wireshark Docker Build Fails with WolfSSL Due to Undeclared 'QSC_SIG_CPS' Variable HOT 1
- Update test server with liboqs 0.9.2 release HOT 3
- Introduce CI mechanism to use specific liboqs/oqs-provider versions
- Add QUIC support HOT 3
- !DOCTYPE ERROR HOT 1
- Not able to get OQS-Chromium browser working - https://openquantumsafe.org/applications/tls.html#chromium HOT 19
- oqs-epiphany not working HOT 11
- qteslapi is not supported by oqs openssl HOT 1
- Dont get Server Temp Key in openssl s_client when testing HOT 1
- Update test server with liboqs 0.10.0 release HOT 8
- HAProxy HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from oqs-demos.