File: opengl.pri

package info (click to toggle)
openscad 2021.01-6
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 35,972 kB
  • sloc: cpp: 53,199; sh: 4,384; ansic: 4,382; python: 1,813; yacc: 853; javascript: 762; lex: 417; lisp: 163; xml: 127; makefile: 118
file content (24 lines) | stat: -rw-r--r-- 693 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Prefer QOpenGLWidget for non-Windows platforms
# To explicitly enable QOpenGLWidget: qmake CONFIG += qopenglwidget
# To explicitly enable QGLWidget: qmake CONFIG += qglwidget
has_qopenglwidget {
  !win*: CONFIG += qopenglwidget
  qopenglwidget:!qglwidget: CONFIG += using_qopenglwidget
}

using_qopenglwidget {
  message("Using QOpenGLWidget")
  DEFINES += USE_QOPENGLWIDGET
}
else {
  message("Using QGLWidget")
  QT += opengl
}

# see http://fedoraproject.org/wiki/UnderstandingDSOLinkChange
# and https://github.com/openscad/openscad/pull/119
# ( QT += opengl does not automatically link glu on some DSO systems. )
unix:!macx {
  QMAKE_LIBS_OPENGL *= -lGLU
  QMAKE_LIBS_OPENGL *= -lX11
}