Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] IFC4 does not compile #534

Open
christophKaiser opened this issue Mar 13, 2022 · 1 comment
Open

[BUG] IFC4 does not compile #534

christophKaiser opened this issue Mar 13, 2022 · 1 comment
Labels
bug Something isn't working duplicate This issue or pull request already exists IFC Content related to Industry Foundation Classes (IFC) functionalities

Comments

@christophKaiser
Copy link
Collaborator

Describe the bug
The project OpenInfraPlatform.Core does not compile with IFC4.
In the Output, the first error message is:

(...)\Core\src\IfcGeometryConverter\PlacementConverter.h(586,1): error C2146: syntax error: missing '>' before identifier 'IfcLinearPlacement'

To Reproduce
Steps to reproduce the behavior:

  1. In CMake, select the option EARLYBINDING_WITH_IFC4
  2. Compile all steps according to SetupHelp.md
  3. The compiler error will appear during the project OpenInfraPlatform.Core

Expected behavior
Even with IFC4, I would expect the solution to compile.

CMake configuration
If applicable, list any special configurations you have selected in CMake.

  • EARLYBINDING_WITH_IFC4: selected

Additional context
According to the IFC documentation, the entity IfcLinearPlacement was introduced with IFC4x1 RC3 (link to documentation). Therefore, it will be some kind of undefined type in IFC4.

Probably, the option EARLYBINDING_WITH_IFC2x3 for IFC2x3 will bring up similar issues.

I was albe to find some kind of fix or work around with the if-condition

#if !(defined(OIP_MODULE_EARLYBINDING_IFC2X3) || defined(OIP_MODULE_EARLYBINDING_IFC4))
  // some source code with IfcLinearPlacement
#endif

However, after IfcLinearPlacement was excluded from the code for IFC4, other IFC entities come up with the same problem. Currently, on my list are:

  • IfcLinearPlacement
  • IfcDistanceExpression
  • IfcPointByDistanceExpression
  • IfcAxis2PlacementLinear
  • IfcOrientationExpression
  • IfcPositioningElement
  • IfcOffsetCurve
  • IfcSectionedSolid
  • IfcSectionedSolidHorizontal

At some point, the side effects on the entire namespace IfcGeometryConverter were to big to push a fast fix.

@christophKaiser christophKaiser added bug Something isn't working IFC Content related to Industry Foundation Classes (IFC) functionalities labels Mar 13, 2022
@pjanck
Copy link
Member

pjanck commented Mar 14, 2022

See #334 as well.

@pjanck pjanck added the duplicate This issue or pull request already exists label Sep 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working duplicate This issue or pull request already exists IFC Content related to Industry Foundation Classes (IFC) functionalities
Projects
None yet
Development

No branches or pull requests

2 participants