Compiling on Mac ... problem with the prerequisites with homebrew

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
nyholku
Posts: 149
Joined: Wed Dec 28, 2016 4:18 pm

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by nyholku »

Hi,

ok, so I tried what you suggested.

Code: Select all

nyholku$ brew deps FreeCAD/freecad/freecad | xargs brew uninstall --ignore-dependencies
Uninstalling /usr/local/Cellar/coin/3.1.3... (866 files, 9.1M)
Uninstalling /usr/local/Cellar/med-file/3.2.0... (57 files, 1.7M)
Uninstalling /usr/local/Cellar/nglib/5.3.1_2... (208 files, 6.0M)
nglib 5.3.1 is still installed.
Remove all versions with `brew uninstall --force nglib`.
Uninstalling /usr/local/Cellar/pivy/HEAD-8eab90908f2a... (48 files, 14.3M)
Uninstalling /usr/local/Cellar/boost/1.63.0... (12,491 files, 417.2M)
Uninstalling /usr/local/Cellar/boost-python/1.63.0... (458 files, 17.5M)
Uninstalling /usr/local/Cellar/pyside/1.2.2_1... (92 files, 23.2M)
Uninstalling /usr/local/Cellar/pyside-tools/0.2.15... (41 files, 388.1K)
Uninstalling /usr/local/Cellar/qt/4.8.7_3... (2,816 files, 113.3M)
Uninstalling /usr/local/Cellar/shiboken/1.2.2... (34 files, 3.0M)
Uninstalling /usr/local/Cellar/eigen/3.3.1... (486 files, 6.4M)
Uninstalling /usr/local/Cellar/fontconfig/2.12.1_2... (468 files, 3M)
Uninstalling /usr/local/Cellar/freeimage/3.17.0... (11 files, 30.2M)
Uninstalling /usr/local/Cellar/freetype/2.7.1... (62 files, 2.5M)
freetype 2.7 is still installed.
Remove all versions with `brew uninstall --force freetype`.
Uninstalling /usr/local/Cellar/gdbm/1.12... (18 files, 490.9K)
Uninstalling /usr/local/Cellar/gl2ps/1.3.9_2... (12 files, 228K)
Uninstalling /usr/local/Cellar/hdf5/1.8.18... (181 files, 10.6M)
hdf5 1.8.17 is still installed.
Remove all versions with `brew uninstall --force hdf5`.
Error: No such file or directory - /usr/local/Cellar/hdf5/1.8.18
So this was not successful, at least completely. So I run it again:

Code: Select all

brew deps FreeCAD/freecad/freecad | xargs brew uninstall --ignore-dependencies
Error: No such keg: /usr/local/Cellar/coin
So I quit that approach and tried:

Code: Select all

brew install --only-dependencies FreeCAD/freaked/freecad
Updating Homebrew...
==> Auto-updated Homebrew!
Updated 1 tap (homebrew/core).
==> Updated Formulae
pyqt5 ✔                                                                                   sip ✔

==> Tapping freecad/freaked
Cloning into '/usr/local/Homebrew/Library/Taps/freecad/homebrew-freaked'...
remote: Repository not found.
fatal: repository 'https://github.com/FreeCAD/homebrew-freaked/' not found
Error: Failure while executing: git clone https://github.com/FreeCAD/homebrew-freaked /usr/local/Homebrew/Library/Taps/freecad/homebrew-freaked --depth=1
Ok, so that is not going to fly I think.

The I did what originally worked for me:

Code: Select all

nyholkus-MacBook-Pro-5:build nyholku$ brew tap homebrew/science
nyholkus-MacBook-Pro-5:build nyholku$ brew tap freecad/freecad
nyholkus-MacBook-Pro-5:build nyholku$ brew install --only-dependencies freecad --with-freecad-bottles
This completed but I noticed this:

Code: Select all

