Re: Binary won't run on MacOSX
Scott Klement <[email protected]> Tue, 31 Jul 2012 21:49:14 -0500
| Newsgroups | gmane.comp.emulators.tn5250 |
|---|---|
| Message-ID | <[email protected]> |
Thanks for the info, Walt. Does anyone know if adding term.h would cause any problems on other systems? It seems to be a part of ncurses, so I suspect it'd work on any curses-based solution? On 7/29/2012 10:41 PM, Walt Madden wrote: > On 6/11/12 1:07 PM, Hugh Caley wrote: >> I'm running Lion 10.7.4. I just built tn5250, but when I run it I get >> Segmentation fault:11. > > I got xt5250/tn5250 to work on Mac OS X by adding #include's as shown below: > > --- tn5250-0.17.4/curses/cursesterm.c 2008-11-21 01:12:20.000000000 -0700 > +++ cursesterm.c 2012-07-28 11:45:04.000000000 -0600 > @@ -22,6 +22,9 @@ > #define _TN5250_TERMINAL_PRIVATE_DEFINED > #include "tn5250-private.h" > #include "cursesterm.h" > +#ifdef __APPLE__ > +#include <term.h> > +#endif > > #ifdef USE_CURSES > > > --- tn5250-0.17.4/curses/tn5250.c 2008-11-21 01:12:21.000000000 -0700 > +++ tn5250.c 2012-07-28 11:37:10.000000000 -0600 > @@ -19,6 +19,7 @@ > */ > > #include "tn5250-private.h" > +#include "cursesterm.h" > > Tn5250Session *sess = NULL; > Tn5250Stream *stream = NULL; > > > Without these, I believe there are un-prototyped routines in the modules > and the C compiler (incorrectly) uses a default prototype returning an > int. On 64-bit OS's where pointers are not interchangeable with int's > this causes addressing issues. > > Hope this helps. > -- This is the Linux 5250 Development Project (LINUX5250) mailing list To post a message email: LINUX5250-Zwy7GipZuJhWk0Htik3J/[email protected] To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/linux5250 or email: LINUX5250-request-Zwy7GipZuJhWk0Htik3J/[email protected] Before posting, please take a moment to review the archives at http://archive.midrange.com/linux5250.