[oe,meta-oe,V2,4/5] cpprest: Fix build with gcc-8

Message ID 20180613063512.1755-4-raj.khem@gmail.com
State Accepted
Commit 91e95fede450c56487f34b6096944183dcf06efa
Headers show
Series
  • [oe,meta-networking,V2,1/5] rdma-core: Update to version 18
Related show

Commit Message

Khem Raj June 13, 2018, 6:35 a.m.
Signed-off-by: Khem Raj <raj.khem@gmail.com>

---
 .../0001-disable-more-Werror-warnings.patch   | 48 +++++++++++++++++++
 .../recipes-support/cpprest/cpprest_2.10.2.bb |  1 +
 2 files changed, 49 insertions(+)
 create mode 100644 meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

-- 
2.17.1

-- 
_______________________________________________
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

Comments

Martin Jansa June 17, 2018, 7:34 a.m. | #1
I think you're missing '=' in -Wno-format-truncation (it's shown in the
error message, so I was always adding it with '=' as well, but it seems
that both work).

cpprest/2.10.2-r0/git/Release/src/utilities/asyncrt_utils.cpp:702:42:
error: '%s' directive output may be truncated writing up to 8 bytes into a
region of size between 1 and 65 [-Werror=format-truncation=]
         snprintf(output, sizeof(output), "%s%sZ", datetime_str, buf);
                                          ^~~~~~~                ~~~
cpprest/2.10.2-r0/git/Release/src/utilities/asyncrt_utils.cpp:702:17: note:
'snprintf' output between 2 and 74 bytes into a destination of size 65
         snprintf(output, sizeof(output), "%s%sZ", datetime_str, buf);
         ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Also can you please drop one of these? The one in meta-networking is still
failing

./meta-oe/recipes-support/cpprest
./meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb
./meta-oe/recipes-support/cpprest/cpprest-2.10.2
./meta-networking/recipes-support/cpprest
./meta-networking/recipes-support/cpprest/cpprest_2.10.2.bb
./meta-networking/recipes-support/cpprest/cpprest-2.10.2

Added in:
meta-oe:
commit 9eb8b9a2c416da018c4a8acb416ef38797436f50
Author:     Gianfranco Costamagna <costamagna.gianfranco@gmail.com>
AuthorDate: Thu Apr 19 19:12:07 2018 +0200
Commit:     Armin Kuster <akuster808@gmail.com>
CommitDate: Tue May 1 18:17:02 2018 -0700

    cpprest: add new recipe based on Debian packaging

    Signed-off-by: Gianfranco Costamagna <locutusofborg@debian.org>

    Signed-off-by: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com

>

    Co-developed-by: Cristiano Prato <cristiano.prato@cnhind.com>
    Signed-off-by: Armin Kuster <akuster808@gmail.com>