==> Installing freecad/freecad/freecad dependency: cartr/qt4/pyside
==> Downloading https://dl.bintray.com/cartr/bottle-qt4/pyside-1.2.2_1.yosemite.bottle.tar.gz
Already downloaded: /Users/nyholku/Library/Caches/Homebrew/pyside-1.2.2_1.yosemite.bottle.tar.gz
Error: SHA256 mismatch
Expected: 8c2463514cd2133b9237143ceb2d73e64f96ff162c5c302b28f894132ad88490
Actual: b87ab7f4961d669028237d7aefafb71863619f09f1c35ec2d4718283cfff561b
Archive: /Users/nyholku/Library/Caches/Homebrew/pyside-1.2.2_1.yosemite.bottle.tar.gz
To retry an incomplete download, remove the file above.
So I said to myself, "Ha, this is the problem with the pyside", so I deleted the offending file, retried and things seemed to go ok.

So I tried Cmake and it failed like this:

Code: Select all

CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
NGLIB_INCLUDE_DIR
   used as include directory in directory /Users/nyholku/FreeCAD/FreeCAD-git/src/3rdParty/salomesmesh
   used as include directory in directory /Users/nyholku/FreeCAD/FreeCAD-git/src/3rdParty/salomesmesh
   used as include directory in directory /Users/nyholku/FreeCAD/FreeCAD-git/src/3rdParty/salomesmesh


At this point I concluded that the uninstallation of pre-requisites had removed something that the bottled installation does not contain.

So went again manually through installing the pre-requisites that are listed in this page:

http://www.freecadweb.org/wiki/?title=CompileOnMac

which of course needed some TLC as some of the things are in multiple taps.

But after that the CMake worked and compilation with make worked.

The resulting FreeCAD runs but complains about the pyside again:

Code: Select all

Last login: Sun Jan 15 11:25:41 on ttys003
nyholkus-MacBook-Pro-5:~ nyholku$ /Users/nyholku/FreeCAD/build/bin/FreeCAD ; exit;
FreeCAD 0.17, Libs: 0.17R9422 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2016
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##

Hello from ~/Library/PreferencesFreeCAD/Mod/cloud9/Init.py
During initialization the error dlopen(/Applications/FreeCAD.app/Contents/lib/Part.so, 2): Symbol not found: __ZN5boost16re_detail_10600012perl_matcherIPKcNSt3__19allocatorINS_9sub_matchIS3_EEEENS_12regex_traitsIcNS_16cpp_regex_traitsIcEEEEE14construct_initERKNS_11basic_regexIcSC_EENS_15regex_constants12_match_flagsE
  Referenced from: /Applications/FreeCAD.app/Contents/lib//libFreeCADBase.dylib
  Expected in: /usr/local/opt/boost/lib/libboost_regex-mt.dylib
 in /Applications/FreeCAD.app/Contents/lib//libFreeCADBase.dylib occurred in /Users/nyholku/Library/Preferences/FreeCAD/Mod/cloud9/Init.py
During initialization the error No module named PySide occurred in /Users/nyholku/FreeCAD/build/Mod/Ship/InitGui.py
During initialization the error No module named PySide occurred in /Users/nyholku/FreeCAD/build/Mod/Plot/InitGui.py
Hello from ~/Library/PreferencesFreeCAD/Mod/cloud9/InitGUI.py TEST1
During initialization the error No module named PySide occurred in /Users/nyholku/FreeCAD/build/Mod/Draft/InitGui.py
During initialization the error No module named PySide occurred in /Users/nyholku/FreeCAD/build/Mod/Arch/InitGui.py
No module named PySide
Coin warning in cc_glglue_instance(): Error when setting up the GL context. This can happen if there is no current context, or if the context has been set up incorrectly.
Failed to import BOPTools package:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/Users/nyholku/FreeCAD/build/Mod/Part/BOPTools/__init__.py", line 47, in importAll
    from . import JoinFeatures
  File "/Users/nyholku/FreeCAD/build/Mod/Part/BOPTools/JoinFeatures.py", line 35, in <module>
    from PySide import QtCore, QtGui
