summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-04-28 19:28:21 +0200
committerRémi Verschelde <rverschelde@gmail.com>2017-04-28 21:19:25 +0200
commitd4029aa51a0f0bce5dc73885af74b592e3aa33b7 (patch)
tree22848a9191aca36a38b6f0bda4c313c3349f2eab
parentc5f830d6b90574ef1e34fd2c35a0ebfa1ad92fe6 (diff)
Move other lone thirdparty files to thirdparty/misc
Also move Box2D ConvexDecomposition contrib code to thirdparty/b2d_convexdecomp.
-rw-r--r--core/SCsub2
-rw-r--r--drivers/convex_decomp/SCsub9
-rw-r--r--drivers/convex_decomp/b2d_decompose.cpp3
-rw-r--r--modules/openssl/SCsub11
-rw-r--r--modules/openssl/stream_peer_openssl.h6
-rw-r--r--modules/stb_vorbis/audio_stream_ogg_vorbis.cpp3
-rw-r--r--modules/stb_vorbis/audio_stream_ogg_vorbis.h2
-rw-r--r--modules/theora/video_stream_theora.cpp3
-rw-r--r--modules/webm/video_stream_webm.cpp3
-rw-r--r--scene/SCsub19
-rw-r--r--scene/resources/SCsub1
-rw-r--r--scene/resources/dynamic_font_stb.cpp1
-rw-r--r--scene/resources/dynamic_font_stb.h3
-rw-r--r--scene/resources/surface_tool.h3
-rw-r--r--thirdparty/README.md37
-rw-r--r--thirdparty/b2d_convexdecomp/b2Glue.h (renamed from drivers/convex_decomp/b2Glue.h)0
-rw-r--r--thirdparty/b2d_convexdecomp/b2Polygon.cpp (renamed from drivers/convex_decomp/b2Polygon.cpp)0
-rw-r--r--thirdparty/b2d_convexdecomp/b2Polygon.h (renamed from drivers/convex_decomp/b2Polygon.h)0
-rw-r--r--thirdparty/b2d_convexdecomp/b2Triangle.cpp (renamed from drivers/convex_decomp/b2Triangle.cpp)0
-rw-r--r--thirdparty/b2d_convexdecomp/b2Triangle.h (renamed from drivers/convex_decomp/b2Triangle.h)0
-rw-r--r--thirdparty/misc/curl_hostcheck.c (renamed from modules/openssl/curl_hostcheck.c)0
-rw-r--r--thirdparty/misc/curl_hostcheck.h (renamed from modules/openssl/curl_hostcheck.h)0
-rw-r--r--thirdparty/misc/mikktspace.c (renamed from scene/resources/mikktspace.c)0
-rw-r--r--thirdparty/misc/mikktspace.h (renamed from scene/resources/mikktspace.h)0
-rw-r--r--thirdparty/misc/stb_truetype.h (renamed from scene/resources/stb_truetype.h)0
-rw-r--r--thirdparty/misc/stb_vorbis.c (renamed from thirdparty/stb_vorbis/stb_vorbis.c)0
-rw-r--r--thirdparty/misc/yuv2rgb.h (renamed from modules/theora/yuv2rgb.h)0
27 files changed, 90 insertions, 16 deletions
diff --git a/core/SCsub b/core/SCsub
index 5e32acb310..fd3f57dd7c 100644
--- a/core/SCsub
+++ b/core/SCsub
@@ -84,7 +84,7 @@ thirdparty_minizip_sources = [thirdparty_minizip_dir + file for file in thirdpar
env.add_source_files(env.core_sources, thirdparty_minizip_sources)
-# Godot's own source
+# Godot's own sources
env.add_source_files(env.core_sources, "*.cpp")
diff --git a/drivers/convex_decomp/SCsub b/drivers/convex_decomp/SCsub
index ee39fd2631..f017e55120 100644
--- a/drivers/convex_decomp/SCsub
+++ b/drivers/convex_decomp/SCsub
@@ -4,4 +4,13 @@ Import('env')
env.add_source_files(env.drivers_sources, "*.cpp")
+# Thirdparty dependencies
+thirdparty_dir = "#thirdparty/b2d_convexdecomp/"
+thirdparty_sources = [
+ "b2Polygon.cpp",
+ "b2Triangle.cpp",
+]
+thirdparty_sources = [thirdparty_dir + file for file in thirdparty_sources]
+env.add_source_files(env.drivers_sources, thirdparty_sources)
+
Export('env')
diff --git a/drivers/convex_decomp/b2d_decompose.cpp b/drivers/convex_decomp/b2d_decompose.cpp
index f918b66c31..d9011b8eab 100644
--- a/drivers/convex_decomp/b2d_decompose.cpp
+++ b/drivers/convex_decomp/b2d_decompose.cpp
@@ -28,7 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
#include "b2d_decompose.h"
-#include "b2Polygon.h"
+
+#include "thirdparty/b2d_convexdecomp/b2Polygon.h"
namespace b2ConvexDecomp {
diff --git a/modules/openssl/SCsub b/modules/openssl/SCsub
index 0e811ce8c9..add7d4dcfc 100644
--- a/modules/openssl/SCsub
+++ b/modules/openssl/SCsub
@@ -677,7 +677,16 @@ if (env['builtin_openssl'] != 'no'):
# Module sources
env_openssl.add_source_files(env.modules_sources, "*.cpp")
-env_openssl.add_source_files(env.modules_sources, "*.c")
+
+
+# Other thirdparty dependencies
+thirdparty_misc_dir = "#thirdparty/misc/"
+thirdparty_misc_sources = [
+ "curl_hostcheck.c",
+]
+thirdparty_misc_sources = [thirdparty_misc_dir + file for file in thirdparty_misc_sources]
+env_openssl.add_source_files(env.modules_sources, thirdparty_misc_sources)
+
# platform/uwp need to know openssl is available, pass to main env
if "platform" in env and env["platform"] == "uwp":
diff --git a/modules/openssl/stream_peer_openssl.h b/modules/openssl/stream_peer_openssl.h
index 12262da94a..5c830ebf37 100644
--- a/modules/openssl/stream_peer_openssl.h
+++ b/modules/openssl/stream_peer_openssl.h
@@ -30,17 +30,19 @@
#ifndef STREAM_PEER_OPEN_SSL_H
#define STREAM_PEER_OPEN_SSL_H
-#include "curl_hostcheck.h"
#include "global_config.h"
#include "io/stream_peer_ssl.h"
#include "os/file_access.h"
-#include <stdio.h> // If you don't know what this is for stop reading now.
+
+#include "thirdparty/misc/curl_hostcheck.h"
#include <openssl/bio.h> // BIO objects for I/O
#include <openssl/err.h> // Error reporting
#include <openssl/ssl.h> // SSL and SSL_CTX for SSL connections
#include <openssl/x509v3.h>
+#include <stdio.h>
+
class StreamPeerOpenSSL : public StreamPeerSSL {
private:
static int _bio_create(BIO *b);
diff --git a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp
index b0870c9dc2..c645a55703 100644
--- a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp
+++ b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp
@@ -30,7 +30,8 @@
#include "audio_stream_ogg_vorbis.h"
#include "os/file_access.h"
-#include "thirdparty/stb_vorbis/stb_vorbis.c"
+
+#include "thirdparty/misc/stb_vorbis.c"
void AudioStreamPlaybackOGGVorbis::_mix_internal(AudioFrame *p_buffer, int p_frames) {
diff --git a/modules/stb_vorbis/audio_stream_ogg_vorbis.h b/modules/stb_vorbis/audio_stream_ogg_vorbis.h
index bb895c4dfa..287aa4ca47 100644
--- a/modules/stb_vorbis/audio_stream_ogg_vorbis.h
+++ b/modules/stb_vorbis/audio_stream_ogg_vorbis.h
@@ -34,7 +34,7 @@
#include "servers/audio/audio_stream.h"
#define STB_VORBIS_HEADER_ONLY
-#include "thirdparty/stb_vorbis/stb_vorbis.c"
+#include "thirdparty/misc/stb_vorbis.c"
#undef STB_VORBIS_HEADER_ONLY
class AudioStreamOGGVorbis;
diff --git a/modules/theora/video_stream_theora.cpp b/modules/theora/video_stream_theora.cpp
index 28463e2cba..61112f20b4 100644
--- a/modules/theora/video_stream_theora.cpp
+++ b/modules/theora/video_stream_theora.cpp
@@ -31,7 +31,8 @@
#include "global_config.h"
#include "os/os.h"
-#include "yuv2rgb.h"
+
+#include "thirdparty/misc/yuv2rgb.h"
int VideoStreamPlaybackTheora::buffer_data() {
diff --git a/modules/webm/video_stream_webm.cpp b/modules/webm/video_stream_webm.cpp
index 9d8062d283..eaf4215302 100644
--- a/modules/webm/video_stream_webm.cpp
+++ b/modules/webm/video_stream_webm.cpp
@@ -32,12 +32,13 @@
#include "OpusVorbisDecoder.hpp"
#include "VPXDecoder.hpp"
-#include "../theora/yuv2rgb.h"
#include "mkvparser/mkvparser.h"
#include "global_config.h"
#include "os/file_access.h"
+#include "thirdparty/misc/yuv2rgb.h"
+
#include <string.h>
class MkvReader : public mkvparser::IMkvReader {
diff --git a/scene/SCsub b/scene/SCsub
index bd2da1eab9..df52e9c6cb 100644
--- a/scene/SCsub
+++ b/scene/SCsub
@@ -3,10 +3,23 @@
Import('env')
env.scene_sources = []
+
+
+# Thirdparty code
+thirdparty_dir = "#thirdparty/misc/"
+thirdparty_sources = [
+ # C sources
+ "mikktspace.c",
+]
+thirdparty_sources = [thirdparty_dir + file for file in thirdparty_sources]
+env.add_source_files(env.scene_sources, thirdparty_sources)
+
+
+# Godot's own sources
env.add_source_files(env.scene_sources, "*.cpp")
-Export('env')
+# Chain load SCsubs
SConscript('main/SCsub')
SConscript('gui/SCsub')
SConscript('3d/SCsub')
@@ -17,6 +30,8 @@ SConscript('resources/SCsub')
SConscript('io/SCsub')
+# Build it all as a library
lib = env.Library("scene", env.scene_sources)
-
env.Prepend(LIBS=[lib])
+
+Export('env')
diff --git a/scene/resources/SCsub b/scene/resources/SCsub
index 60b16cd0d4..2ad90247a7 100644
--- a/scene/resources/SCsub
+++ b/scene/resources/SCsub
@@ -3,7 +3,6 @@
Import('env')
env.add_source_files(env.scene_sources, "*.cpp")
-env.add_source_files(env.scene_sources, "*.c")
Export('env')
diff --git a/scene/resources/dynamic_font_stb.cpp b/scene/resources/dynamic_font_stb.cpp
index 0a784c6496..397349bbf9 100644
--- a/scene/resources/dynamic_font_stb.cpp
+++ b/scene/resources/dynamic_font_stb.cpp
@@ -33,7 +33,6 @@
#define STB_TRUETYPE_IMPLEMENTATION
#include "os/file_access.h"
-#include "stb_truetype.h"
void DynamicFontData::lock() {
diff --git a/scene/resources/dynamic_font_stb.h b/scene/resources/dynamic_font_stb.h
index 3862607ab5..a2c081a925 100644
--- a/scene/resources/dynamic_font_stb.h
+++ b/scene/resources/dynamic_font_stb.h
@@ -34,7 +34,8 @@
#include "font.h"
#include "io/resource_loader.h"
-#include "stb_truetype.h"
+
+#include "thirdparty/misc/stb_truetype.h"
class DynamicFontAtSize;
class DynamicFont;
diff --git a/scene/resources/surface_tool.h b/scene/resources/surface_tool.h
index 6e52db218d..b143086e11 100644
--- a/scene/resources/surface_tool.h
+++ b/scene/resources/surface_tool.h
@@ -30,9 +30,10 @@
#ifndef SURFACE_TOOL_H
#define SURFACE_TOOL_H
-#include "mikktspace.h"
#include "scene/resources/mesh.h"
+#include "thirdparty/misc/mikktspace.h"
+
class SurfaceTool : public Reference {
GDCLASS(SurfaceTool, Reference);
diff --git a/thirdparty/README.md b/thirdparty/README.md
index ea731282ef..1c4bad4836 100644
--- a/thirdparty/README.md
+++ b/thirdparty/README.md
@@ -1,6 +1,13 @@
# Third party libraries
+## b2d_convexdecomp
+
+- Upstream: https://github.com/erincatto/Box2D (Contributions/Utilities/ConvexDecomposition)
+- Version: TBD
+- License: zlib
+
+
## certs
- Upstream: ?
@@ -158,7 +165,9 @@ TODO: Properly sync with version 1.2.4 and document changes.
## misc
-Collection of single-file libraries used in Godot.
+Collection of single-file libraries used in Godot components.
+
+### core
- `aes256.{cpp,h}`
* Upstream: http://www.literatecode.com/aes256
@@ -198,6 +207,32 @@ Collection of single-file libraries used in Godot.
* Version: TBD, class was renamed
* License: MIT
+### modules
+
+- `curl_hostcheck.{c,h}`
+ * Upstream: https://curl.haxx.se/
+ * Version: ? (2013)
+ * License: MIT
+- `yuv2rgb.h`
+ * Upstream: http://wss.co.uk/pinknoise/yuv2rgb/ (to check)
+ * Version: ?
+ * License: BSD
+
+### scene
+
+- `mikktspace.{c,h}`
+ * Upstream: https://wiki.blender.org/index.php/Dev:Shading/Tangent_Space_Normal_Maps
+ * Version: 1.0
+ * License: zlib
+- `stb_truetype.h`
+ * Upstream: https://github.com/nothings/stb
+ * Version: 1.11
+ * License: Public Domain (Unlicense) or MIT
+- `stb_vorbis.c`
+ * Upstream: https://github.com/nothings/stb
+ * Version: 1.09
+ * License: Public Domain (Unlicense) or MIT
+
## openssl
diff --git a/drivers/convex_decomp/b2Glue.h b/thirdparty/b2d_convexdecomp/b2Glue.h
index 425486356e..425486356e 100644
--- a/drivers/convex_decomp/b2Glue.h
+++ b/thirdparty/b2d_convexdecomp/b2Glue.h
diff --git a/drivers/convex_decomp/b2Polygon.cpp b/thirdparty/b2d_convexdecomp/b2Polygon.cpp
index b6ead62c63..b6ead62c63 100644
--- a/drivers/convex_decomp/b2Polygon.cpp
+++ b/thirdparty/b2d_convexdecomp/b2Polygon.cpp
diff --git a/drivers/convex_decomp/b2Polygon.h b/thirdparty/b2d_convexdecomp/b2Polygon.h
index c466e28f7e..c466e28f7e 100644
--- a/drivers/convex_decomp/b2Polygon.h
+++ b/thirdparty/b2d_convexdecomp/b2Polygon.h
diff --git a/drivers/convex_decomp/b2Triangle.cpp b/thirdparty/b2d_convexdecomp/b2Triangle.cpp
index a0a30b9407..a0a30b9407 100644
--- a/drivers/convex_decomp/b2Triangle.cpp
+++ b/thirdparty/b2d_convexdecomp/b2Triangle.cpp
diff --git a/drivers/convex_decomp/b2Triangle.h b/thirdparty/b2d_convexdecomp/b2Triangle.h
index 99ab5cba69..99ab5cba69 100644
--- a/drivers/convex_decomp/b2Triangle.h
+++ b/thirdparty/b2d_convexdecomp/b2Triangle.h
diff --git a/modules/openssl/curl_hostcheck.c b/thirdparty/misc/curl_hostcheck.c
index feef232619..feef232619 100644
--- a/modules/openssl/curl_hostcheck.c
+++ b/thirdparty/misc/curl_hostcheck.c
diff --git a/modules/openssl/curl_hostcheck.h b/thirdparty/misc/curl_hostcheck.h
index 1b7fbe81e3..1b7fbe81e3 100644
--- a/modules/openssl/curl_hostcheck.h
+++ b/thirdparty/misc/curl_hostcheck.h
diff --git a/scene/resources/mikktspace.c b/thirdparty/misc/mikktspace.c
index 62aa2da251..62aa2da251 100644
--- a/scene/resources/mikktspace.c
+++ b/thirdparty/misc/mikktspace.c
diff --git a/scene/resources/mikktspace.h b/thirdparty/misc/mikktspace.h
index 52c44a713c..52c44a713c 100644
--- a/scene/resources/mikktspace.h
+++ b/thirdparty/misc/mikktspace.h
diff --git a/scene/resources/stb_truetype.h b/thirdparty/misc/stb_truetype.h
index 016972785a..016972785a 100644
--- a/scene/resources/stb_truetype.h
+++ b/thirdparty/misc/stb_truetype.h
diff --git a/thirdparty/stb_vorbis/stb_vorbis.c b/thirdparty/misc/stb_vorbis.c
index c4f24d5898..c4f24d5898 100644
--- a/thirdparty/stb_vorbis/stb_vorbis.c
+++ b/thirdparty/misc/stb_vorbis.c
diff --git a/modules/theora/yuv2rgb.h b/thirdparty/misc/yuv2rgb.h
index a9bef76da8..a9bef76da8 100644
--- a/modules/theora/yuv2rgb.h
+++ b/thirdparty/misc/yuv2rgb.h