I Try to clone a Flutter project and it success running in Windows, but when i run in Linux i got error like this.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':bitmap:externalNativeBuildDebug'.
> Build command failed.
Error while executing process /home/wahyu/Android/Sdk/cmake/3.6.4111459/bin/cmake with arguments {--build /home/wahyu/.pub-cache/hosted/pub.dartlang.org/bitmap-0.1.2/android/.cxx/cmake/debug/armeabi-v7a --target bitmap}
[1/2] Building CXX object CMakeFiles/bitmap.dir/home/wahyu/.pub-cache/hosted/pub.dartlang.org/bitmap-0.1.2/ios/Classes/bitmap.cpp.o
FAILED: /home/wahyu/Android/Sdk/ndk/20.1.5948944/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++ --target=armv7-none-linux-androideabi16 --gcc-toolchain=/home/wahyu/Android/Sdk/ndk/20.1.5948944/toolchains/llvm/prebuilt/linux-x86_64 --sysroot=/home/wahyu/Android/Sdk/ndk/20.1.5948944/toolchains/llvm/prebuilt/linux-x86_64/sysroot -Dbitmap_EXPORTS -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -fno-addrsig -march=armv7-a -mthumb -Wa,--noexecstack -Wformat -Werror=format-security -O0 -fno-limit-debug-info -fPIC -MD -MT CMakeFiles/bitmap.dir/home/wahyu/.pub-cache/hosted/pub.dartlang.org/bitmap-0.1.2/ios/Classes/bitmap.cpp.o -MF CMakeFiles/bitmap.dir/home/wahyu/.pub-cache/hosted/pub.dartlang.org/bitmap-0.1.2/ios/Classes/bitmap.cpp.o.d -o CMakeFiles/bitmap.dir/home/wahyu/.pub-cache/hosted/pub.dartlang.org/bitmap-0.1.2/ios/Classes/bitmap.cpp.o -c /home/wahyu/.pub-cache/hosted/pub.dartlang.org/bitmap-0.1.2/ios/Classes/bitmap.cpp
In file included from /home/wahyu/.pub-cache/hosted/pub.dartlang.org/bitmap-0.1.2/ios/Classes/bitmap.cpp:1:
In file included from /snap/flutter/current/usr/include/c++/8/stdlib.h:36:
In file included from /snap/flutter/current/usr/include/c++/8/cstdlib:41:
In file included from /snap/flutter/current/usr/include/x86_64-linux-gnu/c++/8/bits/c++config.h:508:
In file included from /snap/flutter/current/usr/include/x86_64-linux-gnu/c++/8/bits/os_defines.h:39:
In file included from /snap/flutter/current/usr/include/features.h:448:
/snap/flutter/current/usr/include/x86_64-linux-gnu/gnu/stubs.h:7:11: fatal error: 'gnu/stubs-32.h' file not found
# include <gnu/stubs-32.h>
^~~~~~~~~~~~~~~~
1 error generated.
ninja: build stopped: subcommand failed.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 15s
Exception: Gradle task assembleDebug failed with exit code 1
I tried many things like ensure the Flutter version in my Windows and Linux are the same, reinstall the NDK, CMAKE etc but it doesnt help. is it always like this when we continue a project using Flutter?
What should i do? I never facing like this things when i continue a project in React Native.