Page 1 of 1

How can i compile the engine lib's as 1 static exe?

Posted: Mon Apr 30, 2018 6:46 am
by umen
Hello all
i pulled the source code and compiled it successfully in windows all fine.
my question is how can i compile all the current dll's as 1 static executable ?
didn't found any static flags or info in the documents

Re: How can i compile the engine lib's as 1 static exe?

Posted: Mon Apr 30, 2018 8:39 am
by zorg
You can't, legally. Read up on what the licences of some of the required libraries allow or not; some don't allow static linking, hence all the dll files.

Also why do people found this to be such an eyesore? I'm genuinely curious, since there's no issue with accidentally running the dll-s instead of the executable, and since löve can come in a zip, you don't even need the installer

Re: How can i compile the engine lib's as 1 static exe?

Posted: Mon Apr 30, 2018 8:49 am
by umen
i see, you mean some of them are LGPL i guess
Thanks !
is there list of libraries the engine is using and the licenses ?
or should i check manually ?

Re: How can i compile the engine lib's as 1 static exe?

Posted: Mon Apr 30, 2018 9:58 am
by pgimeno
zorg wrote: Mon Apr 30, 2018 8:39 am You can't, legally. Read up on what the licences of some of the required libraries allow or not; some don't allow static linking, hence all the dll files.
This is often repeated in the forums, but it is not correct. You may also opt to offer the rebuild instructions and the source, or a pointer to them. The point of the LGPL is that anyone can replace the library if they wish. Section 6 of the LGPL 2.1 says that "you must do one of these things", where the offering as a dynamic library is point (b) in the list, but points (a), (c), (d) and (e) deal with the above. In fact, point (b) is new in LGPL 2.1; it didn't exist in 2.0 which is the version some of the libs are licensed under.

umen wrote: Mon Apr 30, 2018 6:46 am Hello all
i pulled the source code and compiled it successfully in windows all fine.
my question is how can i compile all the current dll's as 1 static executable ?
didn't found any static flags or info in the documents
I build with ./configure --disable-shared --enable-static. It doesn't link all libraries as static, though, and I don't know what it will do in Windows. It does link liblove statically. YMMV. Under Linux, you have to manually add -lpthread to the linking command.

umen wrote: Mon Apr 30, 2018 8:49 am i see, you mean some of them are LGPL i guess
Thanks !
is there list of libraries the engine is using and the licenses ?
or should i check manually ?
Check license.txt

Re: How can i compile the engine lib's as 1 static exe?

Posted: Mon Apr 30, 2018 10:19 am
by umen
Thanks !