source: clfs-embedded/BOOK/cross-tools/common/libc.xml@ 3f4c1c5

Last change on this file since 3f4c1c5 was b608a6d, checked in by Andrew Bradford <andrew@…>, 11 years ago

libc: Create symlinks for musl ld

Just create one for each arch, that's the easy way out :)

Making this more elegant would be nice, but also doing what musl
recommends in their INSTALL file of creating an /etc/ld-musl-$ARCH.path
file with the proper shared library search path.

  • Property mode set to 100644
File size: 4.9 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-cross-tools-libc" role="wrap">
9 <?dbhtml filename="libc.html"?>
10
11 <title>musl-libc-&musl-libc-version;</title>
12
13 <indexterm zone="ch-cross-tools-libc">
14 <primary sortas="a-libc">musl-libc</primary>
15 <secondary>cross tools</secondary>
16 </indexterm>
17
18 <sect2 role="package">
19 <title/>
20
21 <para>The musl-libc package contains the main C library. This library provides
22 the basic routines for allocating memory, searching directories, opening and
23 closing files, reading and writing files, string handling, pattern matching,
24 arithmetic, and so on.</para>
25
26 </sect2>
27
28 <sect2 role="installation">
29 <title>Installation of musl-libc</title>
30
31 <para os="h">Configure the package:</para>
32
33<screen os="i"><userinput>CC=${CLFS_TARGET}-gcc ./configure \
34 --prefix=${CLFS}/cross-tools/${CLFS_TARGET} \
35 --target=${CLFS_TARGET} \
36 --enable-debug</userinput></screen>
37
38 <para os="h">Compile the package:</para>
39
40<screen os="i"><userinput>CC=${CLFS_TARGET}-gcc make</userinput></screen>
41
42 <para os="l">Install the package:</para>
43
44<screen os="j"><userinput>make install</userinput></screen>
45
46 <para os="k">Make the proper symlinks for the dynamic loader such that
47 dynamically linked executables properly find the musl ld:</para>
48
49<screen os="m"><userinput>ln -s libc.so ${CLFS}/cross-tools/${CLFS_TARGET}/ld-musl-arm.so.1
50ln -s libc.so ${CLFS}/cross-tools/${CLFS_TARGET}/ld-musl-armhf.so.1
51ln -s libc.so ${CLFS}/cross-tools/${CLFS_TARGET}/ld-musl-i386.so.1
52ln -s libc.so ${CLFS}/cross-tools/${CLFS_TARGET}/ld-musl-mips.so.1</userinput></screen>
53
54 </sect2>
55
56 <sect2 id="contents-musl-libc" role="content">
57 <title>Contents of musl-libc</title>
58
59 <segmentedlist>
60 <segtitle>Installed Programs</segtitle>
61 <segtitle>Installed Libraries</segtitle>
62 <segtitle>Installed Headers</segtitle>
63 <seglistitem>
64 <seg>ld-musl-libc.so.0</seg>
65 <seg> libc.so.0, libcrypt.so.0, libdl.so.0, libm.so.0, libpthread.so.0,
66 librt.so.0</seg>
67 <seg>To be written...</seg>
68 </seglistitem>
69 </segmentedlist>
70
71 <variablelist>
72 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
73 <?dbfo list-presentation="list"?>
74 <?dbhtml list-presentation="table"?>
75
76 <varlistentry id="ld-musl-libc">
77 <term><command>ld-musl-libc</command></term>
78 <listitem>
79 <para>The musl-libc dynamic linker / loader</para>
80 <indexterm zone="ch-cross-tools-libc ld-musl-libc">
81 <primary sortas="b-ld-musl-libc">ld-musl-libc</primary>
82 </indexterm>
83 </listitem>
84 </varlistentry>
85
86 <varlistentry id="libc">
87 <term><filename class="libraryfile">libc</filename></term>
88 <listitem>
89 <para>The C library</para>
90 <indexterm zone="ch-cross-tools-libc libc">
91 <primary sortas="c-libc">libc</primary>
92 </indexterm>
93 </listitem>
94 </varlistentry>
95
96 <varlistentry id="libcrypt">
97 <term><filename class="libraryfile">libcrypt</filename></term>
98 <listitem>
99 <para>The cryptographic library</para>
100 <indexterm zone="ch-cross-tools-libc libcrypt">
101 <primary sortas="c-libcrypt">libcrypt</primary>
102 </indexterm>
103 </listitem>
104 </varlistentry>
105
106 <varlistentry id="libdl">
107 <term><filename class="libraryfile">libdl</filename></term>
108 <listitem>
109 <para>The musl-libc dynamic linker / loader library</para>
110 <indexterm zone="ch-cross-tools-libc libdl">
111 <primary sortas="c-libdl">libdl</primary>
112 </indexterm>
113 </listitem>
114 </varlistentry>
115
116 <varlistentry id="libm">
117 <term><filename class="libraryfile">libm</filename></term>
118 <listitem>
119 <para>The math library</para>
120 <indexterm zone="ch-cross-tools-libc libm">
121 <primary sortas="c-libm">libm</primary>
122 </indexterm>
123 </listitem>
124 </varlistentry>
125
126 <varlistentry id="libpthread">
127 <term><filename class="libraryfile">libpthread</filename></term>
128 <listitem>
129 <para>The POSIX thread library</para>
130 <indexterm zone="ch-cross-tools-libc libpthread">
131 <primary sortas="c-libpthread">libpthread</primary>
132 </indexterm>
133 </listitem>
134 </varlistentry>
135
136 <varlistentry id="librt">
137 <term><filename class="libraryfile">librt</filename></term>
138 <listitem>
139 <para>The clock and timer library</para>
140 <indexterm zone="ch-cross-tools-libc librt">
141 <primary sortas="c-librt">librt</primary>
142 </indexterm>
143 </listitem>
144 </varlistentry>
145
146 </variablelist>
147 </sect2>
148</sect1>
Note: See TracBrowser for help on using the repository browser.