bugTransport Sample Protocol - Bugs: bug #19853, tsp_stub_server 0.8.3 not working...

 
 

bug #19853: tsp_stub_server 0.8.3 not working on Windows XP

Submitter:  Laroche <laroche>
Submitted:  Fri 11 May 2007 09:31:02 AM UTC
   
 
Category:  Core Severity:  3 - Normal
Status:  In Progress Privacy:  Public
Assigned to:  deweerdt Open/Closed:  Open
Release:  * 0.8.3 Fixed Release:  * Unknown
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Wed 16 May 2007 06:01:00 PM UTC, comment #16: 

I didn't see your mail on the ML?

Either it didn't reach the ML server yet or
may be you fingers slipped on the keyboard?

The fact is you doesn't seem to be a subscriber of the
tsp-devel list
so your mail may have been dropped silently
since it is a subscriber-only list (in order to avoid SPAM)

So you may either:

1) - subscribe to the list
     (with the address you will use to send the mail)
   - resend the message
   - and optionnally unsubscribe from the list

2) send the mail directly to me and I will
   fwd your mail to the list.


Eric NOULARD <erk>
Group administrator
Wed 16 May 2007 02:49:03 PM UTC, comment #15: 

Hello,

I have sent a mail on the mailing list with a Labview sample.

Hope it will help some people.

PS : I will add the support of more symbol type in the DLL (all the basic Labview variable type I need in my application)

Jeff

Laroche <laroche>
Tue 15 May 2007 02:59:23 PM UTC, comment #14: 

Ok nice :)

1) I've just committed the change.

2)

Now, I have a simple tsp_provider_dll which work with Labview !

I would be glad if you present us your work on this subject
on the mailing list with may be some sketch of screenshot.

I know some people here may be interested.

By the way thank you for using AND improving TSP .

Eric NOULARD <erk>
Group administrator
Tue 15 May 2007 02:32:40 PM UTC, comment #13: 

Hello,

1) About the patch : ADD_DEPENDENCIES(tsp_consumer tsp_common tsp_rpc_rpcgen_exec_clnt)

It works : thanks.


2) About my DLL : After some debug sessions, I understood why it didnt work (I called the TSP_provider_run function before adding the parameters)

Now, I have a simple tsp_provider_dll which work with Labview !

Thank you for you help

Jeff

Laroche <laroche>
Tue 15 May 2007 11:29:49 AM UTC, comment #12: 

ACK.
Could try the patch attached to tracker which simply
replace the line

ADD_DEPENDENCIES(tsp_consumer tsp_common rpcgen_exec_clnt)
with
ADD_DEPENDENCIES(tsp_consumer tsp_common tsp_rpc_rpcgen_exec_clnt)

and rerun CMake and rebuild TSP with BUILD_CONSUMER set to ON.
It should work.

(file #12772)

Eric NOULARD <erk>
Group administrator
Tue 15 May 2007 09:40:35 AM UTC, comment #11: 

Hello again (bis),

Yves helped me and found why I didnt get into the TSP portion of code :
The debugger used the /windows/system32/tsp*.dll instead of my generated dll
I suppressed those, and the it work : I can step into :)

About the rpcgen_exec_cntl, Yves disactivated the BUILT_CONSUMER in the Cmake options (as I dont need it) to avoid the error message.

Going further now ...

Jeff

Laroche <laroche>
Tue 15 May 2007 09:20:14 AM UTC, comment #10: 

Hello again,

Read rpcgen_exec_clnt instead of rpcgen_exec_cht in my previous post

Jeff

Laroche <laroche>
Tue 15 May 2007 09:14:12 AM UTC, comment #9: 

Hello,

Some news from my aventures with TSP on Windows ...

1) I have installed Visual Studio 2003, launched Cmake again with my Cmake file (written by Eric) :

