|Re: [hatari-devel] gst2ascii.c Windows build issue?|
[ Thread Index |
| More lists.tuxfamily.org/hatari-devel Archives
On 15/05/2013 20:00, Eero Tamminen wrote:
On maanantai 13 toukokuu 2013, Nicolas Pomarède wrote:
On 12/05/2013 23:45, Christer Solskogen wrote:
fatal error: netinet/in.h: No such file or directory
gst2ascii is an external tool, so it's not necessary in that case where
we just want to test the patched hatari.exe, so I think you can ignore
this error for now (it's possible netinet/in.h is not standard on
Windows and Eero might need to update gst2ascii.c)
The standard place for byteswapping macros like ntohl is arpa/in.h, but
in MiNTlib (and some other systems) it's in netinet/in.h, so I used that.
This is a POSIX.1-2001 standard header.
Maybe I should add some WIN32 ifdef which uses SDL macros instead?
I think it would be better ; as Hatari requires SDL anyway, I think any
tools should have a failsafe to use SDL in case one of the includes
doesn't exist on a specific OS.
Maybe it would be even better to always use the SDL headers for all
programs included in Hatari and add the possibility to pass a '-D'
switch in cmake/gcc to use "shortcuts" like the posix headers (in case
someone wants to build the tools outside of Hatari environment).
(I switched from those to "standard" headers so that gst2ascii tool doesn't
need extra deps like SDL when built natively on Atari with MiNTlib. I use
that tool when building Douglas' Doom Falcon port with Sparemint GCC. :))