Skip to content

Commit f0fea17

Browse files
committed
readme
1 parent 33f79eb commit f0fea17

File tree

1 file changed

+17
-61
lines changed

1 file changed

+17
-61
lines changed

readme.md

+17-61
Original file line numberDiff line numberDiff line change
@@ -10,63 +10,31 @@ Thirdparty networking is also supported. See `frontend_cryptoTools/tutorial/Netw
1010

1111
## Install
1212

13-
The library is *cross platform* and has been tested on both Windows, Linux and Mac. There are two library dependencies including [Boost 1.69](http://www.boost.org/) (networking), and two **optional dependencies** on, [Miracl](https://www.miracl.com/index), [Relic](https://github.com/relic-toolkit/relic/) for elliptic curves. The version of Miracl used by this library requires specific configuration and therefore we advise using the cloned repository that we provide.
14-
13+
The library is *cross platform* and has been tested on both Windows, Linux and Mac. There are two **optional dependencies** including [Boost 1.69](http://www.boost.org/) (networking), and [Relic](https://github.com/relic-toolkit/relic/) for elliptic curves.
14+
1515
### Windows
1616

1717
In `Powershell`, this will set up the project
1818

1919
```
2020
git clone --recursive https://github.com/ladnir/cryptoTools
2121
cd cryptoTools/thirdparty/win
22-
getBoost.ps1;
22+
[build boost at c:\libs\boost or thirdparty\win\boost]
2323
cd ../..
24-
cryptoTools.sln
24+
cmake .
2525
```
2626

27-
**Boost and visual studio 2017:** If boost does not build with visual studio 2017
28-
follow [these instructions](https://stackoverflow.com/questions/41464356/build-boost-with-msvc-14-1-vs2017-rc).
29-
30-
**Enabling Relic (for fast elliptic curves):**
31-
* Clone the Visual Studio port [Relic](https://github.com/ladnir/relic).
32-
* Use the CMake command `cmake . -DMULTI=OPENMP -DCMAKE_INSTALL_PREFIX:PATH=C:\libs -DCMAKE_GENERATOR_PLATFORM=x64` generate a Visual Studio solution
33-
* Optional: Build with gmp/mpir for faster performance.
34-
* Install it to `C:\libs` (build the `INSTALL` VS project).
35-
* Edit the config file [libOTe/cryptoTools/cryptoTools/Common/config.h](https://github.com/ladnir/cryptoTools/blob/master/cryptoTools/Common/config.h) to include `#define ENABLE_RELIC`.
36-
37-
**Enabling Miracl (for elliptic curves):**
38-
* `cd cryptoTools/thirdparty/win`
39-
* `getMiracl.ps1 ` (If the Miracl script fails to find visual studio 2017, manually open and build the Miracl solution.)
40-
* `cd ../..`
41-
* Edit the config file [libOTe/cryptoTools/cryptoTools/Common/config.h](https://github.com/ladnir/cryptoTools/blob/master/cryptoTools/Common/config.h) to include `#define ENABLE_MIRACL`.
42-
43-
**IMPORTANT:**
44-
By default, the build system needs the NASM compiler to be located
45-
at `C:\NASM\nasm.exe`. In the event that it isn't, there are two options, install it,
46-
or enable the pure c++ implementation:
47-
* Remove `cryptoTools/Crypto/asm/sha_win64.asm` from the cryptoTools Project.
48-
* Edit the config file [libOTe/cryptoTools/cryptoTools/Common/config.h](https://github.com/ladnir/cryptoTools/blob/master/cryptoTools/Common/config.h) to remove `#define ENABLE_NASM`.
27+
* See `cmake .` for build options.
4928

50-
**Other options:**
51-
* The implementation of binary circuits in cryptoTools (`BetaCircuit`) can be enabled by edit the config file [libOTe/cryptoTools/cryptoTools/Common/config.h](https://github.com/ladnir/cryptoTools/blob/master/cryptoTools/Common/config.h) to include `#define ENABLE_CIRCUITS`.
52-
53-
54-
**IMPORTANT:** By default, the build system needs the NASM compiler to be located
55-
at `C:\NASM\nasm.exe`. In the event that it isn't, there are two options, install it,
56-
or enable the pure c++ implementation:
57-
* Remove `cryptoTools/Crypto/asm/sha_win64.asm` from the cryptoTools Project.
58-
* Edit the config file [libOTe/cryptoTools/cryptoTools/Common/config.h](https://github.com/ladnir/cryptoTools/blob/master/cryptoTools/Common/config.h) to remove `#define ENABLE_NASM`.
59-
60-
61-
Build the solution within visual studio or with `MSBuild`. To see all the command line options, execute the program
62-
63-
`frontend.exe`
64-
29+
**Enable elliptic curves using:**
30+
* `cmake . -DENABLE_RELIC=ON`: Build the library with integration to the
31+
[Relic](https://github.com/relic-toolkit/relic/) library. Requires that
32+
relic is built with `cmake . -DMULTI=OPENMP` and installed.
6533

34+
**Boost and visual studio:** If boost does not build with visual studio 2017+
35+
follow [these instructions](https://stackoverflow.com/questions/41464356/build-boost-with-msvc-14-1-vs2017-rc).
6636

67-
68-
69-
### Linux
37+
### Unix
7038

7139
In short, this will build the project (without elliptic curves)
7240

@@ -78,32 +46,20 @@ cd ../../..
7846
make
7947
```
8048

81-
This will build the minimum version of the library (wihtout elliptic curves). The libraries
82-
will be placed in `libOTe/lib` and the binary `frontend_libOTe` will be placed in
83-
`libOTe/bin` To see all the command line options, execute the program
49+
This will build the minimum version of the library (wihtout elliptic curves).
50+
To see all the command line options, execute the program
8451

85-
`./bin/frontend_libOTe`
52+
`./frontend_libOTe`
8653

8754

8855
**Enable elliptic curves using:**
8956
* `cmake . -DENABLE_RELIC=ON`: Build the library with integration to the
9057
[Relic](https://github.com/relic-toolkit/relic/) library. Requires that
91-
relic is built with `cmake . -DMULTI=OPENMP` and installed.
92-
* `cmake . -DENABLE_MIRACL=ON`: Build the library with integration to the
93-
[Miracl](https://www.miracl.com/index) library. Requires building miracl
94-
` cd libOTe/cryptoTools/thirdparty/linux; bash miracl.get`.
95-
96-
**Other Options:**
97-
* `cmake . -DENABLE_CIRCUITS=ON`: Build the library with the circuit library enabled.
98-
* `cmake . -DENABLE_NASM=ON`: Build the library with the assembly base SHA1 implementation. Requires the NASM compiler.
99-
100-
58+
relic is built with `cmake . -DMULTI=PTHREAD` and installed.
10159

10260
**Note:** In the case that miracl or boost is already installed, the steps
10361
`cd cryptoTools/thirdparty/linux; bash boost.get` can be skipped and CMake will attempt
104-
to find them instead. Boost is found with the CMake findBoost package and miracl
105-
is found with the `find_library(miracl)` command.
106-
62+
to find them instead. Boost is found with the CMake findBoost package.
10763

10864

10965
## License

0 commit comments

Comments
 (0)