<type 'exceptions.ImportError'>: No module named PySide
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/Users/nyholku/FreeCAD/build/Mod/Part/AttachmentEditor/Commands.py", line 27, in <module>
    from PySide import QtCore
<type 'exceptions.ImportError'>: No module named PySide
Can't find Origin for "Body"
Can't find Origin for "Body"
Can't find Origin for "Body001"
Can't find Origin for "Body001"
Reading failed from embedded file: PartShape.bin (0 bytes, 2 bytes compressed)
2017-01-15 21:58:57.321 FreeCAD[72209:387896] modalSession has been exited prematurely - check for a reentrant call to endModalSession:

But as everything seems to work, do I really need pyside?

I guess the main takeaway from this whole thread is that the easy prerequisite installation with the bottles is not complete (as I suspected) and that manually installing all the dependencies listed on that page fixes things.

And that with Xcode 7.2 it is necessary to specify 10.11 deployment target. More or less what I said in my summary.

cheers Kusti

PS

Boys is the C build system brittle when it is based on system installed shared libraries.

Would it not be much better to have the project have its own libraries and system installed?

Is there no Maven equivalent system for C that would pull the correct version of required libraries automatically from some common repo?

With the current system so many people are fighting the tool chain and probably there are subtle errors when the version of the system installed libraries that are used when people who build from source are (likely) different from those that the FreeCAD is tested against?!

Not to mention that installing libraries needed by some other project is likely break an other project build.

Just saying...
peterl94
Veteran
Posts: 1001
Joined: Thu May 23, 2013 7:31 pm
Location: United States

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by peterl94 »

nyholku wrote:But as everything seems to work, do I really need pyside?
Only if you want to use anything mentioned in the error message: Draft, Arch, Ship, and some Part tools written in Python.

By the way, I see what seems like a typo in one of your "brew install --only-dependencies" attempts. FreeCAD/freaked/freecad. :D

The first thing I would do is find out where PySide is actually installed to (or linked to -- it would be installed in the Cellar). The folder PySide should show up if you enter the following.

Code: Select all

ls /usr/local/opt/python/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
Also try importing it from the python interpreter.

Code: Select all

which python
python
>>> import PySide
>>> PySide.__path__
blacey
Posts: 370
Joined: Tue Dec 08, 2015 11:28 pm

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by blacey »

peterl94 wrote:By the way, I see what seems like a typo in one of your "brew install --only-dependencies" attempts. FreeCAD/freaked/freecad. :D
That's my fault, or I should I say autocorrect! Arghhhh.

@nyholku, if you are up for it, I can walk you through resetting Homebrew and rebuilding from scratch. Travis does this all the time and I do the same on a VM. Perhaps you have some /usr/local cruft that is wreaking havoc... Let me know and I will provide instructions.
nyholku
Posts: 149
Joined: Wed Dec 28, 2016 4:18 pm

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by nyholku »

I'm ok for building this from scratch, maybe we get complete instruction then in this thread for posterity.

So please fire away...

cheers Kusti
nyholku
Posts: 149
Joined: Wed Dec 28, 2016 4:18 pm

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by nyholku »

Update of my latest experiments.

I wiped homebrew and started from scratch:

Code: Select all

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"
This left some stuff dangling which I did not try to remove:

Code: Select all

==> Homebrew uninstalled!
The following possible Homebrew files were not deleted:
/usr/local/.DS_Store
/usr/local/bin/
/usr/local/Caskroom/
/usr/local/cuda/
/usr/local/etc/
/usr/local/git/
/usr/local/include/
/usr/local/lib/
/usr/local/Library/
/usr/local/Qt/
/usr/local/share/
/usr/local/texlive/
/usr/local/var/
I then re-installed homebrew:

Code: Select all

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Then I tried the pre-requisite install with the bottles like this:

Code: Select all

brew tap homebrew/science
brew tap freecad/freecad
brew install --only-dependencies freecad --with-freecad-bottles
This went ok, but when I try to CMake:

Code: Select all

