[cfe-users] Linking error and memory bloating for .so file creation

Ankush Sharma via cfe-users cfe-users at lists.llvm.org
Wed Mar 13 03:43:53 PDT 2019


 Hi,

We are generating the .so file for the Android ARM 64 flavor on Windows
platform.
Following is the version info for the "clang++.exe" executable used for
generating the .so file.


*F:\Debug>"F:\androidndk.16.1.9\toolchains\llvm\prebuilt\windows-x86_64\bin\clang++.exe"
-v*
- Android clang version 5.0.300080  (based on LLVM 5.0.300080)
- Target: x86_64-unknown-linux
- Thread model: posix

Note: No I/O error is getting reported during the link run. Also we are
witnessing this issue when moving
from "gnustl" to "LibC++" support for standard C++ library.

The linker flags used are attached with the mail. It would be good if some
linker flags be turned on
to further debug the link run.

On Tue, Mar 12, 2019 at 2:03 PM Csaba Raduly <rcsaba at gmail.com> wrote:

> Hi Ankush,
> On Mon, Mar 11, 2019 at 8:23 PM Ankush Sharma wrote:
> > During the linking stage for an “.so” file creation, an error message is
> being flagged by clang.
> >
> > ld: error: dummy.so: write: Function not implemented
>
> What was the command line that was used to invoke the linker?
> What filesystem are you using?
>
> Csaba
> --
> You can get very substantial performance improvements
> by not doing the right thing. - Scott Meyers, An Effective C++11/14 Sampler
> So if you're looking for a completely portable, 100% standards-conformat
> way
> to get the wrong information: this is what you want. - Scott Meyers
> (C++TDaWYK)
>


-- 
Thanks and Regards
Ankush
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-users/attachments/20190313/fff3c4c4/attachment.html>
-------------- next part --------------
-Wl,--no-whole-archive
--gcc-toolchain=f:/androidndk.16.1.9/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64
--target=armv7-none-linux-androideabi
-Wl,-z,relro
-Wl,-z,now
--sysroot=f:/androidndk.16.1.9/platforms/android-21/arch-arm
-Lf:/androidndk.16.1.9/platforms/android-21/arch-arm/usr/lib
-llog
-lEGL
-lGLESv1_CM
-lOpenSLES
-lGLESv2
-Wl,--dynamic-linker,/system/bin/linker
-Wl,--build-id=sha1
-shared
-Wl,--fix-cortex-a8
-Wl,--gc-sections
-Wl,-z,noexecstack
-Wl,-Bsymbolic
-Wl,--no-undefined
-Wl,--stats
-Wl,--no-map-whole-files
-Wl,--no-wchar-size-warning
-lgcc
-landroid
-lz
-Wl,-rpath-link=f:/androidndk.16.1.9/platforms/android-21/arch-arm/usr/lib
-lstdc++
-lc
-lm


More information about the cfe-users mailing list