I got it now, I will update script to 10G, thank you. One question regarding this, are you using rpi4 or another hardware?
I just tried copying and pasting your script above and it worked fine for me, weird indeed.
I got it now, I will update script to 10G, thank you. One question regarding this, are you using rpi4 or another hardware?
I just tried copying and pasting your script above and it worked fine for me, weird indeed.
Hello Marxon,
Thank you very much for your feedback. I just fixed step 5 on procedure but I didn't find the same issue on the script. What is killing me is that it should have checked that you had 9G of free space, not sure why it failed..
Besides that, let me tell you there is some extra work in progress for some cores (ie: scummvm) that needs shared libraries not present in LibreElec, I already found a way to make it work, just need to put all together.
Andres.-
Hello fellas!
I was posting when this thread got suggested, I get both working together by this way:
Hope it help you too!
I have been a fan of both distros, LibreElec and Lakka, it's time to have the best of both worlds in one place, I want to have my cake and eat it too.
Teorically, this should work for all architectures, I focused on my rpi4 aarch64.
It totally can be an addon with a helper, I spent a whole day making it work this way described below, right now, I just want to enjoy it. =D
UPDATE: I realized that all tools needed were present ar LibreElec image so I wrote the script below to get it working easily.
NOTE: Keep a keyboard at hand to configure joystick first time you run it.
NOTE: Share a download directory with zachmorrris IAGL addon to get games.
NOTE: Published at: https://github.com/basilean/retroarch_install
One line install:
wget -q -O - https://raw.githubusercontent.com/basilean/retroarch_install/refs/heads/main/retroarch_install.sh | bash
DISCLAIMER: Take a time to read and understand each step, most of the commands used needs to run as root, that means you can criple your PC if done wrong.
1. Download LibreElec image and install it on an SD as usual.
NOTE: Change the image version to your like.
wget https://releases.libreelec.tv/LibreELEC-RPi4.aarch64-12.0.2.img.gz
gunzip LibreELEC-RPi4.aarch64-12.0.2.img.gz
WARNING: Make sure "/dev/mmcblk0" is the SD target. Change it yo suit you.
dd if=LibreELEC-RPi4.aarch64-12.0.2.img of=/dev/mmcblk0 bs=4M
WARNING: Be sure IO transfer is done, await for "sync" command to return.
sync
2. Boot new sd card in the target device. Once Kodi is up, just power it off, remove the card and insert it back in the PC.
NOTE: This is needed to get "storage" resized in the first boot.
3. Download Lakka image and mount it
NOTE: Change the image version to your like, just match architecture with LibeElec and try to be close on release dates.
https://nightly.builds.lakka.tv/6.x/2025-02-07/RPi4.aarch64/Lakka-RPi4.aarch64-6.x-20250207-0af7dae.img.gz
gunzip Lakka-RPi4.aarch64-6.x-20250207-0af7dae.img.gz
Create mount points.
mkdir /media/flash
mkdir /media/root
WARNING: Make sure /dev/loop0 and /dev/loop1 are the targets or change them. Command "losetup" will return assigned loop for each file.
Mount "Lakka" source (flash),
losetup --show -P -f Lakka-RPi4.aarch64-6.x-20250207-0af7dae.img
mount /dev/loop0p1 /media/flash
From there, mount "SYSTEM" source (rootfs)
losetup --show -f /media/flash/SYSTEM
mount /dev/loop1 /media/root
4. Copy retroarch Lakka components into kodi LibreElec "/storage" filesystem.
Create a mount point.
mkdir /media/storage
WARNING: Make sure "/dev/mmcblk0p2" is the SD target partition. Change it to suit you.
Mount SD card "storage" partition target.
mount /dev/mmcblk0p2 /media/storage
Copy binary (72M).
cp -a /media/root/usr/bin/retroarch /media/storage/retroarch
Copy assets (806M).
cp -a /media/root/usr/share/retroarch /media/storage/.config/retroarch
Copy cores (4.9G).
cp -a /media/root/usr/lib/libretro /media/storage/.config/retroarch/cores
LibRetro Database (684M).
cp -a /media/root/usr/share/libretro-database /media/storage/.config/retroarch/database
Filters (3M)
mkdir /media/storage/.config/retroarch/filters
cp -a /media/root/usr/share/video_filters /media/storage/.config/retroarch/filters/video
cp -a /media/root/usr/share/audio_filters /media/storage/.config/retroarch/filters/audio
WARNING: Be sure IO transfer is done, await for "sync" command to return.
sync
5. Create a retroarch systemd unit.
NOTE: kodi.conf has HOME definition used by retroarch.
vi /media/storage/.config/system.d/retroarch.service
[Unit]
Description=Retroarch
After=network-online.target graphical.target
Requires=graphical.target
Wants=network-online.target
[Service]
EnvironmentFile=/usr/lib/kodi/kodi.conf
ExecStartPre=systemctl stop kodi
ExecStart=/storage/retroarch/retroarch
ExecStopPost=systemctl start kodi
TimeoutStopSec=10
Restart=no
StartLimitInterval=0
LimitNOFILE=16384
[Install]
WantedBy=kodi.target
Display More
Reload systemd and disable retroarch service. It only is going to run when swaps with kodi.
systemctl daemon-reload
systemctl disable retroarch
6. Create a wrapper script.
vi /media/storage/retroarch.py
from xbmc import executebuiltin
from subprocess import run
executebuiltin('Notification(Retroarch, Loading..., 5000, /storage/.config/retroarch/assets/xmb/monochrome/png/retroarch.png)')
run(["/usr/bin/systemctl", "start", "retroarch"])
7. Create a shortcut in favourites
vi /media/storage/.kodi/userdata/favourites.xml
<favourites>
<favourite name="RetroArch" thumb="/storage/.config/retroarch/assets/xmb/monochrome/png/retroarch.png">RunScript(/storage/retroarch.py)</favourite>
</favourites>
8. Clear all mounted filesystems and used devices.
umount /media/storage
umount /media/root/
losetup -d /dev/loop1
umount /media/flash/
losetup -d /dev/loop0
every Youtube App uses API Keys, thats nothing new
API keys are the gold standard at those services
One thing is an api key to identified application that consumes service... this is complete different... we are talking a personal (user) key that would enable google to track your privacy (searches, videos you reproduce, etc).
This practice attempts freedom, I'm not sure why you try to make it looks as it were ok.
Hi basilean,
did you finally find a way to get youtube working without personal API keys?
I would be interessted as well!
Mat
Hey Mat,
Nope, I just quit using youtube through xbmc. I don't feel comfortable using a plugin that lets google to know about usage and link it to my user.
The answers pointing to git howto, makes it clear you have to login into google in order to create keys so really it doesn't solve my question.
I really hope this doesn't become a standard where people develops plugins that serves companies hidden interests.
Hello CvH,
Yes, I know, my point is that using a pool of share keys as it was before, they know you are using a specific app but not who you are.
So, I'm just another guy using kodi or samsung app, even so, if they created a unique serial, I just a number and not a specific person.
That is basic anonymous that I'm asking for that is not fulfilled if I create a key related to my user.
Andres.-
Hello donbrew,
What you said only applies to an android phone.
Using a browser or even on samsung tv client, I don't need to [login|create keys] to watch videos.
While probably they create a random serial to keep track and collect on both, using a VPN, I would be just another unknown, not giving them chance to relate it to my user (becoming paranoid that they are relating IP, UA, cookie and/or another method to get you).
As I stated before, it is a matter of privacy, I appreciate freedom.
Andres.-
Hello cdu13a,
Thank you for your reply but to be truth, we don't really know what google tracks and collects, actually, I think they are better ways to avoid abusing without needing personal keys.
I'm just looking for a better way than creating a fake account just for these keys.
Andres.-
Hello guys,
Like everyone, I found youtube addon is not working anymore without a registered API.
I already read this thread and I have not doubts on how to create personal keys: YouTube Plug-in Thread
I'm not a paranoid guy but kinda like my privacy so my question is:
Do I need to link these keys to a valid google account or is it a workaround to use it anonymous like in my browser?
Thank you in advance.
Andres.-
Hello guys,
Libretro stop working, I'm just getting logs:
ERROR: Add-on 'game.libretro' is not compatible with Kodi
I tried removing "import" lines on addon.xml just to try something but no luck.
I'm using latest: #0203, 03-Feb-2020 but I noticed this few months back.
Any advice or hack to make it work again?
Thank you in advance.
Hey man, I repeated process today, I just needed to comment SHA256 line and it worked like a champ. Original post updated.
Forgot to tell you, also remember to update autostart.sh to new kernel modules location, IE:
cat /storage/.config/autostart.sh
(
cp -v /storage/.config/hid-xpadneo.ko /lib/modules/5.2.0/kernel/drivers/hid/
depmod
) &
Hello guys,
First at all, I love LibreELEC, best mmc ever, thank you very much!
I tried to reply back soon but looked some issue on registration so I'm not sure if xpadneo support was already addressed.
If not, I wrote this recipe to get it working.
apt install gcc make git unzip wget xz-utils wget bash bc gcc sed patch patchutils tar bzip2 gzip perl gawk gperf zip unzip diffutils lzop libc6-dev libncurses5-dev libjson-perl
git clone https://github.com/LibreELEC/LibreELEC.tv.git
cd LibreELEC.tv/
mkdir packages/linux-drivers/xpadneo
vi packages/linux-drivers/xpadneo/package.mk
PKG_NAME="xpadneo"
PKG_VERSION="master"
#PKG_SHA256="6626c55eeb13a0608a68209f7da29efb11a841aa443bab4d4bef5db8dc04d33d"
PKG_LICENSE="GPL"
PKG_SITE="https://github.com/atar-axis/xpadneo"
PKG_URL="https://github.com/atar-axis/xpadneo/archive/master.zip"
PKG_DEPENDS_TARGET="toolchain linux"
PKG_NEED_UNPACK="$LINUX_DEPENDS"
PKG_LONGDESC="Advanced Linux Driver for Xbox One Wireless Gamepad"
PKG_IS_KERNEL_PKG="yes"
PKG_TOOLCHAIN="manual"
make_target() {
kernel_make -C $(kernel_path) M=$PKG_BUILD/hid-xpadneo/src modules
}
makeinstall_target() {
mkdir -p $INSTALL/$(get_full_module_dir)/$PKG_NAME
cp $PKG_BUILD/hid-xpadneo/src/*.ko $INSTALL/$(get_full_module_dir)/$PKG_NAME
}
Display More
/sbin/modinfo build.LibreELEC-RPi2.arm-9.1-devel/xpadneo-master/hid-xpadneo/src/hid-xpadneo.ko
Quote from modinfo output...
vermagic: 5.0.13 SMP mod_unload ARMv7 p2v8
...
#0507, 07-May-2019: RPi / RPi2 -- Release post (New 5.0.13 kernel; drop omxplayer)
scp build.LibreELEC-RPi2.arm-9.1-devel/xpadneo-master/hid-xpadneo/src/hid-xpadneo.ko root@PI:/storage/.config/
vi /storage/.config/modprobe.d/xpadneo.conf
vi /storage/.config/autostart.sh
chmod 755 /storage/.config/autostart.sh
vi /storage/.config/udev.rules.d/99-xpadneo.rules
ACTION=="bind", KERNEL=="0005:045E:02FD.*|0005:045E:02E0.*", SUBSYSTEM=="hid", DRIVER=="microsoft", \
RUN+="/bin/sh -c 'echo $kernel > /sys/bus/hid/drivers/microsoft/unbind; echo $kernel > /sys/bus/hid/drivers/xpadneo/bind'"
Reboot to confirm that all works as expected and that should be all.
Keep press X button few seconds until it starts to blink and try pair it, probably you will need to remap keys, so keep a keyboard close.
Hope you find it useful.
Andres.-