IFC Viewer ifcplusplus

This forum section is only for IFC-related issues
User avatar
bernd
Veteran
Posts: 12536
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland

Re: IFC Viewer ifcplusplus

Post by bernd »

mhh me neither ... On Debian Buster it runs smooth ...
User avatar
bernd
Veteran
Posts: 12536
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland

Re: IFC Viewer ifcplusplus

Post by bernd »

I haven never ever used fedora but I may give it a try on a fedora VM. What packages did you install to compile Ifc++ Do you know how to install them in a bash?

bernd
paullee
Veteran
Posts: 4395
Joined: Wed May 04, 2016 3:58 pm

Re: IFC Viewer ifcplusplus

Post by paullee »

I figured out and was successful in compiling e.g. in Fedora 27, packages installed are recorded in earlier post, e.g.

https://forum.freecadweb.org/viewtopic. ... 50#p231732

I remember reading some documents on your repo and/or IFC++ website, something like...

Code: Select all

cmake ../
make
make install
User avatar
bernd
Veteran
Posts: 12536
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland

Re: IFC Viewer ifcplusplus

Post by bernd »

no error here ...

try this script ... https://gist.github.com/berndhahnebach/ ... f897676be1


Screenshot_20191010_223937.png
Screenshot_20191010_223937.png (414.41 KiB) Viewed 1330 times
paullee
Veteran
Posts: 4395
Joined: Wed May 04, 2016 3:58 pm

Re: IFC Viewer ifcplusplus

Post by paullee »

Thanks for the script :)

Running and building again ... seems no much difference in the script, just it use git rather than me downloading the zip.

Hope it builds.

[EDIT]

It works ! Thanks!
Screenshot from 2019-10-12 07-42-15.png
Screenshot from 2019-10-12 07-42-15.png (711.96 KiB) Viewed 1298 times
User avatar
bernd
Veteran
Posts: 12536
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland

Re: IFC Viewer ifcplusplus

Post by bernd »

great!
User avatar
bernd
Veteran
Posts: 12536
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland

Re: IFC Viewer ifcplusplus

Post by bernd »

rebased my branch to latest ifcplusplus. Had to add some imports to get it compiled.

https://github.com/berndhahnebach/ifcpl ... its/master
User avatar
bernd
Veteran
Posts: 12536
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland

Re: IFC Viewer ifcplusplus

Post by bernd »

rebased my branch to latest ifcplusplus. Head compiles on Debian Buster :D

https://github.com/berndhahnebach/ifcpl ... its/master

https://github.com/ifcquery/ifcplusplus/commits/master
User avatar
twohot
Posts: 63
Joined: Tue May 17, 2011 10:48 pm
Location: 9ja://coalcity
Contact:

Re: IFC Viewer ifcplusplus

Post by twohot »

bernd wrote: Mon Jan 13, 2020 10:50 am rebased my branch to latest ifcplusplus. Head compiles on Debian Buster :D

https://github.com/berndhahnebach/ifcpl ... its/master

https://github.com/ifcquery/ifcplusplus/commits/master
Resurrecting this thread.

I needed to look at some IFC files while in Linux (Fedora Rawhide) so I tried to complie IfcPlusPlus.
Required Packages (deduced from errors during compilation):

Code: Select all

cmake
qt5-qtbase-devel
OpenSceneGraph-devel
Here is my mileage:

Code: Select all

$ make -j$(nproc --ignore=2)
Consolidate compiler generated dependencies of target carve
[  3%] Built target carve
Consolidate compiler generated dependencies of target IfcPlusPlus
[  3%] Building CXX object IfcPlusPlus/CMakeFiles/IfcPlusPlus.dir/src/ifcpp/reader/ReaderUtil.cpp.o
[  3%] Building CXX object IfcPlusPlus/CMakeFiles/IfcPlusPlus.dir/src/ifcpp/reader/ReaderSTEP.cpp.o
In file included from /home/oss/bim/ifcplusplus-git/ifcplusplus/IfcPlusPlus/src/ifcpp/reader/ReaderSTEP.cpp:45:
/home/oss/bim/ifcplusplus-git/ifcplusplus/IfcPlusPlus/src/ifcpp/reader/ReaderUtil.h: In function ‘void readIntegerValue(const std::wstring&, int&)’:
/home/oss/bim/ifcplusplus-git/ifcplusplus/IfcPlusPlus/src/ifcpp/reader/ReaderUtil.h:70:34: error: ‘numeric_limits’ is not a member of ‘std’
   70 |                 int_value = std::numeric_limits<int>::quiet_NaN();
      |                                  ^~~~~~~~~~~~~~
/home/oss/bim/ifcplusplus-git/ifcplusplus/IfcPlusPlus/src/ifcpp/reader/ReaderUtil.h:70:49: error: expected primary-expression before ‘int’
   70 |                 int_value = std::numeric_limits<int>::quiet_NaN();
      |                                                 ^~~
/home/oss/bim/ifcplusplus-git/ifcplusplus/IfcPlusPlus/src/ifcpp/reader/ReaderUtil.h:74:34: error: ‘numeric_limits’ is not a member of ‘std’
   74 |                 int_value = std::numeric_limits<int>::quiet_NaN();
      |                                  ^~~~~~~~~~~~~~
/home/oss/bim/ifcplusplus-git/ifcplusplus/IfcPlusPlus/src/ifcpp/reader/ReaderUtil.h:74:49: error: expected primary-expression before ‘int’
   74 |                 int_value = std::numeric_limits<int>::quiet_NaN();
      |                                                 ^~~
Any idea how to get this to work?
User avatar
yorik
Founder
Posts: 12866
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: IFC Viewer ifcplusplus

Post by yorik »

Std::numeric_limits, which your error says is undefined, is defined in a "limits.h" header according to https://en.cppreference.com/w/cpp/types/numeric_limits

I would check if 1) the erroring file has #include <limits> in it (on some systems (windows) it's not required to #include std headers, so it's not uncommon these lines are missing), and 2) there is a "limits.h" file installed by some package in usual places (/usr/include for ex). i'm not familiar with fedora, but your package manager should be able to tell which package you need to get that file
Post Reply