[Windows] Fix driver version detection of AMD RDNA+ GPU on Windows 10
[xbmc.git] / xbmc / guilib / CMakeLists.txt
blob5d598cbad3a32c0be0fea6dde327b01b52bd7bb2
1 set(SOURCES DDSImage.cpp
2             DirtyRegionSolvers.cpp
3             DirtyRegionTracker.cpp
4             FFmpegImage.cpp
5             GUIAction.cpp
6             GUIAudioManager.cpp
7             GUIBaseContainer.cpp
8             GUIBorderedImage.cpp
9             GUIButtonControl.cpp
10             GUIColorButtonControl.cpp
11             GUIColorManager.cpp
12             GUIComponent.cpp
13             GUIControl.cpp
14             GUIControlFactory.cpp
15             GUIControlGroup.cpp
16             GUIControlGroupList.cpp
17             GUIControlLookup.cpp
18             GUIControlProfiler.cpp
19             GUIDialog.cpp
20             GUIEditControl.cpp
21             GUIFadeLabelControl.cpp
22             GUIFixedListContainer.cpp
23             GUIFont.cpp
24             GUIFontCache.cpp
25             GUIFontManager.cpp
26             GUIFontTTF.cpp
27             GUIImage.cpp
28             GUIIncludes.cpp
29             GUIKeyboardFactory.cpp
30             GUILabelControl.cpp
31             GUILabel.cpp
32             GUIListContainer.cpp
33             GUIListGroup.cpp
34             GUIListItem.cpp
35             GUIListItemLayout.cpp
36             GUIListLabel.cpp
37             GUIMessage.cpp
38             GUIMoverControl.cpp
39             GUIMultiImage.cpp
40             GUIPanelContainer.cpp
41             GUIProgressControl.cpp
42             GUIRadioButtonControl.cpp
43             GUIRangesControl.cpp
44             GUIRenderingControl.cpp
45             GUIResizeControl.cpp
46             GUIRSSControl.cpp
47             GUIScrollBarControl.cpp
48             GUISettingsSliderControl.cpp
49             GUISliderControl.cpp
50             GUISpinControl.cpp
51             GUISpinControlEx.cpp
52             GUIStaticItem.cpp
53             GUITextBox.cpp
54             GUITextLayout.cpp
55             GUITexture.cpp
56             GUIToggleButtonControl.cpp
57             GUIVideoControl.cpp
58             GUIVisualisationControl.cpp
59             GUIWindow.cpp
60             GUIWindowManager.cpp
61             GUIWrappingListContainer.cpp
62             imagefactory.cpp
63             IWindowManagerCallback.cpp
64             LocalizeStrings.cpp
65             StereoscopicsManager.cpp
66             TextureBundle.cpp
67             TextureBundleXBT.cpp
68             Texture.cpp
69             TextureBase.cpp
70             TextureManager.cpp
71             VisibleEffect.cpp
72             XBTF.cpp
73             XBTFReader.cpp)
75 set(HEADERS DDSImage.h
76             DirtyRegion.h
77             DirtyRegionSolvers.h
78             DirtyRegionTracker.h
79             DispResource.h
80             FFmpegImage.h
81             gui3d.h
82             GUIAction.h
83             GUIAudioManager.h
84             GUIBaseContainer.h
85             GUIBorderedImage.h
86             GUIButtonControl.h
87             GUIColorButtonControl.h
88             GUIColorManager.h
89             GUIComponent.h
90             GUIControl.h
91             GUIControlFactory.h
92             GUIControlGroup.h
93             GUIControlGroupList.h
94             GUIControlProfiler.h
95             GUIControlLookup.h
96             GUIDialog.h
97             GUIEditControl.h
98             GUIFadeLabelControl.h
99             GUIFixedListContainer.h
100             GUIFont.h
101             GUIFontCache.h
102             GUIFontManager.h
103             GUIFontTTF.h
104             GUIImage.h
105             GUIIncludes.h
106             GUIKeyboard.h
107             GUIKeyboardFactory.h
108             GUILabel.h
109             GUILabelControl.h
110             GUIListContainer.h
111             GUIListGroup.h
112             GUIListItem.h
113             GUIListItemLayout.h
114             GUIListLabel.h
115             GUIMessage.h
116             GUIMoverControl.h
117             GUIMultiImage.h
118             GUIPanelContainer.h
119             GUIProgressControl.h
120             GUIRadioButtonControl.h
121             GUIRangesControl.h
122             GUIRenderingControl.h
123             GUIResizeControl.h
124             GUIRSSControl.h
125             GUIScrollBarControl.h
126             GUISettingsSliderControl.h
127             GUISliderControl.h
128             GUISpinControl.h
129             GUISpinControlEx.h
130             GUIStaticItem.h
131             GUITextBox.h
132             GUITextLayout.h
133             GUITexture.h
134             GUIToggleButtonControl.h
135             GUIVideoControl.h
136             GUIVisualisationControl.h
137             GUIWindow.h
138             GUIWindowManager.h
139             GUIWrappingListContainer.h
140             IAudioDeviceChangedCallback.h
141             IDirtyRegionSolver.h
142             IGUIContainer.h
143             iimage.h
144             imagefactory.h
145             IMsgTargetCallback.h
146             IRenderingCallback.h
147             ISliderCallback.h
148             IWindowManagerCallback.h
149             LocalizeStrings.h
150             StereoscopicsManager.h
151             Texture.h
152             TextureBase.h
153             TextureBundle.h
154             TextureBundleXBT.h
155             TextureManager.h
156             Tween.h
157             VisibleEffect.h
158             WindowIDs.h
159             XBTF.h
160             XBTFReader.h)
162 if(TARGET OpenGL::GL OR TARGET OpenGL::GLES)
163   list(APPEND SOURCES Shader.cpp
164                       TextureGL.cpp)
165   list(APPEND HEADERS Shader.h
166                       TextureGL.h)
168   if(TARGET OpenGL::GL)
169     list(APPEND SOURCES GUIFontTTFGL.cpp
170                         GUITextureGL.cpp)
171     list(APPEND HEADERS GUIFontTTFGL.h
172                         GUITextureGL.h)
173   endif()
175   if(TARGET OpenGL::GLES)
176     list(APPEND SOURCES GUIFontTTFGLES.cpp
177                         GUITextureGLES.cpp)
178     list(APPEND HEADERS GUIFontTTFGLES.h
179                         GUITextureGLES.h)
180   endif()
182 endif()
184 if(CORE_SYSTEM_NAME STREQUAL windows OR CORE_SYSTEM_NAME STREQUAL windowsstore)
185   list(APPEND SOURCES D3DResource.cpp
186                       DirectXGraphics.cpp
187                       GUIFontTTFDX.cpp
188                       GUIShaderDX.cpp
189                       GUITextureD3D.cpp
190                       TextureDX.cpp)
191   list(APPEND HEADERS D3DResource.h
192                       DirectXGraphics.h
193                       GUIFontTTFDX.h
194                       GUIShaderDX.h
195                       GUITextureD3D.h
196                       TextureDX.h)
197 endif()
199 core_add_library(guilib)
201 if(CORE_SYSTEM_NAME STREQUAL windows OR CORE_SYSTEM_NAME STREQUAL windowsstore)
202   set(SHADERS_VERTEX guishader_vert.hlsl)
203   set(SHADERS_PIXEL guishader_checkerboard_right.hlsl
204                     guishader_checkerboard_left.hlsl
205                     guishader_default.hlsl
206                     guishader_fonts.hlsl
207                     guishader_interlaced_right.hlsl
208                     guishader_interlaced_left.hlsl
209                     guishader_multi_texture_blend.hlsl
210                     guishader_texture.hlsl
211                     guishader_texture_noblend.hlsl)
212   foreach(shader ${SHADERS_VERTEX})
213     get_filename_component(file ${shader} NAME_WE)
214     add_custom_command(OUTPUT ${file}.h
215                        COMMAND windows::FXC
216                        ARGS /Fh ${file}.h /E VS /T vs_4_0_level_9_1 /Vn ${file} /Qstrip_reflect
217                             ${CMAKE_SOURCE_DIR}/system/shaders/${shader}
218                        DEPENDS ${CMAKE_SOURCE_DIR}/system/shaders/${shader}
219                        COMMENT "FX compile vertex shader ${shader}"
220                        VERBATIM)
221     list(APPEND SHADERS ${file}.h)
222   endforeach()
223   foreach(shader ${SHADERS_PIXEL})
224     get_filename_component(file ${shader} NAME_WE)
225     add_custom_command(OUTPUT ${file}.h
226                        COMMAND windows::FXC
227                        ARGS /Fh ${file}.h /E PS /T ps_4_0_level_9_1 /Vn ${file} /Qstrip_reflect
228                             ${CMAKE_SOURCE_DIR}/system/shaders/${shader}
229                        DEPENDS ${CMAKE_SOURCE_DIR}/system/shaders/${shader}
230                        COMMENT "FX compile pixel shader ${shader}"
231                        VERBATIM)
232     list(APPEND SHADERS ${file}.h)
233   endforeach()
235   add_custom_target(generate_shaders ALL DEPENDS ${SHADERS})
236   set_target_properties(generate_shaders PROPERTIES FOLDER "Build Utilities")
237   target_include_directories(${CORE_LIBRARY} PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
238   add_dependencies(${CORE_LIBRARY} generate_shaders)
239 endif()