Comments (18)
@ianrrees, two other observations for this formula that you might want to consider.
- Patching configure.ac causes make to regenerate the configure script by invoking automake/aclocal. This results in errors during make unless you have automake installed however
brew install automake
does not seem to resolve the errors. All of that said, perhaps we don't need to patch configure.ac because we are patching the configure script in the distro with the same changes... That way make would not try to rebuild the patched configure script. Unless I am missing something, I see two options and we should only need one.- Retain configure.ac patch, add appropriate :build options to ensure that make can regenerate the configure script. This makes the configure script patch redundant and should be eliminated.
- Remove configure.ac patch to avoid regeneration. It doesn't work as is and is redundant with the configure script patches.
- The opencascade cad_kernal opt_prefix is appended with /include. This results in invalid paths such as
OCCFLAGS = -DOCCGEOMETRY -I/usr/local/opt/opencascade/include/include/opencascade -I/usr/local/include/opencascade
andOCCLIBS = -L/usr/local/opt/opencascade/include/lib
that are invalid/non-existant. A quick test using the following change, corrected the paths. Why this doesn't affect builds on Mavericks and Yosemite is beyond me.
diff --git a/nglib.rb b/nglib.rb
index 80d8667..be07308 100644
--- a/nglib.rb
+++ b/nglib.rb
@@ -34,7 +34,7 @@ class Nglib < Formula
cad_kernel = Formula[build.with?("opencascade") ? "opencascade" : "oce"]
if build.with? "opencascade"
- args << "--with-occ=#{cad_kernel.opt_prefix}/include"
+ args << "--with-occ=#{cad_kernel.opt_prefix}"
else
args << "--with-occ=#{cad_kernel.opt_prefix}/include/oce"
from homebrew-freecad.
Looks like this may be an Apple toolchain problem - https://openradar.appspot.com/27822079
from homebrew-freecad.
@ianrrees is aware and on this issue - see https://github.com/Homebrew/homebrew-science/issues/3624 and http://www.freecadweb.org/tracker/view.php?id=2500
from homebrew-freecad.
Hey Bruce, sorry I've been super busy for the last couple months and haven't been able to contribute to FreeCAD. I'm going to try to get my machine updated to have a look at that issue 3624 later today.
from homebrew-freecad.
@ianrrees, good to hear from you! I completely understand being too busy ;) That said, you might want to glance at #33 when you investigate this issue because it seems like the same underlying problem but with different output when built on Sierra... I am hopeful that you can figure it out because I haven't been able to... ;)
from homebrew-freecad.
Yes, I accepted the collaborator invite a few minutes ago, thanks!
from homebrew-freecad.
Ah, well that explains it. I went to re-send the invite and saw you were a collaborator so I edited my remark above to remove that part ;) Thanks in advance for the help.
from homebrew-freecad.
@ianrrees, I was reviewing your nglib PR and realize that point 1) in my comment above about patching configure.ac is incorrect. That must have been a patch introduced by @vejmarie, so you can disregard however I believe my point 2) is still valid. Thoughts?
from homebrew-freecad.
Yeah, configure.ac doesn't matter in the current formula since we're not running autoconf during the homebrew build process.
Haven't had a chance to try --with-opencascade against the new version of opencascade, perhaps in the next few days. I'm pretty sure I had it working for the initial commit, so perhaps we'll need to make a condition on the opencascade version.
from homebrew-freecad.
Ian, are you planning to also upgrade the nglib formula in this freecad-homebrew repo? The one here supports OCCT7 and is used to build a custom bottle with the --with-opencascade option.
from homebrew-freecad.
Not immediately, feel free to adapt those changes here if you have a minute. I think it would be best if we can get to a point where the homebrew-science formula for nglib does what we need for FreeCAD, so was going to work towards that goal.
from homebrew-freecad.
Ok, OCCT7 support falls into "nglib does what we need for FreeCAD" hence my question... Maybe that is already part of your goal because hombrew-science/opencascade switched to OCCT7 a couple months ago.
from homebrew-freecad.
@ianrrees - I am working on patching the occt7 nglib formula here to incorporate your recent changes in homebrew/science however the Makefile.in patch does not exist in the Makefile.in if I simply download the netgen 5.3.1 source usingcurl -L -o - "https://downloads.sourceforge.net/project/netgen-mesher/netgen-mesher/5.3/netgen-5.3.1.tar.gz" | tar xvz
. It doesn't seem to be a showstopper because it is resolved with a fuzzy merge but I'm wondering if your intended change is now absent.
$ brew install --interactive freecad/freecad/nglib
==> Installing nglib from freecad/freecad
==> Downloading https://downloads.sourceforge.net/project/netgen-mesher/netgen-mesher/5.3/netgen-5.3.1.tar.gz
Already downloaded: /Users/blacey/Library/Caches/Homebrew/nglib-5.3.1.tar.gz
==> Patching
patching file configure
patching file libsrc/occ/Partition_Loop2d.cxx
patching file ng/Makefile.in
Hunk #1 succeeded at 327 with fuzz 1.
patching file libsrc/meshing/improve2.hpp
patching file libsrc/meshing/meshclass.hpp
patching file libsrc/meshing/meshtype.hpp
patching file libsrc/occ/Partition_Inter2d.hxx
patching file libsrc/occ/Partition_Inter3d.hxx
patching file libsrc/occ/Partition_Loop.hxx
patching file libsrc/occ/Partition_Loop2d.hxx
patching file libsrc/occ/Partition_Loop3d.hxx
patching file libsrc/occ/Partition_Spliter.hxx
patching file libsrc/occ/occgeom.cpp
patching file libsrc/occ/occgeom.hpp
patching file libsrc/occ/occmeshsurf.hpp
patching file libsrc/occ/vsocc.cpp
patching file ng/ngpkg.cpp
==> Entering interactive mode
Type `exit' to return and finalize the installation
Install to this prefix: /usr/local/Cellar/nglib/5.3.1
bash-3.2$ diff Makefile.in /tmp/netgen-5.3.1/Makefile.in
from homebrew-freecad.
cc: @jimhigson because this is the same root cause as #33 that I closed as a duplicate of this issue.
from homebrew-freecad.
Hi @bblacey, sorry for the slow response (and lack of work on my part...)
The recent "fix" for building nglib is, I think, more to do with the new XCode rather than the new MacOS. It was just to cut out the -lTK* from the configure script - see https://github.com/Homebrew/homebrew-science/pull/4587/files . Very hacky; my guess is that there's a bug in ld where it goes in to an infinite loop in that situation (several non-existent libraries specified), but I haven't yet gotten around to making a simpler test case.
I think there are some OCCT7-related changes that aren't my work, can't remember. Hope this helps?
from homebrew-freecad.
@ianrrees - thanks. I will include the Makefile.in patch even though it is benign in its current form.
from homebrew-freecad.
@ianrrees - the homebrew patch regresses opencascade. Re-opening to resolve. You will need to include the same change to the Homebrew-science nglib patch.
from homebrew-freecad.
@bblacey, thank you for taking care of this! Works fine with macOS 10.12/xcode 8.2.1. Haven't had time for FreeCAD these past couple of weeks.
from homebrew-freecad.
Related Issues (20)
- Homebrew update pyside & shiboken to 5.15.5 HOT 9
- update readme with contributing section HOT 1
- freecad/freecad/[email protected] fails to install HOT 10
- `[email protected]` install fails HOT 15
- mac app bundling using cmake on m1 failure due to install_name_tool HOT 11
- swig, add a caveat section to formula HOT 1
- Freecad formula failing on M1 mac HOT 8
- Failing to build from HEAD HOT 14
- Documentation on building dev version HOT 6
- installing 0.20.1 on Apple M1 (errors installing [email protected]) HOT 17
- update workflow files for github actions to remove deprecated commands HOT 4
- [email protected] fails to build on gnu+linux ie. arch linux HOT 3
- setup a github action for the self-hosted runners to auto renew before they expire. HOT 6
- periodically update bottle artifacts HOT 1
- home brew install failed with "Could not identify shiboken version" HOT 3
- fix broken link for med-file HOT 3
- med-file todo add caveats section to formula about python mismatches
- brew install --only-dependencies freecad fails in step freecad/freecad/[email protected] HOT 17
- "brew install --only-dependencies freecad" error building PySide2 QtSensors HOT 2
- "Python.h no such file or directory" error on compilation of freecad/freecad/[email protected] HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from homebrew-freecad.