2021-07-05 18:59:03 +08:00
|
|
|
#!/bin/sh -e
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
|
|
|
|
# This script runs one build with setup environment variables: BUILD_LIBPCAP,
|
2021-07-23 08:52:50 +08:00
|
|
|
# REMOTE, CC, CMAKE, CRYPTO and SMB.
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
|
2021-07-23 08:52:50 +08:00
|
|
|
: "${BUILD_LIBPCAP:=no}"
|
|
|
|
: "${REMOTE:=no}"
|
|
|
|
: "${CC:=gcc}"
|
|
|
|
: "${CMAKE:=no}"
|
|
|
|
: "${CRYPTO:=no}"
|
|
|
|
: "${SMB:=no}"
|
2021-07-30 16:44:04 +08:00
|
|
|
: "${TCPDUMP_TAINTED:=no}"
|
2021-08-18 03:35:21 +08:00
|
|
|
: "${MAKE_BIN:=make}"
|
2021-07-23 08:52:50 +08:00
|
|
|
|
|
|
|
. ./build_common.sh
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
# Install directory prefix
|
2021-03-21 08:26:58 +08:00
|
|
|
if [ -z "$PREFIX" ]; then
|
2021-07-23 08:52:50 +08:00
|
|
|
PREFIX=`mktempdir tcpdump_build`
|
2021-03-21 08:26:58 +08:00
|
|
|
echo "PREFIX set to '$PREFIX'"
|
|
|
|
fi
|
2021-07-23 08:52:50 +08:00
|
|
|
TCPDUMP_BIN="$PREFIX/bin/tcpdump"
|
2021-08-03 22:31:54 +08:00
|
|
|
# For TESTrun
|
2021-07-23 08:52:50 +08:00
|
|
|
export TCPDUMP_BIN
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
|
2021-07-23 08:52:50 +08:00
|
|
|
print_cc_version
|
2021-07-30 17:12:59 +08:00
|
|
|
|
|
|
|
# The norm is to compile without any warnings, but tcpdump builds on some OSes
|
|
|
|
# are not warning-free for one or another reason. If you manage to fix one of
|
|
|
|
# these cases, please remember to remove respective exemption below to help any
|
|
|
|
# later warnings in the same matrix subset trigger an error.
|
2021-08-05 21:18:55 +08:00
|
|
|
|
2021-08-18 00:39:47 +08:00
|
|
|
case `cc_id`/`os_id` in
|
2022-03-11 23:07:08 +08:00
|
|
|
clang-*/SunOS-5.11)
|
|
|
|
# (Clang 9 on OpenIndiana, Clang 11 on OmniOS)
|
2021-08-18 00:39:47 +08:00
|
|
|
# tcpdump.c:2312:51: warning: this function declaration is not a prototype
|
|
|
|
# [-Wstrict-prototypes]
|
|
|
|
# tcpdump.c:2737:11: warning: this function declaration is not a prototype
|
|
|
|
# [-Wstrict-prototypes]
|
|
|
|
[ "`uname -o`" = illumos ] && TCPDUMP_TAINTED=yes
|
|
|
|
;;
|
|
|
|
esac
|
2021-08-05 21:18:55 +08:00
|
|
|
|
2021-07-30 17:12:59 +08:00
|
|
|
[ "$TCPDUMP_TAINTED" != yes ] && CFLAGS=`cc_werr_cflags`
|
|
|
|
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
if [ "$CMAKE" = no ]; then
|
|
|
|
if [ "$BUILD_LIBPCAP" = yes ]; then
|
|
|
|
echo "Using PKG_CONFIG_PATH=$PKG_CONFIG_PATH"
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo ./configure --with-crypto="$CRYPTO" \
|
|
|
|
--enable-smb="$SMB" --prefix="$PREFIX"
|
|
|
|
LD_LIBRARY_PATH="$PREFIX/lib"
|
|
|
|
export LD_LIBRARY_PATH
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
else
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo ./configure --with-crypto="$CRYPTO" \
|
|
|
|
--enable-smb="$SMB" --prefix="$PREFIX" --disable-local-libpcap
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
fi
|
|
|
|
else
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo rm -rf build
|
|
|
|
run_after_echo mkdir build
|
|
|
|
run_after_echo cd build
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
if [ "$BUILD_LIBPCAP" = yes ]; then
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo cmake -DWITH_CRYPTO="$CRYPTO" -DENABLE_SMB="$SMB" \
|
2021-07-30 17:12:59 +08:00
|
|
|
${CFLAGS:+-DEXTRA_CFLAGS="$CFLAGS"} \
|
2021-07-23 08:52:50 +08:00
|
|
|
-DCMAKE_INSTALL_PREFIX="$PREFIX" -DCMAKE_PREFIX_PATH="$PREFIX" ..
|
|
|
|
LD_LIBRARY_PATH="$PREFIX/lib"
|
|
|
|
export LD_LIBRARY_PATH
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
else
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo cmake -DWITH_CRYPTO="$CRYPTO" -DENABLE_SMB="$SMB" \
|
2021-07-30 17:12:59 +08:00
|
|
|
${CFLAGS:+-DEXTRA_CFLAGS="$CFLAGS"} \
|
2021-07-23 08:52:50 +08:00
|
|
|
-DCMAKE_INSTALL_PREFIX="$PREFIX" ..
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
fi
|
|
|
|
fi
|
2021-08-18 03:35:21 +08:00
|
|
|
run_after_echo "$MAKE_BIN" -s clean
|
2021-07-30 17:12:59 +08:00
|
|
|
if [ "$CMAKE" = no ]; then
|
2021-08-18 03:35:21 +08:00
|
|
|
run_after_echo "$MAKE_BIN" -s ${CFLAGS:+CFLAGS="$CFLAGS"}
|
2021-07-30 17:12:59 +08:00
|
|
|
else
|
|
|
|
# The "-s" flag is a no-op and CFLAGS is set using -DEXTRA_CFLAGS above.
|
2021-08-18 03:35:21 +08:00
|
|
|
run_after_echo "$MAKE_BIN"
|
2021-07-30 17:12:59 +08:00
|
|
|
fi
|
2021-08-18 03:35:21 +08:00
|
|
|
run_after_echo "$MAKE_BIN" install
|
2021-07-26 22:33:17 +08:00
|
|
|
print_so_deps "$TCPDUMP_BIN"
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo "$TCPDUMP_BIN" -h
|
2021-07-30 23:20:34 +08:00
|
|
|
# The "-D" flag depends on HAVE_PCAP_FINDALLDEVS and it would not be difficult
|
|
|
|
# to run the command below only if the macro is defined. That said, it seems
|
|
|
|
# more useful to run it anyway: every system that currently runs this script
|
|
|
|
# has pcap_findalldevs(), thus if the macro isn't defined, it means something
|
|
|
|
# went wrong in the build process (as was observed with GCC, CMake and the
|
|
|
|
# system libpcap on Solaris 11).
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo "$TCPDUMP_BIN" -D
|
2021-07-08 00:37:12 +08:00
|
|
|
if [ "$CIRRUS_CI" = true ]; then
|
2021-07-30 23:20:34 +08:00
|
|
|
# Likewise for the "-J" flag and HAVE_PCAP_SET_TSTAMP_TYPE.
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo sudo \
|
|
|
|
${LD_LIBRARY_PATH:+LD_LIBRARY_PATH="$LD_LIBRARY_PATH"} \
|
|
|
|
"$TCPDUMP_BIN" -J
|
|
|
|
run_after_echo sudo \
|
|
|
|
${LD_LIBRARY_PATH:+LD_LIBRARY_PATH="$LD_LIBRARY_PATH"} \
|
|
|
|
"$TCPDUMP_BIN" -L
|
2021-07-08 00:37:12 +08:00
|
|
|
fi
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
if [ "$BUILD_LIBPCAP" = yes ]; then
|
2021-08-18 03:35:21 +08:00
|
|
|
run_after_echo "$MAKE_BIN" check
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
fi
|
|
|
|
if [ "$CMAKE" = no ]; then
|
2021-08-18 03:35:21 +08:00
|
|
|
run_after_echo "$MAKE_BIN" releasetar
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
fi
|
2021-07-08 00:37:12 +08:00
|
|
|
if [ "$CIRRUS_CI" = true ]; then
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo sudo \
|
|
|
|
${LD_LIBRARY_PATH:+LD_LIBRARY_PATH="$LD_LIBRARY_PATH"} \
|
|
|
|
"$TCPDUMP_BIN" -#n -c 10
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
fi
|
2021-07-23 08:52:50 +08:00
|
|
|
handle_matrix_debug
|
2021-03-21 08:26:58 +08:00
|
|
|
if [ "$DELETE_PREFIX" = yes ]; then
|
2021-07-23 08:52:50 +08:00
|
|
|
run_after_echo rm -rf "$PREFIX"
|
2021-03-21 08:26:58 +08:00
|
|
|
fi
|
Add the build_matrix.sh and build.sh scripts
Use them with Travis CI to build with less builders and save CI runtime.
This will currently run five builders: amd64, arm64, ppc64le, s390x and osx.
The build_matrix.sh script executes the matrix loops, exclude tests and
cleaning.
It conditionally builds libpcap running the build.sh script of libpcap.
It calls the build.sh script which runs one build with setup environment
variables: BUILD_LIBPCAP, REMOTE, CC, CMAKE, CRYPTO and SMB
(default: BUILD_LIBPCAP=no, REMOTE=no, CC=gcc, CMAKE=no, CRYPTO=no, SMB=no).
The matrix can be configured with environment variables
MATRIX_BUILD_LIBPCAP, MATRIX_REMOTE, MATRIX_CC, MATRIX_CMAKE, MATRIX_CRYPTO
and MATRIX_SMB
(default: MATRIX_BUILD_LIBPCAP='no yes', MATRIX_REMOTE='no yes',
MATRIX_CC='gcc clang', MATRIX_CMAKE='no yes', MATRIX_CRYPTO='no yes',
MATRIX_SMB='no yes').
These scripts can easily be updated to run new tests (32 bits builds,
sanitizers, coverage, etc).
They can be used locally for build tests or used with other CI systems.
Run examples:
./build_matrix.sh
MATRIX_BUILD_LIBPCAP=yes ./build_matrix.sh
MATRIX_CC=clang ./build_matrix.sh
CC=clang ./build.sh
CMAKE=yes ./build.sh
CC=clang CMAKE=yes CRYPTO=yes ./build.sh
Moreover:
Remove the old workaround PATH=$PATH...
Update the install directory prefix to /tmp/local.
Use vim modeline in the two shell scripts.
2021-02-07 18:22:24 +08:00
|
|
|
# vi: set tabstop=4 softtabstop=0 expandtab shiftwidth=4 smarttab autoindent :
|