MacOS Testing request - OpenCAMLib Homebrew formula

Here's the place for discussion related to CAM/CNC and the development of the Path module.
ian.rees
Posts: 535
Joined: Sun Jun 15, 2014 3:28 am
Contact:

MacOS Testing request - OpenCAMLib Homebrew formula

Postby ian.rees » Sun Mar 12, 2017 3:16 am

Hi folks,

I've made a formula for building OpenCAMLib via Homebrew - it would be great to get some feedback on it from any Mac users who are interested in CAM. It's in the FreeCAD "Tap" https://github.com/freecad/homebrew-freecad

I intend to put together a few pull requests to make building OpenCAMLib a bit easier on Mac. Until then the formula depends on the Homebrew provided clang, which takes some time to build/install. -Ian-
blacey
Posts: 337
Joined: Tue Dec 08, 2015 11:28 pm

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby blacey » Sun Mar 12, 2017 6:00 am

ian.rees wrote:I've made a formula for building OpenCAMLib via Homebrew - it would be great to get some feedback on it from any Mac users who are interested in CAM. It's in the FreeCAD "Tap" https://github.com/freecad/homebrew-freecad
-Ian-


Nice!!!
dlhenke
Posts: 11
Joined: Fri Mar 24, 2017 1:47 pm

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby dlhenke » Sat Mar 25, 2017 1:46 am

I've tried to compile this stuff .. it does not work on my MacOs Sierra.
ian.rees
Posts: 535
Joined: Sun Jun 15, 2014 3:28 am
Contact:

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby ian.rees » Sat Mar 25, 2017 2:45 am

Hi dlhenke,

There's really not much I can do to help until I have a better picture of what you have done, what you're seeing, what you're expecting, etc. -Ian-
dlhenke
Posts: 11
Joined: Fri Mar 24, 2017 1:47 pm

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby dlhenke » Sat Mar 25, 2017 10:30 pm

after a lot of google search ..
sucessfuly build FreeCad from GitHub.
there is 3 commands that you need to put in order to build.
first put QT5 in your .bash_profile
export PATH="/usr/local/opt/qt\@5.6/bin:$PATH"
brew link --force qt@5.6
sudo ln -f -s /usr/local/Cellar/qt\@5.*/*/mkspecs /usr/local/mkspecs
sudo ln -f -s /usr/local/Cellar/qt\@5.*/*/plugins /usr/local/plugins
where this commands are
https://github.com/bblacey/FreeCAD-MacO ... #L141-L159

But nothing of opencamlib..
it is at Homebrew/library/taps/freecad ... opencamlib.rb
and then .. the magic..

brew install opencamlib
Updating Homebrew...
==> Auto-updated Homebrew!
Updated 1 tap (homebrew/core).
==> Updated Formulae
bmake convox dpkg ejabberd lft nspr percona-server percona-server@5.6 percona-xtrabackup talloc

==> Installing opencamlib from freecad/freecad
==> Cloning https://github.com/aewallin/opencamlib.git
Cloning into '/Users/duhenke/Library/Caches/Homebrew/opencamlib--git'...
remote: Counting objects: 7780, done.
remote: Total 7780 (delta 0), reused 0 (delta 0), pack-reused 7780
Receiving objects: 100% (7780/7780), 9.01 MiB | 398.00 KiB/s, done.
Resolving deltas: 100% (4597/4597), done.
==> Checking out revision 398f7c7fac60169fda067ea0f5ebc15083361f5c
==> cmake -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/opencamlib/0.0.1 -DCMAKE_BUILD_TYPE=Release -DCMAKE_FIND_FRAMEWORK=LAST -DCMAKE_VERBOSE_MA
==> make -j4 install
/usr/local/Cellar/opencamlib/0.0.1: 53 files, 2.2MB, built in 1 minute 32 seconds
ian.rees
Posts: 535
Joined: Sun Jun 15, 2014 3:28 am
Contact:

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby ian.rees » Sat Mar 25, 2017 11:23 pm

dlhenke wrote:after a lot of google search ..

Could you please list out what you have done with your system, and why, using https://freecadweb.org/wiki/CompileOnMac as a common starting point. Ideally, our wiki page should explain how to compile FreeCAD, so there shouldn't be a lot of searching required.

