What can I do to make Love 2d transferable after compiling?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
XxHAMADEHxX
Prole
Posts: 19
Joined: Sun Mar 13, 2016 3:23 am

What can I do to make Love 2d transferable after compiling?

Post by XxHAMADEHxX »

Recently I had to compile Love again after an Update messed up my current Setup on my Raspberry Pi. Unfortunately it appears I cannot simply throw my compiled Love into a usb stick without it breaking(no errors or anything it just won't work). What can I do to fix this problem? Thanks friends.
User avatar
s-ol
Party member
Posts: 1077
Joined: Mon Sep 15, 2014 7:41 pm
Location: Cologne, Germany
Contact:

Re: What can I do to make Love 2d transferable after compiling?

Post by s-ol »

Nothing can be done. An executable is only valid on a system with the same architecture and relies on libraries of specific versions being available. You cannot take the love executable from an amd64 system and run it under i386 for example and generally moving executables around is very discouraged unless they are designed for that (like .exe s on windows, the format is called "Portable Executable" after all).

What you need to do is compile it on the raspi, or cross-compile it to the raspi.

s-ol.nu /blog  -  p.s-ol.be /st8.lua  -  g.s-ol.be /gtglg /curcur

Code: Select all

print( type(love) )
if false then
  baby:hurt(me)
end
bobbyjones
Party member
Posts: 730
Joined: Sat Apr 26, 2014 7:46 pm

Re: What can I do to make Love 2d transferable after compiling?

Post by bobbyjones »

You can throw it on a USB if you make sure to get all the dependencies on there as well if it was compiled for the pi anyways. There is a Linux distribution thing for love that does that as well. But anyways the pi has a love package in retropi I think it's called. So you could just install that instead
XxHAMADEHxX
Prole
Posts: 19
Joined: Sun Mar 13, 2016 3:23 am

Re: What can I do to make Love 2d transferable after compiling?

Post by XxHAMADEHxX »

s-ol wrote:Nothing can be done. An executable is only valid on a system with the same architecture and relies on libraries of specific versions being available. You cannot take the love executable from an amd64 system and run it under i386 for example and generally moving executables around is very discouraged unless they are designed for that (like .exe s on windows, the format is called "Portable Executable" after all).

What you need to do is compile it on the raspi, or cross-compile it to the raspi.
I want to transfer it between different raspberry pis or keep it as a back up if my pi fails again.

You can throw it on a USB if you make sure to get all the dependencies on there as well if it was compiled for the pi anyways. There is a Linux distribution thing for love that does that as well. But anyways the pi has a love package in retropi I think it's called. So you could just install that instead
????
User avatar
pgimeno
Party member
Posts: 3674
Joined: Sun Oct 18, 2015 2:58 pm

Re: What can I do to make Love 2d transferable after compiling?

Post by pgimeno »

I'm puzzled. If it misses libraries, which is what I'd look into first, it should spit some error on a terminal.

Maybe you're not executing it from a terminal?
XxHAMADEHxX
Prole
Posts: 19
Joined: Sun Mar 13, 2016 3:23 am

Re: What can I do to make Love 2d transferable after compiling?

Post by XxHAMADEHxX »

Ok one detail I left out. When I first transfered the files it said file system does not support symbolic links. After I reformatted the usb to NTFS and tried again that error did not pop up again. (I just went back to fat32 and the error came back)

Now when running Love itself I either get a "permission denied" error or if I use sudo(keep in mind this is only for the files on the flash drive) I get "./love command not found"

I'm starting to thing maybe I need to reformat the USB to ext4?

Thanks friends
bobbyjones
Party member
Posts: 730
Joined: Sat Apr 26, 2014 7:46 pm

Re: What can I do to make Love 2d transferable after compiling?

Post by bobbyjones »

I will clarify my admittedly cryptic reply.

In order to build love and have it run on the pi from a USB stick you need to have it compiled on the pi. You also need to include all of the packages and libraries required for love

For example Like they do here https://bitbucket.org/funkeh/love-linux ... n/overview

But all of that is pointless because you do not even have to build it because someone else has already done it for you.
https://github.com/retropie/retropie-setup/wiki/Love
Hopefully I was much more clear than before.
Post Reply

Who is online

Users browsing this forum: Amazon [Bot], Bing [Bot] and 15 guests