Fitzcarraldo wrote:But there still remains the question I asked previously: Why does lirc-0.9.0_pre1.ebuild not generate /etc/init.d/lircd and /etc/conf.d/lircd in my case? I'd like to know, even though I now know how to work around it.
I have found out the reason: my stupidity!
cloc3 wrote:when I prepare a local overlay, I always copy the original $FILEDIR from portage. that's may it be the difference betwen us.
cloc3 was correct all along. I built lirc-0.9.0_pre1 in a local overlay on a laptop to test the ebuild. On that laptop I had copied the contents of /usr/portage/app-misc/lirc/files/ to /usr/local/portage/app-misc/lirc/files/. It worked. But on the ASRock ION 330HT I thought I had done it but had not. Doh!
The merge works as it should, now:
- Code: Select all
# # Double-check what is on my ASRock ION 330HT:
#
# # Check what is in the ebuild directory of lirc in main tree:
# ls /usr/portage/app-misc/lirc/
ChangeLog files lirc-0.8.5.ebuild lirc-0.8.7.ebuild lirc-0.8.7_pre1.ebuild Manifest metadata.xml
#
# # Check what is in the ebuild files directory of lirc in main tree:
# ls /usr/portage/app-misc/lirc/files
irexec-confd irexec-initd-0.8.6-r2 lirc-0.8.4-portaudio_check.patch lircd-0.8.3 lircd.conf.2 modprobed.lirc
irexec-initd lirc-0.8.3_pre1-remotewonderplus.patch lirc-0.8.6-send-evsyn.diff lircd-0.8.6 lircmd modulesd.lirc
#
# # Check what is in the ebuild directory of lirc in local overlay:
# ls /usr/local/portage/app-misc/lirc/
files lirc-0.9.0_pre1.ebuild Manifest
#
# # Check what is in the ebuild files directory of lirc in local overlay:
# ls /usr/local/portage/app-misc/lirc/files/
lirc-0.8.3_pre1-remotewonderplus.patch lirc-0.8.4-portaudio_check.patch
#
# # Copy files from main tree files directory to local overlay files directory:
# cp /usr/portage/app-misc/lirc/files/* /usr/local/portage/app-misc/lirc/files/
# ls /usr/local/portage/app-misc/lirc/files/
irexec-confd irexec-initd-0.8.6-r2 lirc-0.8.4-portaudio_check.patch lircd-0.8.3 lircd.conf.2 modprobed.lirc
irexec-initd lirc-0.8.3_pre1-remotewonderplus.patch lirc-0.8.6-send-evsyn.diff lircd-0.8.6 lircmd modulesd.lirc
#
# # Now generate the manifest and build lirc
# cd /usr/local/portage/app-misc/lirc
# ebuild lirc-0.9.0_pre1.ebuild manifest
>>> Creating Manifest for /usr/local/portage/app-misc/lirc
# emerge -1v =lirc-0.9.0_pre1
# etc-update
Scanning Configuration files...
The following is the list of files which need updating, each
configuration file is followed by a list of possible replacement files.
1) /etc/conf.d/lircd (1)
2) /etc/init.d/lircd (1)
Please select a file to edit by entering the corresponding number.
(don't use -3, -5, -7 or -9 if you're unsure what to do)
(-1 to exit) (-3 to auto merge all remaining files)
(-5 to auto-merge AND not use 'mv -i')
(-7 to discard all updates)
(-9 to discard all updates AND not use 'rm -i'): -3
Replacing /etc/conf.d/lircd with /etc/conf.d/._cfg0000_lircd
mv: overwrite `/etc/conf.d/lircd'? y
Replacing /etc/init.d/lircd with /etc/init.d/._cfg0000_lircd
mv: overwrite `/etc/init.d/lircd'? y
Exiting: Nothing left to do; exiting. :)
#
# # Check if initscript and config file were created this time:
# ls -la /etc/init.d/lircd
-rwxr-xr-x 1 root root 973 Mar 23 12:11 /etc/init.d/lircd
asrockion330ht lirc # ls -la /etc/conf.d/lircd
-rw-r--r-- 1 root root 317 Mar 23 12:11 /etc/conf.d/lircd
asrockion330ht lirc # date
Wed Mar 23 12:16:45 GMT 2011
#
# # They were. So edit config file to specify correct device:
# cat /etc/conf.d/lircd | grep lirc0
#LIRCD_OPTS="-d /dev/lirc0"
# nano /etc/conf.d/lircd
# cat /etc/conf.d/lircd | grep lirc0
LIRCD_OPTS="-d /dev/lirc0"
#
# # Now test latest version of daemon to see if it works:
# /etc/init.d/lircd stop
* Caching service dependencies ... [ ok ]
* Stopping lircd ... [ ok ]
# /etc/init.d/lircd start
* Starting lircd ...
#
# # It does.
#
EDIT (Wed Mar 23 15:07:21 GMT 2011): Another thing. I forgot to mention that the only modules I need to have loaded are are follows:
- Code: Select all
# lsmod | grep nuvoton
nuvoton_cir 10306 0
ir_core 10299 3 ir_lirc_codec,nuvoton_cir
# lsmod | grep lirc
ir_lirc_codec 2744 3
lirc_dev 6614 1 ir_lirc_codec
ir_core 10299 3 ir_lirc_codec,nuvoton_cir
- Code: Select all
# lsmod | grep lirc
ir_lirc_codec 2744 3
lirc_dev 6614 1 ir_lirc_codec
ir_core 10299 9 ir_lirc_codec,ir_sony_decoder,rc_rc6_mce,ir_jvc_decoder,ir_rc6_decoder,ir_rc5_decoder,ir_nec_decoder,nuvoton_cir
# rmmod ir_sony_decoder
# rmmod ir_jvc_decoder
# rmmod ir_nec_decoder
# rmmod ir_rc5_decoder
# rmmod ir_rc6_decoder
# rmmod rc_rc6_mce
# lsmod | grep lirc
ir_lirc_codec 2744 3
lirc_dev 6614 1 ir_lirc_codec
ir_core 10299 3 ir_lirc_codec,nuvoton_cir
If the rc6 modules are loaded then, as
cloc3 discovered, when you press some of the keys on the remote you get double presses, because the nuvoton driver and the rc6 driver are both issuing a keypress.
EDIT (Sat Mar 26 17:04:03 GMT 2011): Yet another thing I forgot to mention. I found that the file /usr/share/xbmc/system/Lircmap.xml needs to have the following contents:
- Code: Select all
<!-- This file contains the mapping of LIRC keys to XBMC keys used in Keymap.xml -->
<!-- -->
<!-- How to add remotes -->
<!-- <remote device="name_Lirc_calls_the_remote"> -->
<!-- -->
<!-- For the commands the layout following layout is used -->
<!-- <XBMC_COMMAND>LircButtonName</XBMC_COMMAND> -->
<!-- -->
<!-- For a list of XBMC_COMMAND's check out the <remote> sections of keymap.xml -->
<lircmap>
<remote device="nuvoton-cir">
<obc148>Topleft</obc148>
<play>Play</play>
<pause>Pause</pause>
<stop>Stop</stop>
<forward>Forward</forward>
<reverse>Rewind</reverse>
<left>Left</left>
<right>Right</right>
<up>Up</up>
<down>Down</down>
<select>OK</select>
<pageplus>ChanUp</pageplus>
<pageminus>ChanDown</pageminus>
<back>Back</back>
<menu>PreviousMenu</menu>
<title>Guide</title>
<livetv>LiveTV</livetv>
<info>More</info>
<skipplus>Skip</skipplus>
<skipminus>Replay</skipminus>
<display>Teletext</display>
<start>Home</start>
<record>Record</record>
<volumeplus>VolUp</volumeplus>
<volumeminus>VolDown</volumeminus>
<mute>Mute</mute>
<power>Power</power>
<myvideo>Videos</myvideo>
<mymusic>Music</mymusic>
<mypictures>Pictures</mypictures>
<mytv>TV</mytv>
<one>One</one>
<two>Two</two>
<three>Three</three>
<four>Four</four>
<five>Five</five>
<six>Six</six>
<seven>Seven</seven>
<eight>Eight</eight>
<nine>Nine</nine>
<zero>Zero</zero>
<star>Star</star>
<hash>Hash</hash>
<clear>Clear</clear>
<enter>Enter</enter>
<red>Red</red>
<green>Green</green>
<yellow>Yellow</yellow>
<blue>Blue</blue>
</remote>
</lircmap>
EDIT (Sat Mar 26 21:14:03 GMT 2011): For Entropy users, add LIRC to /etc/entropy/packages/package.mask so that Entropy does not overwrite the LIRC that you had to install via Portage:
- Code: Select all
echo "app-misc/lirc" >> /etc/entropy/packages/package.mask