source: general/genlib/libusb.xml@ fa0eb91a

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 6.0 6.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since fa0eb91a was fa0eb91a, checked in by Randy McMurchy <randy@…>, 19 years ago

Added Autotools reconfiguration and indexing tags to libusb instructions

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@3348 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 5.8 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
3 "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7<!ENTITY libusb-download-http "http://prdownloads.sourceforge.net/libusb/libusb-&libusb-version;.tar.gz">
8<!ENTITY libusb-download-ftp " ">
9<!ENTITY libusb-size "314 KB">
10<!ENTITY libusb-buildsize "4.5 MB (includes HTML documentation installation)">
11<!ENTITY libusb-time "0.25 SBU">
12]>
13
14<sect1 id="libusb" xreflabel="libusb-&libusb-version;">
15<sect1info>
16<othername>$LastChangedBy$</othername>
17<date>$Date$</date>
18</sect1info>
19<?dbhtml filename="libusb.html"?>
20<title>libusb-&libusb-version;</title>
21<indexterm zone="libusb">
22<primary sortas="a-Libusb">Libusb</primary>
23</indexterm>
24
25<sect2>
26<title>Introduction to <application>libusb</application></title>
27
28<para>The <application>libusb</application> package contains a library
29used by some applications for <acronym>USB</acronym> device access.</para>
30
31<sect3><title>Package information</title>
32<itemizedlist spacing='compact'>
33<listitem><para>Download (HTTP):
34<ulink url="&libusb-download-http;"/></para></listitem>
35<listitem><para>Download (FTP):
36<ulink url="&libusb-download-ftp;"/></para></listitem>
37<listitem><para>Download size:
38&libusb-size;</para></listitem>
39<listitem><para>Estimated disk space required:
40&libusb-buildsize;</para></listitem>
41<listitem><para>Estimated build time:
42&libusb-time;</para></listitem></itemizedlist>
43</sect3>
44
45<sect3><title><application>libusb</application> dependencies</title>
46<sect4><title>Optional</title>
47<para><xref linkend="openjade"/> and <xref linkend="sgml-dtd-3"/> (both
48required to build the <acronym>HTML</acronym> documentation)</para>
49</sect4>
50</sect3>
51
52</sect2>
53
54<sect2>
55<title>Installation of <application>libusb</application></title>
56
57<para>Install <application>libusb</application> by running the following
58commands:</para>
59
60<screen><userinput><command>libtoolize -f &amp;&amp;
61autoreconf -f &amp;&amp;
62./configure --prefix=/usr --disable-build-docs &amp;&amp;
63make</command></userinput></screen>
64
65<para>Now, as the root user:</para>
66
67<screen><userinput role='root'><command>make install</command></userinput></screen>
68
69<para>If you built the <acronym>HTML</acronym> documentation, install it using
70the following commands:</para>
71
72<screen><userinput role='root'><command>install -v -d -m755 /usr/share/doc/libusb-&libusb-version;/html &amp;&amp;
73install -v -m644 doc/html/* /usr/share/doc/libusb-&libusb-version;/html</command></userinput></screen>
74
75</sect2>
76
77<sect2>
78<title>Command explanations</title>
79
80<para><command>libtoolize -f</command>: There is a mismatch in the Autotools
81with <acronym>LFS</acronym>-6.0. This command forces the build to use the
82system installed <command>libtool</command> tools so that the shared library
83is created correctly.</para>
84
85<para><command>autoreconf -f</command>: This command recreates some of the
86Autotools, required by running <command>libtoolize</command>.</para>
87
88<para><option>--disable-build-docs</option>: This switch avoids building the
89documentation. If you wish to build the documentation, you may need to remove
90the <application>OpenSP</application> catalog definitions from the system
91<acronym>SGML</acronym> catalogs. Use the following command before building
92the package to accomplish this:</para>
93
94<screen><userinput role='root'><command>sed -i.orig \
95 -e "/CATALOG \/etc\/sgml\/OpenSP-1.5.1.cat/d" \
96 /etc/sgml/catalog \
97 /etc/sgml/sgml-docbook.cat</command></userinput></screen>
98
99</sect2>
100
101<sect2>
102<title>Configuring <application>libusb</application></title>
103
104<para>libusb requires the usbfs kernel filesystem to be mounted on
105<filename class="directory">/proc/bus/usb</filename>. Applications require the
106files in this directory to be accessible to the user, sometimes for both
107reading and writing. To restrict access to <acronym>USB</acronym> devices,
108ensure the usb group exits on your system. If necessary, create the usb group
109using the following command:</para>
110
111<screen><userinput role='root'><command>groupadd -g 14 usb</command></userinput></screen>
112
113<para id="libusb-kernel">Ensure that you have compiled the <quote>USB device
114filesystem</quote> directly into the kernel or compiled it as a module
115(listing the resulting <quote>usbcore</quote> module in the
116<filename>/etc/sysconfig/modules</filename> file). You should also have an
117entry similar to the line below in your <filename>/etc/fstab</filename>
118file:</para>
119<indexterm zone="libusb libusb-kernel">
120<primary sortas="d-USB-device-filesystem">USB device filesystem</primary>
121</indexterm>
122
123<screen><userinput role='root'>usbfs /proc/bus/usb usbfs devgid=14,devmode=0660 0 0</userinput></screen>
124
125</sect2>
126
127<sect2>
128<title>Contents</title>
129
130<segmentedlist>
131<segtitle>Installed Program</segtitle>
132<segtitle>Installed Library</segtitle>
133<segtitle>Installed Directory</segtitle>
134
135<seglistitem>
136<seg>usb-config</seg>
137<seg>libusb.[so,a]</seg>
138<seg>/usr/share/doc/libusb-&libusb-version;</seg>
139</seglistitem>
140</segmentedlist>
141
142<variablelist>
143<bridgehead renderas="sect3">Short Descriptions</bridgehead>
144<?dbfo list-presentation="list"?>
145
146<varlistentry id="usb-config">
147<term><command>usb-config</command></term>
148<listitem><para>is a script that provides the right compiler and linker
149flags for programs using
150<filename class='libraryfile'>libusb</filename>.</para>
151<indexterm zone="libusb usb-config">
152<primary sortas="b-usb-config">usb-config</primary>
153</indexterm></listitem>
154</varlistentry>
155
156<varlistentry id="libusb-lib">
157<term><filename class='libraryfile'>libusb.[so,a]</filename></term>
158<listitem><para> libraries contain C functions for accessing
159<acronym>USB</acronym> hardware.</para>
160<indexterm zone="libusb libusb-lib">
161<primary sortas="c-libusb">libusb.[so,a]</primary>
162</indexterm></listitem>
163</varlistentry>
164</variablelist>
165
166</sect2>
167
168</sect1>
169
Note: See TracBrowser for help on using the repository browser.