-
Notifications
You must be signed in to change notification settings - Fork 345
/
mythtv-HOWTO-4.html
214 lines (193 loc) · 9 KB
/
mythtv-HOWTO-4.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD>
<META NAME="GENERATOR" CONTENT="LinuxDoc-Tools 0.9.21">
<TITLE>Installing and using MythTV: System Configuration Requirements for Compiling MythTV </TITLE>
<LINK HREF="mythtv-HOWTO-5.html" REL=next>
<LINK HREF="mythtv-HOWTO-3.html" REL=previous>
<LINK HREF="mythtv-HOWTO.html#toc4" REL=contents>
</HEAD>
<BODY>
<A HREF="mythtv-HOWTO-5.html">Next</A>
<A HREF="mythtv-HOWTO-3.html">Previous</A>
<A HREF="mythtv-HOWTO.html#toc4">Contents</A>
<HR>
<H2><A NAME="Setting_up_paths"></A> <A NAME="s4">4.</A> <A HREF="mythtv-HOWTO.html#toc4">System Configuration Requirements for Compiling MythTV </A></H2>
<P>Before you compile MythTV from the current source tarball or from CVS, you
may need to modify your system configuration in a few ways.</P>
<P>In general, if you install MythTV from pre-packaged binaries for your Linux
distribution/version, you don't need to be too concerned about the issues in
this section of the HOWTO - the install script for the packages should take
care of them. However, this section is still recommended reading which may
help if the packager skipped a step in their packaging.</P>
<H2><A NAME="ss4.1">4.1</A> <A HREF="mythtv-HOWTO.html#toc4.1">Software requirements for compiling MythTV</A>
</H2>
<H3>General requirements</H3>
<P>MythTV is written in C++ and requires a fairly complete, but standard,
compilation environment, including a recent g++ compiler, <CODE>make</CODE>, and
appropriate headers files for shared libraries. Any standard Linux
distribution should be able to install a suitable compilation environment
from its packaging system. Section 3.2 of this HOWTO provides some details
of how to install the required environment for many distributions.</P>
<P>Subsequent sections of this chapter address the few oddities that you may
have to adjust by hand before you compile MythTV.</P>
<P>The reference compilation system for MythTV is Debian.</P>
<H3>Distribution-Specific Notes </H3>
<P>None </P>
<H2><A NAME="ss4.2">4.2</A> <A HREF="mythtv-HOWTO.html#toc4.2">Shared-Library Requirements for MythTV </A>
</H2>
<H3><A NAME="modifying_ld.so.conf"></A> Modifying /etc/ld.so.conf </H3>
<P>The runtime manager for shared libraries, <B>/lib/ld.so</B>, gets
information about the locations and contents of shared libraries from
<CODE>/etc/ld.so.cache</CODE>, a file created by <B>ldconfig</B> from
information in <CODE>/etc/ld.so.conf</CODE>. Because MythTV installs some
shared libraries in <CODE>/usr/local/lib</CODE>, that directory needs to be
added to the list of directories for <B>ld.so</B> to search when doing
runtime linking of programs. You do this, as root, by editing
<CODE>/etc/ld.so.conf</CODE>, then running <B>ldconfig</B>. There are many
ways to do this; one that works is to enter this series of commands:</P>
<P>
<BLOCKQUOTE><CODE>
<PRE>
$ su -
# echo /usr/local/lib >> /etc/ld.so.conf
# /sbin/ldconfig
# exit
$
</PRE>
</CODE></BLOCKQUOTE>
</P>
<H3>Distribution-Specific Notes</H3>
<H2><A NAME="ss4.3">4.3</A> <A HREF="mythtv-HOWTO.html#toc4.3">Environment variable Requirements for MythTV</A>
</H2>
<H3>General requirements</H3>
<H3>QT libraries and binaries</H3>
<P>The compiler needs to be able to locate QT binaries and libraries in order
to compile MythTV. QTDIR needs to be set and <CODE>/usr/lib/qt3/bin</CODE> must be
added to your path. Your distribution may already be making these changes
as a part of the installation of the software prerequisites detailed
earlier.</P>
<P>One way to do this is as follows:
<A NAME="Checking_that_it_worked"></A> </P>
<P>Open a shell and execute the following:
<BLOCKQUOTE><CODE>
<PRE>
$ echo $PATH
/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/usr/lib/qt3/bin:/home/mythtv/bin:/usr/lib/qt3/bin
$ echo $QTDIR
/usr/lib/qt3
</PRE>
</CODE></BLOCKQUOTE>
</P>
<P>You should see a value like <CODE>/usr/lib/qt3</CODE> for <CODE>QTDIR</CODE>
and <CODE>/usr/lib/qt3/bin</CODE> should be in $PATH.</P>
<P>If you don't, do not proceed past this step until you have resolved this
error. You may need to manually specify the QTDIR and PATH at the shell
prompt before compiling.</P>
<P>Also, check that there has been a link created in
<CODE>/usr/lib/qt3/mkspecs</CODE> called <CODE>default</CODE>. If not, you'll get
errors during the compile. See the Troubleshooting Section for more
information.</P>
<H3>Distribution-Specific Notes</H3>
<H3>Mandrake</H3>
<P>The following instructions work for Mandrake 9.0 and 9.1 using
<B>bash</B> as the shell, and may be applicable for a distribution which
uses <CODE>/etc/profile.d</CODE>.</P>
<P>As root, create the following file in <CODE>/etc/profile.d</CODE> The example
filename is "mythtv.sh". Use what you feel is appropriate.</P>
<P>Open a shell, and switch to superuser mode.
<B>NOTE</B>: ^D means press CTRL and d at the same time.
<BLOCKQUOTE><CODE>
<PRE>
$ su
# cd /etc/profile.d
cat > mythtv.sh
export QTDIR=/usr/lib/qt3
export PATH=$PATH:/usr/lib/qt3/bin
^D
# chmod a+x mythtv.sh
# exit
$ exit
</PRE>
</CODE></BLOCKQUOTE>
The last two commands are to exit out of the shell. This way, when you next
open a shell your new commands
will take effect.</P>
<H3>Red Hat Linux 9</H3>
<P>Red Hat Linux 9 use a default locale with UTF-8 encoding.
Date::Manip, a perl module used by XMLTV, is not UTF-8 safe. As a result,
whenever you run setup or mythfilldatabase you will get a lot of UTF-8
warnings. There is an
<A HREF="http://membled.com/work/patches/DateManip/">http://membled.com/work/patches/DateManip/</A> updated version of
Date::Manip at the XMLTV site fixing this and other XMLTV related
# bugs.</P>
<H3>Debian</H3>
<P>Debian source packages are available from the same place as the
binary packages. These can be used to build customized packages, and
to automatically satisfy MythTV's build-time dependencies.</P>
<P>
<BLOCKQUOTE><CODE>
<PRE>
sh-2.05b# apt-get build-dep mythtv
Reading Package Lists...
Building Dependency Tree...
The following NEW packages will be installed:
debconf-utils debhelper file fontconfig gettext html2text intltool-debian
libaudio2 libexpat1 libfontconfig1 libfontconfig1-dev libfreetype6
libfreetype6-dev libglib2.0-0 libjpeg62 libjpeg62-dev liblame-dev liblame0
liblcms1 liblcms1-dev libmagic1 libmng-dev libmng1 libmysqlclient-dev
libmysqlclient12 libogg-dev libogg0 libpng12-0 libpng12-dev libqt3-headers
libqt3-mt-dev libqt3c102-mt libvorbis-dev libvorbis0a libvorbisenc2
libvorbisfile3 libxcursor-dev libxcursor1 libxft2 libxft2-dev libxrender-dev
libxrender1 mysql-common pkg-config po-debconf qt3-dev-tools xfree86-common
xlibmesa-gl-dev xlibmesa-glu-dev xlibmesa3-gl xlibmesa3-glu xlibs xlibs-dev
zlib1g-dev
0 upgraded, 54 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B/24.0MB of archives.
After unpacking 78.7MB of additional disk space will be used.
Do you want to continue? [Y/n]
[...]
sh-2.05b# cd /tmp
sh-2.05b# apt-get source mythtv
Reading Package Lists...
Building Dependency Tree...
Need to get 3085kB of source archives.
Get:1 http://dijkstra.csh.rit.edu unstable/mythtv mythtv 0.11-4 (dsc) [507B]
Get:2 http://dijkstra.csh.rit.edu unstable/mythtv mythtv 0.11-4 (tar) [3071kB]
Get:3 http://dijkstra.csh.rit.edu unstable/mythtv mythtv 0.11-4 (diff) [13.9kB]
Fetched 3085kB in 0s (8120kB/s)
dpkg-source: extracting mythtv in mythtv-0.11
sh-2.05b# cd mythtv-0.11
[customize settings.pro, etc.]
[edit debian/changelog and increment the version number]
sh-2.05b# dpkg-buildpackage -rfakeroot -us -uc -b
[...]
dpkg-deb: building package `mythtv-backend' in `../mythtv-backend_0.11-4_i386.deb'.
dpkg-deb: building package `mythtv-frontend' in `../mythtv-frontend_0.11-4_i386.deb'.
dpkg-deb: building package `libmyth-0.11' in `../libmyth-0.11_0.11-4_i386.deb'.
dpkg-deb: building package `libmyth-0.11-dev' in `../libmyth-0.11-dev_0.11-4_i386.deb'.
dpkg-genchanges -b
dpkg-genchanges: binary-only upload - not including any source code
dpkg-buildpackage: binary only upload (no source included)
sh-2.05b# ls -l ../*.deb
-rw-r--r-- 1 root root 31734 Sep 6 19:07 ../libmyth-0.11-dev_0.11-4_i386.deb
-rw-r--r-- 1 root root 408444 Sep 6 19:07 ../libmyth-0.11_0.11-4_i386.deb
-rw-r--r-- 1 root root 3324966 Sep 6 19:07 ../mythtv-backend_0.11-4_i386.deb
-rw-r--r-- 1 root root 15350 Sep 6 19:07 ../mythtv-common_0.11-4_all.deb
-rw-r--r-- 1 root root 17978 Sep 6 19:07 ../mythtv-database_0.11-4_all.deb
-rw-r--r-- 1 root root 422232 Sep 6 19:07 ../mythtv-doc_0.11-4_all.deb
-rw-r--r-- 1 root root 4900474 Sep 6 19:07 ../mythtv-frontend_0.11-4_i386.deb
-rw-r--r-- 1 root root 12372 Sep 6 19:07 ../mythtv_0.11-4_all.deb
</PRE>
</CODE></BLOCKQUOTE>
</P>
<P>If building from CVS instead of the source package, then the QTDIR
environment variable must be set when building. On Debian woody,
QTDIR should be set to <CODE>/usr/share/qt</CODE>. On Debian unstable,
QTDIR should be set to <CODE>/usr/share/qt3</CODE>.</P>
<HR>
<A HREF="mythtv-HOWTO-5.html">Next</A>
<A HREF="mythtv-HOWTO-3.html">Previous</A>
<A HREF="mythtv-HOWTO.html#toc4">Contents</A>
</BODY>
</HTML>