Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 11 additions & 12 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ test_asan_ubsan_gcc:
image: greenaddress/wallycore@sha256:956b107d688f549c6e3884424991b7d3d34d84173990d43046fd760d7918db7c
parallel:
matrix:
- CONFIGURE_ARGS: [--enable-elements=yes, --enable-elements=no,--enable-minimal=yes]
- CONFIGURE_ARGS: [ --enable-elements=no, --enable-elements=no --enable-minimal=yes, "", --enable-minimal=yes ]
tags:
- ga
script:
Expand All @@ -48,19 +48,19 @@ test_scan_build_clang:
image: greenaddress/wallycore@sha256:956b107d688f549c6e3884424991b7d3d34d84173990d43046fd760d7918db7c
parallel:
matrix:
- CONFIGURE_ARGS: [--enable-elements=yes, --enable-elements=no,--enable-minimal=yes]
- CONFIGURE_ARGS: [ --enable-elements=no, --enable-elements=no --enable-minimal=yes, "", --enable-minimal=yes ]
tags:
- ga
script:
- ./tools/cleanup.sh && ./tools/autogen.sh
- CC=clang scan-build-11 ./configure --enable-export-all --enable-swig-python --enable-swig-java --disable-clear-tests --disable-asm
- scan-build-11 --keep-cc --exclude src/secp256k1/ --status-bugs --keep-empty -o scan-build$CONFIGURE_ARGS make -j $(($(grep ^processor /proc/cpuinfo | wc -l) / 2))
- CC=clang scan-build-11 ./configure --enable-export-all --enable-swig-python --enable-swig-java --disable-clear-tests --disable-asm $CONFIGURE_ARGS
- scan-build-11 --keep-cc --exclude src/secp256k1/ --status-bugs --keep-empty -o scan-build-output make -j $(($(grep ^processor /proc/cpuinfo | wc -l) / 2))
artifacts:
expire_in: 3 days
name: scan-build$CONFIGURE_ARGS
name: scan-build-output
when: on_success
paths:
- scan-build$CONFIGURE_ARGS/*
- scan-build-output/

test_cmake:
stage: test
Expand Down Expand Up @@ -95,16 +95,15 @@ test_cmake:
test_amalgamation:
stage: test
image: greenaddress/wallycore@sha256:956b107d688f549c6e3884424991b7d3d34d84173990d43046fd760d7918db7c
parallel:
matrix:
- CC: [gcc, clang ]
BUILD_ARGS: [ "", -DBUILD_MINIMAL, -DBUILD_ELEMENTS, -DBUILD_ELEMENTS -DBUILD_MINIMAL ]
tags:
- ga
script:
- touch config.h
- gcc -Wall -W -Wextra -Werror -I. -I./src -I./src/ccan -I./src/secp256k1/include src/ctest/amalgamation_compile_test.c
- gcc -DBUILD_ELEMENTS -Wall -W -Wextra -Werror -I. -I./src -I./src/ccan -I./src/secp256k1/include src/ctest/amalgamation_compile_test.c
- gcc -DBUILD_ELEMENTS -DBUILD_MINIMAL -Wall -W -Wextra -Werror -I. -I./src -I./src/ccan -I./src/secp256k1/include src/ctest/amalgamation_compile_test.c
- clang -Wall -W -Wextra -Werror -I. -I./src -I./src/ccan -I./src/secp256k1/include src/ctest/amalgamation_compile_test.c
- clang -DBUILD_ELEMENTS -Wall -W -Wextra -Werror -I. -I./src -I./src/ccan -I./src/secp256k1/include src/ctest/amalgamation_compile_test.c
- clang -DBUILD_ELEMENTS -DBUILD_MINIMAL -Wall -W -Wextra -Werror -I. -I./src -I./src/ccan -I./src/secp256k1/include src/ctest/amalgamation_compile_test.c
- $CC $BUILD_ARGS -Wall -W -Wextra -Werror -I. -I./src -I./src/ccan -I./src/secp256k1/include src/ctest/amalgamation_compile_test.c

test_mingw_static_build:
stage: test
Expand Down
3 changes: 0 additions & 3 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -149,9 +149,6 @@ if test "x$standard_secp" = "xyes"; then
fi

if test "x$minimal" = "xyes"; then
if test "x$elements" = "xno"; then
AC_MSG_FAILURE([ERROR: Minimal mode requires Elements support to be enabled])
fi
AX_CHECK_COMPILE_FLAG([-DBUILD_MINIMAL=1], [AM_CFLAGS="$AM_CFLAGS -DBUILD_MINIMAL=1"])
fi

Expand Down
2 changes: 2 additions & 0 deletions src/transaction.c
Original file line number Diff line number Diff line change
Expand Up @@ -2111,6 +2111,8 @@ static int tx_to_bytes(const struct wally_tx *tx,
p += varbuff_to_bytes(output->rangeproof, output->rangeproof_len, p);
}
}
#else
(void)p; /* Prevent scan-build warning in non-elements builds */
#endif
*written = n;
return WALLY_OK;
Expand Down