---------- Forwarded message ----------
From: Miguel Enrique Cobá Martinez <
[hidden email]>
Date: 2009/8/24
Subject: [Pharo-project] Networking on images running on 64 bit OSes.
To: Pharo <
[hidden email]>
Is someone working on issues:
http://code.google.com/p/pharo/issues/detail?id=1031http://code.google.com/p/pharo/issues/detail?id=961http://code.google.com/p/pharo/issues/detail?id=794Without them fixed the in-image network doesn't work.
CPU: intel
CPU arch: x86
OS: Debian GNU/Linux i386
OS arch: 32 bits
works: YES
CPU: intel
CPU arch: x86_64
OS: Debian GNU/Linux amd64
OS arch: 64 bits
works: NO
CPU: amd
CPU arch: x86_64
OS: Debian GNU/Linux i386
OS arch: 32 bits
works: YES
CPU: amd
CPU arch: x86_64
OS: Debian GNU/Linux amd64
OS arch: 64 bits
works: NO
In short it doesn't work on a 64 bit OS.
I tried to see the source code for the squeak vm because it is the
primitives that are failing but I got confused and gave up.
The interesting part that I found was this:
static char localHostName[MAXHOSTNAMELEN];
static u_long localHostAddress; /* GROSS IPv4 ASSUMPTION! */
assigned in:
/* start a new network session */
sqInt sqNetworkInit(sqInt resolverSemaIndex)
{
if (0 != thisNetSession)
return 0; /* already initialised */
gethostname(localHostName, MAXHOSTNAMELEN);
localHostAddress= nameToAddr(localHostName);
thisNetSession= clock() + time(0);
if (0 == thisNetSession)
thisNetSession= 1; /* 0 => uninitialised */
resolverSema= resolverSemaIndex;
return 0;
}
by means of:
static int nameToAddr(char *hostName)
{
struct hostent *he;
lastError= 0; /* ditto */
if ((he= gethostbyname(hostName)))
return ntohl(*(long *)(he->h_addr_list[0]));
lastError= h_errno; /* and one more ditto */
return 0;
}
there it appears to call a system function (gethostbyname)
and to convert the result struct first entry on array h_addr_list.
Well the point is, this is for someone with more experience with the
socket plugin in squeak.
So, it is someone trying to fix this? Are there any news here?
It is a structural problem, because before this I could connect to the
network in
my 64 bit OS on my x86_64 architecture without the ia32libs on debian.
For these test
I installed the ia32libs package of debian in order load and start the
closure vm.
Maybe Jose Luis Redrejo has a hint about how to build the vm in order to having
a full networking vm/image.
Or someone more involved with the internals of the vm.
--
Miguel Cobá
http://miguel.leugim.com.mx_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project--
Damien Cassou
http://damiencassou.seasidehosting.st"Lambdas are relegated to relative obscurity until Java makes them
popular by not having them." James Iry