开发者

How to run the Android NDK install on Windows? [closed]

开发者 https://www.devze.com 2022-12-26 02:20 出处:网络
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical andcannot be reasonably answered in its current form. For help开发者
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help开发者_如何学C clarifying this question so that it can be reopened, visit the help center. Closed 9 years ago.

Below are the only instructions I managed to find from Google on how to install the Android NDK, it is written as if we all run Linux and presumes we all understand what these obscure tools are. My comments and questions appear in italics if someone who knows Unix and Windows would translate, that would be great!


Android NDK Installation

Introduction:

Please read docs/OVERVIEW.TXT to understand what the Android NDK is and is not. This file gives instructions on how to properly setup your NDK.

I. Requirements:

The Android NDK currently requires a Linux, OS X or Windows host operating system. Windows users will need to install Cygwin (http://www.cygwin.com) to use it. Note that running the NDK under MSys is not supported.

You will need to have the Android SDK and its dependencies installed. The NDK cannot generate final application packages (.apk files), only the shared library files that can go into them.

IMPORTANT:

The Android NDK can only be used to target system images using the Cupcake (1.5) or later releases of the platform. This is due to subtle toolchain and ABI related changed that make it incompatible with 1.0 and 1.1 system images.

The NDK requires GNU Make 3.81 or later being available on your development system. Earlier versions of GNU Make might work but have not been tested.

You can check this by running 'make -v' from the command-line. The output should look like:

GNU Make 3.81
Copyright (C) 2006  Free Software Foundation, Inc.
...

On certain systems, GNU Make might be available through a different command like 'gmake' or 'gnumake'. For these systems, replace 'make' by the appropriate command when invoking the NDK build system as described in the documentation.

Great, some strange thing called gnu make. If you're not going to tell me what it does maybe you then at least you could give me a URL to it?

The NDK also requires a Nawk or GNU Awk executable being available on your development system. Note that the original 'awk' program doesn't implement the 'match' and 'substr' functions used by the NDK build system.

OK, another tool, with 1 of 2 possible names, but not the third... and again where should I download this?

On Windows, you will need to install a recent release of Cygwin to use the NDK. See http://www.cygwin.com for instructions.

Woohoo a URL! Download took about a day because these install instructions do not specify what parts to download.

II. Preparing your installation prebuilt cross-toolchain binaries:

After installing and unarchiving the NDK, you will need to run the following command from the root folder:

build/host-setup.sh

hello? Windows doesn't run anything but .exe .com or .dll, just tell me how you want me to run it.

This will test your setup and make sure the NDK can work properly.

Nothing is said about where any of these things need to be installed to (what directory)


I would highly recommend not developing this on windows. Go get virtual box and create an ubuntu or fedora image (or whatever other flavor of linux you may prefer) and use that for development. I've been developing in the windows world with cygwin for several months now and I completely hate it. While cygwin is awesome, it's a complete hack onto windows and its only a matter of time before you discover that painful fact. You will run into issues with paths/executables/etc trying to get anything done within cygwin. Configuration nightmares abound when it comes to specifying where things are in cygwin versus windows. The whole thing really just sucks. If the development environment requires cygwin, I would highly suggest just going with linux instead. You will love yourself later on for it - I wish I would have done it months ago.


Great some strange thing called gnu make.. if your not going to tell me what it does maybe you then at least you could give me a URL to it?

This is a fundamental part of the Unix build system, and you're going to have to learn it. They're assuming you're fairly familiar with Linux development.

windows dont run nothing but .exe .com or .dll, just tell me how you want me to run it..

That's what you downloaded Cygwin for. Do that from a Cygwin bash prompt. AWK probably came with Cygwin.

Nothing is said about where any of these things need to be installed to (what directory)

Because they're running from the root folder of the SDK install, it isn't going to matter. The host-setup.sh script might record where it is for later reference, so do run that from where you intend to keep it.


You're expected to run everything from within Cygwin, which is a linux-like environment for Windows. The instructions clearly expect you to understand how to use Cygwin, which is a subject too broad for them to include in their instructions. All the "obscure" tools it references can be installed using the Cygwin setup/installer program (the same one that installed Cygwin on your computer).


Regarding running an .sh file, you'll do that in Cygwin.

0

精彩评论

暂无评论...
验证码 换一张
取 消