0029589: Configuration - allow MFC samples to be built when OCCT is linked statically
authorabv <abv@opencascade.com>
Mon, 19 Mar 2018 06:04:17 +0000 (09:04 +0300)
committerbugmaster <bugmaster@opencascade.com>
Thu, 22 Mar 2018 16:51:20 +0000 (19:51 +0300)
commit0553a8ea9924f42f3dbace50c26f51ec3b4af412
tree30b0d3044431563c495d4eddab50846bc0e99837
parent1fa1615244319b1e0ede0aba9b86f0dc1d3672a9
0029589: Configuration - allow MFC samples to be built when OCCT is linked statically

CMake scripts are corrected to do perform search of libs and dlls of third-party libraries even for static builds of OCCT.
Treatment of errors in this case is relaxed: not found DLLs are reported as warnings, and not found libs as warning for static build, and continuable error for shared build.

Code of samples is corrected to allow building with OCCT linked statically.
Implementation of main application class is corrected to ensure that initialization is done after all global objects are created.
Note however that samples still fails to start for unclear reason (creation of MFC frame window fails).
25 files changed:
CMakeLists.txt
adm/cmake/3rdparty_macro.cmake
adm/cmake/ffmpeg.cmake
adm/cmake/freetype.cmake
adm/cmake/qt.cmake
adm/cmake/tbb.cmake
adm/cmake/tcl.cmake
adm/cmake/tk.cmake
adm/cmake/vtk.cmake
samples/mfc/standard/05_ImportExport/src/ImportExportApp.cpp
samples/mfc/standard/06_Ocaf/CMakeLists.txt
samples/mfc/standard/Common/OCC_2dChildFrame.h
samples/mfc/standard/Common/OCC_2dDoc.h
samples/mfc/standard/Common/OCC_2dView.h
samples/mfc/standard/Common/OCC_3dBaseDoc.h
samples/mfc/standard/Common/OCC_3dChildFrame.h
samples/mfc/standard/Common/OCC_3dDoc.h
samples/mfc/standard/Common/OCC_3dView.h
samples/mfc/standard/Common/OCC_App.cpp
samples/mfc/standard/Common/OCC_App.h
samples/mfc/standard/Common/OCC_BaseChildFrame.h
samples/mfc/standard/Common/OCC_BaseDoc.h
samples/mfc/standard/Common/OCC_BaseView.h
samples/mfc/standard/Common/OCC_StereoConfigDlg.h
samples/mfc/standard/mfcsample/CMakeLists.txt