Important: Please read the Qt Code of Conduct -

Qt 5.4: how to write a file .pro

  • Hello everyone! I'm trying to use Qt for the firts time and I have some doubts about how to write a for a project.
    Specifically, I have to use VTK libraries but i don't understand how to communicate these libraries to my code.
    Thnaks for the help! :)

  • Hi and welcome to devnet,

    if you use Qt Creator you have a lot of wizard helping you.
    For other stuff the manual is your best friend

  • I would suggest using cmake instead of qmake in your project, as vtk provides
    cmake macros but no pkg-config or qmake files. Things will be much more simple.
    If you really want to go for qmake, you need to set LIBS & INCLUDPATHS manually
    to point to the vtk directories, but take note that this can easily break the compiling
    on other machines, if the VTK version is installed to different path or if the installed
    version is different as the VTK libs have a version suffix in their names.

    See for more info on using cmake with Qt,
    and for VTK specific bits.

Log in to reply