Merged
Conversation
hellt
reviewed
Nov 2, 2025
Dockerfile
Outdated
Comment on lines
+9
to
+33
| RUN mkdir /bngblaster | ||
| WORKDIR /bngblaster | ||
| RUN wget https://github.com/rtbrick/libdict/archive/refs/tags/1.0.4.zip | ||
| RUN unzip 1.0.4.zip | ||
| RUN mkdir libdict-1.0.4/build | ||
| WORKDIR /bngblaster/libdict-1.0.4/build | ||
| RUN cmake .. | ||
| RUN make -j16 install | ||
| WORKDIR /bngblaster | ||
| RUN wget https://github.com/rtbrick/bngblaster/archive/refs/tags/0.9.26.zip | ||
| RUN unzip 0.9.26.zip | ||
| RUN mkdir bngblaster-0.9.26/build | ||
| WORKDIR /bngblaster/bngblaster-0.9.26/build | ||
| #remove redundant include to avoid preprocessor redirect warning and consequent compilation failure | ||
| RUN 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 | ||
| RUN sed -i '$i typedef unsigned int uint;' ../code/common/src/common.h | ||
| # add include to support be32toh and htobe32 on alpine musl libc | ||
| RUN 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 | ||
| RUN 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. | ||
| RUN sed -i 's/APPEND CMAKE_C_FLAGS "-pthread"/APPEND CMAKE_C_FLAGS "-pthread -Wno-error=sequence-point"/' ../code/bngblaster/CMakeLists.txt | ||
| RUN cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBNGBLASTER_VERSION=0.9.26 .. | ||
| RUN make install |
Member
There was a problem hiding this comment.
Hi @jcpvdm
can you please carve this out as install-bngbluster.sh and execute this script instead of doing this in the dockerfile? Thanks!
hellt
reviewed
Nov 2, 2025
install-bngblaster.sh
Outdated
| cmake .. | ||
| make -j16 install | ||
| cd /bngblaster | ||
| wget https://github.com/rtbrick/bngblaster/archive/refs/tags/0.9.26.zip |
Member
There was a problem hiding this comment.
maybe worth setting the BNGBLASTER_VERSION var to 0.9.26 at the top of the script and use it in the commands below.
This would allow to change the version easily in one place when the upgrade to bng blaster would be required
Contributor
Author
There was a problem hiding this comment.
yeah that's better. agreed & done @hellt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.