Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ContainerShip/Dockerfile.android-base
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM library/ubuntu:16.04
# set default build arguments
ARG ANDROID_VERSION=25.2.3
ARG BUCK_VERSION=f3452a6a7ab15a60e94c962e686293acbe677473
ARG NDK_VERSION=10e
ARG NDK_VERSION=15c
ARG NODE_VERSION=6.2.0
ARG WATCHMAN_VERSION=4.7.0

Expand Down
4 changes: 3 additions & 1 deletion ReactAndroid/src/main/jni/Application.mk
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,11 @@ APP_MK_DIR := $(dir $(lastword $(MAKEFILE_LIST)))

NDK_MODULE_PATH := $(APP_MK_DIR)$(HOST_DIRSEP)$(THIRD_PARTY_NDK_DIR)$(HOST_DIRSEP)$(REACT_COMMON_DIR)$(HOST_DIRSEP)$(APP_MK_DIR)first-party

APP_CPPFLAGS += -std=c++14

APP_STL := gnustl_shared

# Make sure every shared lib includes a .note.gnu.build-id header
APP_LDFLAGS := -Wl,--build-id

NDK_TOOLCHAIN_VERSION := 4.8
NDK_TOOLCHAIN_VERSION := 4.9
3 changes: 1 addition & 2 deletions ReactAndroid/src/main/jni/packagerconnection/Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,12 @@ LOCAL_CFLAGS += $(CXX11_FLAGS)
LOCAL_EXPORT_CPPFLAGS := $(CXX11_FLAGS)

LOCAL_LDLIBS += -landroid
LOCAL_SHARED_LIBRARIES := libfolly_json libfbjni libjsc libglog_init
LOCAL_SHARED_LIBRARIES := libfolly_json libfb libjsc libglog_init

include $(BUILD_SHARED_LIBRARY)

$(call import-module,fb)
$(call import-module,jsc)
$(call import-module,folly)
$(call import-module,fbgloginit)
$(call import-module,jni)
$(call import-module,jscwrapper)
2 changes: 1 addition & 1 deletion ReactAndroid/src/main/jni/react/jni/Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ LOCAL_CFLAGS += $(CXX11_FLAGS)
LOCAL_EXPORT_CPPFLAGS := $(CXX11_FLAGS)

LOCAL_LDLIBS += -landroid
LOCAL_SHARED_LIBRARIES := libfolly_json libfbjni libjsc libglog_init libyoga
LOCAL_SHARED_LIBRARIES := libfolly_json libfb libjsc libglog_init libyoga
LOCAL_STATIC_LIBRARIES := libreactnative

include $(BUILD_SHARED_LIBRARY)
Expand Down
20 changes: 11 additions & 9 deletions docs/AndroidBuildingFromSource.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,16 @@ You will need to build React Native from source if you want to work on a new fea

## Prerequisites

Assuming you have the Android SDK installed, run `android` to open the Android SDK Manager.
Assuming you have the Android Studio installed, run Android Studio.

Make sure you have the following installed:

1. Android SDK version 23 (compileSdkVersion in [`build.gradle`](https://github.com/facebook/react-native/blob/master/ReactAndroid/build.gradle))
2. SDK build tools version 23.0.1 (buildToolsVersion in [`build.gradle`](https://github.com/facebook/react-native/blob/master/ReactAndroid/build.gradle))
3. Android Support Repository >= 17 (for Android Support Library)
4. Android NDK (download links and installation instructions below)
4. Android NDK

<img src="https://developer.android.com/studio/images/projects/ndk-install_2-2_2x.png" alt="" width="727">

### Point Gradle to your Android SDK:

Expand All @@ -36,7 +38,7 @@ Example:

```
export ANDROID_SDK=/Users/your_unix_name/android-sdk-macosx
export ANDROID_NDK=/Users/your_unix_name/android-ndk/android-ndk-r10e
export ANDROID_NDK=/Users/your_unix_name/android-sdk-macosx/ndk-bundle
```

**Step 2:** Create a `local.properties` file in the `android` directory of your react-native app with the following contents:
Expand All @@ -45,15 +47,15 @@ Example:

```
sdk.dir=/Users/your_unix_name/android-sdk-macosx
ndk.dir=/Users/your_unix_name/android-ndk/android-ndk-r10e
ndk.dir=/Users/your_unix_name/android-sdk-macosx/ndk-bundle
```

### Download links for Android NDK
### Manual Download links for Android NDK

1. Mac OS (64-bit) - http://dl.google.com/android/repository/android-ndk-r10e-darwin-x86_64.zip
2. Linux (64-bit) - http://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip
3. Windows (64-bit) - http://dl.google.com/android/repository/android-ndk-r10e-windows-x86_64.zip
4. Windows (32-bit) - http://dl.google.com/android/repository/android-ndk-r10e-windows-x86.zip
1. Mac OS (64-bit) - http://dl.google.com/android/repository/android-ndk-r15c-darwin-x86_64.zip
2. Linux (64-bit) - http://dl.google.com/android/repository/android-ndk-r15c-linux-x86_64.zip
3. Windows (64-bit) - http://dl.google.com/android/repository/android-ndk-r15c-windows-x86_64.zip
4. Windows (32-bit) - http://dl.google.com/android/repository/android-ndk-r15c-windows-x86.zip

You can find further instructions on the [official page](https://developer.android.com/ndk/index.html).

Expand Down