source: x/installing/xorg7.xml@ 4ef2527

11.3 12.0 12.1 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk xry111/llvm18 xry111/xf86-video-removal
Last change on this file since 4ef2527 was 4ef2527, checked in by Bruce Dubbs <bdubbs@…>, 19 months ago

Recommend using /usr as the xorg install prefix

  • Property mode set to 100644
File size: 11.0 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="xorg7" xreflabel="Xorg-&xorg-version;">
9 <?dbhtml filename="xorg7.html"?>
10
11 <sect1info>
12 <date>$Date$</date>
13 </sect1info>
14
15 <title>Introduction to Xorg-&xorg-version;</title>
16
17 <indexterm zone="xorg7">
18 <primary sortas="a-xorg7">Xorg</primary>
19 </indexterm>
20
21
22 <para>
23 <application>Xorg</application> is a freely redistributable,
24 open-source implementation of the <application>X</application> Window
25 System. This system provides a client/server interface between display
26 hardware (the mouse, keyboard, and video displays) and the desktop
27 environment, while also providing both the windowing infrastructure and a
28 standardized application interface (API).
29 </para>
30
31 <para condition="html" role="usernotes">User Notes:
32 <ulink url='&blfs-wiki;/Xorg7'/></para>
33
34 <bridgehead renderas="sect3">Xorg Download and Installation
35 Instructions</bridgehead>
36
37 <para>
38 Xorg-7.0 introduced a completely auto-tooled, modular build system.
39 With the new modular build system, it is no longer possible to download
40 the entire package in a single file. In fact, there will be well over 100
41 packages that need to be fetched from the download location. To assist
42 with such a large task, installing <xref linkend="wget"/> is strongly
43 recommended for downloading the needed files. A complete
44 <application>wget</application> file list is provided for each page
45 that includes multiple packages.
46 </para>
47
48 <para>
49 Given the number of packages available, deciding which packages you
50 need to install for your particular setup may seem a bit overwhelming at
51 first. Take a look at <ulink url=
52 "https://wiki.x.org/wiki/ModuleDescriptions">this page</ulink>
53 and <ulink url=
54 "https://lists.x.org/archives/xorg-modular/2005-November/000801.html">
55 this thread</ulink>
56 to get an idea of what you will need. If you are unsure, you should
57 install all packages at the cost of extra disk space.
58 </para>
59
60 <note>
61 <para>
62 Even if you intend to download only the necessary packages, you
63 should download the wget file lists. The list of files are ordered by
64 dependency, and the package versions listed in the files are known to
65 work well with each other. Further, the wget file lists contain comments
66 for specific packages that are deprecated or are not recommended to
67 install. Newer packages are likely intended for the
68 next release of <application>Xorg</application> and have already proved
69 to be incompatible with current versions of software installed in BLFS.
70 The installed size of <application>Xorg</application> can be reduced
71 considerably by installing only the packages that you will need and use,
72 however, the BLFS book cannot account for all dependencies and build
73 options for the individual <application>Xorg</application> packages.
74 The instructions assume that all packages have been built. A
75 <ulink url="&blfs-wiki;/Xorg7">wiki</ulink>
76 page containing dependency information is under development. You are
77 encouraged to add to these pages if you discover additional information
78 that may be helpful to other users who selectively install individual
79 packages.
80 </para>
81 </note>
82
83 <para>
84 Additionally, because of the large number of repetitive commands,
85 you are encouraged to partially automate the build. Instructions have been
86 given that utilize the <xref linkend="sudo"/> package. It is recommended
87 that you use the <parameter>:NOPASSWD</parameter> configuration option
88 for the user that will be building the xorg packages.
89 </para>
90
91 <sect2 id="xorg-env" xreflabel="Xorg build environment">
92 <title>Setting up the Xorg Build Environment</title>
93
94 <note>
95 <para>
96 The following instructions assume that the shell
97 startup files have been set up as described in
98 <xref linkend="postlfs-config-profile" />.
99 </para>
100 </note>
101
102 <para>
103 As with previous releases of the X Window System, it may be
104 desirable to install <application>Xorg</application> into an alternate
105 prefix. This is no longer common practice among Linux distributions.
106 The common installation prefix for <application>Xorg</application> on
107 Linux is <filename class="directory">/usr</filename>. There is no
108 standard alternate prefix, nor is there any exception in the current
109 revision of the Filesystem Hierarchy Standard for Release 7 of the X
110 Window System. Alan Coopersmith of Sun Microsystems, once
111 stated "At Sun, we were using
112 <filename class="directory">/usr/X11</filename> and plan to stick with
113 it." Only the <filename class="directory">/opt/*</filename> prefix or
114 the <filename class="directory">/usr</filename> prefix adhere to the
115 current FHS guidelines.
116 </para>
117
118 <para>
119 The BLFS editors recommend using the <filename class="directory">/usr</filename>
120 prefix.
121 </para>
122
123 <para>
124 Choose your installation prefix, and set the <envar>XORG_PREFIX</envar>
125 variable with the following command:
126 </para>
127
128<screen><userinput>export XORG_PREFIX="<replaceable>&lt;PREFIX&gt;</replaceable>"</userinput></screen>
129
130 <para>
131 Throughout these instructions, you will use the following
132 <command>configure</command> switches for all of the packages. Create the
133 <envar>XORG_CONFIG</envar> variable to use for this parameter
134 substitution:
135 </para>
136
137<screen><userinput>export XORG_CONFIG="--prefix=$XORG_PREFIX --sysconfdir=/etc \
138 --localstatedir=/var --disable-static"</userinput></screen>
139
140 <para>
141 Create an <filename>/etc/profile.d/xorg.sh</filename> configuration
142 file containing these variables as the
143 <systemitem class="username">root</systemitem> user:
144 </para>
145
146<screen role="root"><userinput>cat &gt; /etc/profile.d/xorg.sh &lt;&lt; EOF
147<literal>XORG_PREFIX="$XORG_PREFIX"
148XORG_CONFIG="--prefix=\$XORG_PREFIX --sysconfdir=/etc --localstatedir=/var --disable-static"
149export XORG_PREFIX XORG_CONFIG</literal>
150EOF
151chmod 644 /etc/profile.d/xorg.sh</userinput></screen>
152
153 <note>
154 <para>
155 There is some confusion about the above 'here' document.
156 The backslash in front of the dollar sign is correct. Bash
157 will remove it when creating /etc/profile.d/xorg.sh. However, if
158 you are creating the file with an editor, a copy and paste operation
159 will not remove the backslash. It must then be removed manually.
160 </para>
161 </note>
162
163 <para>
164 If you've installed <xref linkend="sudo"/>, ensure that
165 <envar>XORG_PREFIX</envar> and <envar>XORG_CONFIG</envar> are available
166 in the <application>sudo</application> environment. As the
167 <systemitem class="username">root</systemitem> user, run the following
168 command:
169 </para>
170
171<screen role="root"><userinput>cat &gt; /etc/sudoers.d/xorg &lt;&lt; EOF
172<literal>Defaults env_keep += XORG_PREFIX
173Defaults env_keep += XORG_CONFIG</literal>
174EOF</userinput></screen>
175
176<bridgehead renderas="sect2">If you are not using the standard Xorg prefix...</bridgehead>
177
178 <warning>
179 <para>
180 If you've decided to use the standard <filename
181 class="directory">/usr</filename> prefix, you must omit the remainder of
182 this page and continue at <xref linkend='util-macros'/>.
183 </para>
184 </warning>
185
186 <para>
187 If you've decided to <emphasis>not</emphasis> use the standard
188 prefix, be sure to add <filename
189 class="directory">$XORG_PREFIX/bin</filename> to your <envar>PATH</envar>
190 environment variable, and <filename class="directory">
191 $XORG_PREFIX/lib/pkgconfig</filename> and <filename class="directory">
192 $XORG_PREFIX/share/pkgconfig</filename> to your
193 <envar>PKG_CONFIG_PATH</envar> variable. It is also helpful to specify
194 additional search paths for <command>gcc</command> and an include
195 directory for the <command>aclocal</command> program. Issue the
196 following commands as the <systemitem class="username">root</systemitem>
197 user:
198 </para>
199
200<screen role="root"><userinput>cat &gt;&gt; /etc/profile.d/xorg.sh &lt;&lt; "EOF"
201<literal>
202pathappend $XORG_PREFIX/bin PATH
203pathappend $XORG_PREFIX/lib/pkgconfig PKG_CONFIG_PATH
204pathappend $XORG_PREFIX/share/pkgconfig PKG_CONFIG_PATH
205
206pathappend $XORG_PREFIX/lib LIBRARY_PATH
207pathappend $XORG_PREFIX/include C_INCLUDE_PATH
208pathappend $XORG_PREFIX/include CPLUS_INCLUDE_PATH
209
210ACLOCAL="aclocal -I $XORG_PREFIX/share/aclocal"
211
212export PATH PKG_CONFIG_PATH ACLOCAL LIBRARY_PATH C_INCLUDE_PATH CPLUS_INCLUDE_PATH</literal>
213EOF</userinput></screen>
214
215 <para>
216 The script above needs to be activated. Normally it will be
217 automatic at login, but to activate it now, as a regular user, run:
218 </para>
219
220<screen><userinput>source /etc/profile.d/xorg.sh</userinput></screen>
221
222 <para>
223 You should also add
224 <filename class="directory"> $XORG_PREFIX/lib</filename> to the
225 <filename>/etc/ld.so.conf</filename> file. Again, as the
226 <systemitem class="username">root</systemitem> user, issue the following
227 command:
228 </para>
229
230<screen role="root"><userinput>echo "$XORG_PREFIX/lib" >> /etc/ld.so.conf</userinput></screen>
231
232 <para>
233 You should also modify
234 <filename>/etc/man_db.conf</filename>, adding appropriate
235 MANDATORY_MANPATH, MANPATH_MAP, and MANDB_MAP entries following the
236 examples for <filename class="directory">/usr/X11R6</filename>. Issue the
237 following command as the <systemitem class="username">root</systemitem>
238 user:
239 </para>
240
241<screen role="root"><userinput>sed -e "s@<replaceable>X11R6/man</replaceable>@X11R6/share/man@g" \
242 -e "s@<replaceable>/usr/X11R6</replaceable>@$XORG_PREFIX@g" \
243 -i /etc/man_db.conf</userinput></screen>
244
245 <para>
246 Some applications look for shared files in <filename
247 class="directory">/usr/share/X11</filename>. Create a symbolic link to
248 the proper location as the <systemitem class="username">root</systemitem>
249 user:
250 </para>
251
252<screen role="root"><userinput>ln -svf $XORG_PREFIX/share/X11 /usr/share/X11</userinput></screen>
253
254 <para>
255 If building KDE, some cmake files look for Xorg in places other than
256 $XORG_PREFIX. Allow cmake to find Xorg with:
257 </para>
258
259<screen role="root"><userinput>ln -svf $XORG_PREFIX /usr/X11R6</userinput></screen>
260<!--
261 <para>
262 Finally, if building on x86_64, you will need to create the
263 <filename class="directory">$XORG_PREFIX/lib</filename> directory and the
264 <filename>$XORG_PREFIX/lib64</filename> symlink. Again, as the
265 <systemitem class="username">root</systemitem> user, issue the following
266 commands:
267 </para>
268
269<screen role="root"><userinput>install -v -m755 -d $XORG_PREFIX &amp;&amp;
270install -v -m755 -d $XORG_PREFIX/lib &amp;&amp;
271ln -sf lib $XORG_PREFIX/lib64</userinput></screen>
272-->
273 </sect2>
274
275</sect1>
Note: See TracBrowser for help on using the repository browser.