0

I'm following this tutorial set to set up Moai for Android porting. When I run

./make-host.sh –p com.gamefromscratch.moai 

in Cygwin to build the Android host it returns an error of

build.sh: line 17: ndk-build: command not found

I'm 98% certain everything has installed correctly and I've been following the instructions exactly as written. When I look in the shell script line 17 is

use_fmod="false"

I've never had to use shell scripts or set up anything like this before and my scouring of the internet has failed to yield a result.

As a side note, Moai runs perfectly and I haven't had any problems with getting that to work.

thatguyrob
  • 21
  • 1
  • You need to verify that ndk-build is in your path. Try `echo $PATH` from the cygwin command line. It should have something like `c:\android-ndk` in it depending on where you installed the Android NDK – Codeguy007 Nov 16 '12 at 03:53
  • The ndk-build is showing up in path. I went through adding everything to the path just to be safe and I'm still getting the error. – thatguyrob Nov 16 '12 at 04:54

1 Answers1

1

I've solved the issue! When I went to look for the environment variable in Windows (Computer -> right click -> properties -> Advanced System Settings -> Environment Variables), I found that the variable path was there but was listed as ‘%PATH;c:\android-ndk’. As an experiment I changed it to just c:\android-ndk and rebooted the computer. I then ran the line to have the host run and it ran through the process without a hitch. The only difference is that instead of untitled-host my file is called host-source and instead of settings-local.sh my file is called d.settings-local.sh. Outside of those minor file name changes everything else is the same.

thatguyrob
  • 21
  • 1
  • Ah that would do it. The instructions are probably confusing. `PATH=%PATH;c:\android-ndk` is suppose to take the current path `%PATH` and append `c:\android-ndk` to it. Congrats on solving your problem. – Codeguy007 Nov 19 '12 at 20:28