MantisBT - Open CASCADE
View Issue Details
0029589Open CASCADE[OCCT] OCCT:Configurationpublic2018-03-19 08:582018-06-29 21:19
abv 
bugmaster 
normalminor 
closedfixed 
 
[OCCT] 7.3.0[OCCT] 7.3.0 
Not needed
0029589: Configuration - allow MFC samples to be built when OCCT is linked statically
Currently building of MFC samples by CMake fails if option BUILD_LIBRARY_TYPE is set to "Static", for several reasons:
- mfcsample project gets built as DLL, not static lib
- usage of macro AFX_EXT_CLASS in classes defined in that library causes link conflicts
- paths to link libs of third-party libraries are not set due to changes made within #27380
Build OCCT using CMake setting BUILD_LIBRARY_TYPE to "Static" and with BUILD_MODULE_MfcSamples checked.
No tags attached.
related to 0029407closed abv Community Generating static libraries on macOS 
related to 0025713closed bugmaster Open CASCADE CMake configuring procedure should allow to build OCCT as static libraries 
Issue History
2018-03-19 08:58abvNew Issue
2018-03-19 08:58abvAssigned To => bugmaster
2018-03-19 08:58abvRelationship addedchild of 0027380
2018-03-19 08:58abvRelationship addedrelated to 0029407
2018-03-19 08:59abvRelationship addedrelated to 0025713
2018-03-19 08:59abvRelationship addedrelated to 0022651
2018-03-19 15:01gitNote Added: 0074654
2018-03-19 15:50abvNote Added: 0074659
2018-03-19 15:50abvAssigned Tobugmaster => apn
2018-03-19 15:50abvStatusnew => resolved
2018-03-19 15:50abvSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=18752#r18752
2018-03-22 12:48apnTest case number => Not needed
2018-03-22 12:48apnNote Added: 0074756
2018-03-22 12:48apnAssigned Toapn => bugmaster
2018-03-22 12:48apnStatusresolved => reviewed
2018-03-22 13:56bugmasterStatusreviewed => tested
2018-03-22 19:03abvTarget Version7.4.0* => 7.3.0
2018-03-24 11:51bugmasterChangeset attached => occt master 0553a8ea
2018-03-24 11:51bugmasterStatustested => verified
2018-03-24 11:51bugmasterResolutionopen => fixed
2018-03-24 20:01gitNote Added: 0074874
2018-06-29 21:14aivFixed in Version => 7.3.0
2018-06-29 21:19aivStatusverified => closed

Notes
(0074654)
git   
2018-03-19 15:01   
Branch CR29589 has been created by abv.

SHA-1: 4d4fe34306486b634a8b17c3df38f58b8dca8273


Detailed log of new commits:

Author: abv
Date: Mon Mar 19 09:04:17 2018 +0300

    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).
(0074659)
abv   
2018-03-19 15:50   
Fix is pushed to CR29589, please review. Compilation has been tested in Jenkins job CR29589-master-abv.
(0074756)
apn   
2018-03-22 12:48   
Reviewed. Building of MFC samples if option BUILD_LIBRARY_TYPE is set to "Static" was checked.
(0074874)
git   
2018-03-24 20:01   
Branch CR29589 has been deleted by kgv.

SHA-1: 4d4fe34306486b634a8b17c3df38f58b8dca8273