[Nix-dev] Current state about Android development on NixOS

Luke Clifton ltclifton at gmail.com
Fri Jul 18 04:00:46 CEST 2014


Having never owned, or programmed an android device before, and not being a
Java developer, this took me quite some time to get working, but it turned
out to be simple.

The androidsdk does not include some tools that you will probably need such
as ant and openjdk.

Don't use the update facility provided with the SDK. If you want to use
multiple versions of the SDK use a myEnvFun.

My configuration.nix looks like this.

environment.systemPackages = with pkgs; [
    # Other packages here ...
    (myEnvFun {
      name = "android43";
      buildInputs = [ androidenv.androidsdk_4_3
                      ant
                      openjdk
                    ];
    })
];

So when I want to start developing for android targeting 4.3 I do a

$ load-env-android43

And I'm ready to go.

Hope that helps you get started.

Good luck.


On Fri, Jul 18, 2014 at 5:40 AM, Lluís Batlle i Rossell <viric at viric.name>
wrote:

> I didn't do development, but run android apps in an emulator.
>
> I installed one android SDK (nix-env -iA
> nixos.pkgs.androidenv.androidsdk_4_1),
> and the 'android', 'emulator', commands work fine.
>
> Others may tell about developing.
>
>
> On Thu, Jul 17, 2014 at 07:57:03PM +0200, Jascha Geerds wrote:
> > Hi there,
> >
> > I would like to start Android developement as a hobby. Has anyone
> > experience with that on NixOS? I already saw the
> > "pkgs/development/mobile/androidenv" section in nixpkgs but I don't know
> > the usage of all these *.nix files.
> >
> > It would be nice if someone share his workflows on this topic.
> >
> > Jascha Geerds
> >
> > --
> >   Jascha Geerds
> >   jg at ekby.de
> > _______________________________________________
> > nix-dev mailing list
> > nix-dev at lists.science.uu.nl
> > http://lists.science.uu.nl/mailman/listinfo/nix-dev
> _______________________________________________
> nix-dev mailing list
> nix-dev at lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20140718/e275133a/attachment.html 


More information about the nix-dev mailing list