Re: Tn5250 compile under IBM Aix 5.3

James Rich <[email protected]>
Newsgroups gmane.comp.emulators.tn5250
Message-ID <[email protected]>
On Fri, 14 May 2010, Scott Klement wrote:

> James Rich wrote:
>
> Correct, it won't work from QP2TERM under a 5250 emulator.  That's why I
> suggested using Putty...

That's what I was referring to, I should have been more specific.

> I'm way beyond this point already.  I have tn5250 compiled on PASE.  I
> didn't need to muck with autoconf, I just changed the name of the
> pointers in the Tn5250Stream structure.  Seemed easier, and then it can
> run exactly the same on all systems.

Crap - I should have checked my email earlier then.  I just committed some 
changes to cvs to check for naccept using autoconf.  My checks work and 
leave the Tn5250Stream structure unchanged.  But honestly, I'm fine with 
changing the structure.  My changes aren't exactly huge, so it probably 
doesn't matter which method we use.  I figured people would rather keep 
the structure intact.

>> It looks like malloc() isn't the only library function that is weird on
>> AIX.  We're going to have to handle snprintf and a couple of others.
>
> Strangely, I didn't run into any issues with malloc or snprintf.  I
> wonder what I did differently?

What VRM are you on?  I'm on V5R3M0 and just installed gcc via the YiP 
pages.  "gcc --version" shows version 4.0.0.  While I have resolved the 
accept/naccept issue I still have the following compiler warnings and 
errors:

conf.c: In function 'tn5250_config_replacedata':
conf.c:716: warning: incompatible implicit declaration of built-in 
function 'snprintf'

macro.c: In function 'macro_isnewmacro':
macro.c:158: warning: pointer targets in passing argument 1 of 'strncpy' 
differ in signedness
macro.c: In function 'macro_loadfile':
macro.c:290: warning: pointer targets in passing argument 1 of 'strlen' 
differ in signedness
macro.c:291: warning: pointer targets in passing argument 1 of 'strcpy' 
differ in signedness
macro.c:291: warning: pointer targets in passing argument 2 of 'strcpy' 
differ in signedness

sslstream.c: In function 'ssl_getTelOpt':
sslstream.c:207: warning: incompatible implicit declaration of built-in 
function 'snprintf'
sslstream.c: In function 'ssl_stream_host_sb':
sslstream.c:1153: warning: pointer targets in passing argument 2 of 
'tn5250_buffer_append_data' differ in signedness

telnetstr.c: In function 'getTelOpt':
telnetstr.c:189: warning: incompatible implicit declaration of built-in 
function 'snprintf'
telnetstr.c: In function 'telnet_stream_host_sb':
telnetstr.c:857: warning: pointer targets in passing argument 2 of 
'tn5250_buffer_append_data' differ in signedness

utility.c: In function 'tn5250_char_map_new':
utility.c:270: warning: pointer targets in assignment differ in signedness
utility.c:271: warning: pointer targets in assignment differ in signedness
utility.c:275: warning: pointer targets in assignment differ in signedness
utility.c:276: warning: pointer targets in assignment differ in signedness

wtd.c: In function 'tn5250_wtd_context_write_dsfsf':
wtd.c:551: warning: pointer targets in passing argument 1 of 'strlen' 
differ in signedness
wtd.c:613: warning: pointer targets in passing argument 1 of 'strlen' 
differ in signedness
wtd.c:621: warning: pointer targets in passing argument 1 of 'strlen' 
differ in signedness

gcc -g -O2 -o scs2ascii scs2ascii.o  ../lib5250/.libs/lib5250.a -lssl 
-lcrypto
ld: 0711-317 ERROR: Undefined symbol: .rpl_malloc
ld: 0711-317 ERROR: Undefined symbol: .vsyslog
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more 
information.
collect2: ld returned 8 exit status
make: The error code from the last command is 1.

Do you have any of these errors?  Did you pass any options to ./configure? 
Do you have the following line in config.log or config.h:

#define malloc rpl_malloc

> I _am_ running into issues with it not finding the .tn5250rc file,
> though... and I can't see why...   still looking into it.

Maybe getpwuid() isn't working as expected?

James Rich

if you want to understand why that is, there are many good books on
the design of operating systems. please pass them along to redmond
when you're done reading them :)
 	- Paul Davis on ardour-dev
-- 
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.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.