0029639: CMake - rename options for building samples
[occt.git] / samples / mfc / standard / 08_HLR / CMakeLists.txt
1 cmake_minimum_required (VERSION 2.6)
2
3 project (HLR)
4
5 add_definitions(-DWINVER=0x0501 -DUNICODE -D_UNICODE)
6 set (CMAKE_MFC_FLAG 2)
7
8 set (HLR_SRC_DIR      ${MFC_STANDARD_SAMPLES_DIR}/08_HLR/src)
9 set (HLR_HEADER_FILES ${HLR_SRC_DIR}/HLRApp.h
10                       ${HLR_SRC_DIR}/HLRDoc.h
11                       ${HLR_SRC_DIR}/HLRView2D.h
12                       ${HLR_SRC_DIR}/SelectionDialog.h
13                       ${HLR_SRC_DIR}/StdAfx.h )
14 set (HLR_SOURCE_FILES ${HLR_SRC_DIR}/HLRApp.cpp
15                       ${HLR_SRC_DIR}/HLRDoc.cpp
16                       ${HLR_SRC_DIR}/HLRView2D.cpp
17                       ${HLR_SRC_DIR}/SelectionDialog.cpp
18                       ${HLR_SRC_DIR}/StdAfx.cpp )
19
20 set (HLR_RESOURCE_DIR    ${MFC_STANDARD_SAMPLES_DIR}/08_HLR/res)
21 set (HLR_RESOURCE_HEADER ${HLR_RESOURCE_DIR}/resource.h)
22 set (HLR_RESOURCE_FILES  ${HLR_RESOURCE_DIR}/axoviewd.bmp
23                          ${HLR_RESOURCE_DIR}/axoviewf.bmp
24                          ${HLR_RESOURCE_DIR}/AXOVIEWU.bmp
25                          ${HLR_RESOURCE_DIR}/BACKVIEWD.bmp
26                          ${HLR_RESOURCE_DIR}/BACKVIEWF.bmp
27                          ${HLR_RESOURCE_DIR}/BACKVIEWU.bmp
28                          ${HLR_RESOURCE_DIR}/BOTTOMVIEWD.bmp
29                          ${HLR_RESOURCE_DIR}/BOTTOMVIEWF.bmp
30                          ${HLR_RESOURCE_DIR}/BOTTOMVIEWU.bmp
31                          ${HLR_RESOURCE_DIR}/ChildFrame2D.bmp
32                          ${HLR_RESOURCE_DIR}/ChildFrame3D.bmp
33                          ${HLR_RESOURCE_DIR}/FRONTVIEWD.bmp
34                          ${HLR_RESOURCE_DIR}/FRONTVIEWF.bmp
35                          ${HLR_RESOURCE_DIR}/FRONTVIEWU.bmp
36                          ${HLR_RESOURCE_DIR}/LEFTVIEWD.bmp
37                          ${HLR_RESOURCE_DIR}/LEFTVIEWF.bmp
38                          ${HLR_RESOURCE_DIR}/LEFTVIEWU.bmp
39                          ${HLR_RESOURCE_DIR}/RIGHTVIEWD.bmp
40                          ${HLR_RESOURCE_DIR}/RIGHTVIEWF.bmp
41                          ${HLR_RESOURCE_DIR}/RIGHTVIEWU.bmp
42                          ${HLR_RESOURCE_DIR}/Toolbar.bmp
43                          ${HLR_RESOURCE_DIR}/ToolBarObjects.bmp
44                          ${HLR_RESOURCE_DIR}/topviewd.bmp
45                          ${HLR_RESOURCE_DIR}/topviewf.bmp
46                          ${HLR_RESOURCE_DIR}/topviewu.bmp
47                          ${HLR_RESOURCE_DIR}/HLR.rc)
48
49 # groups in the VS solution
50 source_group ("Source Files" FILES ${HLR_SOURCE_FILES}
51                                    ${COMMON_WINMAIN_FILE})
52
53 source_group ("Header Files" FILES ${HLR_HEADER_FILES}
54                                    ${HLR_RESOURCE_HEADER})
55
56 source_group ("Resource Files" FILES ${HLR_RESOURCE_FILES})
57
58 add_executable (HLR WIN32 ${HLR_SOURCE_FILES}
59                           ${HLR_HEADER_FILES}
60                           ${COMMON_WINMAIN_FILE}
61                           ${HLR_RESOURCE_HEADER}
62                           ${HLR_RESOURCE_FILES} )
63
64 set_property (TARGET HLR PROPERTY FOLDER "Samples/mfc")
65
66 if (SINGLE_GENERATOR)
67   install (TARGETS HLR DESTINATION "${INSTALL_DIR_BIN}")
68 else()
69   install (TARGETS HLR
70            CONFIGURATIONS Release RelWithDebInfo
71            DESTINATION "${INSTALL_DIR_BIN}")
72   install (TARGETS HLR
73            CONFIGURATIONS Debug
74            DESTINATION "${INSTALL_DIR_BIN}d")
75 endif()
76
77 include_directories (${CMAKE_BINARY_DIR}/inc
78                      ${HLR_RESOURCE_DIR}
79                      ${HLR_SRC_DIR}
80                      ${MFC_STANDARD_SAMPLES_DIR}/Common)
81
82 target_link_libraries (HLR mfcsample)