Page 1 of 1

Websockets

Posted: Sat Jun 13, 2020 6:24 pm
by Massimo Linossi
Hi to all.
I'm testing an application for sending messages from mod_harbour to a websocket server.
Antonio made this test on GitHub https://github.com/fivetechsoft/wsserver and it works perfectly on local server.
But I must place webserver on a machine that is on a public pc and I must change the IP address. And also to change
the operation that must make when receive some messages from the clients inside the farm or from the web.
I can't recompile it because is made in harbour and all my applications are made with xharbour.com so I can't make
some changes.
Thanks a lot for any suggestion.
Massimo.

Re: Websockets

Posted: Sat Jun 13, 2020 11:25 pm
by Antonio Linares
Massimo,

Please try to build wsserver.prg using xHarbour and let us know what compile or link errors you get

Re: Websockets

Posted: Sun Jun 14, 2020 9:27 am
by Massimo Linossi
Hi Antonio.
These are the errors when I compile wsserver with xhb.com.
Thanks a lot for your time.
Massimo

Code: Select all

Type: C >>>xlink.exe -NOEXPOBJ -MAP -FORCE:MULTIPLE -NOIMPLIB -subsystem:console -LIBPATH:"C:\xHB\lib" -LIBPATH:"C:\xHB\c_lib" -LIBPATH:"C:\xHB\c_lib\win"  "obj\wsserver.obj" "C:\xHB\c_lib\Win\wsock32.lib" "xhb.lib" "dbf.lib" "ntx.lib" "cdx.lib" "rmdbfcdx.lib"  crt.lib kernel32.lib user32.lib winspool.lib ole32.lib oleaut32.lib odbc32.lib odbccp32.lib uuid.lib wsock32.lib ws2_32.lib wininet.lib advapi32.lib shlwapi.lib msimg32.lib mpr.lib -out:"wsserver.exe"<<<

Creating object: wsserver.EXP
Creating library: wsserver.LIB
xLINK: error: Unresolved external symbol '_HB_FUN_HB_MTVM referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETOPEN referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_NTOS referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETGETERROR referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETBIND referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETLISTEN referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETACCEPT referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_THREADDETACH referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_THREADSTART referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETSHUTDOWN referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETCLOSE referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SHA1 referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETSEND referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_BITTEST referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_BPEEK referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_DEFAULT referenced from (wsserver.obj)'.
xLINK: error: Unresolved external symbol '_HB_FUN_HB_SOCKETRECV referenced from (wsserver.obj)'.
xLINK: fatal error: 17 unresolved external(s).

Type: C >>>Couldn't build: wsserver.exe<<<
Type: C >>>TMAKEPROJECT<<<
Type: C >>>TMAKEPROJECT:REFRESH<<<
Type: N >>>      1322<<<


Re: Websockets

Posted: Sun Jun 14, 2020 12:30 pm
by Antonio Linares
Massimo,

Why can't you use it built with Harbour ?

Re: Websockets

Posted: Sun Jun 14, 2020 3:03 pm
by Massimo Linossi
I must think about it.

Re: Websockets

Posted: Sun Jun 14, 2020 4:50 pm
by Massimo Linossi
I solved as I wrote in the other post.