Project

General

Profile

Development » History » Version 1

Adam Sutton, 2013-04-04 17:06

1 1 Adam Sutton
h1. Development
2
3
If you are intending to do Tvheadend development or simply self-building / testing then this page gives a few useful hints and tips.
4
5
h2. Environment
6
7
If you intend to build and test tvheadend its recommended that you do this as your own user, it'll make things a lot easier and can help isolate a test build from your main live build.
8
9
You will need to give your user account the necessary permissions to access the DVB hardware:
10
11
<pre>
12
sudo usermod -a -G video $(id -nu)
13
</pre>
14
15
If you already have an existing configuration you might consider taking a copy of this to give you a realistic data set without tainting your main config:
16
17
<pre>
18
sudo cp -a ~hts/.hts/tvheadend/ ./test-conf
19
sudo chown -R $(id -nu):$(id -ng)  ./test-conf
20
</pre>
21
22
You should now be able to run tvheadend as yourself (remember to turn off the main tvheadend service):
23
24
<pre>
25
./build.linux/tvheadend -c ./test-conf
26
</pre>
27
28
h2. Debugging
29
30
If you are investigating problems within Tvheadend then its worth being familiar with tools such as gdb and valgrind, although these are not covered here.
31
32
However one thing that can be useful in investigating crashes within Tvheadend is to ensure that coredumps are generated, this will allow post analysis in gdb without having to actual run Tvheadend within gdb.
33
34
You can enable temporarily by running:
35
36
<pre>
37
ulimit -c unlimited
38
</pre>
39
40
To make this permanent put this somewhere in your shell environment setup (.bashrc, .profile, etc...)