forked from openscad/openscad
-
Notifications
You must be signed in to change notification settings - Fork 2
/
openscadpy.pro
219 lines (189 loc) · 5.27 KB
/
openscadpy.pro
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
# Auto-include config_<variant>.pri if the VARIANT variable is give on the
# command-line, e.g. qmake VARIANT=mybuild
!isEmpty(VARIANT) {
message("Variant: $${VARIANT}")
exists(config_$${VARIANT}.pri) {
message("Including config_$${VARIANT}.pri")
include(config_$${VARIANT}.pri)
}
}
DEFINES += QT_NO_DEBUG_OUTPUT
win32 {
isEmpty(VERSION) VERSION = $$system(date /t)
} else {
isEmpty(VERSION) VERSION = $$system(date "+%Y.%m.%d")
}
#configure additional directories
win32 {
INCLUDEPATH += $$(MPIRDIR)
INCLUDEPATH += $$(MPFRDIR)
}
DEFINES += OPENSCAD_VERSION=$$VERSION
win32:DEFINES += _USE_MATH_DEFINES NOMINMAX _CRT_SECURE_NO_WARNINGS YY_NO_UNISTD_H
#disable warning about too long decorated names
win32:QMAKE_CXXFLAGS += -wd4503
TEMPLATE = app
RESOURCES = openscad.qrc
OBJECTS_DIR = objects
MOC_DIR = objects
UI_DIR = objects
RCC_DIR = objects
INCLUDEPATH += src
macx {
DEPLOYDIR = $$(MACOSX_DEPLOY_DIR)
!isEmpty(DEPLOYDIR) {
INCLUDEPATH += $$DEPLOYDIR/include
LIBS += -L$$DEPLOYDIR/lib
}
# add CONFIG+=deploy to the qmake command-line to make a deployment build
deploy {
message("Building deployment version")
CONFIG += x86 x86_64
}
TARGET = OpenSCADpy
ICON = icons/OpenSCAD.icns
QMAKE_INFO_PLIST = Info.plist
APP_RESOURCES.path = Contents/Resources
APP_RESOURCES.files = OpenSCAD.sdef
QMAKE_BUNDLE_DATA += APP_RESOURCES
LIBS += -framework Carbon
}
else {
TARGET = openscadpy
}
win32 {
RC_FILE = openscad_win32.rc
}
CONFIG += qt
QT += opengl
# Application configuration
macx:CONFIG += mdi
CONFIG += cgal
CONFIG += opencsg
CONFIG += progresswidget
CONFIG += findnreplace
CONFIG += boost
CONFIG += python
#Uncomment the following line to enable QCodeEdit
#CONFIG += qcodeedit
mdi {
# MDI needs an OpenCSG library that is compiled with OpenCSG-Reset-Hack.patch applied
DEFINES += ENABLE_MDI
}
progresswidget {
DEFINES += USE_PROGRESSWIDGET
FORMS += src/ProgressWidget.ui
HEADERS += src/ProgressWidget.h
SOURCES += src/ProgressWidget.cc
}
findnreplace {
system(git submodule init)
system(git submodule update)
DEFINES += USE_FINDNREPLACE
INCLUDEPATH += qtfindreplacedialog/dialogs
SOURCES += qtfindreplacedialog/dialogs/findform.cpp \
qtfindreplacedialog/dialogs/finddialog.cpp \
qtfindreplacedialog/dialogs/findreplaceform.cpp \
qtfindreplacedialog/dialogs/findreplacedialog.cpp
HEADERS += qtfindreplacedialog/dialogs/findreplaceform.h \
qtfindreplacedialog/dialogs/findreplacedialog.h \
qtfindreplacedialog/dialogs/findform.h \
qtfindreplacedialog/dialogs/finddialog.h \
qtfindreplacedialog/dialogs/findreplace_global.h
FORMS += qtfindreplacedialog/dialogs/findreplaceform.ui \
qtfindreplacedialog/dialogs/findreplacedialog.ui
}
include(cgal.pri)
include(opencsg.pri)
include(eigen2.pri)
include(boost.pri)
include(python.pri)
# Standard include path for misc external libs
#macx {
# INCLUDEPATH += /opt/local/include
#}
# QMAKE_CFLAGS += -pg
# QMAKE_CXXFLAGS += -pg
# QMAKE_LFLAGS += -pg
FORMS += src/MainWindow.ui \
src/Preferences.ui
HEADERS += src/CGAL_renderer.h \
src/GLView.h \
src/MainWindow.h \
src/Preferences.h \
src/cgal.h \
src/csgterm.h \
src/csgops.h \
src/dxfdata.h \
src/dxfdim.h \
src/dxftess.h \
src/export.h \
src/grid.h \
src/highlighter.h \
src/matrix.h \
src/node.h \
src/openscad.h \
src/polyset.h \
src/printutils.h \
src/transform.h \
src/primitives.h \
src/progress.h \
src/editor.h \
src/accuracy.h \
src/cgaladv.h \
src/dxflinextrude.h \
src/dxfrotextrude.h \
src/import.h \
src/projection.h \
src/render.h \
src/render-opencsg.h \
src/surface.h \
src/tostring.h \
src/mathc99.h
SOURCES += src/openscad.cc \
src/mainwin.cc \
src/glview.cc \
src/export.cc \
src/matrix.cc \
src/node.cc \
src/csgterm.cc \
src/polyset.cc \
src/csgops.cc \
src/transform.cc \
src/primitives.cc \
src/projection.cc \
src/cgaladv.cc \
src/cgaladv_convexhull2.cc \
src/cgaladv_minkowski3.cc \
src/cgaladv_minkowski2.cc \
src/surface.cc \
src/render.cc \
src/import.cc \
src/dxfdata.cc \
src/dxftess.cc \
src/dxftess-glu.cc \
src/dxftess-cgal.cc \
src/dxfdim.cc \
src/dxflinextrude.cc \
src/dxfrotextrude.cc \
src/highlighter.cc \
src/printutils.cc \
src/nef2dxf.cc \
src/Preferences.cc \
src/progress.cc \
src/editor.cc \
src/accuracy.cc \
src/mathc99.cc
macx {
HEADERS += src/AppleEvents.h \
src/EventFilter.h
SOURCES += src/AppleEvents.cc
}
target.path = /usr/local/bin/
INSTALLS += target
examples.path = /usr/local/share/openscadpy/examples/
examples.files = examples/*
INSTALLS += examples
libraries.path = /usr/local/share/openscadpy/libraries/
libraries.files = libraries/*
INSTALLS += libraries