PROJECT(tsp_provider_dll C)
ADD_DEFINITIONS(-DTSP_SHARED_LIBS)
SET(TSP_INSTALL_DIR "C:\\Program Files\\tsp 0.8.3")
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/include)
LINK_DIRECTORIES(${TSP_INSTALL_DIR}/lib)
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/external/pthreadVC/include)
LINK_DIRECTORIES(${TSP_INSTALL_DIR}/external/pthreadVC/lib)
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/external/oncrpc/include)
LINK_DIRECTORIES(${TSP_INSTALL_DIR}/external/oncrpc/lib)
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/external/TspWin32/include)
SET(LIBS tsp_provider tsp_common tsp_services)
SET(LIBS ${LIBS} pthreadVC TspWin32)
ADD_LIBRARY(tsp_provider_dll SHARED tsp_provider_dll.c)
TARGET_LINK_LIBRARIES(tsp_provider_dll tsp_common tsp_services tsp_provider)
ADD_EXECUTABLE(tsp_provider_dll_test tsp_provider_dll_test.c)
TARGET_LINK_LIBRARIES(tsp_provider_dll_test ${LIBS} tsp_provider_dll)

Then I generated successfully my TSP_Provider_DLL projet :)

But ... when trying to debug it, I can't step into TSP portions of code (as if the installed TSP binaries did'nt contains any debug informations).


2) So I decided to compile the TSP 0.8.3 sources in debug mode.

Cmake generate me two successives errors :

- CMake Error : Unknown Target referenced : rpcgen_exec_cht
- CMake Error : tsp_consumer depends on unknown target : rpcgen_exec_cht

But when I open the TSP solution file and generate the ALL_BUILT I get no error : 18 successful, 0 errors, 0 ignored

Then, I modified my tsp_provider_dll Cmake file to use my freshly generated TSP binaries :

PROJECT(tsp_provider_dll C)
ADD_DEFINITIONS(-DTSP_SHARED_LIBS)
SET(TSP_INSTALL_DIR "C:\\Projets\\TSP\\tsp-0.8.3-Binaries")
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/Windows/include)
LINK_DIRECTORIES(${TSP_INSTALL_DIR}/Windows/bin/Debug)
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/external/pthreadVC/include)
LINK_DIRECTORIES(${TSP_INSTALL_DIR}/external/pthreadVC/lib)
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/external/oncrpc/include)
#LINK_DIRECTORIES(${TSP_INSTALL_DIR}/external/oncrpc/lib)
INCLUDE_DIRECTORIES(${TSP_INSTALL_DIR}/external/TspWin32/include)
SET(LIBS tsp_provider tsp_common tsp_services)
SET(LIBS ${LIBS} pthreadVC TspWin32)
ADD_LIBRARY(tsp_provider_dll SHARED tsp_provider_dll.c)
TARGET_LINK_LIBRARIES(tsp_provider_dll tsp_common tsp_services tsp_provider)
ADD_EXECUTABLE(tsp_provider_dll_test tsp_provider_dll_test.c)
TARGET_LINK_LIBRARIES(tsp_provider_dll_test ${LIBS} tsp_provider_dll)

And to make it work, I had to do some extra :

- tsp_rpc.h withc was missing in the generated include dir (I took it from the installed include dir).

- pthredVC.lib was missing in the generated binaries dir (I have copyied it from the install dir to /external/pthreadVC/lib dir)

- pthreadVC, oncrpc, and TspWin32 include files where missing too (I have copyied these from the install dir to /external/pthreadVC/include , /external/oncrpc/include and /external/TspWin32/includedir)

Then I succeed to generate tsp_provider_dll.
But still the same problem when debuging ...


3) What next ?

I think I have to fix the - CMake Error : Unknown Target referenced : rpcgen_exec_cht to go further (as the goal is to get a debug version of TSP)

So my priority is to get help to fix that point.

But any ideas or remarqs about the other points are welcome ...

Regards,

Jeff

Laroche <laroche>
Fri 11 May 2007 04:53:58 PM UTC, comment #8: 

Installation and removal of the [ACPLT] ONCRPC portmap
is done by the TSP NSIS installer.
here is the excerpt from

tsp/CMakeLists.txt

corresponding to the NSIS install command:


 SET(CPACK_NSIS_MODIFY_PATH ON)
        ## Copy dll to the system path
        IF (BUILD_WIN32_ACPLT_ONCPRC AND ACPLT_ONCRPC_FOUND)
                SET(CPACK_NSIS_EXTRA_INSTALL_COMMANDS "
                    ExecWait  \\\"$INSTDIR\\\\external\\\\oncrpc\\\\bin\\\\inst_pm.exe remove\\\"
                    CopyFiles \\\"$INSTDIR\\\\external\\\\oncrpc\\\\bin\\\\oncrpc.dll\\\" \\\"$SYSDIR\\\"
                    CopyFiles \\\"$INSTDIR\\\\external\\\\oncrpc\\\\bin\\\\portmap.exe\\\" \\\"$SYSDIR\\\"
                    CreateDirectory \\\"$SYSDIR\\\\drivers\\\\etc\\\"
                    CopyFiles \\\"$INSTDIR\\\\external\\\\oncrpc\\\\etc\\\\rpc\\\" \\\"$SYSDIR\\\\drivers\\\\etc\\\"
                    ExecWait  \\\"$INSTDIR\\\\external\\\\oncrpc\\\\bin\\\\inst_pm.exe $SYSDIR\\\\portmap.exe\\\"
                ")


I think inst_pm.exe does the job:
 1) install service and activate-it

