OpenSUSE will not install due libcv

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
SveaHund

OpenSUSE will not install due libcv

Post by SveaHund »

When trying to install FreeCAD in OpenSUSE via YAST it complains about missing libcv.so.1()(64bit). Now this library is infact included in libopencv1 BUT it's one version higher, i.e libcv.so.1.1()(64bit). This causes YAST to throw upp a warning with the message "nothing proivdes libcv.so.1()(64bit) needed by FreeCAD 0.7.2008-1.pm.5x86_64".

Would it be possible to make FreeCAD depending on libvc 1.0 AND higher? Or is it like hardwired to the 1.0 version? Doesn't the higher version contain the same procedures with the same names and doing the same things? Isn't the newer version just containing moore functions, not altered "old" functions?

Needless to say I'm REALLY in to make me and the world less dependent on the large CAD/CAE/FEM manufacturers. Free the CAD! =Ob
User avatar
jriegel
Founder
Posts: 3369
Joined: Sun Feb 15, 2009 5:29 pm
Location: Ulm, Germany
Contact:

Re: OpenSUSE will not install due libcv

Post by jriegel »

OpenCV is already deactivated in the Windows versions. The newer releases will not depend on OpenCV at all. We never really used it.

Jürgen
Stop whining - start coding!
wmayer
Founder
Posts: 20319
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: OpenSUSE will not install due libcv

Post by wmayer »

Hi,

which version of the cv lib is actually used depends on the configuration of your system, not on FreeCAD. In our configure.ac we use: PKG_CHECK_MODULES(opencv, opencv, [HAVE_OPENCV=true], [true])
which creates the variables opencv_LIBS and opencv_CFLAGS. These variables then are used in the Makefile.am in the Image module.

In order to use another version you may change the soflink cv.so to another file or check the content of your opencv.pc file.

Cheers,
Werner
SveaHund

Re: OpenSUSE will not install due libcv

Post by SveaHund »

Thanks a lot Werner, I will test your suggestion later this week and post an update on how it turned out.

Keep up the good work folks!
wmayer
Founder
Posts: 20319
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: OpenSUSE will not install due libcv

Post by wmayer »

As Jürgen already said the opencv stuff was added some time ago to the Image module but we hadn't the time to have a further look on it and extend the functionality there. The opencv libs are currently deactivated for the Windows port and I'll also -- at least for the time being -- deactivate it on the Linux version.

Is FreeCAD 0.7 part of the official packages under openSuse? If yes, then it's time for a new version, isn't it? :) Currently, we're working on the 0.9 version and will make a new release until end of October or beginning of Novermber. The estimated freeze of the Debian testing will be in December and for this time we'll want to release a usable version. Then I think it would make sense that other Linux distributions should have the same version.

Cheers,
Werner
SveaHund

Re: OpenSUSE will not install due libcv

Post by SveaHund »

Hi again, I just installed FreeCAD via YAST and it pulled in opencv version 2 automatically! This means someone at your place fixed the dependency really quickly, BRAVO!
Now, when firing it up it only contains a grey background drop... all menys and tool bars are gone.
It also pulled in QT 4.4.3 if that matters?

Any ideas?
wmayer
Founder
Posts: 20319
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: OpenSUSE will not install due libcv

Post by wmayer »

Hi,

if for any reason the startup module cannot be loaded it goes to a default, i.e. almost empty workbench. But you should be able to load another workbench under View>Workbenches in case the related module can be loaded.

To analyze the problem you can start FreeCAD with the option "-l" which creates a log file under $HOME/.FreeCAD. This file should contain some useful information why what happended.

Cheers,
Werner
SveaHund

Re: OpenSUSE will not install due libcv

Post by SveaHund »

My log according to your instructions:

Msg: FreeCAD 0.7, Libs: 0.8R2237
(c) Juergen Riegel, Werner Mayer 2001-2009

Log: Time = Tue Sep 29 18:49:59 2009
Log: AppDataSkipVendor = true
Log: AppHomePath = /usr/
Log: AppIcon = FCIcon
Log: BinPath = /usr/bin/
Log: BuildCurrentDate = Fri Jul 10 19:48:23 2009
Log: BuildRepositoryURL = https://free-cad.svn.sourceforge.net/sv ... ersion-0-8
Log: BuildRevision = 2237
Log: BuildVersionMajor = 0
Log: BuildVersionMinor = 8
Log: ConsoleBanner = (c) Juergen Riegel, Werner Mayer 2001-2009

