diff options
| author | J08nY | 2023-01-30 16:18:10 +0100 |
|---|---|---|
| committer | J08nY | 2023-01-30 16:18:10 +0100 |
| commit | b0ec41b32eb342b6b7355e3b9aea17be250fb7d8 (patch) | |
| tree | 5a7b99d7200aab6218a31353d796d6b3ab6b0fd4 | |
| parent | 31c6a1783533f7e061244ff54a9a348ad9016504 (diff) | |
| download | ECTester-b0ec41b32eb342b6b7355e3b9aea17be250fb7d8.tar.gz ECTester-b0ec41b32eb342b6b7355e3b9aea17be250fb7d8.tar.zst ECTester-b0ec41b32eb342b6b7355e3b9aea17be250fb7d8.zip | |
| -rw-r--r-- | .gitmodules | 3 | ||||
| -rw-r--r-- | README.md | 11 | ||||
| m--------- | ext/ipp-crypto | 0 | ||||
| -rw-r--r-- | src/cz/crcs/ectester/standalone/libs/IppcpLib.java | 2 | ||||
| -rw-r--r-- | src/cz/crcs/ectester/standalone/libs/jni/Makefile | 9 |
5 files changed, 20 insertions, 5 deletions
diff --git a/.gitmodules b/.gitmodules index 5d6d62f..603e4d9 100644 --- a/.gitmodules +++ b/.gitmodules @@ -13,3 +13,6 @@ [submodule "ext/libressl"] path = ext/libressl url = https://github.com/libressl-portable/portable +[submodule "ext/ipp-crypto"] + path = ext/ipp-crypto + url = https://github.com/intel/ipp-crypto @@ -344,7 +344,7 @@ g++ -fPIC -shared -O2 -o botan_provider.so -Wl,-rpath,'$ORIGIN/lib' botan.o cpp_ g++ -fPIC -shared -O2 -o cryptopp_provider.so -Wl,-rpath,'$ORIGIN/lib' cryptopp.o cpp_utils.o -L. -L/usr/local/lib -lcryptopp -l:lib_timing.so ``` -BoringSSL and LibreSSL are included as git submodules. Make sure you run: `git submodule update --init --recursive` +BoringSSL, LibreSSL and ipp-crypto are included as git submodules. Make sure you run: `git submodule update --init --recursive` after checking out the ECTester repository to initialize them. To build BoringSSL do: ``` cd ext/boringssl @@ -364,6 +364,15 @@ cmake -GNinja -DBUILD_SHARED_LIBS=1 .. ninja ``` +To build ipp-crypto do: +(Make sure you have the necessary [build requirements](https://github.com/intel/ipp-crypto/blob/develop/BUILD.md)) +``` +cd ext/ipp-crypto +CC=clang CXX=clang++ cmake CMakeLists.txt -GNinja -Bbuild -DARCH=intel64 # Does not work with GCC 12+ +cd build +ninja +``` + #### Java diff --git a/ext/ipp-crypto b/ext/ipp-crypto new file mode 160000 +Subproject 48d0e528cf948f32a0ed6e734e6e211470e5971 diff --git a/src/cz/crcs/ectester/standalone/libs/IppcpLib.java b/src/cz/crcs/ectester/standalone/libs/IppcpLib.java index 42f9965..0dec0a2 100644 --- a/src/cz/crcs/ectester/standalone/libs/IppcpLib.java +++ b/src/cz/crcs/ectester/standalone/libs/IppcpLib.java @@ -9,7 +9,7 @@ import java.util.Set; public class IppcpLib extends NativeECLibrary { public IppcpLib() { - super("ippcp_provider", "ippcp"); + super("ippcp_provider", "lib_ippcp.so"); } @Override diff --git a/src/cz/crcs/ectester/standalone/libs/jni/Makefile b/src/cz/crcs/ectester/standalone/libs/jni/Makefile index 322c9c5..c3995e3 100644 --- a/src/cz/crcs/ectester/standalone/libs/jni/Makefile +++ b/src/cz/crcs/ectester/standalone/libs/jni/Makefile @@ -151,11 +151,14 @@ mbedtls.o: mbedtls.c # Intel Performance Primitives crypto shim ippcp: ippcp_provider.so -ippcp_provider.so: ippcp.o c_utils.o - $(CC) $(LFLAGS) -o $@ -Wl,-rpath,'$$ORIGIN/lib' $^ -L. -lippcp -l:lib_timing.so +lib_ippcp.so: + cp ../../../../../../../ext/ipp-crypto/build/.build/RELEASE/lib/libippcp.so lib_ippcp.so + +ippcp_provider.so: ippcp.o c_utils.o | lib_timing.so lib_ippcp.so + $(CC) $(LFLAGS) -o $@ -Wl,-rpath,'$$ORIGIN/lib' $^ -L. lib_ippcp.so -l:lib_timing.so ippcp.o: ippcp.c - $(CC) $(CFLAGS) -c $< + $(CC) -I../../../../../../../ext/ipp-crypto/build/.build/RELEASE/include/ $(CFLAGS) -c $< # MatrixSSL shim |