MACOSX_DEPLOYMENT_TARGET=10.11
cmake -DBUILD_FEM_NETGEN="1"  -DFREECAD_CREATE_MAC_APP="1" ../FreeCAD-git
It ends with:

Code: Select all

CMake Error at CMakeLists.txt:606 (find_package):
  Could not find a package configuration file provided by "VTK" with any of
  the following names:
So I tried to install vtk:

Code: Select all

 
brew install vtk
which results in:

Code: Select all

Error: Formulae found in multiple taps: 
 * freecad/freecad/vtk
 * homebrew/science/vtk
 * sanelson/freecad/vtk
So I made a guess and tried:

Code: Select all

brew install freecad/freecad/vtk
And this time CMake runst to completion without errors.

So I think the pre-requisite bottles are missing VTK.

Ok then try to 'make' the project and that completes without errors but with
lots of warnings, what did you expect, this C/C++ ;)
and when I run bin/FreeCAD I get:

Code: Select all

FreeCAD 0.17, Libs: 0.17R9748 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2016
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##
So no errors, not even the 'pyside' problem, so I guess I'm golden!!!

I hope this thread helps someone out there to compile FreeCAD successfully
on Macos and I hope someone will fix the bottles and update the Wiki.

I would volunteer but I don't know how to update the bottles, I can update
the wiki if someone gives me go-ahead and write access (or maybe anyone
can write, have not checked).

Should I file a bug report about these?
blacey
Posts: 370
Joined: Tue Dec 08, 2015 11:28 pm

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by blacey »

@nholku - I had prepared instructions for you but was waiting to run them on a VM so I could include a gist of the output - sorry but my dev environment was tied up with Qt5 work. That said, it looks like you did effectively what I would have provided with one exception - for some reason the "brew install --only-dependenices freecad" doesn't always install the full set of dependencies so you have to run it twice to ensure all dependencies are installed (on my list to resolve). Glad you are up and running - well done!

I have copied and pasted my "untested" instructions for reference.

Code: Select all

# Remove Homebrew
cd /usr
sudo rm -rf local

# Reinstall Homebrew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

# Record Homebrew config
brew --config   #This is for troubleshooting if it doesn't work

# Tap FreeCAD
git tap-pin FreeCAD/freecad

#  Brew FreeCAD dependencies (until all have been met)
brew install --only-dependencies freecad --with-freecad-bottles
brew install --only-dependencies freecad --with-freecad-bottles  #run a second time to ensure all dependencies are installed

#  Compile FreeCAD
git clone https://github.com/FreeCAD.git
cd FreeCAD
mkdir build && cd build
cmake -DBUILD_FEM_NETGEN=ON -DFREECAD_USE_EXTERNAL_KDL=ON -DFREECAD_CREATE_MAC_APP=ON -DCMAKE_BUILD_TYPE=RELEASE ..
make

./bin/FreeCAD --run-test 0   #Verify good build
sudo make install/fast          #Assemble a relocatable FreeCAD app bundle in /usrl/local
onertom
Posts: 2
Joined: Thu Jan 12, 2017 6:06 pm

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by onertom »

Hello all!

After struggling for a while to compile FreeCAD on my Mac, I finally got it, and I want to start off by saying thanks to you all for contributing to this post. Also, since I got it to compile without any errors, I wanted to share my steps in hopes that it’ll help others.

Just a little background, I have a Mid 2012 MBP, running Sierra v. 10.12.2. I did all this with no version of FreeCAD installed on my machine, just xcode v. 8.2.1.

One thing to note, after I saw in a previous post that it was a good idea to run some commands multiple times, I started doing that for several items, as you’ll see below. I don’t think it was necessary for most of them, but I wanted to play it safe rather than sorry.

Lastly, I found it best that if/when I got stuck, it was better to just uninstall everything and start from scratch rather than trying to find missing files and such. That’s just me though…

Here’s what I did.


#Remove Homebrew:

Code: Select all

cd /usr
sudo rm -rf local
#Reinstall Homebrew: x2

