source: general/genlib/umockdev.xml@ 3a001df8

12.0 12.1 ken/TL2024 ken/tuningfonts lazarus plabs/newcss python3.11 rahul/power-profiles-daemon renodr/vulkan-addition trunk xry111/llvm18
Last change on this file since 3a001df8 was cb594b6c, checked in by Xi Ruoyao <xry111@…>, 12 months ago

general: Remove non-exist User Notes link

Part of User Notes removal by
https://www.linuxfromscratch.org/~xry111/remove-nonexist-usernote.sh

  • Property mode set to 100644
File size: 6.4 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 <!ENTITY umockdev-download-http "https://github.com/martinpitt/umockdev/releases/download/&umockdev-version;/umockdev-&umockdev-version;.tar.xz">
8 <!ENTITY umockdev-download-ftp " ">
9 <!ENTITY umockdev-md5sum "f966821009a94be4e0e3011190ad03e0">
10 <!ENTITY umockdev-size "480 KB">
11 <!ENTITY umockdev-buildsize "6.6 MB (with tests)">
12 <!ENTITY umockdev-time "0.2 SBU (with tests)">
13]>
14
15<sect1 id="umockdev" xreflabel="umockdev-&umockdev-version;">
16 <?dbhtml filename="umockdev.html"?>
17
18
19 <title>Umockdev-&umockdev-version;</title>
20
21 <indexterm zone="umockdev">
22 <primary sortas="a-umockdev">umockdev</primary>
23 </indexterm>
24
25 <sect2 role="package">
26 <title>Introduction to Umockdev</title>
27
28 <para>
29 The <application>Umockdev</application> package contains a framework
30 that allows a developer to mock devices for use in unit testing.
31 </para>
32
33 &lfs113_checked;
34
35 <bridgehead renderas="sect3">Package Information</bridgehead>
36 <itemizedlist spacing="compact">
37 <listitem>
38 <para>
39 Download (HTTP): <ulink url="&umockdev-download-http;"/>
40 </para>
41 </listitem>
42 <listitem>
43 <para>
44 Download (FTP): <ulink url="&umockdev-download-ftp;"/>
45 </para>
46 </listitem>
47 <listitem>
48 <para>
49 Download MD5 sum: &umockdev-md5sum;
50 </para>
51 </listitem>
52 <listitem>
53 <para>
54 Download size: &umockdev-size;
55 </para>
56 </listitem>
57 <listitem>
58 <para>
59 Estimated disk space required: &umockdev-buildsize;
60 </para>
61 </listitem>
62 <listitem>
63 <para>
64 Estimated build time: &umockdev-time;
65 </para>
66 </listitem>
67 </itemizedlist>
68
69 <bridgehead renderas="sect3">Umockdev Dependencies</bridgehead>
70
71 <bridgehead renderas="sect4">Required</bridgehead>
72 <para role="required">
73 <xref linkend="libgudev"/>,
74 <xref linkend="libpcap"/>, and
75 <xref linkend="vala"/>
76 </para>
77
78 <bridgehead renderas="sect4">Optional</bridgehead>
79 <para role="optional">
80 <xref linkend="gtk-doc"/> and
81 <ulink url="http://www.gphoto.org/">libgphoto2</ulink> (optional for tests)
82 </para>
83
84 </sect2>
85
86 <sect2 role="installation">
87 <title>Installation of Umockdev</title>
88
89 <para>
90 Install <application>Umockdev</application> by running the following
91 commands:
92 </para>
93
94<screen><userinput>mkdir build &amp;&amp;
95cd build &amp;&amp;
96
97meson setup --prefix=/usr --buildtype=release .. &amp;&amp;
98ninja</userinput></screen>
99
100 <para>
101 To test the results, issue: <command>PATH=$PATH:/usr/sbin ninja
102 test</command>. The addition to <envar>PATH</envar> is needed if you
103 use the starting scripts in <xref linkend="postlfs-config-profile"/>,
104 because some tests need to run <command>udevadm</command>. One test
105 needs to be run in an X session.
106 </para>
107
108 <para>
109 Now, as the <systemitem class="username">root</systemitem> user:
110 </para>
111
112<screen role="root"><userinput>ninja install</userinput></screen>
113 </sect2>
114
115 <sect2 role="commands">
116 <title>Command Explanations</title>
117
118<!--
119 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
120 href="../../xincludes/static-libraries.xml"/>
121
122 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
123 href="../../xincludes/gtk-doc-rebuild.xml"/>
124-->
125 <para>
126 <option>-Dgtk_doc=true</option>: Use this switch if you have
127 <xref linkend="gtk-doc" role="nodep"/> installed and wish to rebuild and
128 install the API documentation.
129 </para>
130
131 </sect2>
132
133 <sect2 role="content">
134 <title>Contents</title>
135
136 <segmentedlist>
137 <segtitle>Installed Programs</segtitle>
138 <segtitle>Installed Libraries</segtitle>
139 <segtitle>Installed Directories</segtitle>
140
141 <seglistitem>
142 <seg>
143 umockdev-record,
144 umockdev-run, and
145 umockdev-wrapper
146 </seg>
147 <seg>
148 libumockdev-preload.so <!-- Only intended for use by
149 umockdev-wrapper. Don't put in a short description for this--> and
150 libumockdev.so
151 </seg>
152 <seg>
153 /usr/include/umockdev-1.0
154 </seg>
155 </seglistitem>
156 </segmentedlist>
157
158 <variablelist>
159 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
160 <?dbfo list-presentation="list"?>
161 <?dbhtml list-presentation="table"?>
162
163 <varlistentry id="umockdev-record">
164 <term><command>umockdev-record</command></term>
165 <listitem>
166 <para>
167 records Linux devices and their ancestors from sysfs/udev or
168 records ioctls for a device
169 </para>
170 <indexterm zone="umockdev umockdev-record">
171 <primary sortas="b-umockdev-record">umockdev-record</primary>
172 </indexterm>
173 </listitem>
174 </varlistentry>
175
176 <varlistentry id="umockdev-run">
177 <term><command>umockdev-run</command></term>
178 <listitem>
179 <para>
180 runs a program under an <application>umockdev</application>
181 testbed
182 </para>
183 <indexterm zone="umockdev umockdev-run">
184 <primary sortas="b-umockdev-run">umockdev-run</primary>
185 </indexterm>
186 </listitem>
187 </varlistentry>
188
189 <varlistentry id="umockdev-wrapper">
190 <term><command>umockdev-wrapper</command></term>
191 <listitem>
192 <para>
193 wraps a program around
194 <filename class="libraryfile">libumockdev-preload.so.0</filename>
195 through LD_PRELOAD
196 </para>
197 <indexterm zone="umockdev umockdev-wrapper">
198 <primary sortas="b-umockdev-wrapper">umockdev-wrapper</primary>
199 </indexterm>
200 </listitem>
201 </varlistentry>
202
203 <varlistentry id="libumockdev">
204 <term><filename class="libraryfile">libumockdev.so</filename></term>
205 <listitem>
206 <para>
207 provides API functions that allow mocking hardware devices for unit
208 testing
209 </para>
210 <indexterm zone="umockdev libumockdev">
211 <primary sortas="c-libumockdev">libumockdev.so</primary>
212 </indexterm>
213 </listitem>
214 </varlistentry>
215 </variablelist>
216 </sect2>
217
218</sect1>
Note: See TracBrowser for help on using the repository browser.