If you are finding something different (like your last post suggests) then there is something "wrong" either with your computer, or with our wiki page, and we'll need to work together to fix it.

dlhenke wrote:But nothing of opencamlib..
it is at Homebrew/library/taps/freecad ... opencamlib.rb

I would not expect you to find instructions on the opencamlib recipe, because I just made it a couple weeks ago, and hopefully it's very simple to work with. Once you've followed the instructions in the above wiki page, "brew install opencamlib" should be sufficient to install it.

But, installing FreeCAD from source should be similarly straightforward, so I don't know if it's going to work for you. -Ian-
dlhenke
Posts: 11
Joined: Fri Mar 24, 2017 1:47 pm

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby dlhenke » Sun Mar 26, 2017 12:34 am

ok i will put every command ..
I'm compiling with QT5. and i have success doing that.
but it was needed to put some more commands in order to build FreeCad from GitHub source.
First thing first.
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homeb ... er/install)"
brew tap FreeCAD/freecad
brew install --only-dependencies freecad --with-packaging-utils
then mkdir ~/FreeCad
cd ~/Freecad
git clone https://github.com/FreeCAD/FreeCAD source
then mkdir build
cd build
cmake -DBUILD_FEM_NETGEN="1" -DBUILD_QT5="ON" -DCMAKE_BUILD_TYPE="Release" -DFREECAD_CREATE_MAC_APP="1" ../source
make -j8
And Errors.. a lot of them.
needed to do again
brew install --only-dependencies freecad --with-packaging-utils
and again cmake .......
Errors about QT and QT5 libraries..
then google searching..
export PATH="/usr/local/opt/qt\@5.6/bin:$PATH"
brew link --force qt@5.6
sudo ln -f -s /usr/local/Cellar/qt\@5.*/*/mkspecs /usr/local/mkspecs
sudo ln -f -s /usr/local/Cellar/qt\@5.*/*/plugins /usr/local/plugins

again ..
cmake -DBUILD_FEM_NETGEN="1" -DBUILD_QT5="ON" -DCMAKE_BUILD_TYPE="Release" -DFREECAD_CREATE_MAC_APP="1" ../source
make -j8
and the compiling was sucessfull but not opencamlib.
I just do
brew install opencamlib
And everything is working.
ian.rees
Posts: 535
Joined: Sun Jun 15, 2014 3:28 am
Contact:

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby ian.rees » Sun Mar 26, 2017 2:33 am

Ahh, sorry, somehow I didn't notice the opencamlib notes when you first posted them. Thanks for testing, and glad to hear it's working! -Ian-
blacey
Posts: 337
Joined: Tue Dec 08, 2015 11:28 pm

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby blacey » Sun Mar 26, 2017 4:20 am

dlhenke wrote:And Errors.. a lot of them.
needed to
export PATH="/usr/local/opt/qt\@5.6/bin:$PATH"
brew link --force qt@5.6
sudo ln -f -s /usr/local/Cellar/qt\@5.*/*/mkspecs /usr/local/mkspecs
sudo ln -f -s /usr/local/Cellar/qt\@5.*/*/plugins /usr/local/plugins


@dlhenke, glad you manage to get it working. FYI, while the command above will work, you can avoid those steps by adding -DCMAKE_PREFIX_PATH="/usr/local/Cellar/qt@5.6/5.6.2/lib/cmake/" to your cmake command... That is what we currently do on Travis - https://github.com/FreeCAD/FreeCAD/blob ... #L168-L170
dlhenke
Posts: 11
Joined: Fri Mar 24, 2017 1:47 pm

Re: MacOS Testing request - OpenCAMLib Homebrew formula

Postby dlhenke » Sun Mar 26, 2017 5:14 pm

Working on OsX Sierra.
but someone can explain to me what are those movements in the second image capture?
Attachments
Screen Shot 2017-03-26 at 14.10.47.png
Screen Shot 2017-03-26 at 14.10.47.png (255.57 KiB) Viewed 36 times
Screen Shot 2017-03-26 at 14.10.21.png
Screen Shot 2017-03-26 at 14.10.21.png (290.1 KiB) Viewed 36 times