From dd665f092f0c8b752904252b660177b5d5b77372 Mon Sep 17 00:00:00 2001 From: Mat Date: Thu, 2 Jan 2020 17:59:07 +0200 Subject: Clean up server folder for Android (#4448) --- Server/Install/UnixExecutables.list | 17 +++++++++++++++++ android/compile.sh | 6 ++++-- src/CMakeLists.txt | 12 ++++++------ 3 files changed, 27 insertions(+), 8 deletions(-) create mode 100644 Server/Install/UnixExecutables.list diff --git a/Server/Install/UnixExecutables.list b/Server/Install/UnixExecutables.list new file mode 100644 index 000000000..2d6734684 --- /dev/null +++ b/Server/Install/UnixExecutables.list @@ -0,0 +1,17 @@ +Cuberite +Plugins +Prefabs +webadmin +BACKERS +brewing.txt +crafting.txt +furnace.txt +items.ini +monsters.ini +buildinfo.txt +README.txt +favicon.png +CONTRIBUTORS +LICENSE +*.example.ini +ThirdPartyLicenses diff --git a/android/compile.sh b/android/compile.sh index 8be0e147c..72d5df181 100755 --- a/android/compile.sh +++ b/android/compile.sh @@ -64,8 +64,6 @@ case "$1" in echo "Packing server.zip ..." rm -rf Server mkdir -p Server - cd $BASEDIR/../Server - zip -r $BASEDIR/Server/server.zip * for arch in armeabi-v7a arm64-v8a x86 x86_64; do echo "Doing ... $arch ..." && \ @@ -76,6 +74,10 @@ case "$1" in zip $BASEDIR/Server/"$arch".zip Cuberite done + echo "Packing server.zip ..." + cd $BUILDDIR/Server + zip -r $BASEDIR/Server/server.zip -@ -x Cuberite < Install/UnixExecutables.list + cd $BASEDIR/Server for file in server.zip armeabi-v7a.zip arm64-v8a.zip x86.zip x86_64.zip; do echo "Generating sha1 sum for ... $file ..." && \ diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 70572d845..92f7b11b5 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -403,12 +403,12 @@ set(symlinks message("Creating output folder and symlinks...") file(MAKE_DIRECTORY "${CMAKE_BINARY_DIR}/Server") foreach (symlink ${symlinks}) - make_symlink("${CMAKE_SOURCE_DIR}/Server/${symlink}" "${CMAKE_BINARY_DIR}/Server/${symlink}") + make_symlink("${CMAKE_CURRENT_SOURCE_DIR}/../Server/${symlink}" "${CMAKE_BINARY_DIR}/Server/${symlink}") endforeach(symlink) -make_symlink("${CMAKE_SOURCE_DIR}/BACKERS" "${CMAKE_BINARY_DIR}/Server/BACKERS") -make_symlink("${CMAKE_SOURCE_DIR}/CONTRIBUTORS" "${CMAKE_BINARY_DIR}/Server/CONTRIBUTORS") -make_symlink("${CMAKE_SOURCE_DIR}/LICENSE" "${CMAKE_BINARY_DIR}/Server/LICENSE") -make_symlink("${CMAKE_SOURCE_DIR}/Server/Install/ThirdPartyLicenses" "${CMAKE_BINARY_DIR}/Server/ThirdPartyLicenses") +make_symlink("${CMAKE_CURRENT_SOURCE_DIR}/../BACKERS" "${CMAKE_BINARY_DIR}/Server/BACKERS") +make_symlink("${CMAKE_CURRENT_SOURCE_DIR}/../CONTRIBUTORS" "${CMAKE_BINARY_DIR}/Server/CONTRIBUTORS") +make_symlink("${CMAKE_CURRENT_SOURCE_DIR}/../LICENSE" "${CMAKE_BINARY_DIR}/Server/LICENSE") +make_symlink("${CMAKE_CURRENT_SOURCE_DIR}/../Server/Install/ThirdPartyLicenses" "${CMAKE_BINARY_DIR}/Server/ThirdPartyLicenses") @@ -444,7 +444,7 @@ target_link_libraries(${CMAKE_PROJECT_NAME} luaexpat jsoncpp_lib_static mbedtls # Create a folder for Bindings' documentation: FILE(MAKE_DIRECTORY "Bindings/docs") -make_symlink("${CMAKE_SOURCE_DIR}/src/Bindings/docs" "${CMAKE_BINARY_DIR}/Server/BindingsDocs") +make_symlink("${CMAKE_CURRENT_SOURCE_DIR}/Bindings/docs" "${CMAKE_BINARY_DIR}/Server/BindingsDocs") # For MSVC, set the startup project to Cuberite, and the debugger dir: -- cgit v1.2.3