0030115: Implementation of import from XCAF to VRML.
[occt.git] / samples / qt / Tutorial / Tutorial.pro
CommitLineData
7fd59977 1TEMPLATE = app
2CONFIG += debug_and_release qt
3
4TARGET = Tutorial
5
4b3541c6 6SAMPLESROOT = $$quote($$(CSF_OCCTSamplesPath)/qt)
7fd59977 7
fad8962a 8HEADERS = src/*.h \
9 $${SAMPLESROOT}/Common/src/*.h \
10 $${SAMPLESROOT}/Interface/src/*.h
7fd59977 11
fad8962a 12SOURCES = src/*.cxx \
13 $${SAMPLESROOT}/Common/src/*.cxx \
14 $${SAMPLESROOT}/Interface/src/*.cxx
15
16TS_FILES = $${SAMPLESROOT}/Common/src/Common-icon.ts \
17 $${SAMPLESROOT}/Common/src/Common-string.ts \
18 ./src/Tutorial-icon.ts \
19 ./src/Tutorial-string.ts
20
21RES_FILES = $${SAMPLESROOT}/Common/res/* \
22 ./res/*
23
24RES_DIR = $$quote($$(RES_DIR))
25
26INCLUDEPATH += $$quote($${SAMPLESROOT}/Common/src)
27INCLUDEPATH += $$quote($${SAMPLESROOT}/Interface/src)
4b3541c6 28INCLUDEPATH += $$quote($$(CSF_OCCTIncludePath))
7fd59977 29
861a7b03 30OCCT_DEFINES = $$(CSF_DEFINES)
31
41f03605 32DEFINES = $$split(OCCT_DEFINES, ;)
7fd59977 33
34unix {
90ac6145 35 UNAME = $$system(uname -s)
7a53e886 36 LIBLIST = $$(LD_LIBRARY_PATH)
37 LIBPATHS = $$split(LIBLIST,":")
38 for(lib, LIBPATHS):LIBS += -L$${lib}
90ac6145 39
7fd59977 40 CONFIG(debug, debug|release) {
980d161f 41 DESTDIR = ./$$UNAME/bind
42 OBJECTS_DIR = ./$$UNAME/objd
43 MOC_DIR = ./$$UNAME/mocd
7fd59977 44 } else {
980d161f 45 DESTDIR = ./$$UNAME/bin
46 OBJECTS_DIR = ./$$UNAME/obj
47 MOC_DIR = ./$$UNAME/moc
7fd59977 48 }
5f9575b3 49
50 MACOSX_USE_GLX = $$(MACOSX_USE_GLX)
51
52 !macx | equals(MACOSX_USE_GLX, true): INCLUDEPATH += $$QMAKE_INCDIR_X11 $$QMAKE_INCDIR_OPENGL $$QMAKE_INCDIR_THREAD
dc3fe572 53 equals(MACOSX_USE_GLX, true): DEFINES += MACOSX_USE_GLX
03155c18 54 DEFINES += OCC_CONVERT_SIGNALS QT_NO_STL
5f9575b3 55 !macx | equals(MACOSX_USE_GLX, true): LIBS += -L$$QMAKE_LIBDIR_X11 $$QMAKE_LIBS_X11 -L$$QMAKE_LIBDIR_OPENGL $$QMAKE_LIBS_OPENGL $$QMAKE_LIBS_THREAD
56 LIBS += -lfreeimageplus
57 LIBS += -ltbb -ltbbmalloc
980d161f 58 QMAKE_CXXFLAGS += -std=gnu++11
7fd59977 59}
60
61win32 {
62 CONFIG(debug, debug|release) {
980d161f 63 DEFINES += _DEBUG
64 DESTDIR = ./win$(ARCH)/$(VCVER)/bind
65 OBJECTS_DIR = ./win$(ARCH)/$(VCVER)/objd
66 MOC_DIR = ./win$(ARCH)/$(VCVER)/mocd
7fd59977 67 } else {
980d161f 68 DEFINES += NDEBUG
69 DESTDIR = ./win$(ARCH)/$(VCVER)/bin
70 OBJECTS_DIR = ./win$(ARCH)/$(VCVER)/obj
71 MOC_DIR = ./win$(ARCH)/$(VCVER)/moc
7fd59977 72 }
4b3541c6 73 LIBS = -L$$(QTDIR)/lib;$$(CSF_OCCTLibPath)
50fe2dab 74 DEFINES += NO_COMMONSAMPLE_EXPORTS NO_IESAMPLE_EXPORTS
7fd59977 75}
8854dbb4 76
41f03605 77LIBS += -lTKernel -lTKMath -lTKService -lTKV3d -lTKOpenGl \
7a53e886 78 -lTKBRep -lTKIGES -lTKSTL -lTKVRML -lTKSTEP -lTKSTEPAttr -lTKSTEP209 \
41f03605 79 -lTKSTEPBase -lTKGeomBase -lTKGeomAlgo -lTKG3d -lTKG2d \
80 -lTKXSBase -lTKShHealing -lTKHLR -lTKTopAlgo -lTKMesh -lTKPrim \
a3506de7 81 -lTKCDF -lTKBool -lTKBO -lTKFillet -lTKOffset -lTKLCAF \
7fd59977 82
fad8962a 83!exists($${RES_DIR}) {
84 win32 {
85 system(mkdir $${RES_DIR})
86 } else {
87 system(mkdir -p $${RES_DIR})
88 }
89}
90
3f0a1ac7 91lrelease.name = LRELEASE ${QMAKE_FILE_IN}
fad8962a 92lrelease.commands = lrelease ${QMAKE_FILE_IN} -qm $${RES_DIR}/${QMAKE_FILE_BASE}.qm
93lrelease.output = ${QMAKE_FILE_BASE}.qm
3346c3f9 94lrelease.input = TS_FILES
fad8962a 95lrelease.clean = $${RES_DIR}/${QMAKE_FILE_BASE}.qm
7fd59977 96lrelease.CONFIG += no_link target_predeps
fad8962a 97QMAKE_EXTRA_COMPILERS += lrelease
98
99copy_res.name = Copy resource ${QMAKE_FILE_IN}
100copy_res.output = ${QMAKE_FILE_BASE}${QMAKE_FILE_EXT}
101copy_res.clean = $${RES_DIR}/${QMAKE_FILE_BASE}${QMAKE_FILE_EXT}
102copy_res.input = RES_FILES
103copy_res.CONFIG += no_link target_predeps
104win32: copy_res.commands = type ${QMAKE_FILE_IN} > $${RES_DIR}/${QMAKE_FILE_BASE}${QMAKE_FILE_EXT}
105unix: copy_res.commands = cp -f ${QMAKE_FILE_IN} $${RES_DIR}
106QMAKE_EXTRA_COMPILERS += copy_res
861a7b03 107#QMAKE_CXXFLAGS += /wd4996
fad8962a 108
861a7b03 109greaterThan(QT_MAJOR_VERSION, 4) {
110 QT += widgets
111}