Migrate utf8_range dependency to a git subtree (#11608)

This will make the CMake workflow easier, where users won't need to either install utf8_range or initialize our submodules.  Since this is a relatively small library that's owned by us, we can just bundle it with protobuf as a subtree

Closes #11608

COPYBARA_INTEGRATE_REVIEW=https://github.com/protocolbuffers/protobuf/pull/11608 from mkruskal-google:utf8_range_dep 57d5d91b68d6e5cb006fde22cac8bc3f2b106e36
PiperOrigin-RevId: 503314822
diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml
index e7c63ee..cc4210c 100644
--- a/.github/workflows/codespell.yml
+++ b/.github/workflows/codespell.yml
@@ -14,5 +14,5 @@
       - uses: codespell-project/actions-codespell@master
         with:
           check_filenames: true
-          skip: ./.git,./conformance/third_party,*.snk,*.pb,*.pb.cc,*.pb.h,./src/google/protobuf/testdata,./objectivec/Tests,./python/compatibility_tests/v2.5.0/tests/google/protobuf/internal,./.github/workflows/codespell.yml
+          skip: ./.git,./third_party,./conformance/third_party,*.snk,*.pb,*.pb.cc,*.pb.h,./src/google/protobuf/testdata,./objectivec/Tests,./python/compatibility_tests/v2.5.0/tests/google/protobuf/internal,./.github/workflows/codespell.yml
           ignore_words_list: "alow,alse,ba,chec,cleare,copyable,cloneable,dedup,dur,errorprone,falsy,files',fo,fundementals,hel,importd,inout,leapyear,nd,nin,ois,ons,parseable,process',ro,te,testof,ue,unparseable,wasn,wee,gae,keyserver,objext,od,optin,streem,sur,falsy"
diff --git a/.gitmodules b/.gitmodules
index db938cf..7a46a17 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -9,6 +9,3 @@
 [submodule "third_party/jsoncpp"]
 	path = third_party/jsoncpp
 	url = https://github.com/open-source-parsers/jsoncpp.git
-[submodule "third_party/utf8_range"]
-	path = third_party/utf8_range
-	url = https://github.com/protocolbuffers/utf8_range.git
diff --git a/cmake/utf8_range.cmake b/cmake/utf8_range.cmake
index 4dcfa4b..701de8d 100644
--- a/cmake/utf8_range.cmake
+++ b/cmake/utf8_range.cmake
@@ -2,10 +2,8 @@
 
 if (NOT EXISTS "${protobuf_SOURCE_DIR}/third_party/utf8_range/CMakeLists.txt")
   message(FATAL_ERROR
-          "Cannot find third_party/utf8_range directory that's needed to "
-          "build conformance tests. If you use git, make sure you have cloned "
-          "submodules:\n"
-          "  git submodule update --init --recursive\n")
+          "Cannot find third_party/utf8_range directory that's needed for "
+          "the protobuf runtime.\n")
 endif()
 
 set(utf8_range_ENABLE_INSTALL ${protobuf_INSTALL} CACHE BOOL "Set install")
diff --git a/third_party/utf8_range b/third_party/utf8_range
deleted file mode 160000
index de0b4a8..0000000
--- a/third_party/utf8_range
+++ /dev/null
@@ -1 +0,0 @@
-Subproject commit de0b4a8ff9b5d4c98108bdfe723291a33c52c54f
diff --git a/update_subtrees.sh b/update_subtrees.sh
new file mode 100755
index 0000000..df75ba3
--- /dev/null
+++ b/update_subtrees.sh
@@ -0,0 +1,8 @@
+#! /bin/bash -eux
+
+set -eux
+
+cd $(dirname $0)
+
+git subtree pull --prefix third_party/utf8_range \
+  https://github.com/protocolbuffers/utf8_range.git main --squash