I think the "original" inst_pm.exe did not activate
the service for "automatic" startup and
we did modify the ACPLT ONC RPC source
for make it do the job we want.

Fred did you use/recompile the patched ACPLT ONC RPC
source when packaging 0.8.3 ?

The patched sources are here:

tsp/external/ACPLT-ONCRPC/source/acplt-oncrpc-1.14.3-tsp1.zip


Debug information should be found in

 tsp_services.pdb

or any other
 <libname>.pdb

the *.pdb files are installed when compiling
TSP in Debug build
(the default selected by CMake if none is specified)

Could you check in you tsp-0.8.3 if you find
any tsp_*.pdb file?


For TSP WIn32 hackers:
the CMake macro doing the appropriate
pdb install is TSP_LIBRARY_INSTALL found in
tsp/make/TSPCmakeTools.cmake

MACRO(TSP_LIBRARY_INSTALL)
  INSTALL(
    TARGETS ${ARGV}
    RUNTIME DESTINATION bin
    LIBRARY DESTINATION lib
    ARCHIVE DESTINATION lib
    )
  IF (WIN32 AND CMAKE_BUILD_TYPE STREQUAL "Debug")
        FOREACH(SCRIPT_FILE ${ARGV})
                INSTALL(FILES ${LIBRARY_OUTPUT_PATH}/${CMAKE_BUILD_TYPE}/${SCRIPT_FILE}.pdb
                                DESTINATION bin)
        ENDFOREACH(SCRIPT_FILE)
  ENDIF (WIN32 AND CMAKE_BUILD_TYPE STREQUAL "Debug")
ENDMACRO(TSP_LIBRARY_INSTALL)


I wish I had a Windows box to help you more...
No really just kidding :))

Eric NOULARD <erk>
Group administrator
Fri 11 May 2007 03:24:50 PM UTC, comment #7: 

I don't know the command to activate portmap.
But the 0.8.2 did activate it automatically.
And why the portmap.exe is different between the 2 versions ?

For the debug information, inside the Visual 6.0 debugger, while loading tsp_services.dll it complain on missing debug information. Maybe TSP use an unknown debug format for VC6.0 ?
But forget the debug stuff, because JF will use Visuel 2003 Net Compiler or something funny like this.

Yves

TSP administrator <tsp_admin>
Group administrator
Fri 11 May 2007 03:06:28 PM UTC, comment #6: 

If you want the portmap to be activated by default, could you send the needed command? I'll add it to the install.bat.
It should be something along the lines of "net start ..."

Regarding the debug symbols, how to I know if they are present or not? Because I've compiled the project in debug mode so. Any CMake variable I should be aware of?

Frederik Deweerdt <deweerdt>
Group administrator
Fri 11 May 2007 02:41:54 PM UTC, comment #5: 

Hello again,

I have installed TSP 0.8.3 on an other computer (TSP was never installed on it).

The installation process is OK, but the portmap service is not active.
The only thing to do is to start portmap manualy and then tsp_stub_server and tsp_stdout_client are working fine together.
(I have also set the portmap service in automatic start for the next time).

About the debug symbols problem : I will install Visual Studio 2003.NET monday and hope it will solve that point too.

Thanks for your help.

Best regards,

Jeff

Laroche <laroche>
Fri 11 May 2007 01:56:37 PM UTC, comment #4: 

Hello all.

I've done some tests to help Jean-François.

The status:
- binaries in external/ALTRPC differs from 0.8.2 to 0.8.3
- Using the downloaded source, I try to launch rpc install.bat to copy portmap.exe and oncrpc.dll. The 0.8.3 tsp_stub_server can register itself after the install from 0.8.2. And of course it can do it after install from 0.8.3
- The portmap is not running after 0.8.3 install, and by manually activate it, the tsp_stub can register.

