#libc
[A] review of the C standard library in practice, https://nullprogram.com/blog/2023/02/11/.
All the numerous dangers of the standard libc. The article reviews many surfaces of the API and explains why they are misused in most of the case.
PcapPlusPlus, la lib C++ incontournable pour les amateurs de paquets réseaux https://korben.info/pcaplusplus-bibliotheque-capture-analyse-forgeage-paquets-reseau-protocoles.html #bibliothèqueC++ #Développement #PcapPlusPlus #paquets #réseaux #WinPcap #libC++
I was looking at the 'Blinkenlights' project by Justine Tunney which is "a virtual machine that runs statically-compiled x86-64-linux programs on different operating systems and hardware architectures" (might as well let Justine describe it!) motivated by research on APE ("Actually Portable Executable")¹ ². #ActuallyPortableExecutable
After appreciating blink I looked at Justine's other repos, as one does, and… here's what I already bookmarked:
* "sectorlisp is a 512-byte implementation of LISP that's able to bootstrap John McCarthy's meta-circular evaluator on bare metal." - https://github.com/jart/sectorlisp #Lisp
* "Cosmopolitan Libc makes C a build-once run-anywhere language, like Java, except it doesn't need an interpreter or virtual machine. Instead, it reconfigures stock GCC and Clang to output a POSIX-approved polyglot format that runs natively on Linux + Mac + Windows + FreeBSD + OpenBSD + NetBSD + BIOS with the best possible performance and the tiniest footprint imaginable." - https://github.com/jart/cosmopolitan #Libc #VirtualMachine #Polyglot (you should also look at the work by @Ange on the vast subject of polyglots)
* "Disaster lets you press C-c d to see the compiled assembly code for the C, C++ or Fortran file you're currently editing. It even jumps to and highlights the line of assembly corresponding to the line beneath your cursor." - https://github.com/jart/disaster #Emacs #EmacsLisp #Disassembler ( @anticomputer this one is for you…)
No apologies for sending you down this Github hole :flan_molotov: as it is more fun to go spelunking with friends!
__
¹ https://justine.lol/ape.html
² https://github.com/jart/blink
It's very annoying that #ISO #C has fixed-width integer types in stdint.h, but doesn't provide #libc functions for working with them, like for instance, strtoi32(). Heck, standard C doesn't even have strtoint() for regular ints!
the closest I've come is strtoi() which lets you specify bounds, so you could use E.G. INT32_MIN & INT32_MAX, but that's a nonstandard #BSD extension.
So you have to use a bunch of macro soup to fix this problem yourself and use strtoimax(), which defeats the entire point of the stdint types. 😤
Pretty Petite Picolibc Powers Processors - Many times when someone tells you that language X is “better” at something they re... - https://hackaday.com/2022/11/14/pretty-petite-picolibc-powers-processors/ #softwaredevelopment #microcontrollers #standardlibrary #newlib #libc
Pretty Petite Picolibc Powers Processors
https://hackaday.com/2022/11/14/pretty-petite-picolibc-powers-processors/
#SoftwareDevelopment #Microcontrollers #standardlibrary #newlib #libc
One of my frustrations with #macOS is that it has a broken wcwidth (a #libc function that gets the column width of a wide char).
It thinks each decomposed part of the character '국' (total 2 colums wide) is at least 1 column wide, hence thinking that the whole string needs 4 columns! (Left is the broken macOS, right is the correct Ubuntu.)
This wrecks the #shell line editor, and if I complete a Korean file name, I lose my cursor and the terminal starts erasing wrong characters. So frustrating…
Nice little adventure, but having limited precision can lead to more accumulated errors in your calculations 😬:
“Implementing Cosine In C From Scratch” [2020], Austin Henley (https://austinhenley.com/blog/cosine.html).
Syscalls used by malloc. – sploitF-U-N
#syscalls #syscall #malloc #linux #libc #glibc #howto #explained
https://sploitfun.wordpress.com/2015/02/11/syscalls-used-by-malloc/
mlibc is a #POSIX compatible standard library for #C that's specifically made to be portable between various platforms. Platform-specific code is isolated as much as possible, allowing porting to be as easy as possible. mlibc features support for #Linux as well as several hobby operating systems.
Website 🔗️: https://github.com/managarm/mlibc
Linux Standard Library Implementations: X32 can be 10% faster, but musl Libc 40% slower: https://www.youtube.com/watch?v=wq-a8juPFzs #linux #glibc #musl #libc #performance #comparison #standardlibrary #x32
https://twitter.com/JustineTunney/status/1365805503561957376?s=20
We've just created a 336kb Lua interpreter binary that runs on seven operating systems, thanks to Cosmopolitan Libc.
#Cosmopolitan is a universal #C #libc.
Cosmopolitan is an optimized C #stdlib as well as compilation procedure that lets C programs run on #Linux, #Windows, #macOS, #FreeBSD, #OpenBSD, and even bare #BIOS with a single executable file. Cosmopolitan uses the Actually Portable Executable format to accomplish this, allowing for all supported platforms to run the code with no system modification.
Website 🔗️: https://justine.lol/cosmopolitan/
#free #opensource #foss #fossmendations #programming #development
Second patchset appears to work. Not nearly as complex as the first, turned out to be a couple of lines changed in exactly (I hope) the right places (after a week of what I like to call Staring Into The Void).
But still. This is all working too smoothly.
I'm getting The Fear.
#ActuLibre En vrac’ de milieu de semaine… -> http://frederic.bezies.free.fr/blog/?p=19082 #pitreriesdulibre #Vrac'attitudes! #ArchLinuxeries #mozillafirefox #logiciellibre #Informatique #distribution #Trucsdegeek #EndeavourOS #fedoralinux #Emmabuntüs #Libreries #geekeries #microsoft #Internet #GhostBSD #Inkscape #logiciel #RebornOS #centos #libc++ #libre #vrac