# Error building VTK with Qt support in (Ubuntu) Docker container

**URL:** https://discourse.vtk.org/t/error-building-vtk-with-qt-support-in-ubuntu-docker-container/7671
**Category:** Support
**Created:** [January 18, 2022, 4:23pm UTC](https://discourse.vtk.org/t/error-building-vtk-with-qt-support-in-ubuntu-docker-container/7671 "2022-01-18T16:23:47Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![gipert](https://discourse.vtk.org/user_avatar/discourse.vtk.org/gipert/32/4566_2.png) [@gipert](https://discourse.vtk.org/u/gipert)
#### Post date: [January 18, 2022, 4:23pm UTC](https://discourse.vtk.org/t/error-building-vtk-with-qt-support-in-ubuntu-docker-container/7671/1 "2022-01-18T16:23:47Z")

</div>

I’m trying to build VTK in an `ubuntu:focal`-based Docker container with Qt support. Here’s a link to the [Dockerfile](https://github.com/gipert/remage-docker/blob/cf300f6201ca6ebf445d2d1904fad35e93a75083/Dockerfile.G4-10-11#L77-L90). The build configuration runs smoothly but I get the following error at the very end of `make`:

```auto
[100%] Linking CXX shared library ../../lib/libvtkViewsQt-9.1.so
[100%] Linking CXX shared module ../../../lib/qml/VTK.9.1/libqmlvtkplugin.so
[100%] Built target ViewsQt
Generating qmltypes file using qmlplugindump
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
QQmlComponent: Component is not ready
make[2]: *** [GUISupport/QtQuick/qml/CMakeFiles/qmlvtkplugin.dir/build.make:135: lib/qml/VTK.9.1/libqmlvtkplugin.so] Error 3
make[2]: *** Deleting file 'lib/qml/VTK.9.1/libqmlvtkplugin.so'
make[1]: *** [CMakeFiles/Makefile2:12297: GUISupport/QtQuick/qml/CMakeFiles/qmlvtkplugin.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

```

I’m really not an expert here. Any idea about the origin? How can I circumvent this?

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.vtk.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.vtk.org/u/ben.boeckel)
#### Post date: [January 22, 2022, 4:18pm UTC](https://discourse.vtk.org/t/error-building-vtk-with-qt-support-in-ubuntu-docker-container/7671/2 "2022-01-22T16:18:55Z")

</div>

Qt is very tight-lipped about what is actually going wrong here. Usually it means that the QML plugin isn’t built properly (or its metadata is wrong). This usually also only shows up with incremental builds. Does removing the `lib/qml` directory, rerunning `cmake` and building help?

---

<div class="post-metadata">

### Author: ![gipert](https://discourse.vtk.org/user_avatar/discourse.vtk.org/gipert/32/4566_2.png) [@gipert](https://discourse.vtk.org/u/gipert)
#### Post date: [January 25, 2022, 4:00pm UTC](https://discourse.vtk.org/t/error-building-vtk-with-qt-support-in-ubuntu-docker-container/7671/3 "2022-01-25T16:00:17Z")

</div>

Thanks for the feedback! Unfortunately, what you suggested did not fix it. Since it’s a Docker container I never do incremental builds.