meta-networking:
commit 12e8c3ea698905e2ed0edd9b7f351a497a1bd68d
Author:     Gianfranco Costamagna <costamagna.gianfranco@gmail.com>
AuthorDate: Sun Apr 29 20:02:06 2018 +0200
Commit:     Armin Kuster <akuster808@gmail.com>
CommitDate: Thu May 17 08:32:26 2018 -0700

    cpprest: add new recipe based on Debian packaging

    The patches were imported from the Debian repository
    (https://salsa.debian.org/debian/casablanca) as of commit id
5b58637016a569a5d54714bd151a800028f77532

    Signed-off-by: Gianfranco Costamagna <locutusofborg@debian.org>

    Signed-off-by: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com

>

    Co-developed-by: Cristiano Prato <cristiano.prato@cnhind.com>
    Signed-off-by: Armin Kuster <akuster808@gmail.com>



On Wed, Jun 13, 2018 at 9:01 AM Khem Raj <raj.khem@gmail.com> wrote:

> Signed-off-by: Khem Raj <raj.khem@gmail.com>

> ---

>  .../0001-disable-more-Werror-warnings.patch   | 48 +++++++++++++++++++

>  .../recipes-support/cpprest/cpprest_2.10.2.bb |  1 +

>  2 files changed, 49 insertions(+)

>  create mode 100644

> meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

>

> diff --git

> a/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

> b/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

> new file mode 100644

> index 0000000000..febfd5bc96

> --- /dev/null

> +++

> b/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

> @@ -0,0 +1,48 @@

> +From ee92f84a96a507b0a7a3c54929ce190ee28b4ecd Mon Sep 17 00:00:00 2001

> +From: Alexander Moriarty <amoriarty@fetchrobotics.com>

> +Date: Wed, 6 Jun 2018 10:38:43 -0700

> +Subject: [PATCH] disable more -Werror warnings

> +

> +gcc-8: -Wno-format-truncation

> +

> +clang-6: -Wdelete-non-virtual-dtor

> +clang-6: -Wunused-lambda-capture

> +

> +removed duplicated: -Wno-reorder

> +

> +This fixes #778

> +

> +Upstream-Status: Pending [

> https://github.com/Microsoft/cpprestsdk/pull/779]

> +Signed-off-by: Khem Raj <raj.khem@gmail.com>

> +---

> + Release/CMakeLists.txt | 6 +++---

> + 1 file changed, 3 insertions(+), 3 deletions(-)

> +

> +diff --git a/Release/CMakeLists.txt b/Release/CMakeLists.txt

> +index 1267aff1..fb291ccd 100644

> +--- a/Release/CMakeLists.txt

> ++++ b/Release/CMakeLists.txt

> +@@ -166,12 +166,12 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR IOS)

> +     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes

> -Wno-pointer-arith")

> +   elseif(CMAKE_SYSTEM_NAME MATCHES "Linux")

> +     set(WARNINGS -Wall -Wextra -Wcast-qual -Wconversion -Wformat=2

> -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs

> -Wpacked -Wredundant-decls)

> +-    set(LINUX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion

> -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts

> -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated

> -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage

> -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-reorder

> -Wno-unused-local-typedefs)

> ++    set(LINUX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion

> -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts

> -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated

> -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage

> -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32

> -Wno-unused-local-typedefs -Wno-delete-non-virtual-dtor

> -Wno-unused-lambda-capture)

> +     set(WARNINGS ${WARNINGS} ${LINUX_SUPPRESSIONS})

> +     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-return-type-c-linkage

> -Wno-unneeded-internal-declaration")

> +   else()

> +     set(WARNINGS -Wall -Wextra -Wcast-qual -Wconversion -Wformat=2

> -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs

> -Wpacked -Wredundant-decls)

> +-    set(OSX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion

> -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts

> -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated

> -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage

> -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-reorder

> -Wno-unused-local-typedefs)

> ++    set(OSX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion

> -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts

> -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated

> -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage

> -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32

> -Wno-unused-local-typedefs -Wno-delete-non-virtual-dtor

> -Wno-unused-lambda-capture)

> +     set(WARNINGS ${WARNINGS} ${OSX_SUPPRESSIONS})

> +

> +     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++

> -Wno-return-type-c-linkage -Wno-unneeded-internal-declaration")

> +@@ -184,7 +184,7 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR IOS)

> + elseif(CMAKE_CXX_COMPILER_ID MATCHES "GNU")

> +   message("-- Setting gcc options")

> +

> +-  set(WARNINGS -Wall -Wextra -Wunused-parameter -Wcast-align -Wcast-qual

> -Wconversion -Wformat=2 -Winit-self -Winvalid-pch

> -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked

> -Wredundant-decls -Wunreachable-code)

> ++  set(WARNINGS -Wall -Wextra -Wunused-parameter -Wcast-align -Wcast-qual

> -Wconversion -Wformat=2 -Winit-self -Winvalid-pch

> -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked

> -Wredundant-decls -Wunreachable-code -Wno-format-truncation)

> +   set(LD_FLAGS "${LD_FLAGS} -Wl,-z,defs")

> +

> +   set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11

> -fno-strict-aliasing")

> diff --git a/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

> b/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

> index 1dbe093bee..fea5d4b2eb 100644

> --- a/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

> +++ b/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

> @@ -9,6 +9,7 @@ SRC_URI = "git://

