mirror of
https://github.com/godotengine/godot-git-plugin.git
synced 2026-01-03 10:09:43 +03:00
Add libssh2 to SCons build
This commit is contained in:
1
thirdparty/SCsub
vendored
1
thirdparty/SCsub
vendored
@@ -1,3 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
SConscript("ssh2/SCsub")
|
||||
SConscript("git2/SCsub")
|
||||
|
||||
10
thirdparty/git2/SCsub
vendored
10
thirdparty/git2/SCsub
vendored
@@ -42,14 +42,15 @@ env_git.Prepend(
|
||||
"libgit2/deps/http-parser/",
|
||||
"libgit2/deps/pcre/",
|
||||
"libgit2/deps/zlib/",
|
||||
"../ssh2/libssh2/include/",
|
||||
]
|
||||
)
|
||||
|
||||
env_git.Prepend(
|
||||
CPPDEFINES=[
|
||||
"GIT_THREADS",
|
||||
#"GIT_SSH",
|
||||
#"GIT_SSH_MEMORY_CREDENTIALS",
|
||||
"GIT_SSH",
|
||||
"GIT_SSH_MEMORY_CREDENTIALS",
|
||||
"LIBGIT2_NO_FEATURES_H",
|
||||
"GIT_SHA1_COLLISIONDETECT",
|
||||
"GIT_HTTPS",
|
||||
@@ -83,6 +84,8 @@ if env_git["platform"] == "windows":
|
||||
"PCREGREP_BUFSIZE",
|
||||
("MAX_NAME_SIZE", "32"),
|
||||
("MAX_NAME_COUNT", "10000"),
|
||||
"HAVE_WINCNG",
|
||||
"LIBSSH2_WINCNG"
|
||||
]
|
||||
)
|
||||
|
||||
@@ -116,5 +119,6 @@ if env_git["platform"] in ["x11", "osx"]:
|
||||
]
|
||||
)
|
||||
|
||||
env_git["PDB"] = "git2.pdb"
|
||||
env.Append(LIBPATH=["../bin/"])
|
||||
|
||||
env_git.StaticLibrary(target = "../bin/" + "git2", source = libgit2_sources)
|
||||
|
||||
76
thirdparty/ssh2/SCsub
vendored
Normal file
76
thirdparty/ssh2/SCsub
vendored
Normal file
@@ -0,0 +1,76 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
# Adopted from https://github.com/nodegit/nodegit/blob/4561dcb7c120474a4553baa27e4c4c2f4be23a2b/vendor/libgit2.gyp
|
||||
|
||||
Import("env")
|
||||
|
||||
env_ssh2 = env.Clone()
|
||||
|
||||
# Thirdparty source files.
|
||||
libssh2_sources = [
|
||||
"libssh2/src/agent.c",
|
||||
"libssh2/src/bcrypt_pbkdf.c",
|
||||
"libssh2/src/blowfish.c",
|
||||
"libssh2/src/crypt.c",
|
||||
"libssh2/src/keepalive.c",
|
||||
"libssh2/src/libgcrypt.c",
|
||||
"libssh2/src/openssl.c",
|
||||
"libssh2/src/publickey.c",
|
||||
"libssh2/src/sftp.c",
|
||||
"libssh2/src/version.c",
|
||||
"libssh2/src/channel.c",
|
||||
"libssh2/src/global.c",
|
||||
"libssh2/src/kex.c",
|
||||
"libssh2/src/mac.c",
|
||||
"libssh2/src/packet.c",
|
||||
"libssh2/src/scp.c",
|
||||
"libssh2/src/transport.c",
|
||||
"libssh2/src/comp.c",
|
||||
"libssh2/src/hostkey.c",
|
||||
"libssh2/src/knownhost.c",
|
||||
"libssh2/src/misc.c",
|
||||
"libssh2/src/pem.c",
|
||||
"libssh2/src/session.c",
|
||||
"libssh2/src/userauth.c",
|
||||
]
|
||||
|
||||
env_ssh2.Prepend(
|
||||
CPPPATH=[
|
||||
"libssh2/include/"
|
||||
"libssh2/src/"
|
||||
]
|
||||
)
|
||||
|
||||
env_ssh2.Prepend(
|
||||
CPPDEFINES=[
|
||||
]
|
||||
)
|
||||
|
||||
if env_ssh2["platform"] == "windows":
|
||||
env_ssh2.Append(
|
||||
CPPPATH=[
|
||||
"libssh2/include/",
|
||||
"libssh2/win32/"
|
||||
]
|
||||
)
|
||||
libssh2_sources += [ "libssh2/src/agent_win.c", "libssh2/src/wincng.c"]
|
||||
env_ssh2.Append(
|
||||
CPPDEFINES=[
|
||||
"LIBSSH2_WINCNG",
|
||||
"HAVE_WINCNG"
|
||||
]
|
||||
)
|
||||
env_ssh2.Append(LIBS = ["crypt32", "user32"])
|
||||
|
||||
if env_ssh2["platform"] == "osx":
|
||||
env_ssh2.Append(
|
||||
CPPPATH=[
|
||||
"libssh2/os400/"
|
||||
]
|
||||
)
|
||||
libssh2_sources += ["libssh2/os400/" + "*.c"]
|
||||
env_ssh2.Append(
|
||||
CPPDEFINES=[]
|
||||
)
|
||||
|
||||
env_ssh2.StaticLibrary(target = "../bin/" + "ssh2", source = libssh2_sources)
|
||||
1
thirdparty/ssh2/libssh2
vendored
Submodule
1
thirdparty/ssh2/libssh2
vendored
Submodule
Submodule thirdparty/ssh2/libssh2 added at 635caa9078
Reference in New Issue
Block a user