[olug] C programming question (cross-compiling under Linux to run on Windows).

Rob Townley rob.townley at gmail.com
Sat Feb 28 19:30:59 UTC 2009


On Sat, Feb 28, 2009 at 1:05 PM, Phil Brutsche <phil at brutsche.us> wrote:
> There is third-party stuff to do it, but nothing native.
>
> Here's a freeware thingy that might help:
>
> http://www.toolsack.com/products/baseline/
>
> If you need to go with a "scripted" language my gut feeling would be to
> go with something that natively supports TCP sockets on both platforms -
> Python, for example.
>
> Dan Linder wrote:
>> Q2: I'd really like to rewrite this in either VBScript or WScript rather
>> than the compiled binary.  Does anyone have a simple example code of opening
>> a socket connection and sending data in VBScript?
>
> --
>
> Phil Brutsche
> phil at brutsche.us
> _______________________________________________
> OLUG mailing list
> OLUG at olug.org
> https://lists.olug.org/mailman/listinfo/olug
>


py> import socket
py> help(socket.gethostbyname)
Help on built-in function gethostbyname in module _socket:

gethostbyname(...)
    gethostbyname(host) -> address

    Return the IP address (a string of the form '255.255.255.255') for a
host.

py> socket.gethostbyname("www.google.com")
'209.85.165.147'



More information about the OLUG mailing list