Skip to content

Commit c32e777

Browse files
committed
merge silent and coproto
1 parent 9cb4bbf commit c32e777

File tree

156 files changed

+21061
-13767
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

156 files changed

+21061
-13767
lines changed

.github/workflows/build-test.yml

Lines changed: 23 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ name: CI
66
on:
77
# Triggers the workflow on push or pull request events but only for the master branch
88
push:
9-
branches: [ master, ci, soft]
9+
branches: [ master, stage, coproto ]
1010
pull_request: {}
1111

1212
# Allows you to run this workflow manually from the Actions tab
@@ -18,6 +18,7 @@ jobs:
1818
build-ubuntu:
1919
# The type of runner that the job will run on
2020
runs-on: ubuntu-latest
21+
timeout-minutes: 20
2122

2223
# Steps represent a sequence of tasks that will be executed as part of the job
2324
steps:
@@ -27,17 +28,15 @@ jobs:
2728
submodules: recursive
2829

2930
# Runs a set of commands using the runners shell
30-
- name: build boost
31-
run: python3 build.py --setup --boost --par=4
32-
31+
3332
- name: build relic
34-
run: python3 build.py --setup --relic --par=4
35-
33+
run: python3 build.py --setup --relic --par=4 -DVERBOSE_FETCH=ON -DENABLE_BOOST=OFF -DENABLE_SODIUM=OFF
34+
3635
- name: build bitpolymul
37-
run: python3 build.py --setup --bitpolymul --par=4
36+
run: python3 build.py --setup --bitpolymul --par=4 -DVERBOSE_FETCH=ON
3837

3938
- name: build libOTe
40-
run: python3 build.py --par=4 -D ENABLE_ALL_OT=ON -D ENABLE_RELIC=ON -DENABLE_CIRCUIT=ON -DENABLE_BITPOLYMUL=ON
39+
run: python3 build.py --par=4 -D ENABLE_ALL_OT=ON -DENABLE_CIRCUITS=ON
4140

4241
- name: unit tests
4342
run: ./out/build/linux/frontend/frontend_libOTe -u
@@ -63,7 +62,7 @@ jobs:
6362
6463
- name: install prefix test
6564
run: |
66-
python3 build.py --setup --boost --relic --bitpolymul --install=~/install
65+
python3 build.py --setup --relic --bitpolymul --install=~/install
6766
python3 build.py --install=~/install
6867
cd libOTe_Tests/cmakeTests
6968
cmake -S . -B out/ -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=~/install
@@ -75,7 +74,7 @@ jobs:
7574
7675
- name: install test
7776
run: |
78-
python3 build.py --setup --boost --relic --bitpolymul --install --sudo
77+
python3 build.py --setup --relic --bitpolymul --install --sudo
7978
python3 build.py --install --sudo
8079
cd libOTe_Tests/cmakeTests
8180
cmake -S . -B out/ -DCMAKE_BUILD_TYPE=Release
@@ -84,11 +83,14 @@ jobs:
8483
rm -rf out/
8584
cd ../..
8685
86+
8787
- name: build sodium
88-
run: python3 build.py --setup --sodium --par=4
88+
run: python3 build.py --setup --sodium --par=4 -DVERBOSE_FETCH=ON -DENABLE_BOOST=OFF
8989

9090
- name: build libOTe
91-
run: python3 build.py --par=4 -D ENABLE_ALL_OT=ON -D ENABLE_SODIUM=ON -DENABLE_RELIC=OFF
91+
run: |
92+
rm ./out/build/linux/frontend/frontend_libOTe
93+
python3 build.py --par=4 -D ENABLE_ALL_OT=ON -D ENABLE_SODIUM=ON -DENABLE_RELIC=OFF -DPRINT_LOG_ON_FAIL=ON
9294
9395
- name: unit tests
9496
run: ./out/build/linux/frontend/frontend_libOTe -u
@@ -114,7 +116,7 @@ jobs:
114116
115117
- name: install prefix test
116118
run: |
117-
python3 build.py --setup --boost --relic --sodium --install=~/install
119+
python3 build.py --setup --sodium --install=~/install
118120
python3 build.py --install=~/install
119121
cd libOTe_Tests/cmakeTests
120122
cmake -S . -B out/ -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=~/install
@@ -126,7 +128,7 @@ jobs:
126128
127129
- name: install test
128130
run: |
129-
python3 build.py --setup --boost --sodium --install --sudo
131+
python3 build.py --setup --sodium --install --sudo
130132
python3 build.py --install --sudo
131133
cd libOTe_Tests/cmakeTests
132134
cmake -S . -B out/ -DCMAKE_BUILD_TYPE=Release
@@ -139,6 +141,7 @@ jobs:
139141
build-osx:
140142
# The type of runner that the job will run on
141143
runs-on: macos-latest
144+
timeout-minutes: 20
142145