Code: Select all

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
#Install FreeCAD:

Code: Select all

brew install Caskroom/cask/freecad
#Install Dependencies:

Code: Select all

brew tap homebrew/science
brew tap freecad/freecad
# x3

Code: Select all

brew install --only-dependencies freecad --with-freecad-bottles
#Make Directory:

Code: Select all

mkdir ~/FreeCAD
cd ~/Freecad
#Get Source:

Code: Select all

git clone https://github.com/FreeCAD/FreeCAD FreeCAD-git
#Make Build Directory:

Code: Select all

mkdir ~/FreeCAD/build
cd build
#Cmake Stuff:

Code: Select all

MACOSX_DEPLOYMENT_TARGET=10.11
# x2

Code: Select all

cmake -DBUILD_FEM_NETGEN="1"  -DFREECAD_CREATE_MAC_APP="1" ../FreeCAD-git 
#Make

Code: Select all

make
Below is also my brew list with the versions

boost 1.63.0
boost-python 1.63.0
ccache 3.3.3
cmake 3.7.2
coin 3.1.3
eigen 3.3.1
eigen@3.2 3.2.10
fontconfig 2.12.1_2
freeimage 3.17.0
freetype 2.7.1
gdbm 1.12
gl2ps 1.3.9_2
hdf5 1.8.18
jpeg 8d
libpng 1.6.28
libtiff 4.0.7_2
matplotlib 2.0.0
med-file 3.2.0
nglib 5.3.1_2
numpy 1.12.0
opencascade 7.0.0
openssl 1.0.2k
orocos-kdl 1.3.0_2
pcre 8.39
pivy 0.5.0
pkg-config 0.29.1_2
pyside 1.2.2_1
pyside-tools 0.2.15
python 2.7.13
qt 4.8.7_3
readline 7.0.1
shiboken 1.2.2
sqlite 3.16.2
swig 3.0.12
szip 2.1
tbb 4.4-20161128
vtk 7.1.0_3
xerces-c 3.1.4


Taa Daa!!!

Last login: Wed Feb  1 21:38:07
FreeCAD 0.17, Libs: 0.17R9934 (Git)
(c) Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2016
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##

[FreeCAD Console mode <Use Ctrl-D (i.e. EOF) to exit.>]
>>> 

:D :D :D
User avatar
easyw-fc
Veteran
Posts: 3633
Joined: Thu Jul 09, 2015 9:34 am

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by easyw-fc »

blacey wrote: I have copied and pasted my "untested" instructions for reference.
...
Hi,
I am trying to compile FC 0.17 on Sierra...
brew tap homebrew/science
brew tap freecad/freecad
brew install --only-dependencies freecad
brew install --only-dependencies freecad
cd ..
mkdir ~/FreeCAD
cd ~/FreeCAD
git clone -b step https://github.com/FreeCAD/FreeCAD.git FreeCAD-git
mkdir ~/FreeCAD/build
cd ~/FreeCAD/build
and then I tried with cmake
cmake -DFREECAD_USE_EXTERNAL_KDL="1" -DBUILD_QT5="1" -DCMAKE_BUILD_TYPE="Release" -DFREECAD_CREATE_MAC_APP ="1" ../FreeCAD-git
or
cmake -DBUILD_FEM_NETGEN=ON -DFREECAD_USE_EXTERNAL_KDL=ON -DFREECAD_CREATE_MAC_APP=ON -DCMAKE_BUILD_TYPE=RELEASE ../FreeCAD-git
I did follow all the steps but I have this error
CMake Warning at CMakeLists.txt:772 (find_package):
By not providing "FindQt5Network.cmake" in CMAKE_MODULE_PATH this project
has asked CMake to find a package configuration file provided by
"Qt5Network", but CMake did not find one.

Could not find a package configuration file provided by "Qt5Network" with
any of the following names:

Qt5NetworkConfig.cmake
qt5network-config.cmake

