nvm was another issue.

This commit is contained in:
Edward R. Gonzalez 2022-05-12 09:06:22 -04:00
parent 96dad8a849
commit 0033fb160b
7 changed files with 15 additions and 8 deletions

3
.gitignore vendored
View File

@ -39,3 +39,6 @@ mono_crash.*.json
# Built Visual Studio Code Extensions # Built Visual Studio Code Extensions
*.vsix *.vsix
# Fork
Source/.sconsign.dblite

3
.gitmodules vendored
View File

@ -1,3 +1,6 @@
[submodule "Engine/gd"] [submodule "Engine/gd"]
path = Engine/gd path = Engine/gd
url = https://github.com/godotengine/godot url = https://github.com/godotengine/godot
[submodule "Engine/gdnative_cpp"]
path = Engine/gdnative_cpp
url = https://github.com/godotengine/godot-cpp

1
Engine/gdnative_cpp Submodule

@ -0,0 +1 @@
Subproject commit 95a2303e37fd28b20c2e53f82e867f5a08e1af53

Binary file not shown.

View File

@ -18,10 +18,13 @@ opts.Add(PathVariable('target_path', 'The path where the lib is installed.', Pro
opts.Add(PathVariable('target_name', 'The library name.', 'libgdexample', PathVariable.PathAccept)) opts.Add(PathVariable('target_name', 'The library name.', 'libgdexample', PathVariable.PathAccept))
# Local dependency paths, adapt them to your setup # Local dependency paths, adapt them to your setup
godot_headers_path = ProjPath + "/Engine/gdnative_cpp/godot-headers/" godot_headers_path = ProjPath + "/Engine/gdnative_cpp/godot_cpp/godot-headers/"
cpp_bindings_path = ProjPath + "/Engine/gdnative_cpp/" cpp_bindings_path = ProjPath + "/Engine/gdnative_cpp/godot_cpp/"
cpp_library = "libgodot-cpp" cpp_library = "libgodot-cpp"
GDNative_Src = ProjPath + '/Engine/gdnative_cpp/godot_cpp/src/*.cpp'
Src = ProjPath + "/Source/*.cpp"
# only support 64 at this time.. # only support 64 at this time..
bits = 64 bits = 64
@ -100,16 +103,13 @@ env.Append(CPPPATH=['.', godot_headers_path, cpp_bindings_path + 'include/', cpp
env.Append(LIBPATH=[cpp_bindings_path + 'bin/']) env.Append(LIBPATH=[cpp_bindings_path + 'bin/'])
env.Append(LIBS=[cpp_library]) env.Append(LIBS=[cpp_library])
GDNative_Src = ProjPath + '/Engine/gdnative_cpp/src/*.cpp'
Src = ProjPath + "/Source/*.cpp"
# tweak this if you want to use different folders, or more folders, to store your source code in. # tweak this if you want to use different folders, or more folders, to store your source code in.
env.Append(CPPPATH=[GDNative_Src]) env.Append(CPPPATH=[GDNative_Src])
env.Append(CPPPATH=[Src]) env.Append(CPPPATH=[Src])
sources = Glob(GDNative_Src, Src) sources = Glob(GDNative_Src, Src)
test = "Sources: ".join(sources)
print(test);
print(sources);
library = env.SharedLibrary(target=env['target_path'] + env['target_name'] , source=sources) library = env.SharedLibrary(target=env['target_path'] + env['target_name'] , source=sources)
Default(library) Default(library)

Binary file not shown.

Binary file not shown.