> github.com/Microsoft/cpprestsdk.git;protocol=https;branch=maste

>             file://fix-cmake-install.patch \

>             file://0001-Fix-a-build-problem-on-Clang.patch;patchdir=.. \

>             file://0002-Define-virtual-destructor.patch;patchdir=.. \

> +           file://0001-disable-more-Werror-warnings.patch;patchdir=.. \

>             "

>

>  # tag 2.10.2

> --

> 2.17.1

>

> --

> _______________________________________________

> Openembedded-devel mailing list

> Openembedded-devel@lists.openembedded.org

> http://lists.openembedded.org/mailman/listinfo/openembedded-devel

>

-- 
_______________________________________________
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel
Khem Raj June 17, 2018, 7:38 a.m. | #2
On Sun, Jun 17, 2018 at 12:34 AM Martin Jansa <martin.jansa@gmail.com> wrote:
>

> I think you're missing '=' in -Wno-format-truncation (it's shown in the error message, so I was always adding it with '=' as well, but it seems that both work).



there is a level you can set and that when you need '='
-Wformat-truncation is same as -Wformat-truncation=1

>

> cpprest/2.10.2-r0/git/Release/src/utilities/asyncrt_utils.cpp:702:42: error: '%s' directive output may be truncated writing up to 8 bytes into a region of size between 1 and 65 [-Werror=format-truncation=]

>          snprintf(output, sizeof(output), "%s%sZ", datetime_str, buf);

>                                           ^~~~~~~                ~~~

> cpprest/2.10.2-r0/git/Release/src/utilities/asyncrt_utils.cpp:702:17: note: 'snprintf' output between 2 and 74 bytes into a destination of size 65

>          snprintf(output, sizeof(output), "%s%sZ", datetime_str, buf);

>          ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

>

> Also can you please drop one of these? The one in meta-networking is still failing

>


yes good point.


> ./meta-oe/recipes-support/cpprest

> ./meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

> ./meta-oe/recipes-support/cpprest/cpprest-2.10.2

> ./meta-networking/recipes-support/cpprest

> ./meta-networking/recipes-support/cpprest/cpprest_2.10.2.bb

> ./meta-networking/recipes-support/cpprest/cpprest-2.10.2

>

> Added in:

> meta-oe:

> commit 9eb8b9a2c416da018c4a8acb416ef38797436f50

> Author:     Gianfranco Costamagna <costamagna.gianfranco@gmail.com>

> AuthorDate: Thu Apr 19 19:12:07 2018 +0200

> Commit:     Armin Kuster <akuster808@gmail.com>

> CommitDate: Tue May 1 18:17:02 2018 -0700

>

>     cpprest: add new recipe based on Debian packaging

>

>     Signed-off-by: Gianfranco Costamagna <locutusofborg@debian.org>

>     Signed-off-by: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com>

>     Co-developed-by: Cristiano Prato <cristiano.prato@cnhind.com>

>     Signed-off-by: Armin Kuster <akuster808@gmail.com>

>

> meta-networking:

> commit 12e8c3ea698905e2ed0edd9b7f351a497a1bd68d

> Author:     Gianfranco Costamagna <costamagna.gianfranco@gmail.com>

> AuthorDate: Sun Apr 29 20:02:06 2018 +0200

> Commit:     Armin Kuster <akuster808@gmail.com>

> CommitDate: Thu May 17 08:32:26 2018 -0700

>

>     cpprest: add new recipe based on Debian packaging

>

>     The patches were imported from the Debian repository

