GithubHelp home page GithubHelp logo

Comments (12)

HuguesDelorme avatar HuguesDelorme commented on August 23, 2024 1

Hello Victor,
Sorry for the compilation error (GCC?). Try what the compiler suggests to solve the issue :

     for (const typename Tree<T>::TreeNode& node : tree.m_vecNode) {

If it works then could you provide a PR ? I'll be pleased to merge it.

Your CMakeLists.txt looks promising, many thanks for the effort. I would suggest to use file globbing when specifying the headers/sources to be compiled, don't you think so ?

from mayo.

VictorLamoine avatar VictorLamoine commented on August 23, 2024 1

gcc 9.3.0, pull request is over there, I should have read the error with more attention it was pretty straightforward!

Using glob to parse source files is discouraged with CMake, for now I'll keep it like it and we can discuss that when the CMake script works 😝

from mayo.

HuguesDelorme avatar HuguesDelorme commented on August 23, 2024

BSplCLib is defined in TKMath package(TKMath.so)
Indeed the symbol lookup error indicates that the system doesn't search in the folder pointed to be CSF_OCCTLibPath
Does the path /home/victor/software/opencascade-7.5.0/install/lib appear in your LD_LIBRARY_PATH ? Shouldn't be required though as RPATH is used for that (see opencascade.pri)
Will try to build and run on a Linux PC and let you know

from mayo.

VictorLamoine avatar VictorLamoine commented on August 23, 2024

I've got some progress (see develop...VictorLamoine:develop)

/usr/bin/ld: application.o: undefined reference to symbol '_ZN34BinDrivers_DocumentRetrievalDriver16ReadShapeSectionER27BinLDrivers_DocumentSectionRSibRK21Message_ProgressRange'
/usr/bin/ld: /home/victor/software/opencascade-7.5.0/install/lib//libTKBin.so.7: error adding symbols: DSO missing from command line
$ c++filt _ZN34BinDrivers_DocumentRetrievalDriver16ReadShapeSectionER27BinLDrivers_DocumentSectionRSibRK21Message_ProgressRange
BinDrivers_DocumentRetrievalDriver::ReadShapeSection(BinLDrivers_DocumentSection&, std::basic_istream<char, std::char_traits<char> >&, bool, Message_ProgressRange const&)

It's now linking against the correct library but there is still something missing


See ce5ab9a for my fix to link against the correct libraries. LIBS += $$system_path($$join(CASCADE_LIB_DIR, " -L", -L)) does not seem to work and looks pretty hacky 😄

from mayo.

VictorLamoine avatar VictorLamoine commented on August 23, 2024

Any reason you use qmake instead of CMake ? I think the project would be easier to manage with CMake, and qmake will probably disappear in the future!

https://www.qt.io/blog/qt-6-build-system

At the moment the qmake build system is still in place.

from mayo.

HuguesDelorme avatar HuguesDelorme commented on August 23, 2024

Any reason you use qmake instead of CMake ? I think the project would be easier to manage with CMake, and qmake will probably disappear in the future!

Yes CMake is a better choice for the long-term. I started some weeks ago a port to CMake but this requires more work than expected, I have personally less know-how in CMake than qmake.
I always liked qmake. Honestly for developing Qt applications it will always feel simpler and more direct than CMake, it was tailored for that ...

from mayo.

HuguesDelorme avatar HuguesDelorme commented on August 23, 2024

See ce5ab9a for my fix to link against the correct libraries. LIBS += $$system_path($$join(CASCADE_LIB_DIR, " -L", -L)) does not seem to work and looks pretty hacky 😄

Could you try to add message($$system_path($$join(CASCADE_LIB_DIR, " -L", -L))) after this LIBS += ... line and check the output ?
It's working correctly with Windows builds and tried successfully in the past with GCC/Linux builds (some people could also build Mayo on macOS).
It looks "hacky" because of the syntax of qmake's join() function, here it is prepending the contents of variable CASCADE_LIB_DIR with -L
The surrounding system_path() function converts to native dir separators and by experience Windows/MSVC is touchy about this ...

Sorry for the inconvenience but I'm not sure if Mayo's qmake build script is the cause of your problems here.

from mayo.

VictorLamoine avatar VictorLamoine commented on August 23, 2024

Hey there,

git version 2.25.1
Project MESSAGE: Mayo version 0.3.0.645-316bc06 release
Project MESSAGE: Qt version 5.12.8
Project MESSAGE: ---
Project MESSAGE: CASCADE_INC_DIR = /home/victor/software/opencascade-7.5.0/install/include/opencascade/
Project MESSAGE: CASCADE_LIB_DIR = /home/victor/software/opencascade-7.5.0/install/lib/
Project MESSAGE: CASCADE_BIN_DIR =
Project MESSAGE: CASCADE_SRC_DIR =
Project MESSAGE: ---
Project MESSAGE: OpenCascade version 7.5.0
Project MESSAGE: -L/home/victor/software/opencascade-7.5.0/install/lib/
Project MESSAGE: gmio OFF
$ ls -1 /home/victor/software/opencascade-7.5.0/install/lib/
cmake
libTKBinL.so
libTKBinL.so.7
libTKBinL.so.7.5.0
libTKBin.so
libTKBin.so.7
libTKBin.so.7.5.0
libTKBinTObj.so
libTKBinTObj.so.7
libTKBinTObj.so.7.5.0
libTKBinXCAF.so
libTKBinXCAF.so.7
libTKBinXCAF.so.7.5.0
libTKBool.so
libTKBool.so.7
libTKBool.so.7.5.0
libTKBO.so
libTKBO.so.7
libTKBO.so.7.5.0
libTKBRep.so
libTKBRep.so.7
libTKBRep.so.7.5.0
libTKCAF.so
libTKCAF.so.7
libTKCAF.so.7.5.0
libTKCDF.so
libTKCDF.so.7
libTKCDF.so.7.5.0
libTKDCAF.so
libTKDCAF.so.7
libTKDCAF.so.7.5.0
libTKDraw.so
libTKDraw.so.7
libTKDraw.so.7.5.0
libTKernel.so
libTKernel.so.7
libTKernel.so.7.5.0
libTKFeat.so
libTKFeat.so.7
libTKFeat.so.7.5.0
libTKFillet.so
libTKFillet.so.7
libTKFillet.so.7.5.0
libTKG2d.so
libTKG2d.so.7
libTKG2d.so.7.5.0
libTKG3d.so
libTKG3d.so.7
libTKG3d.so.7.5.0
libTKGeomAlgo.so
libTKGeomAlgo.so.7
libTKGeomAlgo.so.7.5.0
libTKGeomBase.so
libTKGeomBase.so.7
libTKGeomBase.so.7.5.0
libTKHLR.so
libTKHLR.so.7
libTKHLR.so.7.5.0
libTKIGES.so
libTKIGES.so.7
libTKIGES.so.7.5.0
libTKLCAF.so
libTKLCAF.so.7
libTKLCAF.so.7.5.0
libTKMath.so
libTKMath.so.7
libTKMath.so.7.5.0
libTKMesh.so
libTKMesh.so.7
libTKMesh.so.7.5.0
libTKMeshVS.so
libTKMeshVS.so.7
libTKMeshVS.so.7.5.0
libTKOffset.so
libTKOffset.so.7
libTKOffset.so.7.5.0
libTKOpenGl.so
libTKOpenGl.so.7
libTKOpenGl.so.7.5.0
libTKPrim.so
libTKPrim.so.7
libTKPrim.so.7.5.0
libTKQADraw.so
libTKQADraw.so.7
libTKQADraw.so.7.5.0
libTKRWMesh.so
libTKRWMesh.so.7
libTKRWMesh.so.7.5.0
libTKService.so
libTKService.so.7
libTKService.so.7.5.0
libTKShHealing.so
libTKShHealing.so.7
libTKShHealing.so.7.5.0
libTKStdL.so
libTKStdL.so.7
libTKStdL.so.7.5.0
libTKStd.so
libTKStd.so.7
libTKStd.so.7.5.0
libTKSTEP209.so
libTKSTEP209.so.7
libTKSTEP209.so.7.5.0
libTKSTEPAttr.so
libTKSTEPAttr.so.7
libTKSTEPAttr.so.7.5.0
libTKSTEPBase.so
libTKSTEPBase.so.7
libTKSTEPBase.so.7.5.0
libTKSTEP.so
libTKSTEP.so.7
libTKSTEP.so.7.5.0
libTKSTL.so
libTKSTL.so.7
libTKSTL.so.7.5.0
libTKTObjDRAW.so
libTKTObjDRAW.so.7
libTKTObjDRAW.so.7.5.0
libTKTObj.so
libTKTObj.so.7
libTKTObj.so.7.5.0
libTKTopAlgo.so
libTKTopAlgo.so.7
libTKTopAlgo.so.7.5.0
libTKTopTest.so
libTKTopTest.so.7
libTKTopTest.so.7.5.0
libTKV3d.so
libTKV3d.so.7
libTKV3d.so.7.5.0
libTKVCAF.so
libTKVCAF.so.7
libTKVCAF.so.7.5.0
libTKViewerTest.so
libTKViewerTest.so.7
libTKViewerTest.so.7.5.0
libTKVRML.so
libTKVRML.so.7
libTKVRML.so.7.5.0
libTKXCAF.so
libTKXCAF.so.7
libTKXCAF.so.7.5.0
libTKXDEDRAW.so
libTKXDEDRAW.so.7
libTKXDEDRAW.so.7.5.0
libTKXDEIGES.so
libTKXDEIGES.so.7
libTKXDEIGES.so.7.5.0
libTKXDESTEP.so
libTKXDESTEP.so.7
libTKXDESTEP.so.7.5.0
libTKXMesh.so
libTKXMesh.so.7
libTKXMesh.so.7.5.0
libTKXmlL.so
libTKXmlL.so.7
libTKXmlL.so.7.5.0
libTKXml.so
libTKXml.so.7
libTKXml.so.7.5.0
libTKXmlTObj.so
libTKXmlTObj.so.7
libTKXmlTObj.so.7.5.0
libTKXmlXCAF.so
libTKXmlXCAF.so.7
libTKXmlXCAF.so.7.5.0
libTKXSBase.so
libTKXSBase.so.7
libTKXSBase.so.7.5.0
libTKXSDRAW.so
libTKXSDRAW.so.7
libTKXSDRAW.so.7.5.0

Now I have a compile error because of the libtree template:

In file included from ../src/src/base/document_tree_node.h:10,
                 from ../src/src/base/document_tree_node_properties_provider.cpp:8:
../src/src/base/libtree.h: In function ‘void Mayo::traverseTree_unorder(const Mayo::Tree<T>&, const FN&)’:
../src/src/base/libtree.h:237:16: error: need ‘typename’ before ‘Mayo::Tree<T>::TreeNode’ because ‘Mayo::Tree<T>’ is a dependent scope
  237 |     for (const Tree<T>::TreeNode& node : tree.m_vecNode) {
      |                ^~~~~~~
      |                typename 

I also started to write a CMake script: https://github.com/VictorLamoine/mayo/blob/develop/CMakeLists.txt
Same compile error as the qmake project for the moment, I'm pretty sure the CMake script does not work but I'll work on it when i have some spare time!

from mayo.

HuguesDelorme avatar HuguesDelorme commented on August 23, 2024

@VictorLamoine
How are you dealing with this build issue ? Did you solve it ?

from mayo.

VictorLamoine avatar VictorLamoine commented on August 23, 2024

Sorry not yet, I did not take time to improve the CMake yet!

from mayo.

HuguesDelorme avatar HuguesDelorme commented on August 23, 2024

Can we close this issue as you could build Mayo with "official" OpenCascade packages(from #30 (comment)) ?

from mayo.

VictorLamoine avatar VictorLamoine commented on August 23, 2024

Yes let's close it

from mayo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.