Add the installation prefix of "Qt5Network" to CMAKE_PREFIX_PATH or set
"Qt5Network_DIR" to a directory containing one of the above files. If
"Qt5Network" provides a separate development package or SDK, be sure it has
been installed
thx for helping me
Maurice
blacey
Posts: 370
Joined: Tue Dec 08, 2015 11:28 pm

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by blacey »

easyw-fc wrote: Hi,
I am trying to compile FC 0.17 on Sierra...

I did follow all the steps but I have this error
CMake Warning at CMakeLists.txt:772 (find_package):
By not providing "FindQt5Network.cmake" in CMAKE_MODULE_PATH this project
has asked CMake to find a package configuration file provided by
"Qt5Network", but CMake did not find one.

Could not find a package configuration file provided by "Qt5Network" with
any of the following names:

Qt5NetworkConfig.cmake
qt5network-config.cmake

Add the installation prefix of "Qt5Network" to CMAKE_PREFIX_PATH or set
"Qt5Network_DIR" to a directory containing one of the above files. If
"Qt5Network" provides a separate development package or SDK, be sure it has
been installed
thx for helping me
Maurice
Hi Maurice,

With Qt5, you also need to add the CMAKE_PATH_PREFIX so cmake is able to find the Qt5 modules. This is required for Qt5 and has changed since we started this thread. While we try to keep the CompileOnMac wiki instructions up-today, what we use to build on Travis-CI is always an up-to-date reference/example.

So, to build with Qt5.6, you can do the following:

Code: Select all

cmake -DBUILD_FEM_NETGEN=ON -DFREECAD_USE_EXTERNAL_KDL=ON -DFREECAD_CREATE_MAC_APP=ON -DCMAKE_BUILD_TYPE=DEBUG -DBUILD_QT5=ON -DCMAKE_PREFIX_PATH="/usr/local/Cellar/qt@5.6/5.6.2/lib/cmake/" ..
Finally, apologies for the slow response but I am currently traveling. Let me know if you are successful in building on Sierra.
User avatar
easyw-fc
Veteran
Posts: 3633
Joined: Thu Jul 09, 2015 9:34 am

Re: Compiling on Mac ... problem with the prerequisites with homebrew

Post by easyw-fc »

blacey wrote:With Qt5, you also need to add the CMAKE_PATH_PREFIX so cmake is able to find the Qt5 modules.
Hi,
many thank to all for your support and for this highly friendly forum! :D

I finally managed to build FC on Sierra.
My Sierra is a clean installation and to build FC I followed the steps here, cleaning up all my previous attempts, brew included
I just had installed XQuartz: https://www.xquartz.org/
and Xcode
and Homebrew https://brew.sh/

here the steps I did:

Code: Select all

# Remove Homebrew
cd /usr
sudo rm -rf local

# Reinstall Homebrew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

#  Brew FreeCAD dependencies
brew tap homebrew/science
brew tap freecad/freecad

brew install --only-dependencies freecad --with-freecad-bottles
brew install --only-dependencies freecad --with-freecad-bottles  #run a second time to ensure all dependencies are installed

#  get FreeCAD src
git clone https://github.com/FreeCAD.git
cd FreeCAD
mkdir build && cd build
after a incomplete configure attempt I did also

Code: Select all

#  Brew FreeCAD dependencies
brew install eigen
brew install libspnav
brew install doxygen
brew install graphviz

# made a symlink for OpenGL
ln -s /opt/X11/include/GL /usr/local/include/GL
and finally I did

Code: Select all

cmake -DBUILD_FEM_NETGEN="1" -DFREECAD_CREATE_MAC_APP="1" -DCMAKE_PREFIX_PATH=/usr/local/Cellar/qt@5.6/5.6.2/lib/cmake -CMAKE_BUILD_TYPE="Release" -DBUILD_QT5="1"  ../FreeCAD-git
make
then I went to drink a real bear waiting for the gem to be released! ;)

and finally I got my FC branch built! yeah! :D

thx again @blacey and all!
Maurice
Post Reply