Test request

Discussion about the development of the Assembly workbench.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
jmaustpc
Veteran
Posts: 11207
Joined: Tue Jul 26, 2011 6:28 am
Location: Australia

Re: Test request

Post by jmaustpc »

Hi

I believe jriegel/dev-assembly on Sourceforge is the latest Assembly branch. I have just had a look, neither have been updated for a while, but this one has some more recent commits.

Since you have been using the PPA you must be on a Ubuntu or derivative of some sort, but it might help to mention which one and which version, there are version specific issues.

I have compiled the above on Kubuntu 12.04 LTS, and you did need to fix a couple of things. If you are on 12.04 I will look it up for you.

Jim
whirlybomber
Posts: 69
Joined: Wed Aug 14, 2013 6:54 am

Re: Test request

Post by whirlybomber »

Hello Jim,

Yes, I'm on Ubuntu 12.04 at the moment. I've been on Ubuntu since back in the day when 07.04 was a big step! Not sure about the whole combine the interface with mobile thingy canoniacle are doing, but I'd still have that problem if I was on windows anyway wouldn't I?

But having said that, I'm just a user not any sort of hardcore Linux guru. As my attempts to compile the assembly branch in the past have shown.

Cheers,

Brad
jmaustpc
Veteran
Posts: 11207
Joined: Tue Jul 26, 2011 6:28 am
Location: Australia

Re: Test request

Post by jmaustpc »

Hi Brad
whirlybomber wrote: Not sure about the whole combine the interface with mobile thingy canoniacle are doing,
Yeah, that's why I stayed with Kubuntu, (I had previously hated Gnome, especially with its deliberate policy to attempt to remove features/simplify itself to the point of stupidity), at the time Unity came out KDE4 was far more mature and in my opinion a far better thing.

I have always been angry that Canonical didn't get behind KDE4, think where it could have been if they had used all the time and effort they spent on Unity on KDE4 instead. I hate what I see as mostly just a duplication of effort and thus a waste of time. I also don't want my time wasted with having to learn some new "super cool" way to use my computer, I am quite happy with the traditional menus and layout etc. that I am currently familiar with, in short I would rather use my computer than spend time working out "how" to work the "new way" with my computer.

Anyway back to Assembly! :D

In 12.04 you have to
1) upgrade all your Boost and Boost-Dev packages from 1.46 to 1.48.
2) DO NOT TICK THE "DEBUG ASSEMBLY" OPTION TICK BOX IN CMAKE-GUI, If you have ticked this box, unticking it will not help, you have to "delete the cache" and start configuration again from the start. This tick box comes up by itself, the second time you run configure in Cmake-gui.
3) there is also a bug in one line of one file in Boost 1.48 for Ubuntu 12.04, you have to change one variable definition from Long_max to Int_max....see here for instruction and/or just use the replacement file I posted there.

Other than those three things, I think you should be right to compile. Assembly is still rather buggy and missing stuff etc...but I still think its great and worth compiling to have a look at it.


Jim
PascalB
Posts: 17
Joined: Tue Apr 01, 2014 10:11 am

Re: Test request

Post by PascalB »

hello,

The following is done under Mageia 3. The compilation of FreeCad 0.14-3392 has been successfull compiled and run (but assembly module is very short).
libqt4-devel is 4.8.5
libboost-devel is 1.53.0

I understood that guilhemdesq/FreeCAD_dev is the latest Assembly branch (as per April 7, 2014) : right or wrong ?
So I did :
git clone https://github.com/guilhemdesq/FreeCAD_dev
mkdir master_build && cd master_build
cmake -DCMAKE_BUILD_TYPE=Release ../FreeCAD_dev
make

Then tick the assembly box (there is no debug box in this branch), but compilation fails as follows.

