Skip to content
Open
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
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ RUN apk update \
iproute2 iputils jq lftp mtr mysql-client netcat-openbsd net-snmp-tools \
net-tools nginx nmap openntpd openssh-client openssl perl-net-telnet \
postgresql-client procps rsync socat sudo tcpdump tcptraceroute \
tshark wget envsubst scapy liboping fping bash-completion \
tshark wget envsubst scapy liboping fping bash-completion openssh-sftp-server \
&& mkdir /certs /docker \
&& chmod 700 /certs \
&& openssl req \
Expand Down
12 changes: 1 addition & 11 deletions install-bngblaster.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
LIBDICT_VERSION="1.0.4"
BNGBLASTER_VERSION="0.9.26"
BNGBLASTER_VERSION="0.9.27"
mkdir /bngblaster
cd /bngblaster
wget https://github.com/rtbrick/libdict/archive/refs/tags/$LIBDICT_VERSION.zip
Expand All @@ -14,15 +14,5 @@ wget https://github.com/rtbrick/bngblaster/archive/refs/tags/$BNGBLASTER_VERSION
unzip $BNGBLASTER_VERSION.zip
mkdir bngblaster-$BNGBLASTER_VERSION/build
cd /bngblaster/bngblaster-$BNGBLASTER_VERSION/build
#remove redundant include to avoid preprocessor redirect warning and consequent compilation failure
sed -i '/#include <sys\/signal.h>/d' ../code/lwip/contrib/ports/unix/port/netif/sio.c
#typedef for uint to avoid compilation error on alpine musl libc
sed -i '$i typedef unsigned int uint;' ../code/common/src/common.h
# add include to support be32toh and htobe32 on alpine musl libc
sed -i '/#include <stdlib.h>/i #include <endian.h>' ../code/common/src/common.h
#replace __time_t with time_t to make it compatible with alpine musl libc
find /bngblaster/bngblaster-0.9.26/code/ -type f \( -name "*.c" -o -name "*.h" \) -exec sed -i 's/\b__time_t\b/time_t/g' {} +
#Don't error on sequence-point errors to allow build to complete on musl libc. Ideally code should be fixed on upstream repo.
sed -i 's/APPEND CMAKE_C_FLAGS "-pthread"/APPEND CMAKE_C_FLAGS "-pthread -Wno-error=sequence-point"/' ../code/bngblaster/CMakeLists.txt
cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBNGBLASTER_VERSION=$BNGBLASTER_VERSION ..
make install