Questions tagged [uclibc]

uclibc is a version of the C standard library for embedded systems

110 questions
26
votes
3 answers

Year 2038 solution for embedded Linux (32 bit)?

What is the proper way to handle times in C code for 32-bit embedded Linux (ARMLinux) to ensure that the code continues to work properly after 03:14:07 UTC on 19 January 2038 (when a signed 32-bit time_t overflows)? Given that time_t is signed…
Ian Goldby
  • 5,609
  • 1
  • 45
  • 81
10
votes
3 answers

Cross compiling for MIPS router from x86

My end goal is to compile wireless tools for my old Actiontec modem/router so I can configure it as a wireless to ethernet bridge. Currently it's wireless features are (seemingly) controlled by the same binary that manages most of the web interface,…
sagenite
  • 103
  • 1
  • 1
  • 4
10
votes
2 answers

Any porting available of backtrace for uclibc?

We are running the uclibc linux on ARM 9. The problem is uclibc doesn't support backtrace. When a core dump happens, I cannot grab the call stack. Does anyone have a good solution for that? For example, an existing porting of backtrace for uclibc,…
user303967
  • 131
  • 2
  • 6
10
votes
1 answer

Can GHC link binaries against a libc implementation such as uclibc (used in OpenWrt by default)?

I am using Debian/MIPS+QEMU to build MIPS ports of PortFusion (a TCP tunneling solution). The resulting binaries are linked against GNU libc. Thus, they cannot be just copied over and used on vanilla OpenWrt which ships with uclibc instead of eglibc…
Cetin Sert
  • 4,497
  • 5
  • 38
  • 76
9
votes
1 answer

Cross compile PHP with UCLIBC

THIS IS A REPOST, PREVIOUS POST GOT CLOSED, MOVED TO SERVERFAULT AND CLOSED AGAIN. I think this post is a valid stackoverflow problem because i think its caused by some automake/compile/linking error. This is a programming problem not a server…
Maidenone
  • 723
  • 10
  • 22
8
votes
5 answers

Can I use boost on uclibc linux?

Does anyone have any experience with running C++ applications that use the boost libraries on uclibc-based systems? Is it even possible? Which C++ standard library would you use? Is uclibc++ usable with boost?
bmdhacks
  • 15,841
  • 8
  • 34
  • 55
7
votes
2 answers

Using an alternative libc in a cmake project

I have a C/C++ project that is built using CMake. While trying to compile a static binary, I've run into issues with different GLIBC versions on my computer and the target machine. In a different question on SO, the accepted answer to a similar…
janoliver
  • 7,744
  • 14
  • 60
  • 103
7
votes
2 answers

How to solve undefined reference to functions in fenv.h when using uclibc?

I'm trying to test some of the functions in fenv.h, however, when I compile the below function ld fails with undefined reference to 'feclearexcept' and undefined reference to 'fetestexcept'. I'm running hardened gentoo compiled against uclibc, and I…
ragingSloth
  • 1,094
  • 8
  • 22
7
votes
3 answers

How to get proper backtrace in process signal handler (armv7-uclibc)?

I already did google many times to find right solution for backtrace() in signal handler and tried almost everything but I was not able to get the backtrace successfully in my signal handler - this is not SIGUSR1 handler. enable…
user2526111
  • 444
  • 4
  • 17
7
votes
3 answers

Specifying the dynamic linker / loader to be used when launching an executable on Linux

I have a weird Linux system where most of the software is compiled against Glibc and some others against uClibc. Since the Linux is a standard distro when I launch and executable the standard dynamic linker is invoked (/lib/ld.so.1) from glibc. I'm…
Ben Hirschberg
  • 1,410
  • 1
  • 12
  • 17
6
votes
6 answers

Howto use readlink with dynamic memory allocation

Problem: On a linux machine I want to read the target string of a link. From documentation I have found the following code sample (without error processing): struct stat sb; ssize_t r; char * linkname; lstat("", &sb); linkname =…
ARF
  • 7,420
  • 8
  • 45
  • 72
6
votes
3 answers

GCC is generating binaries filled with zeroes

I'm trying to figure out why the binaries generated by GCC are so large. Consider this empty program: int main() { return 0; } Now I build it with GCC 9.2.1 20190827 (Red Hat 9.2.1-1) and glibc 2.29 without any additional parameters: gcc -o…
Antti Laine
  • 139
  • 10
5
votes
3 answers

Anybody cross compiled Mono for MIPS 64 using uClibc?

I am trying to statically cross compile Mono for MIPS. I am able to compile Mono, but it is always dynamically linked with it's dependencies, even though I specify static to the compiler. I wrote a test program and I am able to statically compile…
Dale Ragan
  • 18,202
  • 3
  • 54
  • 70
5
votes
1 answer

Is there an equivalent of set_new_handler() for malloc() failures?

In C++, you can arrange for a function to be called whenever new fails. Is there a way to have a function called whenever malloc fails? Assume that malloc is being called from third-party libraries that I don't want to change. I don't think…
user9876
  • 10,954
  • 6
  • 44
  • 66
5
votes
1 answer

Looking for a pure c-version of math.h functions (no co-processor support)

I have to work with some (semi-)automatical verification software (CBMC (link)) which is statically working on C sources. Floating point is supported, but there are no definitions for all the mathematical functions. The attempt is to check, if it's…
sascha
  • 32,238
  • 6
  • 68
  • 110
1
2 3 4 5 6 7 8