I am desperately trying to install the sdk on bazzite, but that turned out to be way harder than I imagined. I now am hoping someone here will be able to help me. I am a novice developer, but did manage to create a game, this development started on windows, and continued on ubuntu (when I switched OS on my laptop). I recently bought a Legion GO running bazzite, and wanted to make this my primary machine. So it turns out bazzite is containerized? Which means it's hard to install stuff. I found some old posts here talking about making a flatpak, is that still in development? Will it release soon? I was also pointed in the direction of distrobox, but the installations simply won't work for me. Has anyone here installed it this way, and would you be so kind as to help me with a step by step guide?
This is the output I get when I try to install using distrobox (ubuntu):
Sudo ./setup.sh
Creating desktop files...
./setup.sh: line 49: desktop-file-install: command not found
Creating mime info...
./setup.sh: line 55: xdg-mime: command not found
./setup.sh: line 61: xdg-icon-resource: command not found
./setup.sh: line 62: xdg-icon-resource: command not found
./setup.sh: line 63: xdg-icon-resource: command not found
./setup.sh: line 64: xdg-icon-resource: command not found
./setup.sh: line 66: update-desktop-database: command not found
Setting udev rule...
cp: cannot create regular file '/etc/udev/rules.d/': No such file or directory
./setup.sh: line 71: udevadm: command not found
./setup.sh: line 72: udevadm: command not found
Hello! I’m currently trying to get the SDK installed myself. I’m trying to install right on top of the Bazzite / Fedora Atomic image though. For starters, you can use brew to install the missing packages:
I am now however stuck on the next bit. Running sudo ./setup.sh presents me with:
sudo ./setup.sh
[sudo] password for fletch:
Creating desktop files...
cp: cannot create regular file '/usr/share/icons/hicolor/scalable/apps/date.play.simulator.svg': Read-only file system
Error on file "/tmp/date.play.simulator.desktop": Failed to create file “/usr/share/applications/date.play.simulator.desktop.9CQWE3”: Read-only file system
Creating mime info...
xdg-mime: No writable system mimetype directory found.
xdg-icon-resource: No writable system icon directory found.
xdg-icon-resource: No writable system icon directory found.
xdg-icon-resource: No writable system icon directory found.
xdg-icon-resource: No writable system icon directory found.
The databases in [/usr/local/share/applications, /usr/share/applications] could not be updated.
Setting udev rule...
cp: cannot create regular file '/usr/share/mime/packages/playdate-types.xml': Read-only file system
I/O error : Read-only file system
I/O error : Read-only file system
Failed to write XML file; For permission problems, try rerunning as root
Tip:
Make sure `PLAYDATE_SDK_PATH` env value is set to the SDK path for development.
See the Inside Playdate documentation for more details.
Done.
This is because Bazzite restricts write-access to certain system-level directories. I’m currently noodling on how to open up those restrictions. Will ping back once I have more info!
As far as I know, the setup script basically just sets up desktop file associations - the tools themselves should work fine without any of that as long as the PLAYDATE_SDK_PATH env var is set to wherever you unzipped the package
Copy <PlaydateSDK Folder>/Resources/date.play.simulator.svg to ~/.local/share/icons/hicolor/scalable/apps/date.play.simulator.svg
Copy <PlaydateSDK Folder>/Resources/50-playdate.rules to /etc/udev/rules.d/50-playdate.rules
Open a terminal and run update-desktop-database. You might see an error message, but don't worry too much about that. You can open your start menu and search for "Simulator" to see if it installed correctly.
In the terminal, run brew install libgudev and wait for installation to complete.
In the terminal, run the following (you may need to sudo these commands)
udevadm control --reload-rules
udevadm trigger
Open ~/.bash_profile and at the bottom of the file, add (and update the path of course!):
export PLAYDATE_SDK_PATH=/path/to/PlaydateSDK
In the terminal, run source ~/.bash_profile. You can check the environment variable was set properly by running echo $PLAYDATE_SDK_PATH.
And that's basically it! You won't get the mimetype information (double-clicking a .pdx.zip to open the simulator) but all of the CLI tools like pdc should work and you'll get a nice desktop application & icon to pin to taskbar or whatever.
Steps 6-9 are the most important bit of this guide. You need to update the udev rules to allow your PC to access the Playdate USB device, and obviously you have to set the PLAYDATE_SDK_PATH.
These steps should work for most Linux distros (change brew install libgudev to use the package manager for your distro - dnf, apt, pacman, etc). Happy development!
When launching the Simulator, if you get an error like:
PlaydateSimulator: error while loading shared libraries: libwebkit2gtk-4.0.so.37: cannot open shared object file: No such file or directory
You'll need to install libwebkit2gtk-4.1.so.0. On Bazzite, dnf isn't allowed. Unfortunately, for the life of me, I can't find in my bash history how I resolved this issue, but these forums might be a good starting point for your search: