ColinIanKing / stress-ng

This is the stress-ng upstream project git repository. stress-ng will stress test a computer system in various selectable ways. It was designed to exercise various physical subsystems of a computer as well as the various operating system kernel interfaces.

Home Page:https://github.com/ColinIanKing/stress-ng

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Static x dynamic linking

danielt3 opened this issue · comments

Hello! I'm trying to use stress-ng in an deeply customized Android device. We have a clang70-based toolchain, vendor libs and some libc support (we don't actually know what is implemented and what is not). Kernel is around 3.6.x. For our development needs, this setup is fine. But now we want to use stress-ng as a benchmarking tool for several of our devices and start making comparisons between software releases and between devices. We think that stress-ng is a great tool for that.

Here are the facts:

  1. I can build and link stress-ng ok in the static-linking mode. In the dynamic linking, I got several libc errors about missing APIs (shared-memory, network, quotas). It seems that the static libc provided by the vendor is more complete;
  2. For the static link to work, I have to copy libGLES.so to libGLES.a because since I'm on static mode, it seems to try to link everything statically and the vendor does not provide libGLES.a for me to use. This one also leads me to think that the actual libGLES is not used at all otherwise linking would fail, am I right?

Questions:

  1. Is there a way to turn-off using GLES in the build system, even if it is present in the toolchain? In a more general question, what would be a generic way of turning on/off things in stress-ng build?
  2. Is there a way to link to libGLES dinamically even in static mode?
  3. This is a more personal question: in order to have the full-blown functionality of stress-ng what would be the options/flag the kernel must be built with? I couldn't find this information anywhere. I'm not sure what were the options the vendor used to build our kernels.

Thank you for your help.