Remove keyconv files to fix the license issue.
[aaf/sshsm.git] / build.sh
index 6365435..856fcc2 100644 (file)
--- a/build.sh
+++ b/build.sh
@@ -17,27 +17,33 @@ sudo apt-get -y install \
     libcmocka0 \
     libcmocka-dev \
     build-essential \
-    git \
     pkg-config \
-    vim \
     gcc \
     g++ \
     m4 \
     curl \
     wget \
     liburiparser-dev \
-    libssl-dev \
     pandoc \
     opensc \
     default-jdk \
     libgcrypt20-dev
 
-export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/
+wget https://www.openssl.org/source/openssl-1.1.0.tar.gz
+gzip -d openssl-1.1.0.tar.gz
+tar -xvf openssl-1.1.0.tar
+cd openssl-1.1.0 && \
+    ./config --prefix=/usr/local/ssl --openssldir=/usr/local/ssl && \
+    make && \
+sudo make install
+cd ..
+
+export LD_LIBRARY_PATH=/usr/local/ssl/lib
 
 echo "Build SoftHSMv2..."
 cd SoftHSMv2
 sh autogen.sh
-./configure --disable-gost --with-openssl=/usr/local/
+./configure --disable-gost --with-openssl=/usr/local/ssl
 make
 make check
 sudo make install
@@ -70,7 +76,7 @@ cd ..
 rm -rf tpm2-abrmd-2.0.0
 
 cd tpm2-tools-3.1.0
-./configure
+./configure --disable-hardening
 make
 sudo make install
 cd ..
@@ -84,7 +90,12 @@ cd ../..
 echo "Build TPM-Plugin"
 cd TPM2-Plugin
 ./bootstrap
-./configure
+./configure LDFLAGS="-L/usr/local/ssl/lib"
 sudo make install
 cd ..
 sudo ldconfig
+
+echo "Build Duplicate Utility tool"
+cd tpm-util/duplicate
+make -f sampleMakefile
+