--- ../OpenFOAM-v1906/etc/config.sh/settings 2019-06-26 16:16:55.000000000 +0200 +++ ./etc/config.sh/settings 2019-09-01 19:46:43.377231828 +0200 @@ -33,8 +33,13 @@ Linux) WM_ARCH=linux - case "$(uname -m)" in + case "$ARCH" in i686) + export WM_COMPILER_LIB_ARCH=32 + export WM_CC='i686-linux-android-clang' + export WM_CXX='i686-linux-android-clang++' + export WM_CFLAGS='-fPIC' + export WM_CXXFLAGS='-fPIC -std=c++11' ;; x86_64) @@ -42,10 +47,19 @@ 32) export WM_ARCH_OPTION=32 # Need to propagate the value export WM_COMPILER_ARCH=64 # 64-bit compiler, 32-bit target + export WM_CC='x86_64-linux-android-clang' + export WM_CXX='x86_64-linux-android-clang++' + export WM_CFLAGS='-m32 -fPIC' + export WM_CXXFLAGS='-m32 -fPIC -std=c++11' + export WM_LDFLAGS='-m32' ;; 64) WM_ARCH=linux64 export WM_COMPILER_LIB_ARCH=64 # Target with lib64 + export WM_CC='x86_64-linux-android-clang' + export WM_CXX='x86_64-linux-android-clang++' + export WM_CFLAGS='-fPIC' + export WM_CXXFLAGS='-fPIC -std=c++11' ;; *) echo "Unknown WM_ARCH_OPTION '$archOption', should be 32|64" 1>&2 @@ -60,11 +74,22 @@ armv7l) WM_ARCH=linuxARM7 export WM_COMPILER_LIB_ARCH=32 + export WM_CC='arm-linux-androideabi-clang' + export WM_CXX='arm-linux-androideabi-clang++' + export WM_CFLAGS='-fPIC' + export WM_CXXFLAGS='-fPIC -std=c++11' + export WM_LDFLAGS= + ;; aarch64) WM_ARCH=linuxARM64 export WM_COMPILER_LIB_ARCH=64 + export WM_CC='aarch64-linux-android-clang' + export WM_CXX='aarch64-linux-android-clang++' + export WM_CFLAGS='-fPIC' + export WM_CXXFLAGS='-fPIC -std=c++11' + export WM_LDFLAGS= ;; ppc64)