mirror of
https://github.com/godotengine/godot-git-plugin.git
synced 2026-01-06 02:09:44 +03:00
Merge pull request #52 from IronicallySerious/mac-port
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -10,6 +10,9 @@ api.json
|
||||
# VSCode Cache
|
||||
.vscode/
|
||||
|
||||
# Mac stuff
|
||||
.DS_Store
|
||||
|
||||
# Binaries
|
||||
bin/
|
||||
intermediate/
|
||||
|
||||
10
README.md
10
README.md
@@ -6,7 +6,7 @@ Git implementation of the Godot Engine VCS interface in Godot. We use [libgit2](
|
||||
|
||||
## Installation Instructions
|
||||
|
||||
1. Grab the Linux and/or Windows binaries here: <https://github.com/godotengine/godot-git-plugin/releases>
|
||||
1. Grab the platform binaries here: <https://github.com/godotengine/godot-git-plugin/releases>
|
||||
2. Then read the installation instructions: https://github.com/godotengine/godot-git-plugin/wiki
|
||||
|
||||
## Build Instructions
|
||||
@@ -34,6 +34,14 @@ Required build tools:
|
||||
2. Run ```. ./build_libs.sh Release```.
|
||||
3. Run ```scons platform=x11 target=release```.
|
||||
|
||||
### MacOS
|
||||
|
||||
> G++ and Clang++ are our recommended compilers for MacOS
|
||||
|
||||
1. Prepare script for execution: ```chmod 755 build_libs_mac.sh```
|
||||
2. Run ```. ./build_libs_mac.sh Release```.
|
||||
3. Run ```scons platform=osx target=release```.
|
||||
|
||||
#### Debug build
|
||||
|
||||
Replace `Release` with `Debug` and `release` with `debug` in the above instructions for a debug build. You will also have to do the same in the paths mentioned in `demo/git_api.gdnlib` before opening the demo project in Godot.
|
||||
|
||||
23
build_libs_mac.sh
Executable file
23
build_libs_mac.sh
Executable file
@@ -0,0 +1,23 @@
|
||||
git submodule init;
|
||||
git submodule update --init --recursive;
|
||||
|
||||
cd godot-git-plugin/thirdparty/libgit2/
|
||||
mkdir build
|
||||
cd build/
|
||||
rm CMakeCache.txt
|
||||
cmake .. -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DBUILD_SHARED_LIBS=OFF -DBUILD_CLAR=OFF -DBUILD_EXAMPLES=OFF -DUSE_SSH=OFF -DUSE_HTTPS=OFF -DUSE_BUNDLED_ZLIB=ON -DUSE_ICONV=OFF
|
||||
cmake --build . --config $1
|
||||
cd ../../../../
|
||||
mkdir -p "demo/bin/osx/"
|
||||
cp "godot-git-plugin/thirdparty/libgit2/build/libgit2.a" "demo/bin/osx/libgit2.a"
|
||||
|
||||
if [ -z "$CI" ]
|
||||
then
|
||||
echo "Non-CI run was detected"
|
||||
else
|
||||
echo "CI run was detected"
|
||||
fi
|
||||
|
||||
cd godot-cpp/;
|
||||
scons platform=osx target=$1 generate_bindings=yes bits=64;
|
||||
cd ..
|
||||
@@ -7,10 +7,12 @@ reloadable=false
|
||||
|
||||
[entry]
|
||||
|
||||
OSX.64="res://bin/osx/release/libgitapi.dylib"
|
||||
Windows.64="res://bin/win64/release/libgitapi.dll"
|
||||
X11.64="res://bin/x11/release/libgitapi.so"
|
||||
|
||||
[dependencies]
|
||||
|
||||
OSX.64=[ ]
|
||||
Windows.64=[ ]
|
||||
X11.64=[ ]
|
||||
|
||||
Reference in New Issue
Block a user