Add replace default build script#292
Conversation
c8969ce to
035575e
Compare
|
General question: where will this script be used? |
I use this to build replace default locally; Added it so that potential customers / devs could test it out easier / build easier. This doesn't have to be merged its just an option and I found it useful when testing |
|
|
||
| # Install wolfProvider main package | ||
| wolfprov_main=$(ls -1 /tmp/wolfprov-packages/libwolfprov_[0-9]*.deb 2>/dev/null | head -n1 || true) | ||
| if [ -z "$wolfprov_main" ]; then |
There was a problem hiding this comment.
Can we print the name of the wolfprov package too for consistency?
| mkdir -p "/tmp/wolfssl-pkg" | ||
| chmod +x debian/install-wolfssl.sh | ||
| ./debian/install-wolfssl.sh \ | ||
| --tag v5.8.2-stable \ |
There was a problem hiding this comment.
Why hardcode the 5.8.2 tag? That deviates from the default behavior of install-wolfssl.sh
| git fetch --tags --force --prune | ||
|
|
||
| # Install wolfSSL Debian packages from repo tarball | ||
| mkdir -p "/tmp/wolfssl-pkg" |
There was a problem hiding this comment.
Should probably clean out this directory if it exists prior to generating the packages. Or just let intstall-wolfssl.sh create a temp dir.
| find /tmp/wolfssl-pkg -name "*wolfssl*" -type f -name "*.deb" -exec cp {} /tmp/wolfprov-packages/ \; | ||
|
|
||
| # Build Debian packages (wolfProvider + OpenSSL) | ||
| yes Y | ./scripts/build-wolfprovider.sh --debian |
There was a problem hiding this comment.
Can we have an option for --debug?
| "/tmp/wolfssl-pkg" | ||
|
|
||
| # Stage wolfSSL debs into artifacts directory | ||
| mkdir -p "/tmp/wolfprov-packages" |
There was a problem hiding this comment.
Same comment here about cleaning out the directory
| echo "=== Installing packages ===" | ||
|
|
||
| # Install wolfSSL first | ||
| wolfssl_debs=$(ls -1 /tmp/wolfprov-packages/*wolfssl*.deb 2>/dev/null || true) |
There was a problem hiding this comment.
This should be already completed by install-wolfssl.sh
| echo "Installing custom OpenSSL packages..." | ||
| if [ -n "$libssl3_debs" ]; then | ||
| echo "Installing custom libssl3 package..." | ||
| sudo dpkg -i $libssl3_debs || sudo apt install -f -y |
There was a problem hiding this comment.
What happens if the package is already installed or is a "downgrade" to a lower version number? Does dpkg -i handle this correctly?
Description
Script to automate build procedure for replace default