143146
# Steps represent a sequence of tasks that will be executed as part of the job
144147
steps:
@@ -148,15 +151,9 @@ jobs:
148151
submodules: recursive
149152

150153
# Runs a set of commands using the runners shell
151-
- name: build boost
152-
run: python3 build.py --setup --boost --par=4 -D ENABLE_SSE=OFF -D ENABLE_AVX=OFF -DENABLE_BITPOLYMUL=OFF
153154

154-
- name: build relic
155-
run: python3 build.py --setup --relic --par=4 -D ENABLE_SSE=OFF -D ENABLE_AVX=OFF -DENABLE_BITPOLYMUL=OFF
156-
157155
- name: build libOTe
158-
run: |
159-
python3 build.py --par=4 -D ENABLE_ALL_OT=ON -D ENABLE_RELIC=ON -D ENABLE_SSE=OFF -D ENABLE_AVX=OFF -DENABLE_BITPOLYMUL=OFF
156+
run: python3 build.py -DENABLE_BOOST=OFF -DVERBOSE_FETCH=ON -DENABLE_SSE=OFF -DENABLE_RELIC=ON -D ENABLE_ALL_OT=ON
160157

161158
- name: unit tests
162159
run: ./out/build/osx/frontend/frontend_libOTe -u
@@ -182,7 +179,7 @@ jobs:
182179
183180
- name: install prefix test
184181
run: |
185-
python3 build.py --setup --boost --relic --install=~/install
182+
python3 build.py --setup --relic --install=~/install
186183
python3 build.py --install=~/install
187184
cd libOTe_Tests/cmakeTests
188185
cmake -S . -B out/ -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=~/install
@@ -194,7 +191,7 @@ jobs:
194191
195192
- name: install test
196193
run: |
197-
python3 build.py --setup --boost --relic --install --sudo
194+
python3 build.py --setup --relic --install --sudo
198195
python3 build.py --install --sudo
199196
cd libOTe_Tests/cmakeTests
200197
cmake -S . -B out/ -DCMAKE_BUILD_TYPE=Release
@@ -207,6 +204,7 @@ jobs:
207204
build-windows:
208205
# The type of runner that the job will run on
209206
runs-on: windows-2019
207+
timeout-minutes: 20
210208

211209
# Steps represent a sequence of tasks that will be executed as part of the job
212210
steps:
@@ -218,11 +216,8 @@ jobs:
218216
- uses: ilammy/msvc-dev-cmd@v1
219217

220218
# Runs a set of commands using the runners shell
221-
- name: build boost
222-
run: python3 build.py --setup --boost --par=4 -G Ninja
223-
224219
- name: build relic
225-
run: python3 build.py --setup --relic --par=4 -G Ninja
220+
run: python3 build.py --setup --relic --par=4 -G Ninja -DENABLE_BOOST=OFF -DVERBOSE_FETCH=ON
226221

227222
- name: build libOTe
228223
run: python3 build.py --par=4 -D ENABLE_ALL_OT=ON -D ENABLE_RELIC=ON -G Ninja
@@ -253,7 +248,7 @@ jobs:
253248
254249
- name: install prefix test
255250
run: |
256-
python3 build.py --relic --boost --bitpolymul --install=~/install
251+
python3 build.py --relic --bitpolymul --install=~/install
257252
cd libOTe_Tests/cmakeTests
258253
cmake -S . -B out/ -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=~/install
259254
cmake --build out/ --config Release

