Skip to content

Commit

Permalink
Use in cryptest-cmake.sh test
Browse files Browse the repository at this point in the history
  • Loading branch information
noloader committed Sep 10, 2018
1 parent fc5a731 commit d0946ab
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
8 changes: 7 additions & 1 deletion TestScripts/cryptest-autotools.sh
@@ -1,5 +1,11 @@
#!/usr/bin/env bash

PWD_DIR=$(pwd)
function cleanup {
cd "$PWD_DIR"
}
trap cleanup EXIT

GREP=grep
SED=sed
AWK=awk
Expand Down Expand Up @@ -119,7 +125,7 @@ if ! ./configure; then
[[ "$0" = "${BASH_SOURCE[0]}" ]] && exit 1 || return 1
fi

make clean 2>/dev/null
"$MAKE" clean 2>/dev/null

if ! "$MAKE" -j2 -f Makefile; then
echo "make failed."
Expand Down
9 changes: 7 additions & 2 deletions TestScripts/cryptest-cmake.sh
Expand Up @@ -6,6 +6,11 @@ function cleanup {
}
trap cleanup EXIT

# Fixup for Solaris and BSDs
if [[ ! -z $(command -v gmake) ]]; then
MAKE=gmake
fi

# Feth the three required files
if ! wget --no-check-certificate https://raw.githubusercontent.com/noloader/cryptopp-cmake/master/CMakeLists.txt -O CMakeLists.txt; then
echo "CMakeLists.txt download failed"
Expand All @@ -28,9 +33,9 @@ if ! cmake ../; then
[[ "$0" = "${BASH_SOURCE[0]}" ]] && exit 1 || return 1
fi

make clean 2>/dev/null
"$MAKE" clean 2>/dev/null

if ! make -j2 -f Makefile VERBOSE=1; then
if ! "$MAKE" -j2 -f Makefile VERBOSE=1; then
echo "make failed"
[[ "$0" = "${BASH_SOURCE[0]}" ]] && exit 1 || return 1
fi
Expand Down

0 comments on commit d0946ab

Please sign in to comment.