From MMS Wiki
Jump to: navigation, search

General information

Settings to build the app are stored at MMS/matchmysound/mobile/ in ini files, that are similar to Ansible host files. Versions should be set in that file. Build process uses Cordova but the cordova config.xml is compiled based on the settings ini file and should be kept generic to allow for multiple different-branded apps.

iOS basic workflow

Make sure everything is up to date and that you have the right version numbers in the settings .ini file, then run

 grunt cordova_ios_fast --mconf=<inifile name, without .ini>

NB! Use cordova_ios if the HaXe part has changed to recompile it from scratch. This usually takes ~15 min extra and is usually overkill.

Now open the project in XCode from

 mms/matchmysound/cordova/platforms/ios/<project name>.xcworkspace
  • Switch to legacy build system from File > workspace settings > build system
  • Go to project settings (first and topmost entry in the left toolbar) and select the correct signing profile.

Plug in the iphone/ipad, select it as device and click run. Do some basic smoke testing.

When ready for deployment:

  • Set the signing profile as manual, then as automatic again (not sure why but this is needed)
  • Choose Build -> Archive from the menu
  • Choose "Upload to app store"

Android basic workflow

Make sure everything is up to date and that you have the right version in the settings .ini file, then run

 grunt cordova_android_fast --mconf=<inifile name, without .ini>

Now open the project in Android Studio, wait until it loads. Say "later" to gradle update if it asks.

File -> Sync project with Gradle file

Then manually open build.gradle for Module:android (file tree on top left) and ctrl-f for "". Make sure all versions match ("+" signifying the latest version may not be a good choice).

NB! The last step is required for Google login to work! Otherwise a version conflict causes it to crash. For apps where it is not needed (Note Ahoy!, SoR), this is not needed.

Plug in the Android device, click run in the top toolbar. Do some basic testing.

When ready for deployment:

  • In menu, choose Build -> Generate signed APK
  • Find the MMS.keystore file and its passwords, enter them. Note the path where the binary will be generated
  • Find the file android-release.apk in that path and upload via Google Play! developer console.

Adding a new app (both)

Requires access to FB and Google developer consoles, Google Play! and iTunes connect developer tools and MMS.keystore file.


  • Create the new settings .ini file for it (at matchmysound/mobile) and fill it out (use info from the corresponding server conf file for ansible). Choose new recaptcha value.
  • Commission icon and splash screen from the client and create appropriate skin. Put splash screen and icon into matchmysound/mobile/res as <skin name>-icon.png and <skin name>-ls.png
  • Create Google login credentials for both ios and android at . Update reversed api keys (NB! reversed i.e. should have in the front instead of back!)
  • Create a new Facebook app and get app login credentials from there. Put them into settings .ini
  • Create a google play app metainfo, fill in required fields. Compile android version, then upload binary
  • Create iTunes connect metainfo (use wildcard bundle id, then type in the id as suffix). Compile iOS version, archive it and then upload to app store.
  • Update the ansible server config (google_web_client_id, new FB app creds, recaptcha_bypass for new users, all_domains for CORS, deep linking things such as mobile_project_id etc), then update server with them

iOS app review

  • Make sure metadata is filled out properly
  • Check that the test account works and can be used to log in
  • Check that no "contact us" or other equivalent links are removed
  • Nothing indicating people should buy or pay for something should be seen (unless it is an in-app purchase)


Compiling Ogg Vorbis (iOS)

This is needed in case ogg libraries ever need to be rebuilt for some reason (like ios devices moving to a new binary architecture):

IDZPrecompiledOgg and IDZPrecompiledVorbis are very helpful, with README file having instructions.

If new XCode has been installed xcode-select --install needs to be done

In both packages, .bash file needs to be modified so that IOS version is one for which simulator sdk is present (9.2 for XCode 7.2.1)

To get bitcode support, add "-fembed-bitcode -DENABLE_BITCODE=YES" to IDZ_FLAGS in IDZ_BUILD/idz_configuration

Vorbis will then refuse to compile, complaining of a conflict with -fembed-bitcode. Simplest workaround is to download the tar.gz manually, unpack it, edit configure and to remove the conflicting flag, repack it and change IDZPrecompiledVorbis to use the new file instead of curl-ing from internet.

To get them to output a lipo-ed file, add

  1. Or just create a combined library with lipo
 lipo -create install-*/lib/libvorbisall.a -output libFatVorbis.a

to the .bash file instead of the framework command

Files can then be found in IDZBuildRoot/lib{ogg|vorbis}/<version>/