CMakeLists.txt

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,6 @@ if("${CMAKE_CURRENT_SOURCE_DIR}" STREQUAL "${CMAKE_SOURCE_DIR}")
1818
############################################
1919
add_definitions(-DSOLUTION_DIR='${CMAKE_SOURCE_DIR}')
2020
if(MSVC)
21-
22-
# optionally add the following to CMAKE_PREFIX_PATH
23-
if(NOT DEFINED CMAKE_PREFIX_PATH AND NOT DEFINED NO_OC_DEFAULT_PREFIX)
24-
set(CMAKE_PREFIX_PATH
25-
"c:/libs"
26-
"${CMAKE_CURRENT_LIST_DIR}/..;"
27-
)
28-
endif()
29-
3021
else()
3122
set(COMMON_FLAGS "-Wall -march=native -Wfatal-errors")
3223
SET(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG")

CMakePresets.json

Lines changed: 33 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,19 @@
88
"generator": "Ninja",
99
"binaryDir": "${sourceDir}/out/build/${presetName}",
1010
"cacheVariables": {
11-
"CMAKE_BUILD_TYPE": "Release",
12-
"FETCH_AUTO": true,
13-
"VERBOSE_FETCH": true,
14-
"ENABLE_RELIC": true,
11+
"CMAKE_BUILD_TYPE": "Debug",
1512
"ENABLE_ALL_OT": true,
13+
"LIBOTE_CPP_VER": "17",
14+
"ENABLE_KKRT": "ON",
15+
"ENABLE_IKNP": "ON",
16+
"ENABLE_MR": "ON",
17+
"ENABLE_SIMPLESTOT": "ON",
18+
"ENABLE_RELIC": "OFF",
19+
"ENABLE_SODIUM": "ON",
20+
"ENABLE_BOOST": "OFF",
21+
"FETCH_AUTO": "ON",
22+
"ENABLE_CIRCUITS": true,
23+
"VERBOSE_FETCH": true,
1624
"CMAKE_INSTALL_PREFIX": "${sourceDir}/out/install/${presetName}"
1725
},
1826
"vendor": {
@@ -32,14 +40,20 @@
3240
},
3341
"cacheVariables": {
3442
"CMAKE_BUILD_TYPE": "Debug",
35-
"FETCH_AUTO": true,
36-
"VERBOSE_FETCH": true,
37-
"ENABLE_BOOST": true,
38-
"ENABLE_RELIC": true,
43+
"LIBOTE_CPP_VER": "17",
3944
"ENABLE_ALL_OT": true,
40-
"ENABLE_BITPOLYMUl": false,
41-
"ENABLE_SSE": false,
42-
"ENABLE_AVX": false,
45+
"ENABLE_KKRT": "ON",
46+
"ENABLE_IKNP": "ON",
47+
"ENABLE_MR": "ON",
48+
"ENABLE_SIMPLESTOT": "ON",
49+
"ENABLE_RELIC": "ON",
50+
"ENABLE_BOOST": "ON",
51+
"ENABLE_BITPOLYMUL": true,
52+
"FETCH_AUTO": "ON",
53+
"ENABLE_CIRCUITS": true,
54+
"VERBOSE_FETCH": true,
55+
"ENABLE_SSE": true,
56+
"ENABLE_AVX": true,
4357
"CMAKE_INSTALL_PREFIX": "${sourceDir}/out/install/${presetName}"
4458
},
4559
"vendor": { "microsoft.com/VisualStudioSettings/CMake/1.0": { "hostOS": [ "Windows" ] } }
@@ -56,7 +70,14 @@
5670
},
5771
"cacheVariables": {
5872
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
59-
"FETCH_AUTO": true,
73+
"LIBOTE_CPP_VER": "17",
74+
"ENABLE_ALL_OT": true,
75+
"ENABLE_RELIC": true,
76+
"COPROTO_ENABLE_BOOST": true,
77+
"ENABLE_BOOST": "OFF",
78+
"FETCH_AUTO": "ON",
79+
"ENABLE_CIRCUITS": true,
80+
"ENABLE_BITPOLYMUL": true,
6081
"VERBOSE_FETCH": true,
6182
"ENABLE_RELIC": true,
6283
"ENABLE_ALL_OT": true,

LICENSE

Lines changed: 1 addition & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,5 @@
1-
Dual-licensed under Unlicense or MIT.
2-
3-
4-
----------------------- Unlicense ---------------------------
5-
6-
This is free and unencumbered software released into the public domain.
7-
8-
Anyone is free to copy, modify, publish, use, compile, sell, or
9-
distribute this software, either in source code form or as a compiled
10-
binary, for any purpose, commercial or non-commercial, and by any
11-
means.
12-
13-
In jurisdictions that recognize copyright laws, the author or authors
14-
of this software dedicate any and all copyright interest in the
15-
software to the public domain. We make this dedication for the benefit
16-
of the public at large and to the detriment of our heirs and
17-
successors. We intend this dedication to be an overt act of
18-
relinquishment in perpetuity of all present and future rights to this
19-
software under copyright law.
20-
21-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
22-
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
23-
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
24-
IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
25-
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
26-
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
27-
OTHER DEALINGS IN THE SOFTWARE.
28-
29-
For more information, please refer to <http://unlicense.org/>
30-
31-
32-
----------------------- MIT ---------------------------
331
Copyright 2016 Peter Rindal
2+
Coptright 2022 Visa
343

354
Permission is hereby granted, free of charge, to any person obtaining a copy of this
365
software and associated documentation files (the "Software"), to deal in the Software

0 commit comments

Comments
 (0)