Closed karlp closed 10 years ago
Making a C/C++ project instead compiles a "pvs" binary, but it's missing the libpvsmt dependency.
This was installed from the fedora 19 package repo.
Turns out the package installs to /lib, instead of /lib64 on x64, needs an LD_LIBRARY_PATH hack to run the server :)
mail 1: pvdevelop will start an xterm and execute the according commands in there. If you have something wrong with your xterm installation you can open a terminal and run
cd /your/directory pvslua
from there.
mail 2: If it compiles a pvs binary you can start the binary with
./pvs
About which dependency do you talk ?
main 3: Which package install to /lib ??? Our pvbrowser package is build on the openSUSE buildservice and can be downloaded from here. http://software.opensuse.org/download/package.iframe?project=home:pvbrowser&package=pvbrowser-devel
What did you use ?
PS: Here is not the place to talk get help about pvbrowser. Our forum is here: https://groups.yahoo.com/neo/groups/pvbrowser/conversations/topics
I installed the "pvbrowser-devel" package from http://download.opensuse.org/repositories/home:pvbrowser/Fedora_19/home:pvbrowser.repo
There is no "pvslua" command installed for lua apps, and the C/C++ project as mentioned has dependency paths that don't work out of the box. I'll follow up on the yahoo group.
On My mybox I get: me@mybox:~> which pvslua /usr/bin/pvslua me@mybox:~> ls -al /usr/bin/pvslua lrwxrwxrwx 1 root root 44 1. Okt 10:31 /usr/bin/pvslua -> /opt/pvb/language_bindings/lua/pvslua/pvslua
What do you get?
Regarding your C/C++ issues: We use qmake as Makefile generator. The qmake project files refer to our libraries with unix:LIBS += /opt/pvb/pvserver/libpvsmt.so unix:LIBS += /opt/pvb/rllib/lib/librllib.so Do you have these files?
Also you must have these executables: you@yourbox:~> which pvbrowser /usr/bin/pvbrowser you@yourbox:~> which pvdevelop /usr/bin/pvdevelop
You should not expect things must be "working out of the box". We expect that you should have basic linux/bash/c/c++ knowledge.
pvbrowser/pvdevelop are installed, pvslua is not in the fedora 19 package from opensuse.
I'm fully aware I should have c/c++ knowledge, and I wouldn't have gotten this far even without it. I do however expect that the tutorial steps should work out of the box. Running shell scripts via an xterm is an unusual way of doing that. Having an xterm blink and disappear is an awesome way of hiding the error messages. ( I have libpvsmt.so, but it's not found unless I add it at run time via LD_LIBRARY_PATH, which is... not so cool for a packaged install.
karlp@pojak:~/src/pvtest3$ ldd pvs
linux-vdso.so.1 => (0x00007fff61737000)
libpvsmt.so.1 => not found
libpthread.so.0 => /lib64/libpthread.so.0 (0x0000003df0200000)
libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00000032e6000000)
libm.so.6 => /lib64/libm.so.6 (0x00000032e2400000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00000032e3400000)
libc.so.6 => /lib64/libc.so.6 (0x00000032e1800000)
/lib64/ld-linux-x86-64.so.2 (0x00000032e1400000)
karlp@pojak:~/src/pvtest3$ ls -l /usr/lib/libpvsmt.so
lrwxrwxrwx 1 root root 29 Oct 31 16:15 /usr/lib/libpvsmt.so -> /opt/pvb/pvserver/libpvsmt.so
karlp@pojak:~/src/pvtest3$ locate libpvsmt.so
/opt/pvb/pvserver/libpvsmt.so
/usr/lib/libpvsmt.so
/usr/lib/libpvsmt.so.1
/usr/lib/libpvsmt.so.1.0
/usr/lib/libpvsmt.so.1.0.0
karlp@pojak:~/src/pvtest3$
Have you actually tried the packaged version? or just the built from source version?
pvbrowser is developed under openSUSE Linux. The binaries for Linux are compiled and packaged on the openSUSE Buildservice https://build.opensuse.org/package/show/home:pvbrowser/pvbrowser The binaries are tested on openSUSE and Ubuntu (but not all versions of those) The build log on Fedora 19 looks ok. https://build.opensuse.org/package/live_build_log/home:pvbrowser/pvbrowser/Fedora_19/x86_64
Especially you can see from the build log that pvslua is copied to the package. [ 572s] + cp language_bindings/lua/pvslua/pvslua /home/abuild/rpmbuild/BUILDROOT/pvbrowser-4.7.8-143.1.x86_64/opt/pvb/language_bindings/lua/pvslua/
xterm must be installed. You can build without xterm because we use qmake and Makefie. You can use the following commands to compile a project called pv.pro within a terminal. qmake pvs.pro make ./pvs
That is what i can say.
yes, pvslua is installed into /opt/pvb/language_bindings/lua/pvslua/pvslua but it's not installed into the path like pvbrowser/pvdevelp. (And one of them is installed directly, one as a symlink)
karlp@pojak:~/src/pvtest-lua$ ls -l /usr/bin/pv*
lrwxrwxrwx 1 root root 28 Oct 31 16:15 /usr/bin/pvbrowser -> /opt/pvb/pvbrowser/pvbrowser
-rwxr-xr-x 1 root root 501 Sep 27 15:36 /usr/bin/pvdevelop
karlp@pojak:~/src/pvtest-lua$
of course, the same problems occur with "missing" libraries calling pvslua :smile:
karlp@pojak:~/src/pvtest-lua$ /opt/pvb/language_bindings/lua/pvslua/pvslua
/opt/pvb/language_bindings/lua/pvslua/pvslua: error while loading shared libraries: libpvsmt.so.1: cannot open shared object file: No such file or directory
karlp@pojak:~/src/pvtest-lua$
Running qmake, make, and running pvs manually does indeed work, but as I'm saying, it can't find libpvsmt without LD_LIBRARY_FLAGS, so the xterm blinks and disappears. This is extremely perverse to try and debug. I greatly appreciate your responsiveness however, that's very impressive.
Note: As you may have realised, I have got it running at this point, but it doesn't work out of the box, it doesn't work via the menu commands "start server" and the diagnostics available to get it running manually are non-existant (a quickly blinking xterm, if you have one installed)
You can decide if you want to help us with bug reports or you may decide not to use pvbrowser. #####################################################
As said we build on the openSUSE Buildservice and test on openSUSE and Ubuntu.
Everything used for pvbrowser is installed to /opt/pvb Then some symbolic links are set. /usr/bin/pvbrowser -> /opt/pvb/pvbrowser/pvbrowser /usr/bin/pvdevelop # starts the real pvdevelop. In fact it is a shell script
export PYTHON_INCLUDE=$(find /usr/include -name "python2.*") if [ "x${PYTHON_INCLUDE}" = "x" ]; then echo "python support was not found" fi
if [ -d /usr/lib64 ] then echo find export PYTHON_LIB=$(find /usr/lib64 -name "libpython2.*.so") fi
if [ "x${PYTHON_LIB}" = "x" ]; then export PYTHON_LIB=$(find /usr/lib -name "libpython2.*.so") if [ "x${PYTHON_LIB}" = "x" ]; then echo "python support was not found" fi fi
/opt/pvb/pvdevelop/pvdevelop $1 $2 $3 $4 $5 $6 $7 $8 $9
############################# Same for libraries, they are also links to the real location under /opt/pvb If libraries are not found on your system when using "qmake pvs.pro && make" then something must be wrong on your system. Either ld-config was not run or whatever ...
We are only able to support all those platforms if we find users who report problems. Please decide yourself.
I've been trying to report a bug, but so far you've just kept saying that there's nothing wrong.
the libraries are installed, because pvbrowser/pvdevelop work out of the box, and both are in my regular $PATH. pvslua is not in my path. (but should be) and running the generated "pvs" binaries has incorrect link flags set at build time, so it doesn't find the installed libraries (unlike the provided pvbrowser/pvdevelop binaries) The same link problems affect pvslua, it only works with LD_LIBRARY_FLAGS at run time.
Ok, what can we do to fix these issues?
(1) ln -s /opt/pvb/language_bindings/lua/pvslua/pvslua /usr/bin/ It seems we should add the line above to the %install section of the pvbrowser RPM spec file. For the moment you can do that manually and report if this solves the problem with the $PATH.
With the libraries i have to inquire. As i understand you have set export LD_LIBRARY_PATH=/something:$LD_LIBRARY_PATH and then it worked for you.
These are the libraries provided by pvbrowser cd /opt/pvb: find . -name "*.so" ./rllib/lib/librllib.so ./designer/plugins/libpvb_designer_plugin.so ./designer/plugins/libqwt_designer_plugin.so ./browserplugin/libpvbrowser.so ./language_bindings/python/mt/_pv.so ./language_bindings/python/mt/_rllib.so ./language_bindings/python/id/_pv.so ./language_bindings/python/id/_rllib.so ./pvserver/libpvsmt.so ./pvserver/libpvsid.so
(Example) For libpvsmt there are the following links. cd /usr/ find . -name "libpvsmt.so*" ./lib/libpvsmt.so ./lib/libpvsmt.so.1.0 ./lib/libpvsmt.so.1.0.0 ./lib/libpvsmt.so.1
ls -al lib/libpvsmt.so* lrwxrwxrwx 1 root root 29 1. Okt 10:31 lib/libpvsmt.so -> /opt/pvb/pvserver/libpvsmt.so lrwxrwxrwx 1 root root 29 1. Okt 10:31 lib/libpvsmt.so.1 -> /opt/pvb/pvserver/libpvsmt.so lrwxrwxrwx 1 root root 29 1. Okt 10:31 lib/libpvsmt.so.1.0 -> /opt/pvb/pvserver/libpvsmt.so lrwxrwxrwx 1 root root 29 1. Okt 10:31 lib/libpvsmt.so.1.0.0 -> /opt/pvb/pvserver/libpvsmt.so
You understand ?
These links are set by the %install steps defined within the RPM spec file.
The post install steps within our RPM spec file are as follows. %postin /sbin/ldconfig chmod ugoa+rw /srv/automation/mbx chmod ugoa+rw /srv/automation/shm chmod ugoa+rw /srv/automation/log
Eventually /sbin/ldconfig did not work on Fedora 19 Please become root user and input the following command. which ldconfig What do you get ? You must run ldconfig in order to update the search path for the libraries. Eventually this is a Issue on Fedora. Please manually run ldconfig and tell me if now linking works as expected.
Couldn't find any issue tracking on pvbrowser.org
Working my way through the tutorial, made a lua project, immediately ran into problems with "Action->Start Server" This requires "xterm" to be installed, which I didn't have. I worked around that, but it still never starts any server, it just fails to find a font and sits there. Running "xterm" from the same shell launches a terminal, so that's working at least, and the missing font is then just a warning.