CaveCube
CaveCube copied to clipboard
An in-development open source voxel game
CaveCube
An in-development Minecraft/Infiniminer clone

Contributing
Please read the contributing guide.
The project status is written down in TODO.md.
Requirements
Building
GLFW or SDL2, GNU Make, and a C compiler with pthreads support.
For Windows with MinGW, the GLFW or SDL2 development binaries must be installed from their respective websites: GLFW, SDL2.
For Windows with MSYS2, use the MINGW64 environment and install make for make, mingw-w64-x86_64-gcc for GCC, mingw-w64-x86_64-glfw for GLFW or mingw-w64-x86_64-SDL2 for SDL2.
For outdated/stable Linux distributions (such as Debian or Ubuntu), GLFW must be built from source due to the package being out of date.
Running
OpenGL 3.3 or OpenGLES 3.0 support.
Building
Command to download source code:
git clone --filter=tree:0 https://github.com/PQCraft/CaveCube.git
- To build, run
make -j. - To build and run once done compiling, run
make -j run. - To build for debugging, add
DEBUG=[level]aftermake(e.g.make DEBUG=0 -j run). This will build the executable with debug symbols, disable symbol stripping, and define the internalDEBUGmacro with the level specified. - To compile with using SDL2 instead of GLFW, add
USESDL2=yaftermake. - To compile using OpenGL ES instead of OpenGL, add
USEGLES=yaftermake. - To change the target, add
MODULE=[target]aftermake. The valid targets aregamefor the client (default),serverfor the standalone server, andtoolboxfor the toolbox. This variable may change the object directory and binary name. - To cross compile to another platform, add
CROSS=[platform]aftermake. The valid cross-compilation platforms arewin32for Windows, andemscrfor Emscripten. This variable may change the object directory and binary name. - To compile a 32-bit binary on a 64-bit machine, add
M32=yaftermake. This variable will change the object directory.
These variables can be combined.
For example, make USESDL2=y CROSS=win32 -j run will build CaveCube for Windows with SDL2 and run when compilation finishes.
For any variables that change the object directory or binary name, you must use these flags again when running the clean rule in order to remove the correct files.
When using MSYS2, the MINGW64 environment is recommended and always use MSYS2=y (e.g. make MSYS2=y -j, make MSYS2=y clean).
Notes 
- CaveCube can be installed on Arch Linux using the cavecube, cavecube-bin, cavecube-sdl2, or cavecube-sdl2-bin AUR package.