libssh: Enable support for none ciphers to unbreak build (#3770)

* libssh: Enable support for none ciphers to unbreak build

https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=22074

* Add a new include for libssh_version.h

https://gitlab.com/libssh/libssh-mirror/-/merge_requests/116
This commit is contained in:
Jakub Jelen 2020-05-07 14:29:33 +02:00 committed by GitHub
parent 5dbaaea032
commit f5dbd469c6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -20,14 +20,14 @@ mkdir -p $BUILD
pushd $BUILD
cmake -DCMAKE_C_COMPILER="$CC" -DCMAKE_CXX_COMPILER="$CXX" \
-DCMAKE_C_FLAGS="$CFLAGS" -DCMAKE_CXX_FLAGS="$CXXFLAGS" \
-DBUILD_SHARED_LIBS=OFF $SRC/libssh
-DBUILD_SHARED_LIBS=OFF -DWITH_INSECURE_NONE=ON $SRC/libssh
make "-j$(nproc)"
fuzzers=$(find $SRC/libssh/tests/fuzz/ -name "*_fuzzer.cpp")
for f in $fuzzers; do
fuzzerName=$(basename $f .cpp)
echo "Building fuzzer $fuzzerName"
$CXX $CXXFLAGS -std=c++11 -I$SRC/libssh/include/ \
$CXX $CXXFLAGS -std=c++11 -I$SRC/libssh/include/ -I$BUILD/include/ \
"$f" -o "$OUT/$fuzzerName" \
$LIB_FUZZING_ENGINE ./src/libssh.a -Wl,-Bstatic -lcrypto -lz -Wl,-Bdynamic