0
私は現在のバージョンが '絶対パス'をサポートしていないことを知っていますが、ファイルシステムがアクセスできない 'content uri'しか持っていません。React Native CameraRoll Androidバージョンで絶対イメージパスを取得するには?
「React Native」を公式文書のソースコードでビルドしようとしました。それでも失敗しました。
1)最初のエラー:私は
4.9アームのLinux androideabiシンボルリンク作成することにより、上記のエラーを修正
:ReactAndroid:prepareJSC
:ReactAndroid:buildReactNdkLib
Android NDK: WARNING:/Users/jay/Desktop/bitbucket/v2/Juying/node_modules/react-native/ReactAndroid/src/main/jni//react/Android.mk:reactnative: LOCAL_LDLIBS is always ignored for static libraries
Android NDK: WARNING:/Users/jay/Desktop/bitbucket/v2/Juying/node_modules/react-native/ReactAndroid/src/main/jni//react/Android.mk:reactnative: LOCAL_LDLIBS is always ignored for static libraries
[armeabi-v7a] StaticLibrary : libboost.a
[armeabi-v7a] Prebuilt : libjsc.so <= /Users/jay/Desktop/bitbucket/v2/Juying/node_modules/react-native/ReactAndroid/build/third-party-ndk/jsc/jni/armeabi-v7a/
make: /usr/local/Cellar/android-ndk/r11c/toolchains/arm-linux-androideabi-4.8/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-gcc-ar: No such file or directory
make: *** [/Users/jay/Desktop/bitbucket/v2/Juying/node_modules/react-native/ReactAndroid/build/tmp/buildReactNdkLib/local/armeabi-v7a/libboost.a] Error 1
make: *** Waiting for unfinished jobs....
:ReactAndroid:buildReactNdkLib FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':ReactAndroid:buildReactNdkLib'.
> Process 'command '/usr/local/opt/android-ndk/ndk-build'' finished with non-zero exit value 2
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
2) - > ARM-Linuxベースandroideabi-4.8
3)次のエラー:Googleのページで利用できるRNドキュメントではなく、V12で提供
[armeabi-v7a] Compile++ : glog <= demangle.cc
[armeabi-v7a] Compile++ : glog <= logging.cc
[armeabi-v7a] Compile++ : glog <= raw_logging.cc
./OnLoad.cpp: In member function 'void facebook::react::{anonymous}::bridge::PlatformBridgeCallback::executeCallbackOnCallbackQueueThread(std::function<void(facebook::jni::ResolvedWeakReference&)>&&)':
./OnLoad.cpp:636:39: error: lambda capture initializers only available with -std=c++1y or -std=gnu++1y [-Werror]
auto runnableWrapper = std::bind([weakCallback=weakCallback_] (std::function<void(ResolvedWeakReference&)>& runnable) {
^
[armeabi-v7a] Compile++ : glog <= signalhandler.cc
/Users/jay/Desktop/bitbucket/v2/Juying/node_modules/react-native/ReactAndroid/build/third-party-ndk/glog/glog-0.3.3/src/signalhandler.cc:169:6: warning: 'void google::{anonymous}::DumpSignalInfo(int, siginfo_t*)' defined but not used [-Wunused-function]
void DumpSignalInfo(int signal_number, siginfo_t *siginfo) {
^
[armeabi-v7a] Compile++ : glog <= symbolize.cc
[armeabi-v7a] Compile++ : glog <= utilities.cc
[armeabi-v7a] Compile++ : glog <= vlog_is_on.cc
[armeabi-v7a] Prebuilt : libgnustl_shared.so <= <NDK>/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a/thumb/
[armeabi-v7a] Compile++ : fb <= assert.cpp
[armeabi-v7a] Compile++ : fb <= log.cpp
[armeabi-v7a] Compile++ : fbjni <= Countable.cpp
[armeabi-v7a] Compile++ : fbjni <= Environment.cpp
[armeabi-v7a] Compile++ : fbjni <= fbjni.cpp
[armeabi-v7a] Compile++ : fbjni <= jni_helpers.cpp
[armeabi-v7a] Compile++ : fbjni <= LocalString.cpp
[armeabi-v7a] Compile++ : fbjni <= OnLoad.cpp
[armeabi-v7a] Compile++ : fbjni <= WeakReference.cpp
[armeabi-v7a] Compile++ : fbjni <= ByteBuffer.cpp
[armeabi-v7a] Compile++ : fbjni <= Exceptions.cpp
[armeabi-v7a] Compile++ : fbjni <= Hybrid.cpp
[armeabi-v7a] Compile++ : fbjni <= References.cpp
[armeabi-v7a] Compile++ : folly_json <= json.cpp
[armeabi-v7a] Compile++ : folly_json <= Unicode.cpp
[armeabi-v7a] Compile++ : folly_json <= Conv.cpp
cc1plus: all warnings being treated as errors
make: *** [/Users/jay/Desktop/bitbucket/v2/Juying/node_modules/react-native/ReactAndroid/build/tmp/buildReactNdkLib/local/armeabi-v7a/objs/reactnativejni/OnLoad.o] Error 1
make: *** Waiting for unfinished jobs....
:ReactAndroid:buildReactNdkLib FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':ReactAndroid:buildReactNdkLib'.
> Process 'command '/usr/local/opt/android-ndk/ndk-build'' finished with non-zero exit value 2
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED