Ubuntu 16.04 Compile Issue

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
wescorp
Posts: 2
Joined: Mon Dec 05, 2016 7:35 pm

Ubuntu 16.04 Compile Issue

Post by wescorp »

First time poster here. Newbie to compiling FreeCAD. I've been following the instructions http://www.freecadweb.org/wiki/?title=CompileOnUnix
and attempting to compile on Ubuntu 16.04.1 LTS. Using Google and notes in this form, I've been able almost get a successfull compile.

This is what where I've gotten to so far and looking for help, hints, suggestions.

Thanks.

root@wes-OptiPlex-755:/home/wes/Desktop/folders/freecad_17/FreeCAD-0.17_pre# cmake -DFREECAD_USE_EXTERNAL_PIVY=1 -DCMAKE_BUILD_TYPE=Release
-- prefix: /usr/local
-- datadir: data
-- docdir: doc
-- includedir: include
-- libdir: /usr/local/lib
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- filesystem
-- program_options
-- regex
-- signals
-- system
-- thread
-- chrono
-- date_time
-- atomic
-- Found Xerces-C: /usr/local/lib/libxerces-c.so
-- PyCXX found:
-- Headers: /home/wes/Desktop/folders/freecad_17/FreeCAD-0.17_pre/src
-- Sources: /home/wes/Desktop/folders/freecad_17/FreeCAD-0.17_pre/src/CXX
-- -- OpenCASCADE Community Edition has been found.
-- -- Found OCE/OpenCASCADE version: 6.8.0
-- -- OCE/OpenCASCADE include directory: /usr/lib/x86_64-linux-gnu/oce-0.17/../../../include/oce
-- -- OCE/OpenCASCADE shared libraries directory:
-- Checking for module 'Coin'
-- Found Coin, version 3.1.3
-- libshiboken built for Release
-- Found PySide Tools: /usr/bin/pyside-uic, /usr/bin/pyside-rcc
-- -- matplotlib-1.5.1 has been found.
-- Platform is 64-bit, set -D_OCC64
-- Build type: Release
sh: 1: git: not found
sh: 1: bzr: not found
sh: 1: svnversion: not found
sh: 1: svn: not found
-- setting gcc options: -Wall -Werror -Wno-deprecated -pedantic-errors
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- python
-- found Boost: 1_58
-- boost-incude dirs are: /usr/include
-- boost-python lib is: /usr/lib/x86_64-linux-gnu/libboost_python.so
-- boost_LIBRARY_DIRS is: /usr/lib/x86_64-linux-gnu
-- Boost_LIBRARIES is: /usr/lib/x86_64-linux-gnu/libboost_python.so
-- area module (for Path Workbench) will be installed to: /usr/local/lib
-- Coin3D doc is not installed
=======================================
Now run 'make' to build FreeCAD
=======================================

-- Configuring done
-- Generating done
-- Build files have been written to: /home/wes/Desktop/folders/freecad_17/FreeCAD-0.17_pre
root@wes-OptiPlex-755:/home/wes/Desktop/folders/freecad_17/FreeCAD-0.17_pre# make -j4
[ 1%] Built target Driver
[ 2%] Built target Test
[ 2%] Built target MEFISTO2
[ 4%] Built target SMDS
[ 4%] Generating ../../../Mod/Material/Material_rc.py
[ 5%] Built target MaterialLib
[ 6%] Built target WizardShaft
[ 6%] Built target Material
[ 6%] Generating ../../../Mod/Draft/Draft_rc.py
[ 7%] Built target Idf
[ 8%] Built target ImportPy
[ 9%] Built target Draft
[ 9%] Generating ../../../Mod/Arch/Arch_rc.py
[ 9%] Generating ../../../Mod/OpenSCAD/OpenSCAD_rc.py
[ 9%] Generating ../../../Mod/Plot/Plot_rc.py
Scanning dependencies of target FreeCADBase
[ 10%] Built target Arch
[ 11%] Built target OpenSCAD
[ 12%] Built target Plot
[ 14%] Built target PathScripts
[ 17%] Built target Stylesheets_data
[ 18%] Built target area
[ 18%] Built target Example_data
[ 18%] Built target DriverDAT
[ 18%] Built target DriverSTL
[ 18%] Built target SMESHDS
[ 19%] Built target DriverUNV
[ 20%] Built target SMESH
[ 21%] Built target StdMeshers
[ 21%] Building CXX object src/Base/CMakeFiles/FreeCADBase.dir/swigpyrun.cpp.o
[ 21%] Linking CXX shared library ../../lib/libFreeCADBase.so
[ 26%] Built target FreeCADBase
[ 26%] Linking CXX shared library ../../lib/libFreeCADApp.so
[ 28%] Built target FreeCADApp
[ 28%] Linking CXX executable ../../bin/FreeCADCmd
[ 28%] Linking CXX shared library ../../lib/FreeCAD.so
[ 28%] Linking CXX shared library ../../../../Mod/Points/Points.so
[ 28%] Built target FreeCADMainPy
[ 28%] Linking CXX shared library ../../../../Mod/Image/Image.so
[ 28%] Built target FreeCADMainCmd
[ 28%] Built target Points
[ 28%] Linking CXX shared library ../../../../Mod/Mesh/Mesh.so
[ 29%] Built target Image
[ 29%] Linking CXX shared library ../../../../Mod/Spreadsheet/Spreadsheet.so
[ 30%] Built target Spreadsheet
[ 30%] Linking CXX shared library ../../../../Mod/Web/Web.so
[ 30%] Linking CXX shared library ../../lib/libFreeCADGui.so
[ 30%] Linking CXX shared library ../../../../Mod/Part/Part.so
[ 30%] Built target Web
[ 30%] Linking CXX shared library ../../../../Mod/Start/Start.so
[ 30%] Built target Start
[ 34%] Built target Mesh
[ 39%] Built target Part
[ 39%] Linking CXX shared library ../../../../Mod/Raytracing/Raytracing.so
[ 39%] Linking CXX shared library ../../../../Mod/Sketcher/Sketcher.so
[ 39%] Linking CXX shared library ../../../../Mod/PartDesign/_PartDesign.so
[ 58%] Built target FreeCADGui
[ 58%] Linking CXX shared library ../../../../Mod/Drawing/Drawing.so
[ 59%] Built target Raytracing
[ 59%] Linking CXX shared library ../../../../Mod/Robot/Robot.so
[ 61%] Built target Drawing
[ 63%] Built target PartDesign
[ 64%] Linking CXX shared library ../../../../Mod/MeshPart/MeshPart.so
[ 64%] Linking CXX shared library ../../../../Mod/Draft/DraftUtils.so
[ 65%] Built target Sketcher
[ 65%] Linking CXX shared library ../../../../Mod/Web/WebGui.so
[ 65%] Built target DraftUtils
[ 65%] Linking CXX shared library ../../../../Mod/Start/StartGui.so
[ 65%] Built target MeshPart
[ 65%] Built target WebGui
[ 65%] Linking CXX shared library ../../../../Mod/Import/Import.so
[ 67%] Built target StartGui
[ 67%] Linking CXX shared library ../../../../Mod/Fem/Fem.so
[ 71%] Built target Robot
[ 71%] Linking CXX shared library ../../../../Mod/Spreadsheet/SpreadsheetGui.so
[ 71%] Linking CXX shared library ../../../../Mod/Path/Path.so
[ 72%] Built target Import
[ 72%] Linking CXX executable ../../bin/FreeCAD
[ 73%] Built target Path
[ 74%] Linking CXX shared library ../../lib/FreeCADGui.so
[ 75%] Built target SpreadsheetGui
[ 75%] Linking CXX shared library ../../../../Mod/Points/PointsGui.so
[ 78%] Built target Fem
[ 78%] Linking CXX shared library ../../../../Mod/Test/QtUnitGui.so
../../lib/libFreeCADGui.so: undefined reference to `SoInput::setBuffer(void*, unsigned long)'
../../lib/libFreeCADGui.so: undefined reference to `ScXML::readBuffer(char const*)'
../../lib/libFreeCADGui.so: undefined reference to `SoGLTextureEnabledElement::set(SoState*, SoNode*, int)'
../../lib/libFreeCADGui.so: undefined reference to `SoGLTexture3EnabledElement::set(SoState*, SoNode*, int)'
collect2: error: ld returned 1 exit status
src/Main/CMakeFiles/FreeCADMain.dir/build.make:123: recipe for target 'bin/FreeCAD' failed
make[2]: *** [bin/FreeCAD] Error 1
CMakeFiles/Makefile2:789: recipe for target 'src/Main/CMakeFiles/FreeCADMain.dir/all' failed
make[1]: *** [src/Main/CMakeFiles/FreeCADMain.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 78%] Built target FreeCADGuiPy
[ 79%] Built target PointsGui
[ 79%] Built target QtUnitGui
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2
root@wes-OptiPlex-755:/home/wes/Desktop/folders/freecad_17/FreeCAD-0.17_pre#
User avatar
yorik
Founder
Posts: 13640
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: Ubuntu 16.04 Compile Issue

Post by yorik »

I'm pretty sure there is a problem with coin... (the "SoXXX" symbols are all from coin). The coin version stated by cmake above is 3.1.3, which is unlikely to be the version on ubuntu 16.04. Search for libcoin in your installed packages, normally you should have libcoin80 (which is actually version 4, don't ask me why). I don't think libcoin60 (coin v3) is available anymore. You also need libsoqt with the same version number (3 or 4). Would you have several versions of coin on your machine maybe?
damian
Posts: 583
Joined: Sun May 31, 2015 6:16 pm

Re: Ubuntu 16.04 Compile Issue

Post by damian »

I'm compiling in Ubuntu 16.04, where libcoin is:
libcoin80-dev
libcoin80v5

OS: Ubuntu 16.04.1 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.9166 (Git)
Build type: Unknown
Branch: master
Hash: 7a32aed27e5febf94611a3356d4f20b2bc6b6bf3
Python version: 2.7.12
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.1.0
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Ubuntu 16.04 Compile Issue

Post by NormandC »

yorik wrote:You also need libsoqt with the same version number
Are you saying libsoqt4 is still required? I thought it was no longer used with the switch to quarter?

I just had a look in Synaptic and I saw it's pulled by python-pivy, and freecad somehow still depends on it even though it's no longer listed as build dependency.
wescorp wrote:sh: 1: git: not found
You should install git so the freecad info is reported fully in the About FreeCAD dialog.

And please use "Code" tags when pasting code as long as this. It avoids pages here growing one-kilometer long.
User avatar
yorik
Founder
Posts: 13640
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: Ubuntu 16.04 Compile Issue

Post by yorik »

NormandC wrote:Are you saying libsoqt4 is still required? I thought it was no longer used with the switch to quarter?
Hm I think you are right... Indeed I just checked, FreeCAD itself doesn't seem to use soqt anymore
wescorp
Posts: 2
Joined: Mon Dec 05, 2016 7:35 pm

Re: Ubuntu 16.04 Compile Issue

Post by wescorp »

Thanks for all the answers. I'd had a problem install the 3dcoin files earlier and thought I'd fixed any issues. I'm going to do a clean install in the next couple days and will report back. Thanks again.
Post Reply