Open Jammyjamjamman opened 4 years ago
* Get rid of feathery ftp and either replace it with curl (which is already a dependency to MegaGlest) or get rid of ftp entirely in the code.
Right now, feathery is used as an ftp server to serve maps, mods, etc, and curl is used to download. Is that right?
I was just reading through the libcurl docs a little, and see that it can be used to transfer data to and from a server, but I don't get the impression it can be used as a "server", even though it can send. So basically, if the client were using curl to retrieve a file from an MG host, the MG host could not send it with curl.
Some comments about it and a few options for http server libs at
Right now, feathery is used as an ftp server to serve maps, mods, etc, and curl is used to download. Is that right?
I am convinced this is correct.
I was just reading through the libcurl docs a little, and see that it can be used to transfer data to and from a server, but I don't get the impression it can be used as a "server", even though it can send. So basically, if the client were using curl to retrieve a file from an MG host, the MG host could not send it with curl.
I agree. I'm convinced that libcurl does not implement any HTTP or FTP servers nor does it provide functionality for this purpose. You can use the HTTP (and likely also FTP) client code it provides to have a client send data (HTTP POST, FTP upload) to a server, but this is not relevant here, a MegaGlest instance hosting a game needs to host file downloads for connected game clients.
Some comments about it and a few options for http server libs at
More small footprint HTTP servers could probably be found in Debian, or using a web search engine looking for, e.g.
( "http server" OR "httpd" ) AND ( small OR tiny OR minimal OR micro )
Replacing the FTP server code by HTTP server code would not entirely overcome the need for port forwarding, but would make things less terrible. HTTP downloads need exactly one port forwarded (or two at most if you do HTTP+HTTPS).
This said, there are certainly more pressing issues in MegaGlest, if it is to live much longer, such as a need for IPv6 support.
Related: MegaGlest is going to be removed off Debian because it fails to build from source (FTBFS):
megaglest 3.13.0-5 is marked for autoremoval from testing on 2020-09-01
It is affected by these RC bugs: 966892: megaglest: FTBFS: ld: ../shared_lib/liblibmegaglest.a(ftpAccount.c.o):./obj-x86_64-linux-gnu/source/shared_lib/./source/shared_lib/include/feathery_ftp/ftpTypes.h:84: multiple definition of `ftpIsClientAllowedToGetFile'; /usr/bin/ld: DWARF error: could not find variable specification at offset f7c1 https://bugs.debian.org/966892
I am on the other side of Canada this week, would you guys want me to get these issues fixed next week?
-- Edit: Removed quote + promotional message
Fixed how? But certainly any fix you can provide would be great to have!
I will try to look at fixing the issues next week so that it won't get pulled
-- Edit: Removed quote + promotional message
@softcoder , @Jammyjamjamman committed the feathery_ftp fix in https://github.com/MegaGlest/megaglest-source/commit/5a3520540276a6fd06f7c88e571b6462978e3eab and I've got a PR that adds a test for building with g++-10 (rebased after the feathery patch).
Ok so what remains to be fixed?
-- Edit: Removed quote + promotional message
In order to build on Debian testing/bullseye? I think that's it. As for Debian Sid, there's issue #196. Though #198 could be a problem soon as well.
As @tomreyn stated about feathery in #197 :
Our options for feathery are therefore: