List Info

Thread: x5250 0.5.2-pre3




x5250 0.5.2-pre3
user name
2006-03-09 19:37:34
I'm trying to build x5250 version 0.5.2-pre3, which I
downloaded from 
James' site yesterday.  When I run ./configure it fails
with the following 
error:
   configure: error: ** Unable to find 5250 libraries!

At one point, I had contributed code to this project that
used the 
pkg-config tool to find lib5250.  However, this code appears
to have been 
removed from the project, and now lib5250 can't be found.

How do I tell it where to look for lib5250?

---
Scott Klement  http://www.scottklement.c
om
-- 
This is the Linux 5250 Development Project (LINUX5250)
mailing list
To post a message email: LINUX5250midrange.com
To subscribe, unsubscribe, or change list options,
visit: 
http://lists.midrange.com/mailman/listinfo/linux5250
or email: LINUX5250-requestmidrange.com
Before posting, please take a moment to review the archives
at http://archive
.midrange.com/linux5250.

x5250 0.5.2-pre3
user name
2006-03-09 20:32:53
On Thu, 9 Mar 2006, Scott Klement wrote:

>
> I'm trying to build x5250 version 0.5.2-pre3, which I
downloaded from
> James' site yesterday.  When I run ./configure it
fails with the following
> error:
>   configure: error: ** Unable to find 5250 libraries!
>
> At one point, I had contributed code to this project
that used the
> pkg-config tool to find lib5250.  However, this code
appears to have been
> removed from the project, and now lib5250 can't be
found.
>
> How do I tell it where to look for lib5250?

configure.ac now uses this code:

AC_CHECK_LIB(5250, tn5250_terminal_init, TN5250_LIB=-l5250)
if test "$ac_cv_lib_5250_tn5250_terminal_init"
!= "yes"
then
         AC_MSG_ERROR([** Unable to find 5250 libraries!])
fi

which simply checks for the tn5250_terminal_init() function
in the library 
lib5250.so as found by ld.  If the linker can't find
lib5250 you may need 
to either edit /etc/ld.so.conf or set LD_LIBRARY_PATH to
point to the 
location where you installed lib5250.  configure no longer
uses pkg-config 
to find lib5250 and tn5250 does not produce a pkg-config
package.

James Rich

It's not the software that's free; it's you.
 	- billyskank on Groklaw
-- 
This is the Linux 5250 Development Project (LINUX5250)
mailing list
To post a message email: LINUX5250midrange.com
To subscribe, unsubscribe, or change list options,
visit: 
http://lists.midrange.com/mailman/listinfo/linux5250
or email: LINUX5250-requestmidrange.com
Before posting, please take a moment to review the archives
at http://archive
.midrange.com/linux5250.

x5250 0.5.2-pre3
user name
2006-03-09 21:06:38

> which simply checks for the tn5250_terminal_init()
function in the library
> lib5250.so as found by ld.  If the linker can't find
lib5250 you may need
> to either edit /etc/ld.so.conf or set LD_LIBRARY_PATH
to point to the
> location where you installed lib5250.

I don't have an /etc/ld.so.conf (I'm not running Linux). 
Setting 
LD_LIBRARY_PATH did not help.  I can, however, do the
following:

setenv LDFLAGS -L/usr/local/lib
setenv CFLAGS -I/usr/local/include

Once I've done that, your configure script will find my
libraries.  BUT, 
the point behind having a ./configure script is that it'll
be able to work 
on all systems.  If you wanted it to only work on Linux, you
could simply 
write a Makefile and not bother with all of the
auto-configure stuff.

What's why we were using pkg-config.  So that we didn't
have to manually 
tell gtk-5250 and x5250 all of the flags that it needed to
compile!

Next problem.  When I try to compile x5250, this is what
happens:

Making all in src
if gcc -DHAVE_CONFIG_H -I. -I. -I..
-DSYSCONFDIR=\"/usr/local/etc\" 
-I../bitmaps
     -I/usr/X11R6/include
-DDATADIR=\"/usr/local/share\" 
-I/usr/local/include -MT
  alloccolors.o -MD -MP -MF
".deps/alloccolors.Tpo" -c -o alloccolors.o 
alloccolo
rs.c;  then mv -f ".deps/alloccolors.Tpo"
".deps/alloccolors.Po"; else rm 
-f ".d
eps/alloccolors.Tpo"; exit 1; fi
In file included from /usr/local/include/tn5250.h:33,
                  from x5250.h:34,
                  from alloccolors.c:26:
/usr/local/include/tn5250/utility.h:36: error: syntax error
before '!' 
token
In file included from /usr/local/include/tn5250.h:36,
                  from x5250.h:34,
                  from alloccolors.c:26:
/usr/local/include/tn5250/field.h:80: error: syntax error
before 
"Tn5250Uint16"
In file included from /usr/local/include/tn5250.h:41,
                  from x5250.h:34,
                  from alloccolors.c:26:
/usr/local/include/tn5250/stream.h:84: error: syntax error
before 
"SOCKET_TYPE"
/usr/local/include/tn5250/stream.h:99: error: syntax error
before 
"SOCKET_TYPE"
/usr/local/include/tn5250/stream.h:129: error: syntax error
before 
"masterSock"
In file included from /usr/local/include/tn5250.h:45,
                  from x5250.h:34,
                  from alloccolors.c:26:
/usr/local/include/tn5250/terminal.h:151: error: syntax
error before 
"SOCKET_TYPE"
In file included from /usr/local/include/tn5250.h:47,
                  from x5250.h:34,
                  from alloccolors.c:26:
/usr/local/include/tn5250/printsession.h:55: error: syntax
error before 
"SOCKET_TYPE"
*** Error code 1

Stop in /usr/home/klemscot/tn5250cvs/x5250-0.5.2-pre3/src.
*** Error code 1

Stop in /usr/home/klemscot/tn5250cvs/x5250-0.5.2-pre3.
*** Error code 1

Stop in /usr/home/klemscot/tn5250cvs/x5250-0.5.2-pre3.


I took a look at the first error in this list (line 36 of
the utility.h 
file) and this is what I find:

#if SIZEOF_SHORT == 2
typedef unsigned short Tn5250Uint16;
typedef signed short Tn5250Sint16;
#elif SIZEOF_INT == 2
typedef unsigned int Tn5250Uint16;
typedef signed int Tn5250Sint16;
#else
    ACK!  Need a 16-bit type!
#endif

the word "ACK!" is on line 36.  The problem is
that nothing has defined 
the SIZEOF_SHORT macro prior to this #include file.  When
lib5250 is 
built, there's a file called config.h that has the
definition of this 
macro in it -- so lib5250 builds without any problems.

However, x5250's config.h doesn't have this macro defined,
so it won't 
build.  It's not clear to me whether this belongs in
x5250's config.h 
file, or if the one from tn5250 should be in
/usr/local/include/tn5250 and 
made a part of tn5250.h?

The other errors seem to be caused by the same problem --
there's no 
definition for symbols that ARE defined in config.h in the
main tn5250 
branch.

I find myself wanting to blame the main tn5250 build for
this error rather 
than x5250, since I'd assume that ANY project that wanted
to link with 
lib5250 would run into these same errors.
-- 
This is the Linux 5250 Development Project (LINUX5250)
mailing list
To post a message email: LINUX5250midrange.com
To subscribe, unsubscribe, or change list options,
visit: 
http://lists.midrange.com/mailman/listinfo/linux5250
or email: LINUX5250-requestmidrange.com
Before posting, please take a moment to review the archives
at http://archive
.midrange.com/linux5250.

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )