Skip to content

Install Instructions Linux

collingreen edited this page Nov 9, 2014 · 1 revision

Note: these instructions were created using a fresh install of Ubuntu 14.04.1 on a virtual machine. Your setup for the various dependencies may differ based on your distro.

Linux

DevKit requires that you install a few dependencies first:

Use your preferred package manager to install the pre-requisites if necessary.

On Ubuntu 14.04.1:

sudo apt-get install npm

sudo apt-get install git

Java - Devkit requires java. These instructions install openJDK - you can install any equivalent Java package.

sudo apt-get install openjdk-7-jre-headless

Optional Dependencies

Building games for Android requires installing the corresponding SDKs:

  • Android SDK - required for building games for Android
  • Android NDK - required for building games for Android
  • Ant - required for building games for Android

NOTE: please ensure the apache build tools and ant are available in your path so DevKit can find them when trying to build!

Installing Devkit

Option 1 - Install global NPM modules with sudo

This is the default behavior for global npm modules.

sudo npm install -g devkit

Option 2 - Adv - Solve permissions on global node_modules folder, then install.

-- Instructions from Daniel González

  • Reclaim the global node_modules folder:

sudo chown -R `whoami` /usr/local/lib/node_modules/

  • Reclaim (or add write permissions) on the /usr/local/bin folder to succesfully create the symlink:

sudo chown -R `whoami` /usr/local/bin/

  • Reclaim .npm on inside your home folder, just in case. Maybe you have used sudo npm... any day, so check that everything inside is owned by you:

sudo chown -R `whoami` ~/.npm/

Now you can install npm modules globally without sudo.

npm install -g devkit

Option 3 - Adv - Install devkit locally and manually add to your path

npm install devkit

-- add devkit/src/devkit.js to your path using whatever method you prefer --

Usage

That's it! Run devkit to see the available commands.