@@ -29,7 +29,7 @@ include(KatieBuildMacros)
29
29
set (KATIE_COMPONENTS "Core Gui Declarative Designer DesignerComponents Help Multimedia Network Sql Svg Xml XmlPatterns Script ScriptTools Test UiTools" )
30
30
set (KATIE_TOOLS "moc uic rcc qhelpgenerator qcollectiongenerator lupdate lrelease lconvert designer" )
31
31
32
- # optional package features
32
+ # optional package
33
33
option (WITH_THREADS "Build threads support" ON )
34
34
add_feature_info(threads WITH_THREADS "an open source something" )
35
35
@@ -109,7 +109,7 @@ add_feature_info(sqlite WITH_SQLITE "the world's most popular open source databa
109
109
option (WITH_X11 "Build X11/X.Org support" ON )
110
110
add_feature_info(x11 WITH_X11 "an open source something" )
111
111
112
- # katie features
112
+ # optional features
113
113
option (KATIE_BOOTSTRAP "Build only core tools" OFF )
114
114
add_feature_info(bootstrap KATIE_BOOTSTRAP "internal build option" )
115
115
@@ -471,6 +471,7 @@ if(ENABLE_TESTING)
471
471
add_definitions (-DQT_BUILD_INTERNAL)
472
472
endif ()
473
473
474
+ # optional packages
474
475
if (NOT WITH_THREADS OR NOT THREADS_FOUND)
475
476
katie_definition(-DQT_NO_THREAD)
476
477
endif ()
@@ -511,10 +512,6 @@ if(NOT WITH_NIS OR NOT NIS_FOUND)
511
512
katie_definition(-DQT_NO_NIS)
512
513
endif ()
513
514
514
- if (NOT WITH_DIRECTWRITE)
515
- katie_definition(-DQT_NO_DIRECTWRITE)
516
- endif ()
517
-
518
515
if (NOT WITH_OPENGL OR NOT OPENGL_FOUND)
519
516
katie_definition(-DQT_NO_OPENGL)
520
517
else ()
@@ -525,10 +522,6 @@ if(NOT WITH_NAS OR NOT NAS_FOUND)
525
522
katie_definition(-DQT_NO_NAS)
526
523
endif ()
527
524
528
- if (NOT WITH_PNG)
529
- katie_definition(-DQT_NO_IMAGEFORMAT_PNG)
530
- endif ()
531
-
532
525
if (NOT WITH_JPEG OR NOT JPEG_FOUND)
533
526
katie_definition(-DQT_NO_IMAGEFORMAT_JPEG)
534
527
endif ()
@@ -541,6 +534,32 @@ if(NOT WITH_TIFF OR NOT TIFF_FOUND)
541
534
katie_definition(-DQT_NO_IMAGEFORMAT_TIFF)
542
535
endif ()
543
536
537
+
538
+ # conditional features
539
+ if (NOT WITH_ACCESSIBILITY)
540
+ katie_definition(-DQT_NO_ACCESSIBILITY)
541
+ endif ()
542
+
543
+ if (NOT WITH_DIRECTWRITE)
544
+ katie_definition(-DQT_NO_DIRECTWRITE)
545
+ endif ()
546
+
547
+ if (WITH_OPENGLES1)
548
+ katie_definition(-DQT_OPENGL_ES_1)
549
+ endif ()
550
+
551
+ if (WITH_OPENGLES2)
552
+ katie_definition(-DQT_OPENGL_ES_2)
553
+ endif ()
554
+
555
+ # keep in sucn with multimedia audio component CMake file, only definitions setup is needed here
556
+ if (KATIE_PLATFORM MATCHES "(mac|win32|wince)" OR (UNIX AND WITH_ALSA AND ALSA_FOUND))
557
+ # NOTE: CMake's logical OR does not stop at the first met condition and
558
+ # I'd rather not have a AND condition here with negatives
559
+ else ()
560
+ katie_definition(-DQT_NO_AUDIO_BACKEND)
561
+ endif ()
562
+
544
563
# keep in sync with the gui component CMake file, only definitions setup is needed here
545
564
if (WITH_X11 AND X11_FOUND)
546
565
# TODO: xim
@@ -561,6 +580,11 @@ if(WITH_X11 AND X11_FOUND)
561
580
endif ()
562
581
endif ()
563
582
583
+ # kinda optional package
584
+ if (NOT WITH_PNG)
585
+ katie_definition(-DQT_NO_IMAGEFORMAT_PNG)
586
+ endif ()
587
+
564
588
# semi-shared
565
589
include (src/shared/linguist/linguist.cmake)
566
590
include (src/shared/bootstrap.cmake)
0 commit comments