fragglet / lhasa

Free Software LHA implementation
http://fragglet.github.io/lhasa/
ISC License
80 stars 15 forks source link

Support of MorphOS (Amiga compatible). #18

Closed polluks closed 7 years ago

polluks commented 8 years ago

lhasa is coming home :-)

fragglet commented 8 years ago

lha_arch_unix.c seems like the wrong place to put Amiga-specific code.

fragglet commented 8 years ago

Also, see the TODO comment above the function you've changed. If using the UNIX arch code is the easiest way to make this compile on Amiga, it would be better to come up with a solution that is not tied to a single OS.

polluks commented 8 years ago

I read your TODO comment, in my opinion you already wrote the solution in lha_arch_win32.c. Do you prefer something like "lha_arch_amiga.c"?

fragglet commented 8 years ago

Preferred solution is an autotools-based #define that checks for vasprintf in libc (ie. HAS_VASPRINTF ...) and uses a fallback if it doesn't exist.

I'd prefer to avoid adding lha_arch_amiga.c unless it's really necessary and it seems like we can probably avoid it.

polluks commented 8 years ago

I see. So you are waiting for official autotools support? Not http://www.jhweiss.de/software/snprintf.html?

polluks commented 8 years ago

I have found a solution: Linking with Libiberty :-) https://en.wikipedia.org/wiki/Libiberty Here is my port http://aminet.net/package/util/arc/lhasa Maybe you can add the library to autoconf.