bennugd @ FreeBSD

Started by AMDmi3, November 08, 2009, 03:58:25 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

AMDmi3

Hi!

Just wanted to report that bennugd compiles and runs successfully on FreeBSD, I was able to compile and run Railroad Rampage game. I've also added bennugd to FreeBSD ports collection (http://www.freshports.org/devel/bennugd-core/, http://www.freshports.org/devel/bennugd-modules/). There are, however, some fixes/improvements I'd like to share.

First, there is a bunch of patches: http://amdmi3.ru/files/bgd/.
patch-bgdrtm-src-dirs.c and patch-mod_mem-mod_mem.c are for core/ and modules/ respectively and are pretty straightforward ones.
patch-configure is needed for both core and modules, and addresses two problems: not defining TARGET_BSD on FreeBSD, and fixed checking for des. Not sure where your des.h comes from, but on both my FreeBSD and Linux boxes there's only openssl/des.h - the one from openssl, and DES functions there are named DES_ (des_ are macros, so these can't be used in configure checks). This fix (if applied) should be applied to configure.in, obviously. patch-include-crypt.h is the same thing.

Another change I've done for FreeBSD port is installing modules to ${PREFIX}/lib/bennugd instead of ${PREFIX}/lib. Since files there have very generic names (libtext, libmouse, libfont, mod_ as well) and are only used by bennugd, this is better than creating mess in lib/.

Also, I'd like to ask you to release source tarballs along with binaries. Most source-based packaging systems use checksums to verify distfile integrity, so they need files. For this port, I've packaged SVN snapshot of r112 myself (http://mirror.amdmi3.ru/distfiles/bennugd-r20091106.tar.gz).

Finally, I've just noticed that bgdc segfaults while compiling named Railroad Rampage on amd64. Will investigate that.

SplinterGU

really cool, thanks... I'll check your patchs and include them in official version... thanks... karma++...
Download Lastest BennuGD Release: http://www.bennugd.org/node/2

SplinterGU

please, can you do the patch for configure.ac? configure is builded from configure.ac... thanks...
Download Lastest BennuGD Release: http://www.bennugd.org/node/2

josebita

The native 64 bits version won't work, though.
It's not a matter of you using FreeBSD.

Sandman

Good job, a FreeBSD port is a wonderful thing to have, because somehow it proves to me the project is genuinely multiplatform. Of course a native Wii port does that too, but that one's not finished yet. :) Nice work on the port, patches and tips!

karma++
-- Sandman

AMDmi3

#5
Here's a patch against SVN with all my changes, including configure.in's: http://amdmi3.ru/files/bennugd-freebsd.patch. I didn't properly regenerate configure's as it produces too large patch.

Also I forgot one thing: for some reason bgdc exits with error code 1, although it compiles the game successfully. This is a problem when using it with e.g. make.


BGDC 1.0.0 (Nov  9 2009 08:32:34)
Copyright © 2006-2009 SplinterGU (Fenix/BennuGD)
Copyright © 2002-2006 Fenix Team (Fenix)
Copyright © 1999-2002 José Luis Cebrián Pagüe (Fenix)
Bennu Game Development comes with ABSOLUTELY NO WARRANTY;
see COPYING for details

/usr/home/amdmi3/projects/freebsd/ports/games/railroad-rampage/work/RailroadRampage_Linux/librender:0: warning: Variable redeclared ("ALPHA_STEPS")

File RailroadRampage.dcb compiled (256157 bytes):

 Processes                    94
 Global data                 752 bytes
 Local data                  232 bytes
 Private data               1612 bytes
 Public data                   0 bytes
 Code                     152212 bytes
 System processes            232
 Globals vars                 96
 Locals vars                  31
 Private vars                403
 Publics vars                  0
 Identifiers                 871
 Structs                       7
 Strings                      59 (646 bytes)

*** Error code 1 <-- (this one's from make)

josebita

Seems like these patches have not yet gone upstream. Could you have a look at it, Splinter?

Also, talking to Dmitry, he suggests having a packge for the bennu source, as it certainly makes mantaining packages easier.

PS: The issue with return codes has been there for a long time... I also think it should be treated as a bug.

SplinterGU

I don't know what you are talking... I was never have contact with freebsd people...
Download Lastest BennuGD Release: http://www.bennugd.org/node/2

josebita

Ups! Sorry. Dmitry is the real name for AMDmi3, who started this thread.
It looks like his patches haved not yet been integrated into BennuGD (for example TARGET_BSD is not defined in freebsd, only in dragonflybsd...).

The other suggestion is that with every new Bennu release, together with the normal bennugd-core-1.0-platform.tar.gz, you upload a corresponding bennugd-1.0-src.tar.gz package in the downloads dir. That'll make it easy for him to make the packages for freebsd.