titaniumappceleratortitanium-modules

How to make a backwards-compatible Titanium module?


Title says it all: is it possible to make Titanium modules that are backwards-compatible with Titanium apps that are lower than 7.0.0GA?

I tried to set the minsdk value in manifest for my module to 6.0.4GA but Appcelerator doesn't allow me to add it for apps lower than 7.0.0GA.

How can I make a backwards-compatible Titanium module built with Titanium 7.0.0GA?


Solution

  • Because you need to compile your module with apiversion 4, it has to be minSdk 7.0.0

    However, you can easily recompile the module again for lower versions. So, lower apiversion to 3 and set minsdk to 6.0.0, and you can use it in TiSDK 6.

    It not really is backwards compatible, but just having 2 builds (and 2 versions) should be fine. You could even include them both in your app and just switch based on SDK you use.

    I'd recommend changing the major version by 1 though, so for SDK 6 version 1.0, and for SDK 7, make it version 2.0