Hey, I'm having trouble creating an exe file for my game. I have this:
copy /b "C:\Program Files (x86)\LOVE\love.exe"+Game.love Game.exe
...But when I try to run the executable it creates, it gives the following error:
The application was unable to start correctly (0xc000007b) Click OK to close the application.
But if I drag the executable onto the shortcut to love.exe, it runs fine. I have the executable with all of the required DLLs. Any help here? Am I doing something wrong?
Trouble packaging as an executable
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Re: Trouble packaging as an executable
I'll shamelessy copy my old post:
---
There are several mistakes in your .bat file:
---
- Open notepad
- Paste this:
Code: Select all
@echo off copy /b love.exe+yourloveprojectnamehere.love yourexecutableloveprojectnamehere.exe pause
- Save as test.bat (Well, basically you can you use any name, but it must end with .bat)
- Go to folder you downloaded (or un-archived) love.
- Copy love.exe and all the .dll 's to the folder with your love project
- Launch your .bat file
- Enjoy your fresh executable
There are several mistakes in your .bat file:
- AFAIK, in batch files you provide a directory to a file inside a folder with .bat file
- You don't need to use quotation marks in describing a directory
Re: Trouble packaging as an executable
In .bat files you can use relatives and absolute paths, and you HAVE to use quotation marks if the path of the directory has spaces
lf = love.filesystem
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
Re: Trouble packaging as an executable
Ok, I didn't know that.Nixola wrote:In .bat files you can use relatives and absolute paths, and you HAVE to use quotation marks if the path of the directory has spaces
Yet it's strange that nothing worked.
This is my folder setup: and this is what in genexe.bat:
Code: Select all
@echo off
copy /b love.exe+cube.love cube.exe
pause
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Trouble packaging as an executable
I think the problem is in fact, that he's doing it from another dir. But nothing command-wise, it's just that the dll's are needed as well.
Re: Trouble packaging as an executable
I was going to say the same thing.bartbes wrote:I think the problem is in fact, that he's doing it from another dir. But nothing command-wise, it's just that the dll's are needed as well.
Unfortunately due to licensing issues the DLL's cannot be statically linked into the exe. You'll have to ship them all with your game. I think the DLL's are for SDL, OpenAL, and DevIL. All of these libraries are LGPL, which conflicts with Love's license.
Who is online
Users browsing this forum: Google [Bot] and 8 guests