0024469: cmake mfcsample project skippes ParamsFacesPage
[occt.git] / samples / mfc / standard / 10_Convert / CMakeLists.txt
1 cmake_minimum_required (VERSION 2.6)
2
3 project (Convert)
4
5 add_definitions (-DWINVER=0x0500)
6
7 set (Convert_SRC_DIR      ${MFC_STANDARD_SAMPLES_DIR}/10_Convert/src)
8 set (Convert_HEADER_FILES ${Convert_SRC_DIR}/Convert_Presentation.h
9                           ${Convert_SRC_DIR}/OCCDemo_Presentation.h)
10 set (Convert_SOURCE_FILES ${Convert_SRC_DIR}/Convert_Presentation.cpp
11                           ${Convert_SRC_DIR}/OCCDemo_Presentation.cpp )
12
13 set (ISESSION_SUBDIR       ${Convert_SRC_DIR}/ISession)
14 set (ISESSION_HEADER_FILES ${ISESSION_SUBDIR}/ISession_Curve.h)
15 set (ISESSION_SOURCE_FILES ${ISESSION_SUBDIR}/ISession_Curve.cpp)
16
17 set (WNT_SUBDIR       ${Convert_SRC_DIR}/WNT)
18 set (WNT_HEADER_FILES ${WNT_SUBDIR}/resource.h
19                       ${WNT_SUBDIR}/MainFrm.h
20                       ${WNT_SUBDIR}/OCCDemo.h
21                       ${WNT_SUBDIR}/OCCDemoDoc.h
22                       ${WNT_SUBDIR}/OCCDemoView.h
23                       ${WNT_SUBDIR}/ResultDialog.h
24                       ${WNT_SUBDIR}/StdAfx.h)
25 set (WNT_SOURCE_FILES ${WNT_SUBDIR}/MainFrm.cpp
26                       ${WNT_SUBDIR}/OCCDemo.cpp
27                       ${WNT_SUBDIR}/OCCDemoDoc.cpp
28                       ${WNT_SUBDIR}/OCCDemoView.cpp
29                       ${WNT_SUBDIR}/ResultDialog.cpp
30                       ${WNT_SUBDIR}/StdAfx.cpp)
31
32 set (WNT_RESOURCE_DIR   ${WNT_SUBDIR}/res)
33 set (WNT_RESOURCE_FILES ${WNT_RESOURCE_DIR}/OCCDemo.ico
34                         ${WNT_RESOURCE_DIR}/occlogo.bmp
35                         ${WNT_RESOURCE_DIR}/toolbar.bmp
36                         ${WNT_RESOURCE_DIR}/toolbar1.bmp
37                         ${WNT_RESOURCE_DIR}/logopen.bmp
38                         ${WNT_RESOURCE_DIR}/OCCDemo.rc2
39                         ${WNT_SUBDIR}/OCCDemo.rc)
40
41 # groups in the VS solution
42 source_group ("Source Files" FILES ${Convert_SOURCE_FILES}
43                                    ${COMMON_WINMAIN_FILE})
44
45 source_group ("Source Files\\ISession" FILES ${ISESSION_SOURCE_FILES})
46 source_group ("Source Files\\WNT" FILES ${WNT_SOURCE_FILES})
47
48 source_group ("Header Files" FILES ${Convert_HEADER_FILES} )
49 source_group ("Header Files\\ISession" FILES ${ISESSION_HEADER_FILES} )
50 source_group ("Header Files\\WNT" FILES ${WNT_HEADER_FILES})
51
52 source_group ("Resource Files" FILES ${WNT_RESOURCE_FILES})
53
54 add_executable (Convert WIN32 ${Convert_SOURCE_FILES}
55                               ${Convert_HEADER_FILES}
56                               ${ISESSION_SOURCE_FILES}
57                               ${ISESSION_HEADER_FILES}
58                               ${WNT_SOURCE_FILES}
59                               ${WNT_HEADER_FILES}
60                               ${COMMON_WINMAIN_FILE}
61                               ${WNT_RESOURCE_FILES} )
62
63 set_property (TARGET Convert PROPERTY FOLDER Samples)
64
65 install (TARGETS Convert RUNTIME DESTINATION "${INSTALL_DIR}/bin"
66                          ARCHIVE DESTINATION "${INSTALL_DIR}/lib"
67                          LIBRARY DESTINATION "${INSTALL_DIR}/lib")
68
69 include_directories (${OCCT_ROOT}/inc
70                      ${Convert_SRC_DIR}
71                      ${ISESSION_SUBDIR}
72                      ${WNT_SUBDIR}
73                      ${MFC_STANDARD_SAMPLES_DIR}/Common)
74
75 target_link_libraries (Convert mfcsample)