Conclusion:
Something seems weird inside 0.8.3 WIN portmap installation.
But the TSP binaries are OK, except there is no debug information inside TSP librairies.

Yves




Thanks for helping us tracking bugs in TSP. Be sure you send all
the log & context on the problem.
Please be sure will do our best for correcting it.

Regards,
TSP admin

TSP administrator <tsp_admin>
Group administrator
Fri 11 May 2007 01:08:47 PM UTC, comment #3: 

I believe that the RPC service is called portmap?

Frederik Deweerdt <deweerdt>
Group administrator
Fri 11 May 2007 01:07:13 PM UTC, comment #2: 

Would you try to
uninstall 0.8.2
install 0.8.3
reboot
check if the ONCRPC Service is running

!!! BEWARE THAT !!!!
Windows RPC Service IS NOT the "ONC RPC Service"
!!! BEWARE THAT !!!!

then run the
tsp_stub_server + tsp_stdout test (0.8.3)

Eric NOULARD <erk>
Group administrator
Fri 11 May 2007 10:09:56 AM UTC, comment #1: 

Regarding the debugging symbols, the 0.8.3 executable should contain them. The compile was done in debug mode.
Otherwise, I've absolutely no clue on why we would get this, other than a problem with the installation of portmap.
Could you do a manual install of the oncrpc.dll and portmap.exe. Also please check that there are no such files lying around in the computer.

Regards,
Frederik

Frederik Deweerdt <deweerdt>
Group administrator
Fri 11 May 2007 09:31:02 AM UTC, original submission:  

Hello,

Context : currently using TSP 0.8.2 on XP, tried to use 0.8.3

Step by step :

- Test of 0.8.2 tsp_stub_server and tsp_stout_client : OK.
- Backup of the TSP 0.8.2 directory
- Uninstall of TSP 0.8.2 : OK
- Install of TSP 0.8.3 : OK
- Check of the Windows RPC services : OK (started)
- Launch of 0.8.3 tsp_stub_server : NOK
  TSP Provider on PID 1680 - URL #0 : <rpc://1er/StubbedServer:0>
  ERROR||\tsp_083\src\core\rsp\tsp_server.c
  ##TSP_rpc_run
  ##277: RPC server unable to register ProgId=31230010
- Launch of the backuped 0.8.2 tsp_stub_server : NOK, same error

- Backup of the TSP 0.8.3 directory
- Uninstall of TSP 0.8.3 : OK
- Install of TSP 0.8.2 : OK
- Check of the Windows RPC services : OK (started)
- Test of 0.8.2 tsp_stub_server and tsp_stout_client : OK.
- Launch of 0.8.3 tsp_stub_server : OK !
- Launch of 0.8.3 tsp_stout_client : An error occur, then it receive datas.
  Asking for : <5> samples <0 => INFINITE loop>
  of <1> TSP symbols at period <1>
  ERROR||\tsp_083\src\core\rpc\tsp_client.c
  ##tsp_remote_open_progid
  ##79: ERROR : GLOBAL clnt_create failed host <localhost>
  / prgid <824377360/0x31230010>
  ERROR||\tsp_083\src\core\rpc\tsp_client.c
  ##tsp_remote_open_progid
  ##79: ERROR : GLOBAL clnt_create failed host <localhost>
  / prgid <824377361/0x31230011>
  tsp_stdout_client.exe: Asking for 1 symbols
  symbol <0> is <t>

- Launch of 0.8.2 tsp_stout_client : Same behaviour as 0.8.3

Any idea ?

PS : as asked in my previous post, I need a executable version of TSP (0.8.2 or 0.8.3) containing debug symbols (as I cannot generate it using Visual Studio 6)

Thanks in advance for help.

Jeff

Laroche <laroche>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #12772:  patch-bug19853-erk-1.patch added by erk (689B - text/x-patch - Wrong generated rpc target dependency)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by tsp_admin (Posted a comment)
  • -email is unavailable- added by erk (Posted a comment)
  • -email is unavailable- added by deweerdt (Posted a comment)
  • -email is unavailable- added by laroche (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2007-05-15 erk Attached File- Added patch-bug19853-erk-1.patch, #12772
    2007-05-11 deweerdt StatusNone In Progress
        Assigned toNone deweerdt

    Back to the top

    Powered by Savane 3.14-f13d.
    Corresponding source code