diff options
author | Gianfranco Costamagna <costamagna.gianfranco@gmail.com> | 2018-11-05 16:16:53 +0100 |
---|---|---|
committer | Armin Kuster <akuster808@gmail.com> | 2018-11-15 13:18:51 -0800 |
commit | a4e589147636ce78a0806a96d96102dae5e61319 (patch) | |
tree | 4a4a94320a1c23d3841b5125cee98c5439692a4b /meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch | |
parent | 0ded4a44ac2bbc186e4f3df8c60eade85e8e94eb (diff) | |
download | meta-openembedded-a4e589147636ce78a0806a96d96102dae5e61319.tar.gz |
cpprest: upgrade to version 2.10.7 and add support for brotli library
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Diffstat (limited to 'meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch')
-rw-r--r-- | meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch b/meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch new file mode 100644 index 000000000..e6f64772d --- /dev/null +++ b/meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | Description: Find system brotli | ||
2 | Author: Gianfranco Costamagna <locutusofborg@debian.org> | ||
3 | Forwarded: https://github.com/Microsoft/cpprestsdk/pull/952 | ||
4 | Last-Update: 2018-11-05 | ||
5 | |||
6 | --- cpprest-2.10.7.orig/Release/cmake/cpprest_find_brotli.cmake | ||
7 | +++ cpprest-2.10.7/Release/cmake/cpprest_find_brotli.cmake | ||
8 | @@ -3,8 +3,17 @@ function(cpprest_find_brotli) | ||
9 | return() | ||
10 | endif() | ||
11 | |||
12 | - find_package(unofficial-brotli REQUIRED) | ||
13 | |||
14 | - add_library(cpprestsdk_brotli_internal INTERFACE) | ||
15 | - target_link_libraries(cpprestsdk_brotli_internal INTERFACE unofficial::brotli::brotlienc unofficial::brotli::brotlidec unofficial::brotli::brotlicommon) | ||
16 | + find_package(PkgConfig) | ||
17 | + pkg_check_modules(BROTLIENC libbrotlienc) | ||
18 | + pkg_check_modules(BROTLIDEC libbrotlidec) | ||
19 | + if(BROTLIDEC_FOUND AND BROTLIENC_FOUND) | ||
20 | + target_link_libraries(cpprest PRIVATE ${BROTLIDEC_LDFLAGS} ${BROTLIENC_LDFLAGS}) | ||
21 | + else(BROTLIDEC_FOUND AND BROTLIENC_FOUND) | ||
22 | + find_package(unofficial-brotli REQUIRED) | ||
23 | + add_library(cpprestsdk_brotli_internal INTERFACE) | ||
24 | + target_link_libraries(cpprestsdk_brotli_internal INTERFACE unofficial::brotli::brotlienc unofficial::brotli::brotlidec unofficial::brotli::brotlicommon) | ||
25 | + target_link_libraries(cpprest PRIVATE cpprestsdk_brotli_internal) | ||
26 | + endif(BROTLIDEC_FOUND AND BROTLIENC_FOUND) | ||
27 | + | ||
28 | endfunction() | ||
29 | --- cpprest-2.10.7.orig/Release/src/CMakeLists.txt | ||
30 | +++ cpprest-2.10.7/Release/src/CMakeLists.txt | ||
31 | @@ -84,7 +84,6 @@ else() | ||
32 | target_compile_definitions(cpprest PRIVATE -DCPPREST_EXCLUDE_BROTLI=1) | ||
33 | else() | ||
34 | cpprest_find_brotli() | ||
35 | - target_link_libraries(cpprest PRIVATE cpprestsdk_brotli_internal) | ||
36 | endif() | ||
37 | endif() | ||
38 | |||