From dfaad6f5baa01c6c0975237963e35edcfa37ec08 Mon Sep 17 00:00:00 2001 From: Fabio Alessandrelli Date: Fri, 9 Dec 2022 14:45:31 +0100 Subject: Bump godot-cpp to beta8, libdatachannel to v0.18.0 libdatachannel and libjuice are now released under MPL 2.0. Dependencies has been refactored under a `thirdparty` folder similar to what we have in Godot, with a dedicated `thirdparty/README.md` containing details information on dependencies upstreams, versions, and licenses. --- .github/workflows/build_release.yml | 18 ++++---- .gitmodules | 4 +- README.md | 4 +- SConstruct | 2 +- bin/thirdparty/.gitignore | 2 + builders.py | 4 +- deps/build/.gitignore | 2 - deps/libdatachannel | 1 - deps/openssl | 1 - godot-cpp | 2 +- thirdparty/README.md | 82 +++++++++++++++++++++++++++++++++++++ thirdparty/libdatachannel | 1 + thirdparty/openssl | 1 + 13 files changed, 103 insertions(+), 21 deletions(-) create mode 100644 bin/thirdparty/.gitignore delete mode 100644 deps/build/.gitignore delete mode 160000 deps/libdatachannel delete mode 160000 deps/openssl create mode 100644 thirdparty/README.md create mode 160000 thirdparty/libdatachannel create mode 160000 thirdparty/openssl diff --git a/.github/workflows/build_release.yml b/.github/workflows/build_release.yml index ab7ee01..668d26a 100644 --- a/.github/workflows/build_release.yml +++ b/.github/workflows/build_release.yml @@ -177,7 +177,9 @@ jobs: - uses: actions/upload-artifact@v3 with: name: ${{ github.job }}-${{ matrix.platform }}-${{ matrix.arch }} - path: bin/* + path: | + bin/ + !bin/thirdparty/ package: name: 📦 Package @@ -195,13 +197,13 @@ jobs: - name: Bundle licenses. run: | cp LICENSE artifacts/LICENSE.webrtc-native - cp deps/libdatachannel/LICENSE artifacts/LICENSE.libdatachannel - cp deps/openssl/LICENSE.txt artifacts/LICENSE.openssl - cp deps/libdatachannel/deps/libjuice/LICENSE artifacts/LICENSE.libjuice - cp deps/libdatachannel/deps/usrsctp/LICENSE.md artifacts/LICENSE.usrsctp - cp deps/libdatachannel/deps/libsrtp/LICENSE artifacts/LICENSE.libsrtp - cp deps/libdatachannel/deps/json/LICENSE.MIT artifacts/LICENSE.json - cp deps/libdatachannel/deps/plog/LICENSE artifacts/LICENSE.plog + cp thirdparty/libdatachannel/LICENSE artifacts/LICENSE.libdatachannel + cp thirdparty/openssl/LICENSE.txt artifacts/LICENSE.openssl + cp thirdparty/libdatachannel/deps/libjuice/LICENSE artifacts/LICENSE.libjuice + cp thirdparty/libdatachannel/deps/usrsctp/LICENSE.md artifacts/LICENSE.usrsctp + cp thirdparty/libdatachannel/deps/libsrtp/LICENSE artifacts/LICENSE.libsrtp + cp thirdparty/libdatachannel/deps/json/LICENSE.MIT artifacts/LICENSE.json + cp thirdparty/libdatachannel/deps/plog/LICENSE artifacts/LICENSE.plog - name: Package artifacts for release env: diff --git a/.gitmodules b/.gitmodules index 1aa8d48..cc07501 100644 --- a/.gitmodules +++ b/.gitmodules @@ -5,8 +5,8 @@ path = godot-cpp url = https://github.com/godotengine/godot-cpp.git [submodule "libdatachannel"] - path = deps/libdatachannel + path = thirdparty/libdatachannel url = https://github.com/paullouisageneau/libdatachannel.git [submodule "openssl"] - path = deps/openssl + path = thirdparty/openssl url = https://github.com/openssl/openssl.git diff --git a/README.md b/README.md index b2e87f9..458f399 100644 --- a/README.md +++ b/README.md @@ -45,6 +45,4 @@ You simply need to copy that folder to the root folder of your project. Note tha ### License -The `webrtc-native` plugin is licensed under the MIT license (see [LICENSE](https://github.com/godotengine/webrtc-native/blob/master/LICENSE)), while `libdatachannel` and one of its dependencies (`libjuice`) are licensed under LGPLv2.1 or later, see [libdatachannel LICENSE](https://github.com/paullouisageneau/libdatachannel/blob/master/LICENSE) and [libjuice LICENSE](https://github.com/paullouisageneau/libjuice/blob/master/LICENSE). - -Make sure you understand and comply with the LGPLv2.1 license when redistributing this plugin. +The `webrtc-native` plugin is licensed under the MIT license (see [LICENSE](https://github.com/godotengine/webrtc-native/blob/master/LICENSE)), while `libdatachannel` and its dependencies are licensed under other permissive open source licences. Please see [`thirdparty/README.md`](thirdparty/README.md) for more informations. diff --git a/SConstruct b/SConstruct index 755d650..e804557 100644 --- a/SConstruct +++ b/SConstruct @@ -101,7 +101,6 @@ else: result_path = os.path.join("bin", "extension", "webrtc") # Dependencies -deps_source_dir = "deps" env.Append(BUILDERS={ "BuildOpenSSL": env.Builder(action=builders.ssl_action, emitter=builders.ssl_emitter), "BuildLibDataChannel": env.Builder(action=builders.rtc_action, emitter=builders.rtc_emitter), @@ -126,6 +125,7 @@ env.Prepend(LIBS=[builders.get_rtc_libs(env)]) # Our includes and sources env.Append(CPPPATH=["src/"]) +env.Append(CPPDEFINES=["RTC_STATIC"]) sources = [] sources.append( [ diff --git a/bin/thirdparty/.gitignore b/bin/thirdparty/.gitignore new file mode 100644 index 0000000..d6b7ef3 --- /dev/null +++ b/bin/thirdparty/.gitignore @@ -0,0 +1,2 @@ +* +!.gitignore diff --git a/builders.py b/builders.py index 2f35527..8f1a3bd 100644 --- a/builders.py +++ b/builders.py @@ -8,11 +8,11 @@ def get_android_api(env): def get_deps_dir(env): - return env.Dir("#deps").abspath + return env.Dir("#thirdparty").abspath def get_deps_build_dir(env): - return get_deps_dir(env) + "/build/build{}.{}.dir".format(env["suffix"], "RelWithDebInfo" if env["debug_symbols"] else "Release") + return env.Dir("#bin/thirdparty").abspath + "/{}.{}.dir".format(env["suffix"][1:], "RelWithDebInfo" if env["debug_symbols"] else "Release") def get_rtc_source_dir(env): diff --git a/deps/build/.gitignore b/deps/build/.gitignore deleted file mode 100644 index d6b7ef3..0000000 --- a/deps/build/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -* -!.gitignore diff --git a/deps/libdatachannel b/deps/libdatachannel deleted file mode 160000 index 1ec2a2f..0000000 --- a/deps/libdatachannel +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 1ec2a2f519df5586af191b512b23d792524e44f3 diff --git a/deps/openssl b/deps/openssl deleted file mode 160000 index 19cc035..0000000 --- a/deps/openssl +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 19cc035b6c6f2283573d29c7ea7f7d675cf750ce diff --git a/godot-cpp b/godot-cpp index 576bd17..c20ecea 160000 --- a/godot-cpp +++ b/godot-cpp @@ -1 +1 @@ -Subproject commit 576bd172851932ba3db95fda8760b4f297c89efd +Subproject commit c20ecea090dc0d6fa31f4b72b95dc1f304736546 diff --git a/thirdparty/README.md b/thirdparty/README.md new file mode 100644 index 0000000..94e1e8f --- /dev/null +++ b/thirdparty/README.md @@ -0,0 +1,82 @@ +# Third party libraries + +Please keep categories (`##` level) listed alphabetically and matching their +respective folder names. Use two empty lines to separate categories for +readability. + + +## json + +- Upstream: https://github.com/nlohmann/json +- Version: 3.10.5 (4f8fba14066156b73f1189a2b8bd568bde5284c5, 2022) +- License: MIT + +Module location: + +- thirdparty/libdatachannel/deps/json + + +## libdatachannel + +- Upstream: https://github.com/paullouisageneau/libdatachannel +- Version: 0.18.0 (084445012d6c63c9f2cc250d88df553aed2eb189, 2022) +- License: MPL 2.0 + +Module location: + +- thirdparty/libdatachannel + + +# libjuice + +- Upstream: https://github.com/paullouisageneau/libjuice +- Version: 1.1.0 (0dabc046cd23da6908749e4c6add834ec29a7c49, 2022) +- License: MPL 2.0 + +Module location: + +- thirdparty/libdatachannel/deps/libjuice + + +## libsrtp + +- Upstream: https://github.com/cisco/libsrtp +- Version: 2.4.2 (90d05bf8980d16e4ac3f16c19b77e296c4bc207b, 2021) +- License: BSD-3-Clause + +Module location: + +- thirdparty/libdatachannel/deps/libsrtp + + +## openssl + +- Upstream: git://git.openssl.org/openssl.git +- Version: 3.0.7 (19cc035b6c6f2283573d29c7ea7f7d675cf750ce, 2022) +- License: Apache 2.0 + +Module location: + +- thirdparty/openssl + + +## plog + +- Upstream: https://github.com/SergiusTheBest/plog +- Version: git (d8461e9d473e59fbcc1f79eee021550dcf81e618, 2021) +- License: MPL 2.0 + +Module location: + +- thirdparty/libdatachannel/deps/plog + + +## usrsctp + +- Upstream: https://github.com/sctplab/usrsctp +- Version: git (7c31bd35c79ba67084ce029511193a19ceb97447, 2021) +- License: BSD-3-Clause + +Module location: + +- thirdparty/libdatachannel/deps/usrsctp diff --git a/thirdparty/libdatachannel b/thirdparty/libdatachannel new file mode 160000 index 0000000..0844450 --- /dev/null +++ b/thirdparty/libdatachannel @@ -0,0 +1 @@ +Subproject commit 084445012d6c63c9f2cc250d88df553aed2eb189 diff --git a/thirdparty/openssl b/thirdparty/openssl new file mode 160000 index 0000000..19cc035 --- /dev/null +++ b/thirdparty/openssl @@ -0,0 +1 @@ +Subproject commit 19cc035b6c6f2283573d29c7ea7f7d675cf750ce -- cgit v1.2.3