You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
2.1 KiB
31 lines
2.1 KiB
SET ANDROID_SDK=D:\Android\android-sdk
|
|
SET ANDROID_NDK=D:\Android\android-ndk-r10e-windows-x86_64
|
|
|
|
for /f %%a in ('dir /a:d /b %ANDROID_SDK%\cmake\') do set cmake_version=%%a
|
|
echo %cmake_version%
|
|
set cmake_bin=%ANDROID_SDK%\cmake\%cmake_version%\bin\cmake.exe
|
|
set ninja_bin=%ANDROID_SDK%\cmake\%cmake_version%\bin\ninja.exe
|
|
|
|
mkdir build_v7a
|
|
%cmake_bin% -H.\ -B.\build_v7a "-GAndroid Gradle - Ninja" -DANDROID_ABI=armeabi-v7a -DANDROID_NDK=%ANDROID_NDK% -DCMAKE_BUILD_TYPE=Relase -DCMAKE_MAKE_PROGRAM=%ninja_bin% -DCMAKE_TOOLCHAIN_FILE=.\cmake\android.windows.toolchain.cmake "-DCMAKE_CXX_FLAGS=-std=c++11 -fexceptions -Os -DNDEBUG"
|
|
%ninja_bin% -C .\build_v7a
|
|
mkdir .\plugin_lua53\Plugins\Android\Libs\armeabi-v7a
|
|
copy /Y .\build_v7a\libxlua.so .\plugin_lua53\Plugins\Android\Libs\armeabi-v7a\libxlua.so
|
|
|
|
mkdir build_android_x86
|
|
%cmake_bin% -H.\ -B.\build_android_x86 "-GAndroid Gradle - Ninja" -DANDROID_ABI=x86 -DANDROID_NDK=%ANDROID_NDK% -DCMAKE_BUILD_TYPE=Relase -DCMAKE_MAKE_PROGRAM=%ninja_bin% -DCMAKE_TOOLCHAIN_FILE=.\cmake\android.windows.toolchain.cmake "-DCMAKE_CXX_FLAGS=-std=c++11 -fexceptions -O1 -DNDEBUG"
|
|
%ninja_bin% -C .\build_android_x86
|
|
mkdir .\plugin_lua53\Plugins\Android\Libs\x86
|
|
copy /Y .\build_android_x86\libxlua.so .\plugin_lua53\Plugins\Android\Libs\x86\libxlua.so
|
|
|
|
mkdir build_v8a
|
|
%cmake_bin% -H.\ -B.\build_v8a "-GAndroid Gradle - Ninja" -DANDROID_ABI=arm64-v8a -DANDROID_NDK=%ANDROID_NDK% -DCMAKE_BUILD_TYPE=Relase -DCMAKE_MAKE_PROGRAM=%ninja_bin% -DCMAKE_TOOLCHAIN_FILE=.\cmake\android.windows.toolchain.cmake "-DCMAKE_CXX_FLAGS=-std=c++11 -fexceptions -Os -DNDEBUG"
|
|
%ninja_bin% -C .\build_v8a
|
|
mkdir .\plugin_lua53\Plugins\Android\Libs\arm64-v8a
|
|
copy /Y .\build_v8a\libxlua.so .\plugin_lua53\Plugins\Android\Libs\arm64-v8a\libxlua.so
|
|
|
|
copy /Y .\plugin_lua53\Plugins\Android\Libs\arm64-v8a\*.so E:\GameCode\arpg_cli_proj\arpg\Assets\Plugins\Android\libs\arm64-v8a\
|
|
copy /Y .\plugin_lua53\Plugins\Android\Libs\armeabi-v7a\*.so E:\GameCode\arpg_cli_proj\arpg\Assets\Plugins\Android\libs\armeabi-v7a\
|
|
copy /Y .\plugin_lua53\Plugins\Android\Libs\x86\*.so E:\GameCode\arpg_cli_proj\arpg\Assets\Plugins\Android\libs\x86\
|
|
echo "compile success"
|
|
pause
|