gentoobionic / bionic Goto Github PK
View Code? Open in Web Editor NEWThe Bionic C library
License: Other
The Bionic C library
License: Other
The Bionic C Library =-=-=-=-=-=-=-=-=-=- This is a fork of the Bionic C Library from the Android Open Source Project. The original code can be found here[1]. Purpose =-=-=-= The purpose of this fork is to allow 3rd party developers to use bionic as their primary system C library. The initial port, Gentoo-Bionic[2], mostly focused on Gentoo Linux[3] although the migration to autotools minimizes that tight coupling. This codebase is now Linux-distribution-agnostic and therefore can be used (in theory) with any Linux distribution. License =-=-=-= One of the advantages of using bionic is that it is BSD-licensed (see the file COPYING). This provides greater flexibility for hardware and software product vendors when compared with other free-as-in-speach licenses. Indeed, bionic allows you to have your free-as-in-beer software and use it too. Since the BSD license has more permissive licensing constraints for API consumers, people can freely write both open and proprietary software which links to bionic without much concern of licensing restrictions. However, please keep in mind, that if Program A links to bionic and Library B, regardless of whether Library B links to bionic, then Program A still must abide by the terms and conditions of the Library B software license. Occasionally, this fork of bionic might incorporate files from other projects that are similarly permissively licensed. For any questions regarding software licensing, please email [email protected] . Modifications =-=-=-=-=-=-= 1) Use autotools to build rather than the Android build system 2) Use common prefixes for the runtime (e.g. /usr instead of /system) 3) Remove any dependencies on the Android runtime and revert to more traditional UNIX practices (e.g. use /etc/resolv.conf instead of Android's properties for DNS servers) 4) Add more system calls and libc functions, as appropriate More information can be found from the original ELC2013 presentation [4]. Happy hacking! [1] https://android.googlesource.com/platform/bionic.git [2] https://plus.google.com/113359270067626599390 [3] http://www.gentoo.org [4] http://elinux.org/images/2/25/2013_elc_gentoo_bionic.pdf
A completely arbitrary define (__FORCE_THUMB2) was used to hack thumb / thumb2 support. Rather than using a completely arbitrary define, use the more conventional ones, defined in
libc/arch-arm/include/machine/cpu-features.h
Headers should also be installed to their respective (w.r.t. DESTDIR, prefix) locations.
The kernel header should not be installed in this stage, or it should be optional. This is so that e.g. Gentoo's sys-kernel/bionic-kernel-headers still works.
modify the crt*.o files, possibly, so that we don't need an -mbionic in GCC
arch:x86
scanelf -qT libc.so | wc -l
219
most were referencing __set_errno
This was working. It might still work, but there are probably some kinks to be worked out.
Generally, all BUILT_SOURCES (hint, hint) should be in the build directory and not the source directory.
This is not related to #28 , but it has a similar symptom; sys/linux-syscalls.h file is also not generated when using python-3.3 (at least with Gentoo/x86). It works by setting the interpreter back to python-2.7 (e.g. eselect set python 1).
python ./libc/tools/gensyscalls.py x86 ./ libc/arch-x86/syscalls > syscalls.stamp
File "./libc/tools/gensyscalls.py", line 22
print "could not find the Bionic root directory. aborting"
...
mkdir -p libc/arch-x86/bionic/
libc/arch-x86/bionic/_exit_with_stack_teardown.S:2:32: fatal error: sys/linux-syscalls.h: No such file or directory
compilation terminated.
libc/arch-x86/bionic/clone.S:2:32: fatal error: sys/linux-syscalls.h: No such file or directory
compilation terminated.
libc/arch-x86/bionic/futex_x86.S:2:32: fatal error: sys/linux-syscalls.h: No such file or directory
compilation terminated.
For source-based package managers (e.g. portage) that build code in a sandbox, writing to directories outside of the sandbox can break the build. Currently, gensyscalls.py writes to /tmp/bionic_gensyscalls/.
This or anything later carrying the 'android-4.4*' tag.
https://android.googlesource.com/platform/bionic/+/android-4.4_r1.2
All files should be installed to their proper (w.r.t. DESTDIR and perfix) directories with the correct permissions.
I expect that $(INSTALL) should be used for this purpose.
verify linkage entirely, using custom linker rules in Makefile.am
root@minnow:/chroot/usr/lib# chroot /chroot /usr/lib/hello
Floating point exception
change the behaviour of /sbin/linker - I want this to be more like ld-linux.so
I'm not sure if it's just issue #10 that is blocking this, but as soon as that gets resolved, this needs to be verified.
All make dependencies should be validated.
Possibly use http://posixtest.sourceforge.net
autogen.sh fails because it cannot find libgcc_shared_fake/Makefile.in
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.