Log: Debug = 0
Log: DocPath = /usr/doc/
Log: ExeName = FreeCAD
Log: ExeVendor = FreeCAD
Log: ExeVersion = 0.7
Log: LoggingFile = 1
Log: LoggingFileName = /home/MyHomeDirectory/.FreeCAD/FreeCAD.log
Log: MaintainerUrl = http://apps.sourceforge.net/mediawiki/f ... =Main_Page
Log: PATH = /home/MyHomeDirectory/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/X11R6/bin:/usr/games:/opt/kde3/bin:/usr/lib64/jvm/jre/bin:/usr/lib/mit/bin:/usr/lib/mit/sbin:.
Log: PythonSearchPath = /usr/lib/python26.zip:/usr/lib64/python2.6/:/usr/lib64/python2.6/plat-linux2:/usr/lib64/python2.6/lib-tk:/usr/lib64/python2.6/lib-old:/usr/lib64/python2.6/lib-dynload
Log: RunMode = Gui
Log: SplashAlignment = Bottom|Left
Log: SplashPicture = FreeCADSplasher
Log: SplashTextColor = #000000
Log: StartWorkbench = CompleteWorkbench
Log: SystemParameter = /home/MyHomeDirectory/.FreeCAD/system.cfg
Log: UserAppData = /home/MyHomeDirectory/.FreeCAD/
Log: UserHomePath = /home/MyHomeDirectory
Log: UserParameter = /home/MyHomeDirectory/.FreeCAD/user.cfg
Log: Verbose =
Log: Create Application
Log: Init: starting App::FreeCADInit.py
Log: Using /usr/Mod as module path!
Wrn: No modules found in /usr/Mod
Log: Init: Searching for modules...
Log: System path after init:
Log: /usr/bin
Log: /home/MyHomeDirectory/bin
Log: /usr/local/bin
Log: /usr/bin
Log: /bin
Log: /usr/bin/X11
Log: /usr/X11R6/bin
Log: /usr/games
Log: /opt/kde3/bin
Log: /usr/lib64/jvm/jre/bin
Log: /usr/lib/mit/bin
Log: /usr/lib/mit/sbin
Log: .
Log: Init: App::FreeCADInit.py done
Log: Init: Creating Gui::Application and QApplication
Log: Object::connect: No such slot Gui::DockWnd::TaskPanelView::task1()
Log: Init: Running FreeCADGuiInit.py start script...
Log: Init: Searching modules...
Log: Init: Loading FreeCAD GUI
Log: Init: Running FreeCADGuiInit.py start script... done
Log: Init: Activating default workbench CompleteWorkbench
Log: Init: Showing main window
Log: Main window restored
Log: Show main window
Log: Toolbars restored
Log: Connecting to host...
Log: Sending to host...
Log: Reading from host...
Log: Download failed: Found
Log: Request aborted
Log: Request aborted
Log: Init: Processing command line files
Log: Init: Entering event loop

It didn't find any directory called /usr/Mod/ (since it doesn't exist).
Would it be possible to make the code less "hardwired" and use the OS paths instead? Or quote the OS for what you are looking for and if that fails, install the missing bits? Or is too much to keep track of? But perhaps the guys at the different OS-makers could participate with the small effort of just sending you the paths as they change their respective systems? Mabye there are some other way around to fix this sort of problem with minimal effort?
wmayer
Founder
Posts: 20319
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: OpenSUSE will not install due libcv

Post by wmayer »

It didn't find any directory called /usr/Mod/ (since it doesn't exist).
Would it be possible to make the code less "hardwired" and use the OS paths instead? Or quote the OS for what you are looking for and if that fails, install the missing bits? Or is too much to keep track of? But perhaps the guys at the different OS-makers could participate with the small effort of just sending you the paths as they change their respective systems? Mabye there are some other way around to fix this sort of problem with minimal effort?
The point is that the directory structure is broken. If FreeCAD is e.g. installed to /opt/FreeCAD then the expected structure is:
* /opt/FreeCAD/bin -- with the binaries
* /opt/FreeCAD/lib -- with the libs
* /opt/FreeCAD/doc -- with the docs (./configure's --docdir switch is now supported to use another location e.g. /usr/share/doc/freecad)
* /opt/FreeCAD/Mod -- all modules

When starting FreeCAD we first extract the location of the executable (here: /opt/FreeCAD/bin) and go one level up. There we look for the directory 'Mod' which contains all the modules.

On Debian we do it this way:
* almost everything is installed under /usr/lib/freecad (can be changed with ./configure --prefix)
Other big projects do it the same way like OpenOffice for instance. IMO it's OK for smaller applications to split them into several directories but for bigger projects this is only feasible to a certain point.
* documentation (now) gets installed under /usr/share/doc/freecad (can be changed with ./configure --docdir)
* resource files (now) get installed under /usr/share/freecad/ (can be changed with ./configure --datadir)

Especially for the Debian installation we create a symbolic link under /usr/bin to the executable. Maybe it could make sense to support to install the 'Mod' directory to a separate location (e.g. into Python's site-packages directory) because these are all real Python extension modules.

To fix your problem you must first locate the actual FreeCAD location and move the above listed directories into there. Then simply create a symlink under /usr/bin to the actual executable. This should solve the problem.
SveaHund

Re: OpenSUSE will not install due libcv

Post by SveaHund »

Hi again, this time it complains about:

MyFancyComputer:/opt/FreeCAD/bin # FreeCAD
FreeCAD: error while loading shared libraries: libFreeCADGui.so.2: cannot open shared object file: No such file or directory
MyFancyComputer:/opt/FreeCAD/bin #

but when looking in /opt/FreeCAD/lib64/ it is present. This leads me to believe there's a linking problem yet again.

Oh, and I do have the very latest releases of everything from Packman Bremen.
Trying to launch it from SUSE's meny as a user gives nothing nowadays. Trying to launch it from a terminal in the installation directory as root gives the above.

By the way, how about contacting "the Drop design team" [Fintan Darragh, Rob Frampton, Matt Gaunt, Jack O'Connor, Samuel Smith and Daniel Welsh] (www.drop-game.co.uk) to investigate the possibility to implement their technology with your CAD software? In the long run one could finally design things using just position oriented gloves and get rid of the never ending mouse clicking! (my wet dream since Volvo Trucks introduced ProEngineer at its engine department some 15 years ago) Think of it as designing with a lump of clay or something like that. Extruding, dimensioning, hole drilling, milling and everything else without clicking! Shortly: more intuitive than today's not-so-clever CATIA, which by the way can not handle what it has in memory versus on screen... One must restart it at lunch time to make sure it doesn't crash during afternoon coffee brake.
Post Reply