https://bugs.gentoo.org/723946
--- a/toonz/sources/tnztools/toolutils.cpp
+++ b/toonz/sources/tnztools/toolutils.cpp
@@ -42,6 +42,7 @@
 #include "tools/strokeselection.h"
 
 #include <QPainter>
+#include <QPainterPath>
 #include <QGLWidget>  // for QGLWidget::convertToGLFormat
 #include <QFont>
 #include <QFontMetrics>
--- a/toonz/sources/toonzqt/functionpanel.cpp
+++ b/toonz/sources/toonzqt/functionpanel.cpp
@@ -28,6 +28,7 @@
 #include <QWheelEvent>
 #include <QMenu>
 #include <QSettings>
+#include <QPainterPath>
 
 #include <cmath>
 