>     (https://salsa.debian.org/debian/casablanca) as of commit id 5b58637016a569a5d54714bd151a800028f77532

>

>     Signed-off-by: Gianfranco Costamagna <locutusofborg@debian.org>

>     Signed-off-by: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com>

>     Co-developed-by: Cristiano Prato <cristiano.prato@cnhind.com>

>     Signed-off-by: Armin Kuster <akuster808@gmail.com>

>

>

> On Wed, Jun 13, 2018 at 9:01 AM Khem Raj <raj.khem@gmail.com> wrote:

>>

>> Signed-off-by: Khem Raj <raj.khem@gmail.com>

>> ---

>>  .../0001-disable-more-Werror-warnings.patch   | 48 +++++++++++++++++++

>>  .../recipes-support/cpprest/cpprest_2.10.2.bb |  1 +

>>  2 files changed, 49 insertions(+)

>>  create mode 100644 meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

>>

>> diff --git a/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch b/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

>> new file mode 100644

>> index 0000000000..febfd5bc96

>> --- /dev/null

>> +++ b/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch

>> @@ -0,0 +1,48 @@

>> +From ee92f84a96a507b0a7a3c54929ce190ee28b4ecd Mon Sep 17 00:00:00 2001

>> +From: Alexander Moriarty <amoriarty@fetchrobotics.com>

>> +Date: Wed, 6 Jun 2018 10:38:43 -0700

>> +Subject: [PATCH] disable more -Werror warnings

>> +

>> +gcc-8: -Wno-format-truncation

>> +

>> +clang-6: -Wdelete-non-virtual-dtor

>> +clang-6: -Wunused-lambda-capture

>> +

>> +removed duplicated: -Wno-reorder

>> +

>> +This fixes #778

>> +

>> +Upstream-Status: Pending [https://github.com/Microsoft/cpprestsdk/pull/779]

>> +Signed-off-by: Khem Raj <raj.khem@gmail.com>

>> +---

>> + Release/CMakeLists.txt | 6 +++---

>> + 1 file changed, 3 insertions(+), 3 deletions(-)

>> +

>> +diff --git a/Release/CMakeLists.txt b/Release/CMakeLists.txt

>> +index 1267aff1..fb291ccd 100644

>> +--- a/Release/CMakeLists.txt

>> ++++ b/Release/CMakeLists.txt

>> +@@ -166,12 +166,12 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR IOS)

>> +     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes -Wno-pointer-arith")

>> +   elseif(CMAKE_SYSTEM_NAME MATCHES "Linux")

>> +     set(WARNINGS -Wall -Wextra -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls)

>> +-    set(LINUX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-reorder -Wno-unused-local-typedefs)

>> ++    set(LINUX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-unused-local-typedefs -Wno-delete-non-virtual-dtor -Wno-unused-lambda-capture)

>> +     set(WARNINGS ${WARNINGS} ${LINUX_SUPPRESSIONS})

>> +     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-return-type-c-linkage -Wno-unneeded-internal-declaration")

>> +   else()

>> +     set(WARNINGS -Wall -Wextra -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls)

>> +-    set(OSX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-reorder -Wno-unused-local-typedefs)

>> ++    set(OSX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-unused-local-typedefs -Wno-delete-non-virtual-dtor -Wno-unused-lambda-capture)

>> +     set(WARNINGS ${WARNINGS} ${OSX_SUPPRESSIONS})

>> +

>> +     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++ -Wno-return-type-c-linkage -Wno-unneeded-internal-declaration")

>> +@@ -184,7 +184,7 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR IOS)

>> + elseif(CMAKE_CXX_COMPILER_ID MATCHES "GNU")

>> +   message("-- Setting gcc options")

>> +

>> +-  set(WARNINGS -Wall -Wextra -Wunused-parameter -Wcast-align -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls -Wunreachable-code)

>> ++  set(WARNINGS -Wall -Wextra -Wunused-parameter -Wcast-align -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls -Wunreachable-code -Wno-format-truncation)

>> +   set(LD_FLAGS "${LD_FLAGS} -Wl,-z,defs")

>> +

>> +   set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-strict-aliasing")

>> diff --git a/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb b/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

>> index 1dbe093bee..fea5d4b2eb 100644

>> --- a/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

>> +++ b/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb

>> @@ -9,6 +9,7 @@ SRC_URI = "git://github.com/Microsoft/cpprestsdk.git;protocol=https;branch=maste

>>             file://fix-cmake-install.patch \

>>             file://0001-Fix-a-build-problem-on-Clang.patch;patchdir=.. \

>>             file://0002-Define-virtual-destructor.patch;patchdir=.. \

>> +           file://0001-disable-more-Werror-warnings.patch;patchdir=.. \

>>             "

>>

>>  # tag 2.10.2

