[conda] compile calculix for osx and windows

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

[conda] compile calculix for osx and windows

Post by looo »

Has anybody successfully compiled calculix for osx? I am wondering if it makes sense to try this [1]. Also I am trying to compile calculix for windows with the mingw-toolchain. I think @easyw was successful on windows. Maybe we can transfer the instruction into a build-instruction for conda.

I guess in theory it should be possible to support all 3 major platforms, but some help would be nice! [2]
easyw-fc wrote:
[1] https://travis-ci.org/conda-forge/stage ... tification
[2] https://github.com/conda-forge/staged-recipes/pull/6827
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: [conda] compile calculix for osx and windows

Post by looo »

For windows it looks like it is a bit more difficult. spooles and arpack are not yet available:

https://github.com/conda-forge/spooles- ... a.yaml#L17
https://github.com/conda-forge/arpack-feedstock/pull/22

So I guess this will need some time until we can compile calculix with flang and clang...
peterl94
Veteran
Posts: 1001
Joined: Thu May 23, 2013 7:31 pm
Location: United States

Re: [conda] compile calculix for osx and windows

Post by peterl94 »

I've always just used the homebrew package built using this formula: https://github.com/brewsci/homebrew-sci ... lix-ccx.rb
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: [conda] compile calculix for osx and windows

Post by looo »

Thanks for the instructions. I hope osx won't need too much iterations to get the builds succeed. For Windows arpack is now available build with the mingw-toolchain. So I will try to use the same toolchain for spooles and calculuix too.
UR_
Veteran
Posts: 1355
Joined: Tue Jan 03, 2017 8:42 pm

Re: [conda] compile calculix for osx and windows

Post by UR_ »

ccx is a really sensible piece of software, showing it's weak spots only after doing tons of tests.

So let's speak this guy ("kwip" from mecway forum):
I did some research finding other projects having issues with ARPack which is kind of EOL. ocatve, scilab were forking their own implementation. There is some effort of consolidation, namely arpack-ng. I'll try to build CCX against this arpack version. Maybe we are lucky. I'll report back when I've put the required dependencies together.

http://mecway.com/forum/discussion/comm ... mment_2511


Results can be found here:
https://github.com/ddfem/ccx_mingw64/commits/master

Especially if it comes to non static calculations, this build is really appreciated.
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: [conda] compile calculix for osx and windows

Post by looo »

UR_ wrote: Sun Nov 25, 2018 3:39 pm There is some effort of consolidation, namely arpack-ng.
actually the arpack-package on conda-forge uses sources from arpack-ng [1]. There is also another arpack (arpackpp [2]). Do you know for which part ccx uses arpack and for which it uses spooles?

[1] https://github.com/conda-forge/arpack-feedstock
[2] https://github.com/conda-forge/arpackpp-feedstock
UR_
Veteran
Posts: 1355
Joined: Tue Jan 03, 2017 8:42 pm

Re: [conda] compile calculix for osx and windows

Post by UR_ »

looo wrote: Sun Nov 25, 2018 6:00 pm for which part ccx uses arpack and for which it uses spooles?
For an overview please refer to docs

http://www.dhondt.de/ccx_2.14.pdf

see page 570 chapter 9.6:
9.6 Filling and solving the set of equations, storing the results
In this section a distinction is made between the types of analysis and the solver
used:
• for linear static calculations with SPOOLES or the iterative solver the appropriate routine is prespooles.c
• for nonlinear static or dynamic calculations (which implies the use of SPOOLES or the iterative solver) routine nonlingeo.c is called. This includes all thermal calculations.
• for frequency analysis without cyclic symmetry routine arpack.c is called.9.6 Filling and solving the set of equations, storing the results 571
• for a frequency analysis with cyclic symmetry conditions the appropriate routine is arpackcs.c
• for a buckling analysis arpackbu.c is called
• for linear dynamic calculations (i.e. modal dynamic analysis) the routine is dyna.c
• finally, for steady state dynamics calculations the routine is steadystate.c
...
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: [conda] compile calculix for osx and windows

Post by Kunda1 »

Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: [conda] compile calculix for osx and windows

Post by looo »

I was able to build spooles for windows on my machine. There is still a problem with recursive copying the header files (appveyor):
https://ci.appveyor.com/project/conda-f ... 8069#L1889

If anyone knows a better way to copy header files, please let me know.
Post Reply