The open source Zircon engine ("DarkPlaces Mark V Project") is a modification DarkPlaces engine with a mouse driven menu everywhere, ALT-ENTER fullscreen/windowed switching and 88 other enhancements to support user/mapper/mod coder ease-of-use and optional conveniences for those interested in a "1996 Quake" experience. "csqc_full_width_height 1" in console when running Arcane Dimensions at this time It is hoped that some/many/all of these enhancements will eventually make it into official DarkPlaces. The Zircon engine seeks to keep full compatibility with DarkPlaces so either engine can be used interchangeably.

Post news Report RSS October Lab Report #7 of 12 - Compiling Android, Windows

How to compile for Android, including the debugging methods I use. How to compile current Zircon for Windows.

Posted by on

Pictured: KleskBY's Work On Android Controls (Updated)

kleskby44

Compiling For Android / Windows

The long-time DarkPlaces total conversion modder Kleskby (QUALKER mod) has joined the project and wants to do a version of Zircon in Google Play store so that it does not need to be sideloaded to offer a better experience. I will be supporting him in that effort and linking to it here.

adroid2

I am documenting how to compile the Android Version of Zircon, how I approach debugging it, etc. I will also be covering how to compile the current Windows version of Zircon. Kleskby has a tutorial on how to compile current DarkPlaces beta (link).

On a separate note, I have reported 3 issues in current DarkPlaces beta to the DarkPlaces devs and provided solutions I found to one of the issues (I had some real trouble building on Windows and a serious gamedir change issue). I had hoped to have a 20%-30% Zirconized DarkPlaces beta available for testing this week, it is delayed by a few days. As always, the DarkPlaces devs are more than welcome to put anything from Zircon in official DarkPlaces.

Compiling For Android / Windows


Get The Java That Is Compatible With Android Phones

1. Install jre-8u45-windows-x64.exe - Oracle.com -- as far as I know, it must be this exact version because this is version that Android is compatible with.

zcompileandroid2

1. Install Android Studio (https://developer.android.com/studio). The version I installed today was "Giraffe".

2. Go to the SDK Manager

astud1


11. Install The Android NDK and Google USB Driver (install support, debug messages). The NDK is the "Native" -- C/C++ support.


zcompile8


11. Unzip the source code to Zircon alpha 60 to a folder. (download)

12. Navigate to where zirconsource20231002.zip is unzipped. Find the xtra folder and enter it.

zcompilea3

13. Find make_symlink.bat and run it and press Enter. It makes a symbolic link at xtra/app/jni/SDL2 from a different folder where the SDL2 compile libraries are.

zcompilea4

13. (optional) For future convenience, you should enable Android debugging on your phone. There is .bat file to directly install a compiled APK (the Android package this tutorial builds) from your PC onto your phone (adb_install.bat, adb_install_release.bat) if a USB cable is connected.

To enable Android debugging on your phone,it rough goes like this but likely you will need to use a search engine for your version of Android and your phone model.

  1. Select System.
  2. Scroll to the bottom and select About phone.
  3. Scroll to the bottom and tap Build number 7 times.
  4. Return to the previous screen to find Developer options near the bottom.
  5. Scroll down and enable USB debugging.

Compiling (gradle_assembleDebug.bat)

14. Use the gradle_assembleDebug.bat or the gradle_assembleRelease.bat to compile the Android version of Zircon using the Gradle build system.

zcompile7

DarkPlaces supports ogg sound, freetype fonts, jpeg and the Gradle build system will statically compile each of these libraries and compile them into the Android binary. For Zircon unlike DarkPlaces, we have LodePNG compiled into the Zircon source code, so there is no libpng folder anywhere.

The FreeType, Ogg, Jpeg automatic compilation is a special feature I wrote for Zircon. Serious mods for DarkPlaces typically are using ogg source and jpg/png and I think DarkPlaces support for .ttf fonts is awesome so I went the extra mile and wrote/incorporated build files for those libraries (no easy task) in part based on the DarkPlaces QVR Android build of the past.

An Android .apk is a zip file containing the Android binary and other things like the icons. The icons are located at this location and Android uses .png images. There are various folders for various resolutions.

zcompile5

(WIP - I expect this to take a while to complete with full detail)

Post a comment

Your comment will be anonymous unless you join the community. Or sign in with your social account: