git: 229d643c4dd5 - main - depend-cleanup: apply big hammer for OpenSSL 3.0 update

From: Ed Maste <emaste_at_FreeBSD.org>
Date: Sat, 24 Jun 2023 23:48:59 UTC
The branch main has been updated by emaste:

URL: https://cgit.FreeBSD.org/src/commit/?id=229d643c4dd5c1a1695e5de48fab0524132f5deb

commit 229d643c4dd5c1a1695e5de48fab0524132f5deb
Author:     Ed Maste <emaste@FreeBSD.org>
AuthorDate: 2023-06-24 18:12:06 +0000
Commit:     Ed Maste <emaste@FreeBSD.org>
CommitDate: 2023-06-24 23:46:09 +0000

    depend-cleanup: apply big hammer for OpenSSL 3.0 update
    
    If we find an object corresponding to a source file that existed in
    OpenSSL 1.1.1 but not in 3.0 just remove all of the OpenSSL objdirs.
    
    Reviewed by:    dhw
    Sponsored by:   The FreeBSD Foundation
    Differential Revision: https://reviews.freebsd.org/D40750
---
 tools/build/depend-cleanup.sh | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh
index f047553c377f..7b851873f288 100755
--- a/tools/build/depend-cleanup.sh
+++ b/tools/build/depend-cleanup.sh
@@ -115,3 +115,12 @@ clean_dep   usr.sbin/config  mkoptions c
 
 # 20230401  54579376c05e    kqueue1 from syscall to C wrapper
 clean_dep   lib/libc        kqueue1 S
+
+# 20230623  b077aed33b7b    OpenSSL 3.0 update
+if [ -f "$OBJTOP"/secure/lib/libcrypto/aria.o ]; then
+	echo "Removing old OpenSSL 1.1.1 tree"
+	rm -rf "$OBJTOP"/secure/lib/libcrypto \
+	    "$OBJTOP"/secure/lib/libssl \
+	    "$OBJTOP"/obj-lib32/secure/lib/libcrypto \
+	    "$OBJTOP"/obj-lib32/secure/lib/libssl
+fi