cxong / cdogs-sdl

Classic overhead run-and-gun game
https://cxong.github.io/cdogs-sdl/
GNU General Public License v2.0
887 stars 114 forks source link

Create deb package #89

Closed cxong closed 5 years ago

cxong commented 11 years ago

Also:

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

carstene1ns commented 10 years ago

Okay, debian(/ubuntu/mint...) packages should be possible with https://github.com/carstene1ns/cdogs-sdl/compare/cpackdebrpm. Only thing missing would be to test them in a fresh ubuntu lts installation. If it does not work, maybe a explicit dependency on libc6 has to be added.

cxong commented 9 years ago

Just tried installing the package on Linux Mint, this is what I got:

Reading package lists... Done Building dependency tree
Reading state information... Done Building data structures... Done Building data structures... Done Traceback (most recent call last): File "/usr/bin/gdebi", line 87, in if not debi.open(args[0]): File "/usr/share/gdebi/GDebi/GDebiCli.py", line 88, in open if not self._deb.check(): File "/usr/lib/python2.7/dist-packages/apt/debfile.py", line 484, in check if not self._satisfy_depends(self.depends): File "/usr/lib/python2.7/dist-packages/apt/debfile.py", line 290, in depends depends.extend(apt_pkg.parse_depends(self._sections[key])) ValueError: Problem Parsing Dependency

No idea what that means

carstene1ns commented 9 years ago

Seems like I forgot a comma to separate the debian dependencies. :tired_face: So it parses libc6 libsdl-image1.2 as a package name and fails.

HEXcube commented 9 years ago

Playdeb has already produced cdogs-sdl deb packages and is available for current Ubuntu releases. See the packaging data for cdogs-sdl at Playdeb's github repo. I've installed and tested the package on my Ubuntu 14.04LTS and it runs fine. This game really deserves to be on the Debian repo. You guys should submit the package for inclusion in Debian. Once it's made its way into Debian, it'll automatically be syncd into all derivative distros (including Ubuntu! ).

cxong commented 9 years ago

Thanks for the info @HEXcube ! Looks like some changes to CMakeLists.txt are required (https://github.com/ckorn/PlayDeb/blob/trusty/cdogs-sdl/patches/install.patch) but I'm not familiar with debian packaging, maybe @carstene1ns can help here?

As for inclusion into Debian, yes this has been an important goal for a long time, unfortunately the graphics are freeware, and not under a "debian free" license, so they probably will reject it as-is. To comply we'll need to replace all the non-free assets with free replacements. That will take time as not only is it hard to produce perfect replacements (with the right dimensions and so on), many code changes are also needed since the graphics and rendering code are tightly coupled. Those tasks are tracked here: #336

HEXcube commented 9 years ago

The package can still make it into Debian repos even if some components (game graphics in this case) are not "debian free". According to Debian Free Software Guidelines (DFSG), the proprietary components can go into non-free repo, while the free parts will go into contrib repo. I think you should try submitting cdogs-sdl into Debian right now. Later when #336 is completed and all non-free parts are replaced with free ones, Debian will change the package to the fully free main section.

cxong commented 9 years ago

@HEXcube that sounds like a good approach and would be useful even after the non-free content is replaced - the cdogs-sdl-data package can then contain only the original, non-free content for those who prefer them. It's not something I can work on right now, I'm unfamiliar with building debs and the debian submission process (do they have special requirements for submitted packages?) but I'll include these in this issue: creation of separate cdogs-sdl.deb and cdogs-sdl-data.deb plus submission to debian.

HEXcube commented 9 years ago

When all non-free content is replaced by free ones, I don't think there's any real need to keep the non-free ones. Debian does have some non-free packages in their repos, but afaik they offer some advantages over the currently available free ones. Such packages are mostly firmwares, drivers and other "can't live without" proprietary stuff. I don't know if Debian will keep a cdogs-sdl-data-nonfree package if a better open replacement is already available. Also, users tend to prefer open replacements if there's no real gain in using their proprietary equivalents. Anyway, @cxong let's not worry about that too much for now. Let's just try to get cdogs-sdl and cdogs-sdl-data in it's current state into Debian's contrib and nonfree repos.

hashar commented 6 years ago

If I got it right, one of the potential annoyance was that some sprites/graphics were not free. It seems to have been tracked by #336 which is apparently closed. So I guess it is 100% open source / libre now? :)

cxong commented 6 years ago

Yes.

I don't know how to get a package into debian though, seems like a debian maintainer needs to get involved? Help is welcome

hashar commented 6 years ago

I gave it a try tonight and went with some source code patches: #531 #532 #533

I have targeted Debian stretch for now, the very rough packaging is at:

https://github.com/hashar/cdogs-sdl/tree/debian

The patches from the above pull requests are pilled in a different branch https://github.com/hashar/cdogs-sdl/tree/patch-queue/debian . I then use gbp pq to regenerate debian/patches in the debian branch.

I got it installed and managed to play a little bit :]

Uploading to debian.org would surely be the end goal, but that is really the very last step. We can look at polishing a package and I am willing to help. Then on top of my head we want:

hashar commented 6 years ago

Additional note: the debian packaging work might be done on Debian infrastructure. They have several teams per area of interest/technology, and they will then be able to assist with the maintenance.

For example https://wiki.debian.org/Games/Development

hashar commented 6 years ago

531 #532 #533 have all be merged (thank you!)

I am digging in the files to write a proper debian/copyright, it is going to take a while though.

Seems some sounds have been scrapped from movies or games, that might well be an issue :-( But I am not a lawyer. I will send more pull requests to tweak the copyright notices here and there.

cxong commented 6 years ago

Thanks; to my knowledge the scraped sounds have all been removed, all the current ones can be accounted for but it may not be obvious. Let me know if you're unsure about any specific assets.

Most assets have a text file with a similar file name that track where they were obtained and their license. Some graphics are authored by Ronny Wester for the original C-Dogs game; there's a list at https://github.com/cxong/cdogs-sdl/blob/master/graphics/originals.txt, all are under CC-BY 3.0 If not specified, then the author should be myself, license CC0.

For the custom missions, the ones authored by sauer2 should all be CC0.

cxong commented 5 years ago

Should probably move towards package managers like flatpak/snap