##tvrecΥ󥹥ȡ

#ѥåŸ
  tvrectarΰ̥եȤ°CD-ROM
˼ϿƤޤޤ°CD-ROMɥ
֤ơCD-ROMޥȤޤ

$ mount /cdrom

  rootˤʤäApacheΥɥȥ롼Ȥ˰
ưޤʸĿͤpublic_htmlǤ⹽ޤ
ǤApacheΥɥȥ롼Ȥ˥󥹥ȡ
뤹ˡޤ

$ su -
# cd /opt/httpd/htdocs
# tar zxvf /cdrom/xxx/tvrec-0.5.0.tar.gz

  */opt/httpd/htdocs/tvrec/lib/params.inc*
tvrecǻѤmplayer, mencoder, xawtv
ɤΥѥҤƤޤѥåʳ
餳Υץ򥤥󥹥ȡ뤷
ץΥѥѹƤ
--ꥹ 12 params.inc
<?php
$spooldir="video";
$encoder="/usr/bin/mencoder";
$player="/usr/bin/mplayer";
$tv="/usr/local/bin/xawtv";
$dvdplay=$player;
?>
--
ޤDGAǽΤʤXɥĶǤǻȤ
ϼΤ褦ˤƤ

--ꥹ 13 DGA̵params.inc
<?php
$spooldir="video";
$encoder="/usr/bin/mencoder";
$player="/usr/bin/mplayer";
$tv="/usr/local/bin/xawtv -nodga";
$dvdplay=$player;
?>
--

  Ͽ褷Ȥ
*/opt/httpd/htdocs/tvrec/video*¸
ˤApacheuserȤǽ񤭹
¤ɬפǤѥå饤󥹥ȡ뤷
ϡ桼̾www롼סapache
ʤäƤޤΤǡΥޥɤˤꡤowner
ѹޤ

# cd /opt/httpd/htdocs/tvrec
# chown www.apache video

  DVDɥ饤֤Ѥˤ/etc/groupdisk 
롼פ˥ȤϿɬפޤ
ĿͤΥǥȥåץȡǤsomeuser
ϿƱApacheΥȤǤ
wwwɲäޤ

# vi /etc/group

--ꥹ14 disk롼פؤɲ
root::0:root
bin::1:root,bin,daemon
daemon::2:root,bin,daemon
sys::3:root,bin,adm
adm::4:root,adm,daemon
tty::5:root
disk::6:root,adm,someuser,www
lp::7:lp
mem::8:
--

#ǡ١κ
ApachePostgreSQL³뤿Υ桼
(tvrec)ѥɤʤǺޤǡ
١븢¤ȿ桼
פǤΤ'n'Ϥޤ

--ꥹ15 tvrec桼ɲ
# su - postgres
$ createuser tvrec
Shall the new user be allowed to create databases? (y/n) n
Shall the new user be allowed to create more new users? (y/n) n
CREATE USER
--
tvrecǡ١ơ֥
ޤ

$ createdb tvrec
$ psql -d tvrec -f /opt/httpd/htdocs/tvrec/tools/create.sql

ơ֥뤬Ƥ뤫ǧޤ

--ꥹ16 tvrec DBΥ
$ psql -d tvrec
tvrec=# \z
                         ǡ١ "tvrec" Υ
  | ơ֥  |                                                  
----------+-----------+------------------------------------------------------------
 public   | bstation  | {postgres=a*r*w*d*R*x*t*/postgres,tvrec=arwdRxt/postgres}
 public   | dimension | {postgres=a*r*w*d*R*x*t*/postgres,tvrec=r/postgres}
 public   | iepgsite  | {postgres=a*r*w*d*R*x*t*/postgres,tvrec=r/postgres}
 public   | multiplex | {postgres=a*r*w*d*R*x*t*/postgres,tvrec=r/postgres}
 public   | quality   | {postgres=a*r*w*d*R*x*t*/postgres,tvrec=r/postgres}
 public   | record    | {postgres=a*r*w*d*R*x*t*/postgres,tvrec=arwdRxt/postgres}
 public   | videolib  | {postgres=a*r*w*d*R*x*t*/postgres,tvrec=arwdRxt/postgres}
(7 )
--
Τ褦ɽХơ֥뤬Ƥ


#iepgץ

  ³ơiEPGͽΥץ򥳥ѥ뤷
ޤץtarŸե
*tvrec/tools/iepg.c*ˤޤΥե
ʬΥۡǥ쥯ȥiepgǥ쥯ȥ
˥ԡѥ뤷ޤ

$ cd
$ mkdir iepg
$ cp /opt/httpd/htdocs/tvrec/tools/iepg.c iepg
$ cp /opt/httpd/htdocs/tvrec/tools/Makefile iepg
$ cd iepg
$ make

  iepgץե*.iepg*ۡ
ǥ쥯ȥ˺֥֥饦ͽ
ƤURLꤷޤƤ򼡤˼
ޤ

--ꥹ17 .iepg
browser	/usr/bin/mozilla
URL	http://localhost/tvrec/iepg.php
--
  ˡmozilla֥饦iEPGͽΤ
MIMEפꤷޤ

a.mozillaưޤ
b.[Խ]ץ˥塼¹Ԥޤ
c.Navigatorɢɥإѡץꥱ
  򤷤ޤ
d.[]ܥ򥯥åޤ
e.MIME|"
"application/x-tv-program-info"ꤷޤ
f.ĥҤ"iepg"ˤޤ
e.ɳץɤ"ץꥱ"
򤷡[]ܥ򥯥åޤ
f.ۤɥѥ뤷iepgץ
  ޤ

  Ͽ衤TVDVDκXɥ˹Ԥޤ
ApachewwwȤȤǵưƤ
Τǡ鵯ưxawtv, mplayerˤ
ƤwwwȤȤǵưޤ
ǥȥåפϸĿ̾ΥȤǵư
ƤꡤΤޤޤǤwwwȤβ̤
ɽϤǤޤwwwȤX
ɥɽǤ褦ˡιԤƼ˥ۡ
ǥ쥯ȥˤXɥե
*.xinitrc*ɲäޤ

xhost +localhost

localhostXɥؤɽ
ĤΤǤ

--ꥹ18 .xinitrc
# allow from localhost
xhost +localhost
  
# unclutter ϰưʤ򱣤ץǤ
exec unclutter &

# ᡼Τ餻 :-9
exec xmascot -degree 15 -geometry +10+4 &
--
  ʾ꤬ޤApacheư
ǧơmozilla
*http://localhost/tvrec/index.php*³
ߤޤ礦2β̤ɽ줿饤󥹥ȡ
ϴλǤ
