How to activate openCamLib after compiling it
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
How to activate openCamLib after compiling it
Hello,
After trying to use the surfacing operations in the Path module I learned that openCamLib is required. I cloned the repository: https://github.com/aewallin/opencamlib, built the openCamLibs as according to the README, except I didn't do the install step. If possible, I'd like to keep the library in a unprivileged directory. I expect that FreeCAD is expecting the openCamLib to be in /usr/lib or some standard place.
I tried:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$MY_INSTALLATION_DIRECTORY
before starting FreeCAD and I still get this message in the report view:
This operation requires OpenCamLib to be installed.
Adam
OS: Ubuntu 14.04.5 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.9453 (Git)
Build type: Unknown
Branch: (detached from 0.16_pre)
Hash: b16fbcd4eeb9a5f9195c500e2693cba25a7916d2
Python version: 2.7.6
Qt version: 4.8.6
Coin version: 4.0.0a
OCC version: 6.7.1.oce-0.16
After trying to use the surfacing operations in the Path module I learned that openCamLib is required. I cloned the repository: https://github.com/aewallin/opencamlib, built the openCamLibs as according to the README, except I didn't do the install step. If possible, I'd like to keep the library in a unprivileged directory. I expect that FreeCAD is expecting the openCamLib to be in /usr/lib or some standard place.
I tried:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$MY_INSTALLATION_DIRECTORY
before starting FreeCAD and I still get this message in the report view:
This operation requires OpenCamLib to be installed.
Adam
OS: Ubuntu 14.04.5 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.9453 (Git)
Build type: Unknown
Branch: (detached from 0.16_pre)
Hash: b16fbcd4eeb9a5f9195c500e2693cba25a7916d2
Python version: 2.7.6
Qt version: 4.8.6
Coin version: 4.0.0a
OCC version: 6.7.1.oce-0.16
Re: How to activate openCamLib after compiling it
I think I'm getting closer to the answer. I need to make sure the 'ocl' python module can be imported. This is the code that is generating the error:
Mod/Path/PathScripts/PathSurface.py
Mod/Path/PathScripts/PathSurface.py
Code: Select all
if obj.Algorithm in ['OCL Dropcutter', 'OCL Waterline']:
try:
import ocl
except:
FreeCAD.Console.PrintError(translate(
"PathSurface", "This operation requires OpenCamLib to be installed.\n"))
return
Re: How to activate openCamLib after compiling it
sudo make install makes quick work of this.
Problem solved
Problem solved
Re: How to activate openCamLib after compiling it
I think adding the path to lib would work if you didn't want to install
In the python console
You would need to do it after every restart. or start FreeCAD with the -P switch and add the path.
Oh, or put the library in your macros folder, it's already in sys.path.
In the python console
Code: Select all
import sys
sys.path.append("...")
Oh, or put the library in your macros folder, it's already in sys.path.
"fight the good fight"
Re: How to activate openCamLib after compiling it
I will keep those in mind. Thanks sgrogan!
Re: How to activate openCamLib after compiling it
Hi,
I know this is an old thread. I'm having the same issue, I compiled opencamlib and did a make install, this is the output:
However FreeCAD doesn't find Opencamlib:
Where should be Opencamlib installed in order to be usable by Freecad?
Thank you very much in advance.
I know this is an old thread. I'm having the same issue, I compiled opencamlib and did a make install, this is the output:
Code: Select all
Install the project...
-- Install configuration: ""
-- Installing: /usr/lib64/python2.7/site-packages/ocl.so
-- Up-to-date: /usr/lib/python2.7/site-packages
-- Up-to-date: /usr/lib/python2.7/site-packages/pyocl.py
-- Up-to-date: /usr/lib/python2.7/site-packages/camvtk.py
-- Up-to-date: /usr/lib/python2.7/site-packages/procmemory.py
-- Up-to-date: /usr/lib/python2.7/site-packages/STLTools.py
-- Up-to-date: /usr/lib/opencamlib/libocl.so.11.10.73
-- Up-to-date: /usr/lib/opencamlib/libocl.so
-- Up-to-date: /usr/include/opencamlib/arc.hpp
-- Up-to-date: /usr/include/opencamlib/bbox.hpp
-- Up-to-date: /usr/include/opencamlib/ccpoint.hpp
-- Up-to-date: /usr/include/opencamlib/clpoint.hpp
-- Up-to-date: /usr/include/opencamlib/line.hpp
-- Up-to-date: /usr/include/opencamlib/path.hpp
-- Up-to-date: /usr/include/opencamlib/stlreader.hpp
-- Up-to-date: /usr/include/opencamlib/stlsurf.hpp
-- Up-to-date: /usr/include/opencamlib/triangle.hpp
-- Up-to-date: /usr/include/opencamlib/point.hpp
-- Up-to-date: /usr/include/opencamlib/ballcutter.hpp
-- Up-to-date: /usr/include/opencamlib/bullcutter.hpp
-- Up-to-date: /usr/include/opencamlib/compositecutter.hpp
-- Up-to-date: /usr/include/opencamlib/conecutter.hpp
-- Up-to-date: /usr/include/opencamlib/cylcutter.hpp
-- Up-to-date: /usr/include/opencamlib/ellipseposition.hpp
-- Up-to-date: /usr/include/opencamlib/millingcutter.hpp
-- Up-to-date: /usr/include/opencamlib/ellipse.hpp
-- Up-to-date: /usr/include/opencamlib/adaptivepathdropcutter.hpp
-- Up-to-date: /usr/include/opencamlib/pathdropcutter.hpp
-- Up-to-date: /usr/include/opencamlib/batchdropcutter.hpp
-- Up-to-date: /usr/include/opencamlib/pointdropcutter.hpp
-- Up-to-date: /usr/include/opencamlib/brent_zero.hpp
-- Up-to-date: /usr/include/opencamlib/kdnode.hpp
-- Up-to-date: /usr/include/opencamlib/kdtree.hpp
-- Up-to-date: /usr/include/opencamlib/numeric.hpp
-- Up-to-date: /usr/include/opencamlib/lineclfilter.hpp
-- Up-to-date: /usr/include/opencamlib/clfilter.hpp
-- Up-to-date: /usr/include/opencamlib/halfedgediagram.hpp
-- Up-to-date: /usr/include/opencamlib/operation.hpp
-- Up-to-date: /usr/include/opencamlib/batchpushcutter.hpp
-- Up-to-date: /usr/include/opencamlib/fiberpushcutter.hpp
-- Up-to-date: /usr/include/opencamlib/fiber.hpp
-- Up-to-date: /usr/include/opencamlib/interval.hpp
-- Up-to-date: /usr/include/opencamlib/waterline.hpp
-- Up-to-date: /usr/include/opencamlib/adaptivewaterline.hpp
-- Up-to-date: /usr/include/opencamlib/weave.hpp
-- Up-to-date: /usr/include/opencamlib/simple_weave.hpp
-- Up-to-date: /usr/include/opencamlib/smart_weave.hpp
-- Up-to-date: /usr/include/opencamlib/weave_typedef.hpp
-- Up-to-date: /usr/include/opencamlib/tsp.hpp
-- Installing: /usr/include/opencamlib/version_string.hpp
Code: Select all
FreeCAD 0.17, Libs: 0.17R12435 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2017
##### #### ### ####
# # # # # #
# ## #### #### # # # # #
#### # # # # # # # ##### # #
# # #### #### # # # # #
# # # # # # # # # ## ## ##
# # #### #### ### # # #### ## ## ##
Path workbench activated
Surfacing Select Mode
base object: Clone
This operation requires OpenCamLib to be installed.
Free Select
Thank you very much in advance.
Re: How to activate openCamLib after compiling it
- Please verify if the files are in fact to be found under /usr/local/lib, especially the *.so files.
- verify if /usr/local/lib is contained in /etc/ld.so.conf.d/libc.conf
- run ldconfig and try
- run ldconfig /usr/local/lib and try.
- verify if /usr/local/lib is contained in /etc/ld.so.conf.d/libc.conf
- run ldconfig and try
- run ldconfig /usr/local/lib and try.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Re: How to activate openCamLib after compiling it
Thank you for your reply. Files were installed in /usr/lib.
Re: How to activate openCamLib after compiling it
I did it but I had no success.
Re: How to activate openCamLib after compiling it
Today I wanterd to get ocl running again and cannot find it anymore in Path WB. Did I miss the removal or is it something with my eyes?
OS: Ubuntu 14.04.5 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.12772 (Git)
Build type: None
Branch: master
Hash: c8c9b76f43d2c78c4afb65b756f3f07d626aac85
Python version: 2.7.6
Qt version: 4.8.6
Coin version: 4.0.0a
OCC version: 7.1.0
Locale: English/UnitedStates (en_US)
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.