From d6b4a524082bf6cbd3ed5b11e1059122e0ffcd35 Mon Sep 17 00:00:00 2001 From: "C. J. Howard" Date: Mon, 27 Nov 2023 22:28:53 +0800 Subject: [PATCH] Remove empty build directory. Upgrade antkeeper-source submodule. Update README --- .gitignore | 1 + CMakeLists.txt | 4 ++-- README.md | 48 ++++++++++++++++++---------------------- build/linux32/.gitignore | 2 -- build/linux64/.gitignore | 2 -- build/win32/.gitignore | 2 -- build/win64/.gitignore | 2 -- modules/antkeeper-source | 2 +- 8 files changed, 26 insertions(+), 37 deletions(-) delete mode 100644 build/linux32/.gitignore delete mode 100644 build/linux64/.gitignore delete mode 100644 build/win32/.gitignore delete mode 100644 build/win64/.gitignore diff --git a/.gitignore b/.gitignore index 3497551..4a2896f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ bin +build dist \ No newline at end of file diff --git a/CMakeLists.txt b/CMakeLists.txt index 270c86f..be816e9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,7 +3,7 @@ if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR}) message(FATAL_ERROR "In-source builds prohibited. Call CMake from a build/ directory.") endif() -cmake_minimum_required(VERSION 3.25) +cmake_minimum_required(VERSION 3.28) set(APPLICATION_NAME "Antkeeper") set(APPLICATION_VERSION "0.0.1") @@ -52,7 +52,7 @@ else() endif() # Options -set(BLENDER "blender" CACHE FILEPATH "Path to Blender executable") +option(BLENDER "Path to Blender executable" "") # Set compiler and linker flags if(MSVC) diff --git a/README.md b/README.md index 4601c5e..620ad7d 100644 --- a/README.md +++ b/README.md @@ -1,43 +1,35 @@ # Antkeeper Superbuild -This repository contains the superbuild system and all dependencies required to build Antkeeper. +This repository contains the build system and all dependencies required to build [Antkeeper](https://antkeeper.com/), a 3D ant colony simulation game. ## Download -Download the Antkeeper superbuild repository and all of its Git submodules: +Download the Antkeeper superbuild repository and its Git submodules (excluding `antkeeper-data`): - git clone --recursive https://github.com/antkeeper/antkeeper-superbuild.git + git -c submodule."modules/antkeeper-data".update=none clone --recursive https://github.com/antkeeper/antkeeper-superbuild.git . -> Note: The `antkeeper-data` submodule contains proprietary game data and is not publicly available. The game can be built without this submodule, but the game data is required to play Antkeeper. You can get a copy of the game data by purchasing Antkeeper at [antkeeper.com](https://antkeeper.com/). +> [!NOTE] +> The `antkeeper-data` submodule contains proprietary game data and is not publicly available. The game executable can be built without this submodule, but its data package is required to play Antkeeper. You can get a copy of the data package by purchasing Antkeeper at . ## Configuration & Building -CMake is required to configure and build the application. Depending on the target platform, CMake should be invoked from one of the following directories: +### Windows -| Directory | Platform | -| :----------------------------- | :------------- | -| [build/linux32](build/linux32) | 32-bit Linux | -| [build/linux64](build/linux64) | 64-bit Linux | -| [build\win32](build/win32) | 32-bit Windows | -| [build\win64](build/win64) | 64-bit Windows | +Building for Windows requires CMake and Visual Studio Build Tools. -The following arguments may be passed to CMake during configuration: +Run the following commands in the `x64 Native Tools Command Prompt` to configure and build a 64-bit Windows release: - -DCMAKE_BUILD_TYPE // [Debug, Release] + cmake -B build\win64 -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Release + cmake --build build\win64 --config Release ### Linux -Building for Linux requires CMake, GCC, G++, and GNU Make. Navigate to either the [build/linux32](build/linux32) or [build/linux64](build/linux64) directory and run the following commands: - - cmake ../.. -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=... - cmake --build . - -### Windows +Building for Linux requires CMake, GCC, G++, and GNU Make. -Building for Windows requires CMake and Visual Studio Build Tools. Additionally, [NSIS](http://nsis.sourceforge.net/) is required if you want to build a distributable installer program. In order to correctly build for your target architecture, you must use the `x86 Native Tools Command Prompt` or the `x64 Native Tools Command Prompt` for 32-bit and 64-bit applications, respectively. Then navigate to either the [build\win32](build/win32) or [build\win64](build/win64) directory and run the following commands: +Run the following commands to configure and build a 64-bit Linux release: - cmake ..\.. -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=... - cmake --build . + cmake -B build/linux64 -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release + cmake --build build/linux64 --config Release ## Running @@ -45,9 +37,13 @@ After building, a standalone version of the application will be located somewher ## Distribution -The built application can be packaged into a distributable format with the following command: +The built application can be packaged into a distributable format with the following commands: + + cmake --build build\win64 --target dist + +or - cmake --build . --target dist + cmake --build build/linux64 --target dist The resulting package will be located in the `dist` directory. @@ -55,11 +51,11 @@ The resulting package will be located in the `dist` directory. If any changes have been made to the submodules, commit those first. Each submodule can then be updated to their latest commits with the following command: - git submodule update --recursive --remote + git -c submodule."modules/antkeeper-data".update=none submodule update --recursive --remote ## License -Antkeeper superbuild is licensed under the GNU General Public License, version 3. For more information, see [`LICENSE.md`](LICENSE.md). +Antkeeper superbuild is licensed under the GNU General Public License, version 3. For more information, see [LICENSE.md](./LICENSE.md). ### 3rd-Party Software diff --git a/build/linux32/.gitignore b/build/linux32/.gitignore deleted file mode 100644 index c96a04f..0000000 --- a/build/linux32/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -* -!.gitignore \ No newline at end of file diff --git a/build/linux64/.gitignore b/build/linux64/.gitignore deleted file mode 100644 index c96a04f..0000000 --- a/build/linux64/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -* -!.gitignore \ No newline at end of file diff --git a/build/win32/.gitignore b/build/win32/.gitignore deleted file mode 100644 index c96a04f..0000000 --- a/build/win32/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -* -!.gitignore \ No newline at end of file diff --git a/build/win64/.gitignore b/build/win64/.gitignore deleted file mode 100644 index c96a04f..0000000 --- a/build/win64/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -* -!.gitignore \ No newline at end of file diff --git a/modules/antkeeper-source b/modules/antkeeper-source index d5bb588..628cbca 160000 --- a/modules/antkeeper-source +++ b/modules/antkeeper-source @@ -1 +1 @@ -Subproject commit d5bb5887cc1705a80042c1f9b3b11cb188e0c99c +Subproject commit 628cbca31d424a95a53ded84d1164f8d7f2e85f2