diff options
Diffstat (limited to 'examples/corelib')
20 files changed, 444 insertions, 0 deletions
diff --git a/examples/corelib/CMakeLists.txt b/examples/corelib/CMakeLists.txt new file mode 100644 index 0000000000..5e24def251 --- /dev/null +++ b/examples/corelib/CMakeLists.txt @@ -0,0 +1,10 @@ +# Generated from corelib.pro. + +add_subdirectory(ipc) +add_subdirectory(mimetypes) +add_subdirectory(serialization) +add_subdirectory(tools) + +if(QT_FEATURE_thread) + add_subdirectory(threads) +endif() diff --git a/examples/corelib/ipc/CMakeLists.txt b/examples/corelib/ipc/CMakeLists.txt new file mode 100644 index 0000000000..b134a3aa17 --- /dev/null +++ b/examples/corelib/ipc/CMakeLists.txt @@ -0,0 +1,14 @@ +# Generated from ipc.pro. + + +if(QT_FEATURE_sharedmemory) + add_subdirectory(sharedmemory) +endif() + +if(TARGET Qt::Network) + + if(QT_FEATURE_localserver) + add_subdirectory(localfortuneserver) + add_subdirectory(localfortuneclient) + endif() +endif() diff --git a/examples/corelib/ipc/localfortuneclient/CMakeLists.txt b/examples/corelib/ipc/localfortuneclient/CMakeLists.txt new file mode 100644 index 0000000000..b664e5795c --- /dev/null +++ b/examples/corelib/ipc/localfortuneclient/CMakeLists.txt @@ -0,0 +1,29 @@ +# Generated from localfortuneclient.pro. + +cmake_minimum_required(VERSION 3.14) +project(localfortuneclient LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Network) +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(localfortuneclient + client.cpp client.h + main.cpp +) +target_link_libraries(localfortuneclient PUBLIC + Qt::Network + Qt::Widgets +) +install(TARGETS localfortuneclient + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/ipc/localfortuneserver/CMakeLists.txt b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt new file mode 100644 index 0000000000..4d75ad437f --- /dev/null +++ b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt @@ -0,0 +1,29 @@ +# Generated from localfortuneserver.pro. + +cmake_minimum_required(VERSION 3.14) +project(localfortuneserver LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Network) +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(localfortuneserver + main.cpp + server.cpp server.h +) +target_link_libraries(localfortuneserver PUBLIC + Qt::Network + Qt::Widgets +) +install(TARGETS localfortuneserver + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/ipc/sharedmemory/CMakeLists.txt b/examples/corelib/ipc/sharedmemory/CMakeLists.txt new file mode 100644 index 0000000000..514a49914f --- /dev/null +++ b/examples/corelib/ipc/sharedmemory/CMakeLists.txt @@ -0,0 +1,27 @@ +# Generated from sharedmemory.pro. + +cmake_minimum_required(VERSION 3.14) +project(sharedmemory LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(sharedmemory + dialog.cpp dialog.h dialog.ui + main.cpp +) +target_link_libraries(sharedmemory PUBLIC + Qt::Widgets +) +install(TARGETS sharedmemory + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/mimetypes/CMakeLists.txt b/examples/corelib/mimetypes/CMakeLists.txt new file mode 100644 index 0000000000..0b31e0db69 --- /dev/null +++ b/examples/corelib/mimetypes/CMakeLists.txt @@ -0,0 +1,6 @@ +# Generated from mimetypes.pro. + + +if(TARGET Qt::Widgets) + add_subdirectory(mimetypebrowser) +endif() diff --git a/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt b/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt new file mode 100644 index 0000000000..e3ae3b7bb2 --- /dev/null +++ b/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt @@ -0,0 +1,28 @@ +# Generated from mimetypebrowser.pro. + +cmake_minimum_required(VERSION 3.14) +project(mimetypebrowser LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(mimetypebrowser + main.cpp + mainwindow.cpp mainwindow.h + mimetypemodel.cpp mimetypemodel.h +) +target_link_libraries(mimetypebrowser PUBLIC + Qt::Widgets +) +install(TARGETS mimetypebrowser + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/serialization/CMakeLists.txt b/examples/corelib/serialization/CMakeLists.txt new file mode 100644 index 0000000000..a64b5130d2 --- /dev/null +++ b/examples/corelib/serialization/CMakeLists.txt @@ -0,0 +1,5 @@ +# Generated from serialization.pro. + +add_subdirectory(cbordump) +add_subdirectory(convert) +add_subdirectory(savegame) diff --git a/examples/corelib/serialization/cbordump/CMakeLists.txt b/examples/corelib/serialization/cbordump/CMakeLists.txt new file mode 100644 index 0000000000..cedf7712d4 --- /dev/null +++ b/examples/corelib/serialization/cbordump/CMakeLists.txt @@ -0,0 +1,27 @@ +# Generated from cbordump.pro. + +cmake_minimum_required(VERSION 3.14) +project(cbordump LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Core) + +add_executable(cbordump + main.cpp +) +target_link_libraries(cbordump PUBLIC + # Remove: gui + Qt::Core +) +install(TARGETS cbordump + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/serialization/convert/CMakeLists.txt b/examples/corelib/serialization/convert/CMakeLists.txt new file mode 100644 index 0000000000..04b57bbd3d --- /dev/null +++ b/examples/corelib/serialization/convert/CMakeLists.txt @@ -0,0 +1,34 @@ +# Generated from convert.pro. + +cmake_minimum_required(VERSION 3.14) +project(convert LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Core) + +add_executable(convert + cborconverter.cpp cborconverter.h + converter.h + datastreamconverter.cpp datastreamconverter.h + jsonconverter.cpp jsonconverter.h + main.cpp + nullconverter.cpp nullconverter.h + textconverter.cpp textconverter.h + xmlconverter.cpp xmlconverter.h +) +target_link_libraries(convert PUBLIC + # Remove: gui + Qt::Core +) +install(TARGETS convert + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/serialization/savegame/CMakeLists.txt b/examples/corelib/serialization/savegame/CMakeLists.txt new file mode 100644 index 0000000000..97d866da43 --- /dev/null +++ b/examples/corelib/serialization/savegame/CMakeLists.txt @@ -0,0 +1,30 @@ +# Generated from savegame.pro. + +cmake_minimum_required(VERSION 3.14) +project(savegame LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Core) + +add_executable(savegame + character.cpp character.h + game.cpp game.h + level.cpp level.h + main.cpp +) +target_link_libraries(savegame PUBLIC + # Remove: gui + Qt::Core +) +install(TARGETS savegame + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/threads/CMakeLists.txt b/examples/corelib/threads/CMakeLists.txt new file mode 100644 index 0000000000..b13dd16d93 --- /dev/null +++ b/examples/corelib/threads/CMakeLists.txt @@ -0,0 +1,9 @@ +# Generated from threads.pro. + +add_subdirectory(semaphores) +add_subdirectory(waitconditions) + +if(TARGET Qt::Widgets) + add_subdirectory(mandelbrot) + add_subdirectory(queuedcustomtype) +endif() diff --git a/examples/corelib/threads/mandelbrot/CMakeLists.txt b/examples/corelib/threads/mandelbrot/CMakeLists.txt new file mode 100644 index 0000000000..6905429559 --- /dev/null +++ b/examples/corelib/threads/mandelbrot/CMakeLists.txt @@ -0,0 +1,28 @@ +# Generated from mandelbrot.pro. + +cmake_minimum_required(VERSION 3.14) +project(mandelbrot LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(mandelbrot + main.cpp + mandelbrotwidget.cpp mandelbrotwidget.h + renderthread.cpp renderthread.h +) +target_link_libraries(mandelbrot PUBLIC + Qt::Widgets +) +install(TARGETS mandelbrot + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/threads/queuedcustomtype/CMakeLists.txt b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt new file mode 100644 index 0000000000..78a59ac2dc --- /dev/null +++ b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt @@ -0,0 +1,29 @@ +# Generated from queuedcustomtype.pro. + +cmake_minimum_required(VERSION 3.14) +project(queuedcustomtype LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(queuedcustomtype + block.cpp block.h + main.cpp + renderthread.cpp renderthread.h + window.cpp window.h +) +target_link_libraries(queuedcustomtype PUBLIC + Qt::Widgets +) +install(TARGETS queuedcustomtype + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/threads/semaphores/CMakeLists.txt b/examples/corelib/threads/semaphores/CMakeLists.txt new file mode 100644 index 0000000000..ed36acde55 --- /dev/null +++ b/examples/corelib/threads/semaphores/CMakeLists.txt @@ -0,0 +1,26 @@ +# Generated from semaphores.pro. + +cmake_minimum_required(VERSION 3.14) +project(semaphores LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Core) + +add_executable(semaphores + semaphores.cpp +) +target_link_libraries(semaphores PUBLIC + Qt::Core +) +install(TARGETS semaphores + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/threads/waitconditions/CMakeLists.txt b/examples/corelib/threads/waitconditions/CMakeLists.txt new file mode 100644 index 0000000000..235cb91cdb --- /dev/null +++ b/examples/corelib/threads/waitconditions/CMakeLists.txt @@ -0,0 +1,26 @@ +# Generated from waitconditions.pro. + +cmake_minimum_required(VERSION 3.14) +project(waitconditions LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Core) + +add_executable(waitconditions + waitconditions.cpp +) +target_link_libraries(waitconditions PUBLIC + Qt::Core +) +install(TARGETS waitconditions + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/tools/CMakeLists.txt b/examples/corelib/tools/CMakeLists.txt new file mode 100644 index 0000000000..d25014ee3c --- /dev/null +++ b/examples/corelib/tools/CMakeLists.txt @@ -0,0 +1,5 @@ +# Generated from tools.pro. + +add_subdirectory(contiguouscache) +add_subdirectory(customtype) +add_subdirectory(customtypesending) diff --git a/examples/corelib/tools/contiguouscache/CMakeLists.txt b/examples/corelib/tools/contiguouscache/CMakeLists.txt new file mode 100644 index 0000000000..3adb033c49 --- /dev/null +++ b/examples/corelib/tools/contiguouscache/CMakeLists.txt @@ -0,0 +1,27 @@ +# Generated from contiguouscache.pro. + +cmake_minimum_required(VERSION 3.14) +project(contiguouscache LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(contiguouscache + main.cpp + randomlistmodel.cpp randomlistmodel.h +) +target_link_libraries(contiguouscache PUBLIC + Qt::Widgets +) +install(TARGETS contiguouscache + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/tools/customtype/CMakeLists.txt b/examples/corelib/tools/customtype/CMakeLists.txt new file mode 100644 index 0000000000..11958e1c1b --- /dev/null +++ b/examples/corelib/tools/customtype/CMakeLists.txt @@ -0,0 +1,27 @@ +# Generated from customtype.pro. + +cmake_minimum_required(VERSION 3.14) +project(customtype LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(customtype + main.cpp + message.cpp message.h +) +target_link_libraries(customtype PUBLIC + Qt::Widgets +) +install(TARGETS customtype + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/corelib/tools/customtypesending/CMakeLists.txt b/examples/corelib/tools/customtypesending/CMakeLists.txt new file mode 100644 index 0000000000..f22894d919 --- /dev/null +++ b/examples/corelib/tools/customtypesending/CMakeLists.txt @@ -0,0 +1,28 @@ +# Generated from customtypesending.pro. + +cmake_minimum_required(VERSION 3.14) +project(customtypesending LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +find_package(Qt6 COMPONENTS Widgets) + +add_qt_gui_executable(customtypesending + main.cpp + message.cpp message.h + window.cpp window.h +) +target_link_libraries(customtypesending PUBLIC + Qt::Widgets +) +install(TARGETS customtypesending + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) |