Rich,

Well, problem was elsewhere as it turned out.
My C++ plugin was "using LibSerial;" but resulting lib was NOT linked against libserial.so
So plugin was found, but could not be loaded.
I'm not sure if I resolved this correctly and I would like to know how additional libs should be added to CMakeLists.txt so resulting plugin lib is linked against them as well.

Also, is it possible to change player loading code to produce a more meaningfull error?

Regards,
Marcin.

On Fri, May 27, 2011 at 7:13 PM, Rich Mattes <jpgr87@gmail.com> wrote:
Could you try setting your PLAYERPATH environment variable to
/home/garagoth/UGV/Stage/code/build/src/drivers/qsilver, and then using
"libqsilver.so" as your plugin name?  Also, try putting the name field
before the plugin field in the config file.

Rich

> -----Original Message-----
> From: Garagoth [mailto:garagoth@gmail.com]
> Sent: Thursday, May 26, 2011 10:20 AM
> To: playerstage-users@lists.sourceforge.net
> Subject: [Playerstage-users] Custom Plugin: loading problem
>
> Hi,
>
> I'm having problem using own plugin. It is not being loaded despite
> many attempts and config variables.
> Could you please point what I am missing?
>
> **** Here is real.cfg file:
>
> unit_length "m" # length units in meters unit_angle  "degrees" # Angles
> in degrees
>
> driver
> (
>     plugin "libqsilver"
>     name "qsilver"
>     controller_ids [ 7 8 ]
>     provides ["7:::position1d:0"
>               "8:::position1d:1"
>              ]
>     alwayson 1
> )
>
> **** Here is console output:
>
> garagoth@development:~/UGV/Stage$ player real.cfg Registering driver
> Player v.3.1.0-svn
>
> * Part of the Player/Stage/Gazebo Project
> [http://playerstage.sourceforge.net].
> * Copyright (C) 2000 - 2009 Brian Gerkey, Richard Vaughan, Andrew
> Howard,
> * Nate Koenig, and contributors. Released under the GNU General Public
> License.
> * Player comes with ABSOLUTELY NO WARRANTY.  This is free software, and
> you
> * are welcome to redistribute it under certain conditions; see COPYING
> * for details.
>
> warning : absolute path plugin
> /home/garagoth/UGV/Stage/code/build/src/drivers/qsilver/libqsilver.so
> error   : Failed to load plugin
> /home/garagoth/UGV/Stage/code/build/src/drivers/qsilver/libqsilver.so.
> error   : libtool reports error: file not found
> error   : plugin search path: (null)
> error   : failed to load plugin:
> /home/garagoth/UGV/Stage/code/build/src/drivers/qsilver/libqsilver.so
> error   : failed to parse config file real.cfg driver blocks
> garagoth@development:~/UGV/Stage$ ls -al
> /home/garagoth/UGV/Stage/code/build/src/drivers/qsilver/libqsilver.so
> -rwxr-xr-x 1 garagoth garagoth 41366 2011-05-26 15:30
> /home/garagoth/UGV/Stage/code/build/src/drivers/qsilver/libqsilver.so
> garagoth@development:~/UGV/Stage$ ldd
> /home/garagoth/UGV/Stage/code/build/src/drivers/qsilver/libqsilver.so
>     linux-gate.so.1 =>  (0x00e0b000)
>     libplayercore.so.3.1 => /usr/local/lib/libplayercore.so.3.1
> (0x00ef8000)
>     libpthread.so.0 => /lib/libpthread.so.0 (0x00110000)
>     libltdl.so.7 => /usr/lib/libltdl.so.7 (0x00515000)
>     libdl.so.2 => /lib/libdl.so.2 (0x005b6000)
>     libplayerinterface.so.3.1 =>
> /usr/local/lib/libplayerinterface.so.3.1 (0x0013d000)
>     libplayercommon.so.3.1 => /usr/local/lib/libplayercommon.so.3.1
> (0x00477000)
>     libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00180000)
>     libm.so.6 => /lib/libm.so.6 (0x00a8c000)
>     libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x0095e000)
>     libc.so.6 => /lib/libc.so.6 (0x005ba000)
>     librt.so.1 => /lib/librt.so.1 (0x0012a000)
>     /lib/ld-linux.so.2 (0x00300000)
>
>
> So, file exists, all libs are resolved... what is wrong?
> I tried using lib name without path (plugin "libqsilver") and I made
> sure it is in plugin search path (was in current dir, just next to
> real.cfg file) and results are the same.
>
> Regards,
> Marcin.



------------------------------------------------------------------------------
vRanger cuts backup time in half-while increasing security.
With the market-leading solution for virtual backup and recovery,
you get blazing-fast, flexible, and affordable data protection.
Download your free trial now.
http://p.sf.net/sfu/quest-d2dcopy1
_______________________________________________
Playerstage-users mailing list
Playerstage-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/playerstage-users