163 lines
5.3 KiB
Diff
163 lines
5.3 KiB
Diff
|
Index: sdk/angelscript/projects/meson/meson.build
|
||
|
===================================================================
|
||
|
--- sdk.orig/angelscript/projects/meson/meson.build
|
||
|
+++ sdk/angelscript/projects/meson/meson.build
|
||
|
@@ -1,6 +1,6 @@
|
||
|
project('angelscript', 'cpp',
|
||
|
version : run_command(find_program('python3'), 'detect_ver.py').stdout().strip(),
|
||
|
- meson_version : '>=0.28.0',
|
||
|
+ meson_version : '>=0.49.0',
|
||
|
license : 'zlib')
|
||
|
|
||
|
threads = dependency('threads')
|
||
|
@@ -42,6 +42,31 @@ angel_srcs = [
|
||
|
'../../source/as_typeinfo.cpp',
|
||
|
'../../source/as_variablescope.cpp',
|
||
|
]
|
||
|
+
|
||
|
+angel_incl_dir = get_option('includedir') / 'AngelScript'
|
||
|
+
|
||
|
+angel_addons_srcs = [
|
||
|
+ '../../../add_on/autowrapper/generator/generateheader.cpp',
|
||
|
+ '../../../add_on/contextmgr/contextmgr.cpp',
|
||
|
+ '../../../add_on/datetime/datetime.cpp',
|
||
|
+ '../../../add_on/debugger/debugger.cpp',
|
||
|
+ '../../../add_on/scriptany/scriptany.cpp',
|
||
|
+ '../../../add_on/scriptarray/scriptarray.cpp',
|
||
|
+ '../../../add_on/scriptbuilder/scriptbuilder.cpp',
|
||
|
+ '../../../add_on/scriptdictionary/scriptdictionary.cpp',
|
||
|
+ '../../../add_on/scriptfile/scriptfile.cpp',
|
||
|
+ '../../../add_on/scriptfile/scriptfilesystem.cpp',
|
||
|
+ '../../../add_on/scriptgrid/scriptgrid.cpp',
|
||
|
+ '../../../add_on/scripthandle/scripthandle.cpp',
|
||
|
+ '../../../add_on/scripthelper/scripthelper.cpp',
|
||
|
+ '../../../add_on/scriptmath/scriptmathcomplex.cpp',
|
||
|
+ '../../../add_on/scriptmath/scriptmath.cpp',
|
||
|
+ '../../../add_on/scriptstdstring/scriptstdstring.cpp',
|
||
|
+ '../../../add_on/scriptstdstring/scriptstdstring_utils.cpp',
|
||
|
+ '../../../add_on/serializer/serializer.cpp',
|
||
|
+ '../../../add_on/weakref/weakref.cpp'
|
||
|
+]
|
||
|
+
|
||
|
if host_machine.cpu_family() == 'arm'
|
||
|
add_languages('c')
|
||
|
angel_srcs += [
|
||
|
@@ -55,7 +80,8 @@ angelscript_lib = library(
|
||
|
'angelscript',
|
||
|
sources : angel_srcs,
|
||
|
dependencies : threads,
|
||
|
- version : angelscript_version_num,
|
||
|
+ soversion : meson.project_version(),
|
||
|
+ version : meson.project_version(),
|
||
|
install : true,
|
||
|
)
|
||
|
angelscript_inc = include_directories('../../include')
|
||
|
@@ -65,4 +91,93 @@ angelscript_dep = declare_dependency(
|
||
|
version : meson.project_version(),
|
||
|
)
|
||
|
|
||
|
-install_headers('../../include/angelscript.h')
|
||
|
+angelscript_addons_lib = library(
|
||
|
+ 'angelscript_addons',
|
||
|
+ sources : angel_addons_srcs,
|
||
|
+ link_with : angelscript_lib,
|
||
|
+ include_directories : angelscript_inc,
|
||
|
+ soversion : meson.project_version(),
|
||
|
+ version : meson.project_version(),
|
||
|
+ install : true
|
||
|
+ )
|
||
|
+
|
||
|
+pkg = import('pkgconfig')
|
||
|
+pkg.generate(angelscript_lib, filebase : 'angelscript', description : 'Scripting library', subdirs : 'AngelScript')
|
||
|
+pkg.generate(angelscript_addons_lib, filebase : 'angelscript_addons', description : 'Scripting library', subdirs : 'AngelScript')
|
||
|
+
|
||
|
+install_headers(
|
||
|
+ '../../include/angelscript.h',
|
||
|
+ install_dir : angel_incl_dir
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/autowrapper/aswrappedcall.h',
|
||
|
+ install_dir : angel_incl_dir / 'autowrapper'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/contextmgr/contextmgr.h',
|
||
|
+ install_dir : angel_incl_dir / 'contextmgr'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/datetime/datetime.h',
|
||
|
+ install_dir : angel_incl_dir / 'datetime'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/debugger/debugger.h',
|
||
|
+ install_dir : angel_incl_dir / 'debugger'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptany/scriptany.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptany'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptarray/scriptarray.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptarray'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptbuilder/scriptbuilder.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptbuilder'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptdictionary/scriptdictionary.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptdictionary'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptfile/scriptfile.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptfile'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptfile/scriptfilesystem.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptfile'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptgrid/scriptgrid.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptgrid'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scripthandle/scripthandle.h',
|
||
|
+ install_dir : angel_incl_dir / 'scripthandle'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scripthelper/scripthelper.h',
|
||
|
+ install_dir : angel_incl_dir / 'scripthelper'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptmath/scriptmathcomplex.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptmath'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptmath/scriptmath.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptmath'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/scriptstdstring/scriptstdstring.h',
|
||
|
+ install_dir : angel_incl_dir / 'scriptstdstring'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/serializer/serializer.h',
|
||
|
+ install_dir : angel_incl_dir / 'serializer'
|
||
|
+ )
|
||
|
+install_headers(
|
||
|
+ '../../../add_on/weakref/weakref.h',
|
||
|
+ install_dir : angel_incl_dir / 'weakref'
|
||
|
+ )
|
||
|
Index: sdk/add_on/scriptfile/scriptfilesystem.cpp
|
||
|
===================================================================
|
||
|
--- sdk.orig/add_on/scriptfile/scriptfilesystem.cpp
|
||
|
+++ sdk/add_on/scriptfile/scriptfilesystem.cpp
|
||
|
@@ -15,6 +15,8 @@
|
||
|
#endif
|
||
|
#include <assert.h> // assert
|
||
|
|
||
|
+#include <cstring>
|
||
|
+
|
||
|
using namespace std;
|
||
|
|
||
|
BEGIN_AS_NAMESPACE
|