[ 87%] Generating ../../../../Mod/Assembly/AssemblyLib.py
[ 87%] Generating ../../../../Mod/Assembly/Init.py
Scanning dependencies of target Assembly
[ 87%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/Item.cpp.o
[ 87%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ItemPart.cpp.o
[ 87%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ItemAssembly.cpp.o
[ 87%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/Constraint.cpp.o
[ 87%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ConstraintGroup.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ItemPyImp.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ItemAssemblyPyImp.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ItemPartPyImp.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ConstraintPyImp.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/ConstraintGroupPyImp.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/AppAssembly.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/AppAssemblyPy.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/PreCompiled.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/Solver/solver_3d_ext1.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/Solver/solver_3d_ext2.cpp.o
[ 88%] Building CXX object src/Mod/Assembly/App/CMakeFiles/Assembly.dir/Solver/solver_3d_ext3.cpp.o
Linking CXX shared library ../../../../Mod/Assembly/Assembly.so
[ 88%] Built target Assembly
[ 88%] Generating ui_TaskAssemblyConstraints.h
[ 88%] Generating qrc_Assembly.cxx
[ 88%] Generating ../../../../Mod/Assembly/InitGui.py
[ 88%] Generating moc_TaskDlgAssemblyConstraints.cpp
usr/include/boost/type_traits/detail/has_binary_operator.hp:50: Parse error at "BOOST_JOIN"
make[2]: *** [src/Mod/Assembly/Gui/moc_TaskDlgAssemblyConstraints.cpp] Erreur 1
make[1]: *** [src/Mod/Assembly/Gui/CMakeFiles/AssemblyGui.dir/all] Erreur 2
make: *** [all] Erreur 2

I understood that there could be something to modify with Long_max to Int_max but I didn't ind where.

Some help ?
ickby
Veteran
Posts: 3116
Joined: Wed Oct 05, 2011 7:36 am

Re: Test request

Post by ickby »

Hello,

I have never seen this error before, but it seems to be a problem with QT's moc compiler and its incorrect macro expansion which conflicts with a boost macro definition. What you can do is to put all boost headers included in the file given by the error message inside a guard, something like this:

Code: Select all

#ifndef Q_MOC_RUN
#include <boost/header1>
#include <boost/header2>
...
#endif
this may happen for other files too, just do it for every file for which the compiler give this error.

About the repo: I have no idea which ones repo this is but it seems to have the newest assembly code, so you can use it.
jmaustpc
Veteran
Posts: 11207
Joined: Tue Jul 26, 2011 6:28 am
Location: Australia

Re: Test request

Post by jmaustpc »

PascalB wrote:I understood that guilhemdesq/FreeCAD_dev is the latest Assembly branch (as per April 7, 2014) : right or wrong ?


Ickby said this seemed to have the up to date code, but it seems a strange practice to me, to be taking the code from a random git cloned repo, why not get it from the official FreeCAD repository on Sourceforge?

This is the repository

git clone git://git.code.sf.net/p/free-cad/code free-cad-code

and the branch for Assembly is jriegel/dev-assembly

if you want to see it in your web browser see this url

http://sourceforge.net/p/free-cad/code/ ... ly/~/tree/


Some advice on compiling Assembly....make sure that Assembly wb is selected in Cmake-gui...at least on Kubuntu 12.04 you should NOT tick the Assembly debug box....building a normal debug build should be fine...but don't tick the check box for "Assembly debug" is if you do it will not compile. On my system this tick box comes up as just one option by itself, after the second time you run configure in Cmake-gui.

Jim
PascalB
Posts: 17
Joined: Tue Apr 01, 2014 10:11 am

Re: Test request

Post by PascalB »

I tried the "isolation" of the #include in /usr/include/boost/type_traits/detail/has_binary_operator.hpp but with no success.

The lines where is the mentionned trouble are (in /usr/include/boost/type_traits/detail/has_binary_operator.hpp), 47 to 50 (where is the error) :
namespace boost {
namespace detail {
// This namespace ensures that argument-dependent name lookup does not mess things up.
namespace BOOST_JOIN(BOOST_TT_TRAIT_NAME,_impl) {

A very naive question, just to understand the organization of FreeCAD (as I(ve read that the module are only loaded when needed) :
By the way, is-it possible to compile the Assembly module alone (and to have it run from another FreeCad) ?

And, following the jim's advice (jmaustpc), I'm rebuilding the "official" version.
Last edited by PascalB on Mon Apr 07, 2014 5:04 pm, edited 1 time in total.
jmaustpc
Veteran
Posts: 11207
Joined: Tue Jul 26, 2011 6:28 am
Location: Australia

Re: Test request

Post by jmaustpc »

PascalB wrote:By the way, is-it possible to compile the Assembly module alone (and to have it run from another FreeCad) ?
No, the changes are to invasive.
ickby
Veteran
Posts: 3116
Joined: Wed Oct 05, 2011 7:36 am

Re: Test request

Post by ickby »

No you need to isolate the shaders in the free cad source, in the taskdlgassemblyconstraint file as the moc fails on this one. Maybe isolate all headers as other headers can include boost too.
Post Reply