>> --

>> 2.17.1

>>

>> --

>> _______________________________________________

>> Openembedded-devel mailing list

>> Openembedded-devel@lists.openembedded.org

>> http://lists.openembedded.org/mailman/listinfo/openembedded-devel

-- 
_______________________________________________
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

Patch

diff --git a/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch b/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch
new file mode 100644
index 0000000000..febfd5bc96
--- /dev/null
+++ b/meta-oe/recipes-support/cpprest/cpprest-2.10.2/0001-disable-more-Werror-warnings.patch
@@ -0,0 +1,48 @@ 
+From ee92f84a96a507b0a7a3c54929ce190ee28b4ecd Mon Sep 17 00:00:00 2001
+From: Alexander Moriarty <amoriarty@fetchrobotics.com>
+Date: Wed, 6 Jun 2018 10:38:43 -0700
+Subject: [PATCH] disable more -Werror warnings
+
+gcc-8: -Wno-format-truncation
+
+clang-6: -Wdelete-non-virtual-dtor
+clang-6: -Wunused-lambda-capture
+
+removed duplicated: -Wno-reorder
+
+This fixes #778
+
+Upstream-Status: Pending [https://github.com/Microsoft/cpprestsdk/pull/779]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Release/CMakeLists.txt | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/Release/CMakeLists.txt b/Release/CMakeLists.txt
+index 1267aff1..fb291ccd 100644
+--- a/Release/CMakeLists.txt
++++ b/Release/CMakeLists.txt
+@@ -166,12 +166,12 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR IOS)
+     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes -Wno-pointer-arith")
+   elseif(CMAKE_SYSTEM_NAME MATCHES "Linux")
+     set(WARNINGS -Wall -Wextra -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls)
+-    set(LINUX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-reorder -Wno-unused-local-typedefs)
++    set(LINUX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-unused-local-typedefs -Wno-delete-non-virtual-dtor -Wno-unused-lambda-capture)
+     set(WARNINGS ${WARNINGS} ${LINUX_SUPPRESSIONS})
+     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-return-type-c-linkage -Wno-unneeded-internal-declaration")
+   else()
+     set(WARNINGS -Wall -Wextra -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls)
+-    set(OSX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-reorder -Wno-unused-local-typedefs)
++    set(OSX_SUPPRESSIONS -Wno-overloaded-virtual -Wno-sign-conversion -Wno-deprecated -Wno-unknown-pragmas -Wno-reorder -Wno-char-subscripts -Wno-switch -Wno-unused-parameter -Wno-unused-variable -Wno-deprecated -Wno-unused-value -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-unused-function -Wno-sign-compare -Wno-shorten-64-to-32 -Wno-unused-local-typedefs -Wno-delete-non-virtual-dtor -Wno-unused-lambda-capture)
+     set(WARNINGS ${WARNINGS} ${OSX_SUPPRESSIONS})
+ 
+     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++ -Wno-return-type-c-linkage -Wno-unneeded-internal-declaration")
+@@ -184,7 +184,7 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR IOS)
+ elseif(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
+   message("-- Setting gcc options")
+ 
+-  set(WARNINGS -Wall -Wextra -Wunused-parameter -Wcast-align -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls -Wunreachable-code)
++  set(WARNINGS -Wall -Wextra -Wunused-parameter -Wcast-align -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls -Wunreachable-code -Wno-format-truncation)
+   set(LD_FLAGS "${LD_FLAGS} -Wl,-z,defs")
+ 
+   set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-strict-aliasing")
diff --git a/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb b/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb
index 1dbe093bee..fea5d4b2eb 100644
--- a/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb
+++ b/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb
@@ -9,6 +9,7 @@  SRC_URI = "git://github.com/Microsoft/cpprestsdk.git;protocol=https;branch=maste
            file://fix-cmake-install.patch \
            file://0001-Fix-a-build-problem-on-Clang.patch;patchdir=.. \
            file://0002-Define-virtual-destructor.patch;patchdir=.. \
+           file://0001-disable-more-Werror-warnings.patch;patchdir=.. \
            "
 
 # tag 2.10.2