From 2275bbd9ddddff9378e310664a69107e6184d1dc Mon Sep 17 00:00:00 2001 From: Bill Avery Date: Fri, 8 Jan 2021 13:28:12 -0800 Subject: [PATCH 1/3] Add all generated files to the repo and fix dependencies --- .gitignore | 2 +- CMakeLists.txt | 14 +- include/graphqlservice/internal/Version.h | 21 +++ .../introspection/IntrospectionSchema.h | 2 + res/SchemaGen.rc | 43 ++++++ res/graphqljson_version.rc | 43 ++++++ res/graphqlpeg_version.rc | 43 ++++++ res/graphqlresponse_version.rc | 43 ++++++ res/graphqlservice_nointrospection_version.rc | 43 ++++++ res/graphqlservice_version.rc | 43 ++++++ samples/CMakeLists.txt | 132 ++++++++--------- .../separate/AppointmentConnectionObject.cpp | 2 + .../separate/AppointmentConnectionObject.h | 2 + samples/separate/AppointmentEdgeObject.cpp | 2 + samples/separate/AppointmentEdgeObject.h | 2 + samples/separate/AppointmentObject.cpp | 2 + samples/separate/AppointmentObject.h | 2 + .../separate/CompleteTaskPayloadObject.cpp | 2 + samples/separate/CompleteTaskPayloadObject.h | 2 + samples/separate/ExpensiveObject.cpp | 2 + samples/separate/ExpensiveObject.h | 2 + samples/separate/FolderConnectionObject.cpp | 2 + samples/separate/FolderConnectionObject.h | 2 + samples/separate/FolderEdgeObject.cpp | 2 + samples/separate/FolderEdgeObject.h | 2 + samples/separate/FolderObject.cpp | 2 + samples/separate/FolderObject.h | 2 + samples/separate/MutationObject.cpp | 2 + samples/separate/MutationObject.h | 2 + samples/separate/NestedTypeObject.cpp | 2 + samples/separate/NestedTypeObject.h | 2 + samples/separate/PageInfoObject.cpp | 2 + samples/separate/PageInfoObject.h | 2 + samples/separate/QueryObject.cpp | 2 + samples/separate/QueryObject.h | 2 + samples/separate/SubscriptionObject.cpp | 2 + samples/separate/SubscriptionObject.h | 2 + samples/separate/TaskConnectionObject.cpp | 2 + samples/separate/TaskConnectionObject.h | 2 + samples/separate/TaskEdgeObject.cpp | 2 + samples/separate/TaskEdgeObject.h | 2 + samples/separate/TaskObject.cpp | 2 + samples/separate/TaskObject.h | 2 + samples/separate/TodayObjects.h | 2 + samples/separate/TodaySchema.cpp | 2 + samples/separate/TodaySchema.h | 2 + .../AppointmentConnectionObject.cpp | 2 + .../AppointmentConnectionObject.h | 2 + .../AppointmentEdgeObject.cpp | 2 + .../AppointmentEdgeObject.h | 2 + .../AppointmentObject.cpp | 2 + .../AppointmentObject.h | 2 + .../CompleteTaskPayloadObject.cpp | 2 + .../CompleteTaskPayloadObject.h | 2 + .../ExpensiveObject.cpp | 2 + .../ExpensiveObject.h | 2 + .../FolderConnectionObject.cpp | 2 + .../FolderConnectionObject.h | 2 + .../FolderEdgeObject.cpp | 2 + .../FolderEdgeObject.h | 2 + .../separate_nointrospection/FolderObject.cpp | 2 + .../separate_nointrospection/FolderObject.h | 2 + .../MutationObject.cpp | 2 + .../separate_nointrospection/MutationObject.h | 2 + .../NestedTypeObject.cpp | 2 + .../NestedTypeObject.h | 2 + .../PageInfoObject.cpp | 2 + .../separate_nointrospection/PageInfoObject.h | 2 + .../separate_nointrospection/QueryObject.cpp | 2 + .../separate_nointrospection/QueryObject.h | 2 + .../SubscriptionObject.cpp | 2 + .../SubscriptionObject.h | 2 + .../TaskConnectionObject.cpp | 2 + .../TaskConnectionObject.h | 2 + .../TaskEdgeObject.cpp | 2 + .../separate_nointrospection/TaskEdgeObject.h | 2 + .../separate_nointrospection/TaskObject.cpp | 2 + samples/separate_nointrospection/TaskObject.h | 2 + .../separate_nointrospection/TodayObjects.h | 2 + .../separate_nointrospection/TodaySchema.cpp | 2 + .../separate_nointrospection/TodaySchema.h | 2 + samples/unified/TodaySchema.cpp | 2 + samples/unified/TodaySchema.h | 2 + .../unified_nointrospection/TodaySchema.cpp | 2 + samples/unified_nointrospection/TodaySchema.h | 2 + samples/update_samples.cmake | 29 ++++ samples/validation/ValidationSchema.cpp | 2 + samples/validation/ValidationSchema.h | 2 + src/CMakeLists.txt | 136 +++++++++++------- .../IntrospectionSchema.cpp | 2 + src/SchemaGenerator.cpp | 35 +++-- test/CMakeLists.txt | 20 +-- 92 files changed, 652 insertions(+), 151 deletions(-) create mode 100644 include/graphqlservice/internal/Version.h rename {samples => include/graphqlservice}/introspection/IntrospectionSchema.h (99%) create mode 100644 res/SchemaGen.rc create mode 100644 res/graphqljson_version.rc create mode 100644 res/graphqlpeg_version.rc create mode 100644 res/graphqlresponse_version.rc create mode 100644 res/graphqlservice_nointrospection_version.rc create mode 100644 res/graphqlservice_version.rc create mode 100644 samples/update_samples.cmake rename {samples/introspection => src}/IntrospectionSchema.cpp (99%) diff --git a/.gitignore b/.gitignore index a3a04514..0f77c1a4 100644 --- a/.gitignore +++ b/.gitignore @@ -6,7 +6,7 @@ Debug/ Release/ Testing/ Win32/ -/include/graphqlservice/introspection/IntrospectionSchema.h +/IntrospectionSchema.h /IntrospectionSchema.cpp *.filters *.vcxproj diff --git a/CMakeLists.txt b/CMakeLists.txt index d1f2bf72..fa9f01ea 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,8 +3,11 @@ cmake_minimum_required(VERSION 3.8.2) -# Enable CMAKE_MSVC_RUNTIME_LIBRARY on Windows. -cmake_policy(SET CMP0091 NEW) +if(CMAKE_VERSION VERSION_GREATER_EQUAL "3.15") + # Enable CMAKE_MSVC_RUNTIME_LIBRARY on Windows. + set(MSVC_MATCH_VCPKG_TRIPLET ON) + cmake_policy(SET CMP0091 NEW) +endif() # Default to the last updated version from version.txt. file(TO_CMAKE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/version.txt" VERSION_FILE) @@ -42,7 +45,7 @@ option(BUILD_SHARED_LIBS "Build shared libraries instead of static libs" OFF) if(VCPKG_TARGET_TRIPLET) message(STATUS "Using ${VCPKG_TARGET_TRIPLET} triplet with vcpkg") - if(MSVC) + if(MSVC AND MSVC_MATCH_VCPKG_TRIPLET) # Match the MSVC runtime if we're using VCPKG with static libraries. if(VCPKG_TARGET_TRIPLET MATCHES [[^.+-static$]]) set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>") @@ -51,9 +54,6 @@ if(VCPKG_TARGET_TRIPLET) set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>DLL") message(STATUS "Using MSVC runtime DLL") endif() - - add_custom_target(output_msvc_runtime ALL - ${CMAKE_COMMAND} -E echo "Using ${CMAKE_MSVC_RUNTIME_LIBRARY} MSVC runtime to match ${VCPKG_TARGET_TRIPLET}") endif() endif() @@ -84,6 +84,8 @@ else() set(GRAPHQL_UPDATE_SAMPLES OFF CACHE BOOL "Disable regenerating samples." FORCE) endif() +option(GRAPHQL_UPDATE_VERSION "Regenerate graphqlservice/internal/Version.h and all of the version info rc files for Windows." ON) + add_subdirectory(cmake) add_subdirectory(src) diff --git a/include/graphqlservice/internal/Version.h b/include/graphqlservice/internal/Version.h new file mode 100644 index 00000000..c21497ab --- /dev/null +++ b/include/graphqlservice/internal/Version.h @@ -0,0 +1,21 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +#pragma once + +#ifndef VERSION_H +#define VERSION_H + +#include + +namespace graphql::internal { + +constexpr std::string_view FullVersion { "3.4.1" }; + +constexpr size_t MajorVersion = 3; +constexpr size_t MinorVersion = 4; +constexpr size_t PatchVersion = 1; + +} // namespace graphql::internal + +#endif // VERSION_H diff --git a/samples/introspection/IntrospectionSchema.h b/include/graphqlservice/introspection/IntrospectionSchema.h similarity index 99% rename from samples/introspection/IntrospectionSchema.h rename to include/graphqlservice/introspection/IntrospectionSchema.h index c79eb6cd..8c0c66ca 100644 --- a/samples/introspection/IntrospectionSchema.h +++ b/include/graphqlservice/introspection/IntrospectionSchema.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef INTROSPECTIONSCHEMA_H diff --git a/res/SchemaGen.rc b/res/SchemaGen.rc new file mode 100644 index 00000000..49c7c4a8 --- /dev/null +++ b/res/SchemaGen.rc @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +#include + +#define SCHEMAGEN_RC_VERSION 3,4,1,0 +#define SCHEMAGEN_RC_VERSION_STR "3.4.1" + +#ifndef DEBUG +#define VER_DEBUG 0 +#else +#define VER_DEBUG VS_FF_DEBUG +#endif + +VS_VERSION_INFO VERSIONINFO +FILEVERSION SCHEMAGEN_RC_VERSION +PRODUCTVERSION SCHEMAGEN_RC_VERSION +FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +FILEFLAGS VER_DEBUG +FILEOS VOS__WINDOWS32 +FILETYPE VFT_APP +FILESUBTYPE VFT2_UNKNOWN +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "Microsoft Corporation" + VALUE "FileDescription", "Code generator for https://github.com/microsoft/cppgraphqlgen" + VALUE "FileVersion", SCHEMAGEN_RC_VERSION_STR + VALUE "InternalName", "schemagen" + VALUE "LegalCopyright", "Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License." + VALUE "OriginalFilename", "schemagen.exe" + VALUE "ProductName", "CppGraphQLGen" + VALUE "ProductVersion", SCHEMAGEN_RC_VERSION_STR + END + END + + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/res/graphqljson_version.rc b/res/graphqljson_version.rc new file mode 100644 index 00000000..65103ae4 --- /dev/null +++ b/res/graphqljson_version.rc @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +#include + +#define GRAPHQL_RC_VERSION 3,4,1,0 +#define GRAPHQL_RC_VERSION_STR "3.4.1" + +#ifndef DEBUG +#define VER_DEBUG 0 +#else +#define VER_DEBUG VS_FF_DEBUG +#endif + +VS_VERSION_INFO VERSIONINFO +FILEVERSION GRAPHQL_RC_VERSION +PRODUCTVERSION GRAPHQL_RC_VERSION +FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +FILEFLAGS VER_DEBUG +FILEOS VOS__WINDOWS32 +FILETYPE VFT_DLL +FILESUBTYPE VFT2_UNKNOWN +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "Microsoft Corporation" + VALUE "FileDescription", "Shared library for https://github.com/microsoft/cppgraphqlgen" + VALUE "FileVersion", GRAPHQL_RC_VERSION_STR + VALUE "InternalName", "graphqljson" + VALUE "LegalCopyright", "Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License." + VALUE "OriginalFilename", "graphqljson.dll" + VALUE "ProductName", "CppGraphQLGen" + VALUE "ProductVersion", GRAPHQL_RC_VERSION_STR + END + END + + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/res/graphqlpeg_version.rc b/res/graphqlpeg_version.rc new file mode 100644 index 00000000..68c3e6e4 --- /dev/null +++ b/res/graphqlpeg_version.rc @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +#include + +#define GRAPHQL_RC_VERSION 3,4,1,0 +#define GRAPHQL_RC_VERSION_STR "3.4.1" + +#ifndef DEBUG +#define VER_DEBUG 0 +#else +#define VER_DEBUG VS_FF_DEBUG +#endif + +VS_VERSION_INFO VERSIONINFO +FILEVERSION GRAPHQL_RC_VERSION +PRODUCTVERSION GRAPHQL_RC_VERSION +FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +FILEFLAGS VER_DEBUG +FILEOS VOS__WINDOWS32 +FILETYPE VFT_DLL +FILESUBTYPE VFT2_UNKNOWN +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "Microsoft Corporation" + VALUE "FileDescription", "Shared library for https://github.com/microsoft/cppgraphqlgen" + VALUE "FileVersion", GRAPHQL_RC_VERSION_STR + VALUE "InternalName", "graphqlpeg" + VALUE "LegalCopyright", "Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License." + VALUE "OriginalFilename", "graphqlpeg.dll" + VALUE "ProductName", "CppGraphQLGen" + VALUE "ProductVersion", GRAPHQL_RC_VERSION_STR + END + END + + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/res/graphqlresponse_version.rc b/res/graphqlresponse_version.rc new file mode 100644 index 00000000..96a29132 --- /dev/null +++ b/res/graphqlresponse_version.rc @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +#include + +#define GRAPHQL_RC_VERSION 3,4,1,0 +#define GRAPHQL_RC_VERSION_STR "3.4.1" + +#ifndef DEBUG +#define VER_DEBUG 0 +#else +#define VER_DEBUG VS_FF_DEBUG +#endif + +VS_VERSION_INFO VERSIONINFO +FILEVERSION GRAPHQL_RC_VERSION +PRODUCTVERSION GRAPHQL_RC_VERSION +FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +FILEFLAGS VER_DEBUG +FILEOS VOS__WINDOWS32 +FILETYPE VFT_DLL +FILESUBTYPE VFT2_UNKNOWN +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "Microsoft Corporation" + VALUE "FileDescription", "Shared library for https://github.com/microsoft/cppgraphqlgen" + VALUE "FileVersion", GRAPHQL_RC_VERSION_STR + VALUE "InternalName", "graphqlresponse" + VALUE "LegalCopyright", "Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License." + VALUE "OriginalFilename", "graphqlresponse.dll" + VALUE "ProductName", "CppGraphQLGen" + VALUE "ProductVersion", GRAPHQL_RC_VERSION_STR + END + END + + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/res/graphqlservice_nointrospection_version.rc b/res/graphqlservice_nointrospection_version.rc new file mode 100644 index 00000000..560df932 --- /dev/null +++ b/res/graphqlservice_nointrospection_version.rc @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +#include + +#define GRAPHQL_RC_VERSION 3,4,1,0 +#define GRAPHQL_RC_VERSION_STR "3.4.1" + +#ifndef DEBUG +#define VER_DEBUG 0 +#else +#define VER_DEBUG VS_FF_DEBUG +#endif + +VS_VERSION_INFO VERSIONINFO +FILEVERSION GRAPHQL_RC_VERSION +PRODUCTVERSION GRAPHQL_RC_VERSION +FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +FILEFLAGS VER_DEBUG +FILEOS VOS__WINDOWS32 +FILETYPE VFT_DLL +FILESUBTYPE VFT2_UNKNOWN +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "Microsoft Corporation" + VALUE "FileDescription", "Shared library for https://github.com/microsoft/cppgraphqlgen" + VALUE "FileVersion", GRAPHQL_RC_VERSION_STR + VALUE "InternalName", "graphqlservice_nointrospection" + VALUE "LegalCopyright", "Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License." + VALUE "OriginalFilename", "graphqlservice_nointrospection.dll" + VALUE "ProductName", "CppGraphQLGen" + VALUE "ProductVersion", GRAPHQL_RC_VERSION_STR + END + END + + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/res/graphqlservice_version.rc b/res/graphqlservice_version.rc new file mode 100644 index 00000000..3616a516 --- /dev/null +++ b/res/graphqlservice_version.rc @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +#include + +#define GRAPHQL_RC_VERSION 3,4,1,0 +#define GRAPHQL_RC_VERSION_STR "3.4.1" + +#ifndef DEBUG +#define VER_DEBUG 0 +#else +#define VER_DEBUG VS_FF_DEBUG +#endif + +VS_VERSION_INFO VERSIONINFO +FILEVERSION GRAPHQL_RC_VERSION +PRODUCTVERSION GRAPHQL_RC_VERSION +FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +FILEFLAGS VER_DEBUG +FILEOS VOS__WINDOWS32 +FILETYPE VFT_DLL +FILESUBTYPE VFT2_UNKNOWN +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "Microsoft Corporation" + VALUE "FileDescription", "Shared library for https://github.com/microsoft/cppgraphqlgen" + VALUE "FileVersion", GRAPHQL_RC_VERSION_STR + VALUE "InternalName", "graphqlservice" + VALUE "LegalCopyright", "Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License." + VALUE "OriginalFilename", "graphqlservice.dll" + VALUE "ProductName", "CppGraphQLGen" + VALUE "ProductVersion", GRAPHQL_RC_VERSION_STR + END + END + + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/samples/CMakeLists.txt b/samples/CMakeLists.txt index e9b1df78..098a9591 100644 --- a/samples/CMakeLists.txt +++ b/samples/CMakeLists.txt @@ -9,9 +9,13 @@ if(GRAPHQL_UPDATE_SAMPLES) add_custom_command( OUTPUT - ${CMAKE_CURRENT_BINARY_DIR}/unified/TodaySchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/unified/TodaySchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/unified/TodaySchema.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/unified/TodaySchema.h COMMAND schemagen --schema="${CMAKE_CURRENT_SOURCE_DIR}/schema.today.graphql" --prefix="Today" --namespace="today" + COMMAND ${CMAKE_COMMAND} -E copy_if_different + TodaySchema.cpp + TodaySchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/unified DEPENDS schemagen graphqlpeg schema.today.graphql WORKING_DIRECTORY unified COMMENT "Generating mock TodaySchema files") @@ -21,26 +25,40 @@ if(GRAPHQL_UPDATE_SAMPLES) add_custom_command( OUTPUT - ${CMAKE_CURRENT_BINARY_DIR}/unified_nointrospection/TodaySchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/unified_nointrospection/TodaySchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/unified_nointrospection/TodaySchema.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/unified_nointrospection/TodaySchema.h COMMAND schemagen --schema="${CMAKE_CURRENT_SOURCE_DIR}/schema.today.graphql" --prefix="Today" --namespace="today" --no-introspection + COMMAND ${CMAKE_COMMAND} -E copy_if_different + TodaySchema.cpp + TodaySchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/unified_nointrospection DEPENDS schemagen graphqlpeg schema.today.graphql WORKING_DIRECTORY unified_nointrospection COMMENT "Generating mock TodaySchema files without Introspection (--no-introspection)") - add_custom_target(unified_schema_files ALL - DEPENDS - ${CMAKE_CURRENT_BINARY_DIR}/unified/TodaySchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/unified/TodaySchema.h - ${CMAKE_CURRENT_BINARY_DIR}/unified_nointrospection/TodaySchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/unified_nointrospection/TodaySchema.h) + # validationschema + file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/validation) + + add_custom_command( + OUTPUT + ${CMAKE_CURRENT_SOURCE_DIR}/validation/ValidationSchema.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/validation/ValidationSchema.h + COMMAND schemagen --schema="${CMAKE_CURRENT_SOURCE_DIR}/schema.validation.graphql" --prefix="Validation" --namespace="validation" + COMMAND ${CMAKE_COMMAND} -E copy_if_different + ValidationSchema.cpp + ValidationSchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/validation + DEPENDS schemagen graphqlpeg schema.validation.graphql + WORKING_DIRECTORY validation + COMMENT "Generating ValidationSchema files") # separateschema file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/separate) add_custom_command( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/separate/today_schema_files + OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/separate/today_schema_files COMMAND schemagen --schema="${CMAKE_CURRENT_SOURCE_DIR}/schema.today.graphql" --prefix="Today" --namespace="today" --separate-files > today_schema_files + COMMAND ${CMAKE_COMMAND} -E copy_if_different today_schema_files ${CMAKE_CURRENT_SOURCE_DIR}/separate DEPENDS schemagen graphqlpeg schema.today.graphql WORKING_DIRECTORY separate COMMENT "Generating mock TodaySchema (--separate-files)") @@ -49,62 +67,35 @@ if(GRAPHQL_UPDATE_SAMPLES) file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/separate_nointrospection) add_custom_command( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/separate_nointrospection/today_schema_files + OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/separate_nointrospection/today_schema_files COMMAND schemagen --schema="${CMAKE_CURRENT_SOURCE_DIR}/schema.today.graphql" --prefix="Today" --namespace="today" --no-introspection --separate-files > today_schema_files + COMMAND ${CMAKE_COMMAND} -E copy_if_different today_schema_files ${CMAKE_CURRENT_SOURCE_DIR}/separate_nointrospection DEPENDS schemagen graphqlpeg schema.today.graphql WORKING_DIRECTORY separate_nointrospection COMMENT "Generating mock TodaySchema without Introspection (--no-introspection --separate-files)") - add_custom_target(separate_schema_files ALL - DEPENDS - ${CMAKE_CURRENT_BINARY_DIR}/separate/today_schema_files - ${CMAKE_CURRENT_BINARY_DIR}/separate_nointrospection/today_schema_files) - - # validationschema - file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/validation) - - add_custom_command( - OUTPUT - ${CMAKE_CURRENT_BINARY_DIR}/validation/ValidationSchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/validation/ValidationSchema.h - COMMAND schemagen --schema="${CMAKE_CURRENT_SOURCE_DIR}/schema.validation.graphql" --prefix="Validation" --namespace="validation" - DEPENDS schemagen graphqlpeg schema.validation.graphql - WORKING_DIRECTORY validation - COMMENT "Generating ValidationSchema files") - - add_custom_target(validation_schema_files ALL - DEPENDS - ${CMAKE_CURRENT_BINARY_DIR}/validation/ValidationSchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/validation/ValidationSchema.h) - - file(GLOB OLD_UNIFIED_FILES ${CMAKE_CURRENT_SOURCE_DIR}/unified/*) - file(GLOB OLD_UNIFIED_NOINTROSPECTION_FILES ${CMAKE_CURRENT_SOURCE_DIR}/unified_nointrospection/*) - file(GLOB OLD_SEPARATE_FILES ${CMAKE_CURRENT_SOURCE_DIR}/separate/*) - file(GLOB OLD_SEPARATE_NOINTROSPECTION_FILES ${CMAKE_CURRENT_SOURCE_DIR}/separate_nointrospection/*) - file(GLOB OLD_VALIDATION_FILES ${CMAKE_CURRENT_SOURCE_DIR}/validation/ValidationSchema.*) - add_custom_command( OUTPUT updated_samples - COMMAND ${CMAKE_COMMAND} -E remove -f ${OLD_UNIFIED_FILES} - COMMAND ${CMAKE_COMMAND} -E copy_directory unified/ ${CMAKE_CURRENT_SOURCE_DIR}/unified/ - COMMAND ${CMAKE_COMMAND} -E remove -f ${OLD_UNIFIED_NOINTROSPECTION_FILES} - COMMAND ${CMAKE_COMMAND} -E copy_directory unified_nointrospection/ ${CMAKE_CURRENT_SOURCE_DIR}/unified_nointrospection/ - COMMAND ${CMAKE_COMMAND} -E remove -f ${OLD_SEPARATE_FILES} - COMMAND ${CMAKE_COMMAND} -E copy_directory separate/ ${CMAKE_CURRENT_SOURCE_DIR}/separate/ - COMMAND ${CMAKE_COMMAND} -E remove -f ${OLD_SEPARATE_NOINTROSPECTION_FILES} - COMMAND ${CMAKE_COMMAND} -E copy_directory separate_nointrospection/ ${CMAKE_CURRENT_SOURCE_DIR}/separate_nointrospection/ - COMMAND ${CMAKE_COMMAND} -E remove -f ${OLD_VALIDATION_FILES} - COMMAND ${CMAKE_COMMAND} -E copy_directory validation/ ${CMAKE_CURRENT_SOURCE_DIR}/validation/ + COMMAND ${CMAKE_COMMAND} + "-DSCHEMA_SOURCE_LIST=today_schema_files" + "-DSCHEMA_SOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR}/separate" + "-DSCHEMA_BINARY_DIR=${CMAKE_CURRENT_BINARY_DIR}/separate" + -P "${CMAKE_CURRENT_SOURCE_DIR}/update_samples.cmake" + COMMAND ${CMAKE_COMMAND} + "-DSCHEMA_SOURCE_LIST=today_schema_files" + "-DSCHEMA_SOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR}/separate_nointrospection" + "-DSCHEMA_BINARY_DIR=${CMAKE_CURRENT_BINARY_DIR}/separate_nointrospection" + -P "${CMAKE_CURRENT_SOURCE_DIR}/update_samples.cmake" COMMAND ${CMAKE_COMMAND} -E touch updated_samples DEPENDS - ${CMAKE_CURRENT_BINARY_DIR}/unified/TodaySchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/unified/TodaySchema.h - ${CMAKE_CURRENT_BINARY_DIR}/unified_nointrospection/TodaySchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/unified_nointrospection/TodaySchema.h - ${CMAKE_CURRENT_BINARY_DIR}/separate/today_schema_files - ${CMAKE_CURRENT_BINARY_DIR}/separate_nointrospection/today_schema_files - ${CMAKE_CURRENT_BINARY_DIR}/validation/ValidationSchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/validation/ValidationSchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/unified/TodaySchema.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/unified/TodaySchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/unified_nointrospection/TodaySchema.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/unified_nointrospection/TodaySchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/validation/ValidationSchema.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/validation/ValidationSchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/separate/today_schema_files + ${CMAKE_CURRENT_SOURCE_DIR}/separate_nointrospection/today_schema_files COMMENT "Updating sample files") add_custom_target(update_samples ALL @@ -122,7 +113,6 @@ add_library(separateschema STATIC ${SEPARATE_SCHEMA_PATHS}) target_link_libraries(separateschema PUBLIC graphqlservice) target_compile_definitions(separateschema PUBLIC IMPL_SEPARATE_TODAY) target_include_directories(separateschema PUBLIC - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include separate) @@ -143,7 +133,6 @@ add_library(separateschema_nointrospection STATIC ${SEPARATE_NOINTROSPECTION_SCH target_link_libraries(separateschema_nointrospection PUBLIC graphqlservice_nointrospection) target_compile_definitions(separateschema_nointrospection PUBLIC IMPL_SEPARATE_TODAY) target_include_directories(separateschema_nointrospection PUBLIC - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include separate_nointrospection) @@ -169,7 +158,6 @@ target_link_libraries(sample PRIVATE separategraphql graphqljson) target_include_directories(sample PRIVATE - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include) @@ -179,18 +167,23 @@ target_link_libraries(sample_nointrospection PRIVATE separategraphql_nointrospection graphqljson) target_include_directories(sample_nointrospection PRIVATE - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include) if(WIN32 AND BUILD_SHARED_LIBS) - add_custom_target(copy_sample_dlls ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} + add_custom_command(OUTPUT copied_sample_dlls + COMMAND ${CMAKE_COMMAND} -E copy_if_different + $ + $ + $ + $ + $ + ${CMAKE_CURRENT_BINARY_DIR} + COMMAND ${CMAKE_COMMAND} -E touch copied_sample_dlls DEPENDS graphqlservice graphqljson graphqlpeg graphqlresponse) + add_custom_target(copy_sample_dlls DEPENDS copied_sample_dlls) + add_dependencies(sample copy_sample_dlls) add_dependencies(sample_nointrospection copy_sample_dlls) endif() @@ -201,7 +194,6 @@ target_link_libraries(benchmark PRIVATE separategraphql graphqljson) target_include_directories(benchmark PRIVATE - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include) @@ -211,7 +203,6 @@ target_link_libraries(benchmark_nointrospection PRIVATE separategraphql_nointrospection graphqljson) target_include_directories(benchmark_nointrospection PRIVATE - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include) @@ -225,7 +216,6 @@ if(GRAPHQL_BUILD_TESTS) add_library(unifiedschema STATIC unified/TodaySchema.cpp) target_link_libraries(unifiedschema PUBLIC graphqlservice) target_include_directories(unifiedschema PUBLIC - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include unified) @@ -243,7 +233,6 @@ if(GRAPHQL_BUILD_TESTS) add_library(unifiedschema_nointrospection STATIC unified_nointrospection/TodaySchema.cpp) target_link_libraries(unifiedschema_nointrospection PUBLIC graphqlservice_nointrospection) target_include_directories(unifiedschema_nointrospection PUBLIC - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include unified_nointrospection) @@ -263,7 +252,6 @@ if(GRAPHQL_BUILD_TESTS) validation/ValidationSchema.cpp) target_link_libraries(validationgraphql PUBLIC graphqlservice) target_include_directories(validationgraphql PUBLIC - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include validation) diff --git a/samples/separate/AppointmentConnectionObject.cpp b/samples/separate/AppointmentConnectionObject.cpp index 809e5406..f07cb03d 100644 --- a/samples/separate/AppointmentConnectionObject.cpp +++ b/samples/separate/AppointmentConnectionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/AppointmentConnectionObject.h b/samples/separate/AppointmentConnectionObject.h index a2086518..1b42507e 100644 --- a/samples/separate/AppointmentConnectionObject.h +++ b/samples/separate/AppointmentConnectionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef APPOINTMENTCONNECTIONOBJECT_H diff --git a/samples/separate/AppointmentEdgeObject.cpp b/samples/separate/AppointmentEdgeObject.cpp index 7988b67d..3c80f4b3 100644 --- a/samples/separate/AppointmentEdgeObject.cpp +++ b/samples/separate/AppointmentEdgeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/AppointmentEdgeObject.h b/samples/separate/AppointmentEdgeObject.h index 454cd0d1..5e15b0ed 100644 --- a/samples/separate/AppointmentEdgeObject.h +++ b/samples/separate/AppointmentEdgeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef APPOINTMENTEDGEOBJECT_H diff --git a/samples/separate/AppointmentObject.cpp b/samples/separate/AppointmentObject.cpp index 8f4f7e2b..3bef37d7 100644 --- a/samples/separate/AppointmentObject.cpp +++ b/samples/separate/AppointmentObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/AppointmentObject.h b/samples/separate/AppointmentObject.h index 6ebc29d2..048d281c 100644 --- a/samples/separate/AppointmentObject.h +++ b/samples/separate/AppointmentObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef APPOINTMENTOBJECT_H diff --git a/samples/separate/CompleteTaskPayloadObject.cpp b/samples/separate/CompleteTaskPayloadObject.cpp index 7d2dedbf..caf80b36 100644 --- a/samples/separate/CompleteTaskPayloadObject.cpp +++ b/samples/separate/CompleteTaskPayloadObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/CompleteTaskPayloadObject.h b/samples/separate/CompleteTaskPayloadObject.h index 8d7a122b..1483f3fd 100644 --- a/samples/separate/CompleteTaskPayloadObject.h +++ b/samples/separate/CompleteTaskPayloadObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef COMPLETETASKPAYLOADOBJECT_H diff --git a/samples/separate/ExpensiveObject.cpp b/samples/separate/ExpensiveObject.cpp index eda85902..7c7ad5fc 100644 --- a/samples/separate/ExpensiveObject.cpp +++ b/samples/separate/ExpensiveObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/ExpensiveObject.h b/samples/separate/ExpensiveObject.h index a435994a..cfe70165 100644 --- a/samples/separate/ExpensiveObject.h +++ b/samples/separate/ExpensiveObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef EXPENSIVEOBJECT_H diff --git a/samples/separate/FolderConnectionObject.cpp b/samples/separate/FolderConnectionObject.cpp index a2b4618d..e5e1d00e 100644 --- a/samples/separate/FolderConnectionObject.cpp +++ b/samples/separate/FolderConnectionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/FolderConnectionObject.h b/samples/separate/FolderConnectionObject.h index 9bcd2d4a..06ba04e7 100644 --- a/samples/separate/FolderConnectionObject.h +++ b/samples/separate/FolderConnectionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef FOLDERCONNECTIONOBJECT_H diff --git a/samples/separate/FolderEdgeObject.cpp b/samples/separate/FolderEdgeObject.cpp index fe612ae5..95f80516 100644 --- a/samples/separate/FolderEdgeObject.cpp +++ b/samples/separate/FolderEdgeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/FolderEdgeObject.h b/samples/separate/FolderEdgeObject.h index 4fc210d2..b6ff6aaf 100644 --- a/samples/separate/FolderEdgeObject.h +++ b/samples/separate/FolderEdgeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef FOLDEREDGEOBJECT_H diff --git a/samples/separate/FolderObject.cpp b/samples/separate/FolderObject.cpp index 74326655..37c48e47 100644 --- a/samples/separate/FolderObject.cpp +++ b/samples/separate/FolderObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/FolderObject.h b/samples/separate/FolderObject.h index 13fd2c61..fc2bdb60 100644 --- a/samples/separate/FolderObject.h +++ b/samples/separate/FolderObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef FOLDEROBJECT_H diff --git a/samples/separate/MutationObject.cpp b/samples/separate/MutationObject.cpp index d6b71e55..52601da1 100644 --- a/samples/separate/MutationObject.cpp +++ b/samples/separate/MutationObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/MutationObject.h b/samples/separate/MutationObject.h index fcb6340f..b688fc48 100644 --- a/samples/separate/MutationObject.h +++ b/samples/separate/MutationObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef MUTATIONOBJECT_H diff --git a/samples/separate/NestedTypeObject.cpp b/samples/separate/NestedTypeObject.cpp index df49e2ad..a018b4f1 100644 --- a/samples/separate/NestedTypeObject.cpp +++ b/samples/separate/NestedTypeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/NestedTypeObject.h b/samples/separate/NestedTypeObject.h index 8fa86966..7966c3a4 100644 --- a/samples/separate/NestedTypeObject.h +++ b/samples/separate/NestedTypeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef NESTEDTYPEOBJECT_H diff --git a/samples/separate/PageInfoObject.cpp b/samples/separate/PageInfoObject.cpp index d949ab0b..1320076d 100644 --- a/samples/separate/PageInfoObject.cpp +++ b/samples/separate/PageInfoObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/PageInfoObject.h b/samples/separate/PageInfoObject.h index ca0108ab..961d4e24 100644 --- a/samples/separate/PageInfoObject.h +++ b/samples/separate/PageInfoObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef PAGEINFOOBJECT_H diff --git a/samples/separate/QueryObject.cpp b/samples/separate/QueryObject.cpp index e417b930..ef7905b5 100644 --- a/samples/separate/QueryObject.cpp +++ b/samples/separate/QueryObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/QueryObject.h b/samples/separate/QueryObject.h index 71cae0b8..6a2ff622 100644 --- a/samples/separate/QueryObject.h +++ b/samples/separate/QueryObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef QUERYOBJECT_H diff --git a/samples/separate/SubscriptionObject.cpp b/samples/separate/SubscriptionObject.cpp index 09fd6b0f..9c5e0da2 100644 --- a/samples/separate/SubscriptionObject.cpp +++ b/samples/separate/SubscriptionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/SubscriptionObject.h b/samples/separate/SubscriptionObject.h index 6696710a..696d089a 100644 --- a/samples/separate/SubscriptionObject.h +++ b/samples/separate/SubscriptionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef SUBSCRIPTIONOBJECT_H diff --git a/samples/separate/TaskConnectionObject.cpp b/samples/separate/TaskConnectionObject.cpp index f78c505e..4ccc434c 100644 --- a/samples/separate/TaskConnectionObject.cpp +++ b/samples/separate/TaskConnectionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/TaskConnectionObject.h b/samples/separate/TaskConnectionObject.h index 3b27f775..69d1d262 100644 --- a/samples/separate/TaskConnectionObject.h +++ b/samples/separate/TaskConnectionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TASKCONNECTIONOBJECT_H diff --git a/samples/separate/TaskEdgeObject.cpp b/samples/separate/TaskEdgeObject.cpp index 82d6548b..67add2c0 100644 --- a/samples/separate/TaskEdgeObject.cpp +++ b/samples/separate/TaskEdgeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/TaskEdgeObject.h b/samples/separate/TaskEdgeObject.h index 27b60417..61192b82 100644 --- a/samples/separate/TaskEdgeObject.h +++ b/samples/separate/TaskEdgeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TASKEDGEOBJECT_H diff --git a/samples/separate/TaskObject.cpp b/samples/separate/TaskObject.cpp index 97e77559..04917189 100644 --- a/samples/separate/TaskObject.cpp +++ b/samples/separate/TaskObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/TaskObject.h b/samples/separate/TaskObject.h index a6652cca..fb94da62 100644 --- a/samples/separate/TaskObject.h +++ b/samples/separate/TaskObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TASKOBJECT_H diff --git a/samples/separate/TodayObjects.h b/samples/separate/TodayObjects.h index 37b473ec..80502f8c 100644 --- a/samples/separate/TodayObjects.h +++ b/samples/separate/TodayObjects.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TODAYOBJECTS_H diff --git a/samples/separate/TodaySchema.cpp b/samples/separate/TodaySchema.cpp index 6c7c4a15..deb17504 100644 --- a/samples/separate/TodaySchema.cpp +++ b/samples/separate/TodaySchema.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate/TodaySchema.h b/samples/separate/TodaySchema.h index 2db7df90..d9a9d387 100644 --- a/samples/separate/TodaySchema.h +++ b/samples/separate/TodaySchema.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TODAYSCHEMA_H diff --git a/samples/separate_nointrospection/AppointmentConnectionObject.cpp b/samples/separate_nointrospection/AppointmentConnectionObject.cpp index 809e5406..f07cb03d 100644 --- a/samples/separate_nointrospection/AppointmentConnectionObject.cpp +++ b/samples/separate_nointrospection/AppointmentConnectionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/AppointmentConnectionObject.h b/samples/separate_nointrospection/AppointmentConnectionObject.h index a2086518..1b42507e 100644 --- a/samples/separate_nointrospection/AppointmentConnectionObject.h +++ b/samples/separate_nointrospection/AppointmentConnectionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef APPOINTMENTCONNECTIONOBJECT_H diff --git a/samples/separate_nointrospection/AppointmentEdgeObject.cpp b/samples/separate_nointrospection/AppointmentEdgeObject.cpp index 7988b67d..3c80f4b3 100644 --- a/samples/separate_nointrospection/AppointmentEdgeObject.cpp +++ b/samples/separate_nointrospection/AppointmentEdgeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/AppointmentEdgeObject.h b/samples/separate_nointrospection/AppointmentEdgeObject.h index 454cd0d1..5e15b0ed 100644 --- a/samples/separate_nointrospection/AppointmentEdgeObject.h +++ b/samples/separate_nointrospection/AppointmentEdgeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef APPOINTMENTEDGEOBJECT_H diff --git a/samples/separate_nointrospection/AppointmentObject.cpp b/samples/separate_nointrospection/AppointmentObject.cpp index 8f4f7e2b..3bef37d7 100644 --- a/samples/separate_nointrospection/AppointmentObject.cpp +++ b/samples/separate_nointrospection/AppointmentObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/AppointmentObject.h b/samples/separate_nointrospection/AppointmentObject.h index 6ebc29d2..048d281c 100644 --- a/samples/separate_nointrospection/AppointmentObject.h +++ b/samples/separate_nointrospection/AppointmentObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef APPOINTMENTOBJECT_H diff --git a/samples/separate_nointrospection/CompleteTaskPayloadObject.cpp b/samples/separate_nointrospection/CompleteTaskPayloadObject.cpp index 7d2dedbf..caf80b36 100644 --- a/samples/separate_nointrospection/CompleteTaskPayloadObject.cpp +++ b/samples/separate_nointrospection/CompleteTaskPayloadObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/CompleteTaskPayloadObject.h b/samples/separate_nointrospection/CompleteTaskPayloadObject.h index 8d7a122b..1483f3fd 100644 --- a/samples/separate_nointrospection/CompleteTaskPayloadObject.h +++ b/samples/separate_nointrospection/CompleteTaskPayloadObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef COMPLETETASKPAYLOADOBJECT_H diff --git a/samples/separate_nointrospection/ExpensiveObject.cpp b/samples/separate_nointrospection/ExpensiveObject.cpp index eda85902..7c7ad5fc 100644 --- a/samples/separate_nointrospection/ExpensiveObject.cpp +++ b/samples/separate_nointrospection/ExpensiveObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/ExpensiveObject.h b/samples/separate_nointrospection/ExpensiveObject.h index a435994a..cfe70165 100644 --- a/samples/separate_nointrospection/ExpensiveObject.h +++ b/samples/separate_nointrospection/ExpensiveObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef EXPENSIVEOBJECT_H diff --git a/samples/separate_nointrospection/FolderConnectionObject.cpp b/samples/separate_nointrospection/FolderConnectionObject.cpp index a2b4618d..e5e1d00e 100644 --- a/samples/separate_nointrospection/FolderConnectionObject.cpp +++ b/samples/separate_nointrospection/FolderConnectionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/FolderConnectionObject.h b/samples/separate_nointrospection/FolderConnectionObject.h index 9bcd2d4a..06ba04e7 100644 --- a/samples/separate_nointrospection/FolderConnectionObject.h +++ b/samples/separate_nointrospection/FolderConnectionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef FOLDERCONNECTIONOBJECT_H diff --git a/samples/separate_nointrospection/FolderEdgeObject.cpp b/samples/separate_nointrospection/FolderEdgeObject.cpp index fe612ae5..95f80516 100644 --- a/samples/separate_nointrospection/FolderEdgeObject.cpp +++ b/samples/separate_nointrospection/FolderEdgeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/FolderEdgeObject.h b/samples/separate_nointrospection/FolderEdgeObject.h index 4fc210d2..b6ff6aaf 100644 --- a/samples/separate_nointrospection/FolderEdgeObject.h +++ b/samples/separate_nointrospection/FolderEdgeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef FOLDEREDGEOBJECT_H diff --git a/samples/separate_nointrospection/FolderObject.cpp b/samples/separate_nointrospection/FolderObject.cpp index 74326655..37c48e47 100644 --- a/samples/separate_nointrospection/FolderObject.cpp +++ b/samples/separate_nointrospection/FolderObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/FolderObject.h b/samples/separate_nointrospection/FolderObject.h index 13fd2c61..fc2bdb60 100644 --- a/samples/separate_nointrospection/FolderObject.h +++ b/samples/separate_nointrospection/FolderObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef FOLDEROBJECT_H diff --git a/samples/separate_nointrospection/MutationObject.cpp b/samples/separate_nointrospection/MutationObject.cpp index d6b71e55..52601da1 100644 --- a/samples/separate_nointrospection/MutationObject.cpp +++ b/samples/separate_nointrospection/MutationObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/MutationObject.h b/samples/separate_nointrospection/MutationObject.h index fcb6340f..b688fc48 100644 --- a/samples/separate_nointrospection/MutationObject.h +++ b/samples/separate_nointrospection/MutationObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef MUTATIONOBJECT_H diff --git a/samples/separate_nointrospection/NestedTypeObject.cpp b/samples/separate_nointrospection/NestedTypeObject.cpp index 41dc01a0..7f0a133c 100644 --- a/samples/separate_nointrospection/NestedTypeObject.cpp +++ b/samples/separate_nointrospection/NestedTypeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/NestedTypeObject.h b/samples/separate_nointrospection/NestedTypeObject.h index 8fa86966..7966c3a4 100644 --- a/samples/separate_nointrospection/NestedTypeObject.h +++ b/samples/separate_nointrospection/NestedTypeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef NESTEDTYPEOBJECT_H diff --git a/samples/separate_nointrospection/PageInfoObject.cpp b/samples/separate_nointrospection/PageInfoObject.cpp index d949ab0b..1320076d 100644 --- a/samples/separate_nointrospection/PageInfoObject.cpp +++ b/samples/separate_nointrospection/PageInfoObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/PageInfoObject.h b/samples/separate_nointrospection/PageInfoObject.h index ca0108ab..961d4e24 100644 --- a/samples/separate_nointrospection/PageInfoObject.h +++ b/samples/separate_nointrospection/PageInfoObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef PAGEINFOOBJECT_H diff --git a/samples/separate_nointrospection/QueryObject.cpp b/samples/separate_nointrospection/QueryObject.cpp index c2383090..f3d82e26 100644 --- a/samples/separate_nointrospection/QueryObject.cpp +++ b/samples/separate_nointrospection/QueryObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/QueryObject.h b/samples/separate_nointrospection/QueryObject.h index 20c73917..b9898e7d 100644 --- a/samples/separate_nointrospection/QueryObject.h +++ b/samples/separate_nointrospection/QueryObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef QUERYOBJECT_H diff --git a/samples/separate_nointrospection/SubscriptionObject.cpp b/samples/separate_nointrospection/SubscriptionObject.cpp index 09fd6b0f..9c5e0da2 100644 --- a/samples/separate_nointrospection/SubscriptionObject.cpp +++ b/samples/separate_nointrospection/SubscriptionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/SubscriptionObject.h b/samples/separate_nointrospection/SubscriptionObject.h index 6696710a..696d089a 100644 --- a/samples/separate_nointrospection/SubscriptionObject.h +++ b/samples/separate_nointrospection/SubscriptionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef SUBSCRIPTIONOBJECT_H diff --git a/samples/separate_nointrospection/TaskConnectionObject.cpp b/samples/separate_nointrospection/TaskConnectionObject.cpp index f78c505e..4ccc434c 100644 --- a/samples/separate_nointrospection/TaskConnectionObject.cpp +++ b/samples/separate_nointrospection/TaskConnectionObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/TaskConnectionObject.h b/samples/separate_nointrospection/TaskConnectionObject.h index 3b27f775..69d1d262 100644 --- a/samples/separate_nointrospection/TaskConnectionObject.h +++ b/samples/separate_nointrospection/TaskConnectionObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TASKCONNECTIONOBJECT_H diff --git a/samples/separate_nointrospection/TaskEdgeObject.cpp b/samples/separate_nointrospection/TaskEdgeObject.cpp index 82d6548b..67add2c0 100644 --- a/samples/separate_nointrospection/TaskEdgeObject.cpp +++ b/samples/separate_nointrospection/TaskEdgeObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/TaskEdgeObject.h b/samples/separate_nointrospection/TaskEdgeObject.h index 27b60417..61192b82 100644 --- a/samples/separate_nointrospection/TaskEdgeObject.h +++ b/samples/separate_nointrospection/TaskEdgeObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TASKEDGEOBJECT_H diff --git a/samples/separate_nointrospection/TaskObject.cpp b/samples/separate_nointrospection/TaskObject.cpp index 97e77559..04917189 100644 --- a/samples/separate_nointrospection/TaskObject.cpp +++ b/samples/separate_nointrospection/TaskObject.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/TaskObject.h b/samples/separate_nointrospection/TaskObject.h index a6652cca..fb94da62 100644 --- a/samples/separate_nointrospection/TaskObject.h +++ b/samples/separate_nointrospection/TaskObject.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TASKOBJECT_H diff --git a/samples/separate_nointrospection/TodayObjects.h b/samples/separate_nointrospection/TodayObjects.h index 37b473ec..80502f8c 100644 --- a/samples/separate_nointrospection/TodayObjects.h +++ b/samples/separate_nointrospection/TodayObjects.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TODAYOBJECTS_H diff --git a/samples/separate_nointrospection/TodaySchema.cpp b/samples/separate_nointrospection/TodaySchema.cpp index 3f18df02..b0d0da5b 100644 --- a/samples/separate_nointrospection/TodaySchema.cpp +++ b/samples/separate_nointrospection/TodaySchema.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodayObjects.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/separate_nointrospection/TodaySchema.h b/samples/separate_nointrospection/TodaySchema.h index 2db7df90..d9a9d387 100644 --- a/samples/separate_nointrospection/TodaySchema.h +++ b/samples/separate_nointrospection/TodaySchema.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TODAYSCHEMA_H diff --git a/samples/unified/TodaySchema.cpp b/samples/unified/TodaySchema.cpp index 84506511..f0c8a58c 100644 --- a/samples/unified/TodaySchema.cpp +++ b/samples/unified/TodaySchema.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodaySchema.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/unified/TodaySchema.h b/samples/unified/TodaySchema.h index 6b6fdd91..cf711881 100644 --- a/samples/unified/TodaySchema.h +++ b/samples/unified/TodaySchema.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TODAYSCHEMA_H diff --git a/samples/unified_nointrospection/TodaySchema.cpp b/samples/unified_nointrospection/TodaySchema.cpp index 92f862e7..afca9cd4 100644 --- a/samples/unified_nointrospection/TodaySchema.cpp +++ b/samples/unified_nointrospection/TodaySchema.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "TodaySchema.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/unified_nointrospection/TodaySchema.h b/samples/unified_nointrospection/TodaySchema.h index b2dbbee9..bcc85465 100644 --- a/samples/unified_nointrospection/TodaySchema.h +++ b/samples/unified_nointrospection/TodaySchema.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef TODAYSCHEMA_H diff --git a/samples/update_samples.cmake b/samples/update_samples.cmake new file mode 100644 index 00000000..1d3d2757 --- /dev/null +++ b/samples/update_samples.cmake @@ -0,0 +1,29 @@ +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. + +cmake_minimum_required(VERSION 3.8.2) + +# Get the up-to-date list of files in the binary directory +set(FILE_NAMES "") +file(GLOB NEW_FILES ${SCHEMA_BINARY_DIR}/*.h ${SCHEMA_BINARY_DIR}/*.cpp) +foreach(NEW_FILE ${NEW_FILES}) + get_filename_component(NEW_FILE ${NEW_FILE} NAME) + list(APPEND FILE_NAMES "${NEW_FILE}") +endforeach() + +# Don't update the files in the source directory if no files were generated in the binary directory. +if(NOT FILE_NAMES) + message(FATAL_ERROR "Schema generation failed!") +endif() + +# Remove stale files in the source directory +file(GLOB OLD_FILES ${SCHEMA_SOURCE_DIR}/*.h ${SCHEMA_SOURCE_DIR}/*.cpp) +foreach(OLD_FILE ${OLD_FILES}) + get_filename_component(OLD_FILE ${OLD_FILE} NAME) + if(NOT OLD_FILE IN_LIST FILE_NAMES) + file(REMOVE "${SCHEMA_SOURCE_DIR}/${OLD_FILE}") + endif() +endforeach() + +# Copy new and modified files from the binary directory to the source directory +execute_process(COMMAND ${CMAKE_COMMAND} -E copy_if_different ${SCHEMA_BINARY_DIR}/${SCHEMA_SOURCE_LIST} ${NEW_FILES} ${SCHEMA_SOURCE_DIR}) diff --git a/samples/validation/ValidationSchema.cpp b/samples/validation/ValidationSchema.cpp index 37e08c67..afc96f98 100644 --- a/samples/validation/ValidationSchema.cpp +++ b/samples/validation/ValidationSchema.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "ValidationSchema.h" #include "graphqlservice/introspection/Introspection.h" diff --git a/samples/validation/ValidationSchema.h b/samples/validation/ValidationSchema.h index 997aa208..25dfafaa 100644 --- a/samples/validation/ValidationSchema.h +++ b/samples/validation/ValidationSchema.h @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef VALIDATIONSCHEMA_H diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 66e3302b..b115ee5e 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -3,22 +3,46 @@ cmake_minimum_required(VERSION 3.8.2) -# internal/Version.h -configure_file(${CMAKE_CURRENT_SOURCE_DIR}/../cmake/Version.h.in - ${CMAKE_CURRENT_BINARY_DIR}/../include/graphqlservice/internal/Version.h - @ONLY) - -if(WIN32 AND BUILD_SHARED_LIBS) - # Version.rc +if(GRAPHQL_UPDATE_VERSION) + # internal/Version.h + configure_file(${CMAKE_CURRENT_SOURCE_DIR}/../cmake/Version.h.in + ${CMAKE_CURRENT_BINARY_DIR}/Version.h + @ONLY) + + add_custom_command(OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/internal/Version.h + COMMAND ${CMAKE_COMMAND} -E copy_if_different Version.h ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/internal + DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/Version.h) + + add_custom_target(update_version_h ALL + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/internal/Version.h) + + # res/target_version.rc + set(CMAKE_RC_FLAGS "/nologo") + set(CMAKE_RC_FLAGS_DEBUG "/dDEBUG") set(GRAPHQL_RC_VERSION "${PROJECT_VERSION_MAJOR},${PROJECT_VERSION_MINOR},${PROJECT_VERSION_PATCH},0") set(GRAPHQL_RC_VERSION_STR "${PROJECT_VERSION}") - function(add_version_rc target) + function(update_version_rc target) + add_dependencies(${target} update_version_h) + set(GRAPHQL_RC_FILENAME "${target}") + configure_file(${CMAKE_CURRENT_SOURCE_DIR}/../cmake/Version.rc.in ${CMAKE_CURRENT_BINARY_DIR}/${target}_version.rc @ONLY) - add_library(${target}_version OBJECT ${CMAKE_CURRENT_BINARY_DIR}/${target}_version.rc) + + add_custom_command(OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/../res/${target}_version.rc + COMMAND ${CMAKE_COMMAND} -E copy_if_different ${target}_version.rc ${CMAKE_CURRENT_SOURCE_DIR}/../res + DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${target}_version.rc) + + add_custom_target(update_${target}_version_rc ALL + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/../res/${target}_version.rc) + endfunction() +endif() + +if(WIN32 AND BUILD_SHARED_LIBS) + function(add_version_rc target) + add_library(${target}_version OBJECT ${CMAKE_CURRENT_SOURCE_DIR}/../res/${target}_version.rc) target_link_libraries(${target} PRIVATE ${target}_version) endfunction() endif() @@ -40,6 +64,10 @@ target_include_directories(graphqlpeg PUBLIC $) add_bigobj_flag(graphqlpeg) +if(GRAPHQL_UPDATE_VERSION) + update_version_rc(graphqlpeg) +endif() + if(WIN32 AND BUILD_SHARED_LIBS) target_compile_definitions(graphqlpeg PUBLIC GRAPHQL_DLLEXPORTS @@ -55,6 +83,10 @@ target_include_directories(graphqlresponse PUBLIC $ $) +if(GRAPHQL_UPDATE_VERSION) + update_version_rc(graphqlresponse) +endif() + if(WIN32 AND BUILD_SHARED_LIBS) target_compile_definitions(graphqlresponse PUBLIC GRAPHQL_DLLEXPORTS @@ -67,8 +99,6 @@ endif() if(GRAPHQL_BUILD_SCHEMAGEN) add_executable(schemagen SchemaGenerator.cpp) add_executable(cppgraphqlgen::schemagen ALIAS schemagen) - target_include_directories(schemagen PRIVATE - ${CMAKE_CURRENT_BINARY_DIR}/../include) target_link_libraries(schemagen PRIVATE graphqlpeg graphqlresponse) @@ -128,15 +158,27 @@ if(GRAPHQL_BUILD_SCHEMAGEN) find_package(Boost REQUIRED COMPONENTS ${BOOST_COMPONENTS}) target_link_libraries(schemagen PRIVATE ${BOOST_LIBRARIES}) - if(WIN32) - # SchemaGen.rc + # SchemaGen.rc + if(GRAPHQL_UPDATE_VERSION) + add_dependencies(schemagen update_version_h) + set(SCHEMAGEN_RC_VERSION "${PROJECT_VERSION_MAJOR},${PROJECT_VERSION_MINOR},${PROJECT_VERSION_PATCH},0") set(SCHEMAGEN_RC_VERSION_STR "${PROJECT_VERSION}") + configure_file(${CMAKE_CURRENT_SOURCE_DIR}/../cmake/SchemaGen.rc.in ${CMAKE_CURRENT_BINARY_DIR}/SchemaGen.rc @ONLY) - add_library(schemagen_version OBJECT ${CMAKE_CURRENT_BINARY_DIR}/SchemaGen.rc) + add_custom_command(OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/../res/SchemaGen.rc + COMMAND ${CMAKE_COMMAND} -E copy_if_different SchemaGen.rc ${CMAKE_CURRENT_SOURCE_DIR}/../res + DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/SchemaGen.rc) + + add_custom_target(update_schemagen_rc ALL + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/../res/SchemaGen.rc) + endif() + + if(WIN32) + add_library(schemagen_version OBJECT ${CMAKE_CURRENT_SOURCE_DIR}/../res/SchemaGen.rc) target_link_libraries(schemagen PRIVATE schemagen_version) endif() @@ -148,61 +190,39 @@ endif() # introspection if(GRAPHQL_UPDATE_SAMPLES) - add_custom_command( - OUTPUT - ${CMAKE_CURRENT_BINARY_DIR}/../IntrospectionSchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/../include/graphqlservice/introspection/IntrospectionSchema.h - COMMAND ${CMAKE_COMMAND} -E make_directory include/graphqlservice/introspection - COMMAND schemagen --introspection - DEPENDS schemagen - WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/.. - COMMENT "Generating IntrospectionSchema files") - - file(GLOB OLD_INTROSPECTION_FILES ${CMAKE_CURRENT_SOURCE_DIR}/../samples/introspection/*) - add_custom_command( OUTPUT updated_introspection - COMMAND ${CMAKE_COMMAND} -E remove -f ${OLD_INTROSPECTION_FILES} - COMMAND ${CMAKE_COMMAND} -E copy ../IntrospectionSchema.cpp ${CMAKE_CURRENT_SOURCE_DIR}/../samples/introspection/ - COMMAND ${CMAKE_COMMAND} -E copy ../include/graphqlservice/introspection/IntrospectionSchema.h ${CMAKE_CURRENT_SOURCE_DIR}/../samples/introspection/ + COMMAND schemagen --introspection + COMMAND ${CMAKE_COMMAND} -E copy_if_different IntrospectionSchema.cpp ${CMAKE_CURRENT_SOURCE_DIR} + COMMAND ${CMAKE_COMMAND} -E copy_if_different IntrospectionSchema.h ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/introspection COMMAND ${CMAKE_COMMAND} -E touch updated_introspection - DEPENDS - ${CMAKE_CURRENT_BINARY_DIR}/../IntrospectionSchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/../include/graphqlservice/introspection/IntrospectionSchema.h - COMMENT "Updating introspection files") + DEPENDS schemagen + COMMENT "Updating IntrospectionSchema files") add_custom_target(update_introspection ALL DEPENDS updated_introspection) -else() - add_custom_command( - OUTPUT - ${CMAKE_CURRENT_BINARY_DIR}/../IntrospectionSchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/../include/graphqlservice/introspection/IntrospectionSchema.h - COMMAND ${CMAKE_COMMAND} -E make_directory include/graphqlservice/introspection - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/../samples/introspection/IntrospectionSchema.cpp . - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/../samples/introspection/IntrospectionSchema.h include/graphqlservice/introspection - WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/.. - COMMENT "Copying IntrospectionSchema files") endif() -add_custom_target(copy_introspection - DEPENDS - ${CMAKE_CURRENT_BINARY_DIR}/../IntrospectionSchema.cpp - ${CMAKE_CURRENT_BINARY_DIR}/../include/graphqlservice/introspection/IntrospectionSchema.h) - # graphqlservice_nointrospection add_library(graphqlservice_nointrospection GraphQLService.cpp GraphQLSchema.cpp Validation.cpp) -add_dependencies(graphqlservice_nointrospection copy_introspection) add_library(cppgraphqlgen::graphqlservice_nointrospection ALIAS graphqlservice_nointrospection) target_link_libraries(graphqlservice_nointrospection PUBLIC graphqlpeg graphqlresponse Threads::Threads) -target_include_directories(graphqlservice_nointrospection PUBLIC - $) + +if(GRAPHQL_UPDATE_SAMPLES) + # Even though this target doesn't build IntrospectionSchema.cpp, it still + # depends on IntrospectionSchema.h for some enum definitions. + add_dependencies(graphqlservice_nointrospection update_introspection) +endif() + +if(GRAPHQL_UPDATE_VERSION) + update_version_rc(graphqlservice_nointrospection) +endif() if(WIN32 AND BUILD_SHARED_LIBS) target_compile_definitions(graphqlservice_nointrospection @@ -215,10 +235,14 @@ endif() # graphqlservice add_library(graphqlservice Introspection.cpp - ${CMAKE_CURRENT_BINARY_DIR}/../IntrospectionSchema.cpp) + IntrospectionSchema.cpp) add_library(cppgraphqlgen::graphqlservice ALIAS graphqlservice) target_link_libraries(graphqlservice PUBLIC graphqlservice_nointrospection) +if(GRAPHQL_UPDATE_VERSION) + update_version_rc(graphqlservice) +endif() + if(WIN32 AND BUILD_SHARED_LIBS) target_compile_definitions(graphqlservice PUBLIC GRAPHQL_DLLEXPORTS @@ -244,6 +268,10 @@ if(GRAPHQL_USE_RAPIDJSON) target_link_libraries(graphqljson PUBLIC graphqlresponse) target_include_directories(graphqljson SYSTEM PRIVATE ${RAPIDJSON_INCLUDE_DIRS}) + if(GRAPHQL_UPDATE_VERSION) + update_version_rc(graphqljson) + endif() + if(WIN32 AND BUILD_SHARED_LIBS) target_compile_definitions(graphqljson PUBLIC GRAPHQL_DLLEXPORTS @@ -293,13 +321,13 @@ install(FILES install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/internal/SortedMap.h - ${CMAKE_CURRENT_BINARY_DIR}/../include/graphqlservice/internal/Version.h + ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/internal/Version.h CONFIGURATIONS ${GRAPHQL_INSTALL_CONFIGURATIONS} DESTINATION ${GRAPHQL_INSTALL_INCLUDE_DIR}/graphqlservice/internal) install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/introspection/Introspection.h - ${CMAKE_CURRENT_BINARY_DIR}/../include/graphqlservice/introspection/IntrospectionSchema.h + ${CMAKE_CURRENT_SOURCE_DIR}/../include/graphqlservice/introspection/IntrospectionSchema.h CONFIGURATIONS ${GRAPHQL_INSTALL_CONFIGURATIONS} DESTINATION ${GRAPHQL_INSTALL_INCLUDE_DIR}/graphqlservice/introspection) diff --git a/samples/introspection/IntrospectionSchema.cpp b/src/IntrospectionSchema.cpp similarity index 99% rename from samples/introspection/IntrospectionSchema.cpp rename to src/IntrospectionSchema.cpp index 868ce619..f6024adc 100644 --- a/samples/introspection/IntrospectionSchema.cpp +++ b/src/IntrospectionSchema.cpp @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include "graphqlservice/introspection/Introspection.h" #include diff --git a/src/SchemaGenerator.cpp b/src/SchemaGenerator.cpp index 317f6ec5..bcff6e59 100644 --- a/src/SchemaGenerator.cpp +++ b/src/SchemaGenerator.cpp @@ -3,8 +3,18 @@ #include "SchemaGenerator.h" +#ifdef _MSC_VER +#pragma warning(push) +#pragma warning(disable : 26495) +#pragma warning(disable : 26812) +#endif // _MSC_VER + #include +#ifdef _MSC_VER +#pragma warning(pop) +#endif // _MSC_VER + // clang-format off #ifdef USE_STD_FILESYSTEM #include @@ -55,6 +65,8 @@ IncludeGuardScope::IncludeGuardScope( _outputFile << R"cpp(// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #pragma once #ifndef )cpp" << _includeGuardName @@ -310,11 +322,7 @@ Generator::Generator(GeneratorOptions&& options) std::string Generator::getHeaderDir() const noexcept { - if (_isIntrospection) - { - return (fs::path { "include" } / "graphqlservice" / "introspection").string(); - } - else if (_options.paths) + if (_options.paths) { return fs::path { _options.paths->headerPath }.string(); } @@ -326,13 +334,13 @@ std::string Generator::getHeaderDir() const noexcept std::string Generator::getSourceDir() const noexcept { - if (_isIntrospection || !_options.paths) + if (_options.paths) { - return {}; + return fs::path(_options.paths->sourcePath).string(); } else { - return fs::path(_options.paths->sourcePath).string(); + return {}; } } @@ -1694,9 +1702,11 @@ bool Generator::outputHeader() const noexcept // Check if the library version is compatible with schemagen )cpp" << graphql::internal::FullVersion << R"cpp( static_assert(graphql::internal::MajorVersion == )cpp" - << graphql::internal::MajorVersion << R"cpp(, "regenerate with schemagen: major version mismatch"); + << graphql::internal::MajorVersion + << R"cpp(, "regenerate with schemagen: major version mismatch"); static_assert(graphql::internal::MinorVersion == )cpp" - << graphql::internal::MinorVersion << R"cpp(, "regenerate with schemagen: minor version mismatch"); + << graphql::internal::MinorVersion + << R"cpp(, "regenerate with schemagen: minor version mismatch"); )cpp"; if (_isIntrospection) @@ -2077,7 +2087,10 @@ bool Generator::outputSource() const noexcept sourceFile << R"cpp(// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + )cpp"; + if (!_isIntrospection) { sourceFile << R"cpp(#include ")cpp" << fs::path(_objectHeaderPath).filename().string() @@ -3636,6 +3649,8 @@ std::vector Generator::outputSeparateFiles() const noexcept sourceFile << R"cpp(// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +// WARNING! Do not edit this file manually, your changes will be overwritten. + #include ")cpp" << fs::path(_objectHeaderPath).filename().string() << R"cpp(" diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index e4f51749..dc17e7fd 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -47,30 +47,34 @@ target_link_libraries(pegtl_tests PRIVATE GTest::GTest GTest::Main) target_include_directories(pegtl_tests PUBLIC - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../PEGTL/include) gtest_add_tests(TARGET pegtl_tests) add_executable(response_tests ResponseTests.cpp) target_link_libraries(response_tests PRIVATE - graphqlservice + graphqlservice_nointrospection GTest::GTest GTest::Main) target_include_directories(response_tests PUBLIC - ${CMAKE_CURRENT_BINARY_DIR}/../include ${CMAKE_CURRENT_SOURCE_DIR}/../include) gtest_add_tests(TARGET response_tests) if(WIN32 AND BUILD_SHARED_LIBS) - add_custom_target(copy_test_dlls ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} - COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_CURRENT_BINARY_DIR} + add_custom_command(OUTPUT copied_test_dlls + COMMAND ${CMAKE_COMMAND} -E copy_if_different + $ + $ + $ + $ + $ + ${CMAKE_CURRENT_BINARY_DIR} + COMMAND ${CMAKE_COMMAND} -E touch ${CMAKE_CURRENT_BINARY_DIR}/copied_test_dlls DEPENDS graphqlservice graphqljson graphqlpeg graphqlresponse WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/../src) + add_custom_target(copy_test_dlls DEPENDS copied_test_dlls) + add_dependencies(validation_tests copy_test_dlls) add_dependencies(today_tests copy_test_dlls) add_dependencies(nointrospection_tests copy_test_dlls) From 3a9b2f6c3122517d2643b423da3bd482fde9ed21 Mon Sep 17 00:00:00 2001 From: Bill Avery Date: Fri, 8 Jan 2021 14:03:45 -0800 Subject: [PATCH 2/3] Add graphqlservice_nointrospection.dll to dependencies --- samples/CMakeLists.txt | 7 ++++++- test/CMakeLists.txt | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/samples/CMakeLists.txt b/samples/CMakeLists.txt index 098a9591..a1726174 100644 --- a/samples/CMakeLists.txt +++ b/samples/CMakeLists.txt @@ -180,7 +180,12 @@ if(WIN32 AND BUILD_SHARED_LIBS) $ ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${CMAKE_COMMAND} -E touch copied_sample_dlls - DEPENDS graphqlservice graphqljson graphqlpeg graphqlresponse) + DEPENDS + graphqlservice_nointrospection + graphqlservice + graphqljson + graphqlpeg + graphqlresponse) add_custom_target(copy_sample_dlls DEPENDS copied_sample_dlls) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index dc17e7fd..eaa80282 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -70,7 +70,12 @@ if(WIN32 AND BUILD_SHARED_LIBS) $ ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${CMAKE_COMMAND} -E touch ${CMAKE_CURRENT_BINARY_DIR}/copied_test_dlls - DEPENDS graphqlservice graphqljson graphqlpeg graphqlresponse + DEPENDS + graphqlservice_nointrospection + graphqlservice + graphqljson + graphqlpeg + graphqlresponse) WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/../src) add_custom_target(copy_test_dlls DEPENDS copied_test_dlls) From 8b0e096b1b3993608ae7631084bea0ea04bb4876 Mon Sep 17 00:00:00 2001 From: Bill Avery Date: Fri, 8 Jan 2021 14:04:26 -0800 Subject: [PATCH 3/3] Fix copy/paste bug --- test/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index eaa80282..6340b363 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -75,7 +75,7 @@ if(WIN32 AND BUILD_SHARED_LIBS) graphqlservice graphqljson graphqlpeg - graphqlresponse) + graphqlresponse WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/../src) add_custom_target(copy_test_dlls DEPENDS copied_test_dlls)