When using the Generic (non-Legacy) LE, it should work like that:
Post
RE: RPi4 GPIO using in LibreELEC
I've been installed a power button and a status LED on my RPi3B+. This works for RPi4B, too. After SSH login, you can use the nano editor to create or edit all necessary files.
Power Button Hardware Part
Use GPIO03 (Pin #05) and the opposite Ground (Pin #06) to connect a push button for power on / off.
Power Button Scripting Part
Add dtoverlay=gpio-shutdown to config.txt.
Switching off will let the shutdown menu appear.
To shutdown instantly instead, create this …
Power Button Hardware Part
Use GPIO03 (Pin #05) and the opposite Ground (Pin #06) to connect a push button for power on / off.
Power Button Scripting Part
Add dtoverlay=gpio-shutdown to config.txt.
Switching off will let the shutdown menu appear.
To shutdown instantly instead, create this …
Da Flex