From 3bf3562f9c8ebe33f1f18ef39430307aae304c5d Mon Sep 17 00:00:00 2001
From: Roxie Linden <roxie@lindenlab.com>
Date: Sat, 9 Sep 2023 23:52:34 -0700
Subject: [PATCH] Use webrtc built binaries from temporary s3 location

---
 indra/cmake/WebRTC.cmake | 43 +++++++++++++++++++++++++---------------
 1 file changed, 27 insertions(+), 16 deletions(-)

diff --git a/indra/cmake/WebRTC.cmake b/indra/cmake/WebRTC.cmake
index 2040c86b9f6..c1e5df8b9dd 100644
--- a/indra/cmake/WebRTC.cmake
+++ b/indra/cmake/WebRTC.cmake
@@ -3,23 +3,34 @@
 include(FetchContent)
 
 if (WINDOWS)
-FetchContent_Declare(
-  webrtc
-  URL      http://localhost:8000/webrtc.windows_x86_64.tar.bz2
-  URL_HASH MD5=dfb692562770dc8c877ebfe4302e2881
-  FIND_PACKAGE_ARGS NAMES webrtc
-  DOWNLOAD_EXTRACT_TIMESTAMP TRUE
-  DOWNLOAD_DIR "${LIBS_PREBUILT_DIR}/webrtc/"
-)
+    if( ADDRESS_SIZE EQUAL 32 )
+        FetchContent_Declare(
+              webrtc
+              URL https://webrtc-build-releases.s3.us-west-2.amazonaws.com/webrtc.windows_x86.tar.bz2
+              URL_HASH MD5=0d55e58efceed3fb48085a5f0c58881c
+              FIND_PACKAGE_ARGS NAMES webrtc
+              DOWNLOAD_EXTRACT_TIMESTAMP TRUE
+              DOWNLOAD_DIR "${LIBS_PREBUILT_DIR}/webrtc/"
+            )
+    else ( ADDRESS_SIZE EQUAL 32 )
+        FetchContent_Declare(
+              webrtc
+              URL https://webrtc-build-releases.s3.us-west-2.amazonaws.com/webrtc.windows_x86_64.tar.bz2
+              URL_HASH MD5=dfb692562770dc8c877ebfe4302e2881
+              FIND_PACKAGE_ARGS NAMES webrtc
+              DOWNLOAD_EXTRACT_TIMESTAMP TRUE
+              DOWNLOAD_DIR "${LIBS_PREBUILT_DIR}/webrtc/"
+            )
+    endif ( ADDRESS_SIZE EQUAL 32 )
 elseif (DARWIN)
-FetchContent_Declare(
-  webrtc
-  URL      http://localhost:8000/webrtc.macos_x86_64.tar.bz2
-  URL_HASH MD5=cfbcac7da897a862f9791ea29330b814
-  FIND_PACKAGE_ARGS NAMES webrtc
-  DOWNLOAD_EXTRACT_TIMESTAMP TRUE
-  DOWNLOAD_DIR "${LIBS_PREBUILT_DIR}/webrtc/"
-)
+    FetchContent_Declare(
+      webrtc
+      URL https://webrtc-build-releases.s3.us-west-2.amazonaws.com/webrtc.macos_x86_64.tar.bz2
+      URL_HASH MD5=cfbcac7da897a862f9791ea29330b814
+      FIND_PACKAGE_ARGS NAMES webrtc
+      DOWNLOAD_EXTRACT_TIMESTAMP TRUE
+      DOWNLOAD_DIR "${LIBS_PREBUILT_DIR}/webrtc/"
+    )
 endif (WINDOWS)
 
 FetchContent_MakeAvailable(webrtc)
-- 
GitLab