All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc
@ 2019-05-29 17:29 Fabrice Fontaine
  2019-05-29 17:29 ` [Buildroot] [PATCH 2/2] package/wireshark: fix static build with snappy Fabrice Fontaine
  2019-12-20 14:00 ` [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc Giulio Benetti
  0 siblings, 2 replies; 6+ messages in thread
From: Fabrice Fontaine @ 2019-05-29 17:29 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 .../snappy/0001-Readd-pkgconfig-support.patch | 56 +++++++++++++++++++
 1 file changed, 56 insertions(+)
 create mode 100644 package/snappy/0001-Readd-pkgconfig-support.patch

diff --git a/package/snappy/0001-Readd-pkgconfig-support.patch b/package/snappy/0001-Readd-pkgconfig-support.patch
new file mode 100644
index 0000000000..f27df9c8e8
--- /dev/null
+++ b/package/snappy/0001-Readd-pkgconfig-support.patch
@@ -0,0 +1,56 @@
+From e2c4ae93c6f57a80a71bdcff309006efccd30f42 Mon Sep 17 00:00:00 2001
+From: Niclas Rosenvik <youremailsarecrap@gmail.com>
+Date: Fri, 4 Aug 2017 12:33:18 +0200
+Subject: [PATCH] Readd pkgconfig support.
+
+Readd pkgconfig support to support usage of snappy with other build systems.
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+[Retrieved (and updated to add Libs.private) from:
+https://github.com/google/snappy/pull/51/commits/e2c4ae93c6f57a80a71bdcff309006efccd30f42]
+---
+ CMakeLists.txt     |  6 ++++++
+ cmake/snappy.pc.in | 10 ++++++++++
+ 2 files changed, 16 insertions(+)
+ create mode 100644 cmake/snappy.pc.in
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index e9e70c8..7a8dab4 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -54,6 +54,11 @@ configure_file(
+   "${PROJECT_SOURCE_DIR}/cmake/config.h.in"
+   "${PROJECT_BINARY_DIR}/config.h"
+ )
++configure_file(
++  "${PROJECT_SOURCE_DIR}/cmake/snappy.pc.in"
++  "${PROJECT_BINARY_DIR}/snappy.pc"
++  @ONLY
++)
+ 
+ # We don't want to define HAVE_ macros in public headers. Instead, we use
+ # CMake's variable substitution with 0/1 variables, which will be seen by the
+@@ -165,3 +170,4 @@ install(
+     "${PROJECT_BINARY_DIR}/SnappyConfigVersion.cmake"
+   DESTINATION lib/cmake/Snappy
+ )
++install(FILES "${PROJECT_BINARY_DIR}/snappy.pc" DESTINATION lib/pkgconfig)
+\ No newline at end of file
+diff --git a/cmake/snappy.pc.in b/cmake/snappy.pc.in
+new file mode 100644
+index 0000000..6c43545
+--- /dev/null
++++ b/cmake/snappy.pc.in
+@@ -0,0 +1,10 @@
++prefix=@CMAKE_INSTALL_PREFIX@
++exec_prefix=${prefix}
++libdir=${exec_prefix}/lib
++includedir=${prefix}/include
++
++Name: @PROJECT_NAME@
++Description: A fast compression/decompression library
++Version: @PROJECT_VERSION@
++Libs: -L${libdir} -lsnappy
++Libs.private: -lstdc++
++Cflags: -I${includedir}
+\ No newline at end of file
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 2/2] package/wireshark: fix static build with snappy
  2019-05-29 17:29 [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc Fabrice Fontaine
@ 2019-05-29 17:29 ` Fabrice Fontaine
  2019-12-20 14:28   ` Giulio Benetti
  2019-12-20 14:00 ` [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc Giulio Benetti
  1 sibling, 1 reply; 6+ messages in thread
From: Fabrice Fontaine @ 2019-05-29 17:29 UTC (permalink / raw)
  To: buildroot

Fixes:
 - http://autobuild.buildroot.org/results/419468f0d7d3c2b64d420513aa9505c6de097ed2

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 .../0005-FindSNAPPY-fix-static-build.patch    | 46 +++++++++++++++++++
 1 file changed, 46 insertions(+)
 create mode 100644 package/wireshark/0005-FindSNAPPY-fix-static-build.patch

diff --git a/package/wireshark/0005-FindSNAPPY-fix-static-build.patch b/package/wireshark/0005-FindSNAPPY-fix-static-build.patch
new file mode 100644
index 0000000000..ba528cf01a
--- /dev/null
+++ b/package/wireshark/0005-FindSNAPPY-fix-static-build.patch
@@ -0,0 +1,46 @@
+From 4abe51deee1ed3daffa9042ab41ed0622856c69c Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Tue, 28 May 2019 21:18:09 +0200
+Subject: [PATCH] FindSNAPPY: fix static build
+
+On UNIX, when statically built, snappy can depends on stdc++. This
+dependency can be retrieved through pkg-config, see:
+https://github.com/google/snappy/pull/51
+
+Fixes:
+ - http://autobuild.buildroot.org/results/faa65da84ace974426e220205f4665fc0a73bdfe
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ cmake/modules/FindSNAPPY.cmake | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/cmake/modules/FindSNAPPY.cmake b/cmake/modules/FindSNAPPY.cmake
+index 7964c9d145..93fdb2bc33 100644
+--- a/cmake/modules/FindSNAPPY.cmake
++++ b/cmake/modules/FindSNAPPY.cmake
+@@ -13,7 +13,7 @@ FindWSWinLibs( "snappy-.*" "SNAPPY_HINTS" )
+ 
+ if( NOT WIN32)
+   find_package(PkgConfig)
+-  pkg_search_module(SNAPPY libsnappy)
++  pkg_search_module(SNAPPY libsnappy snappy)
+ endif()
+ 
+ find_path(SNAPPY_INCLUDE_DIR
+@@ -36,7 +36,11 @@ find_package_handle_standard_args( SNAPPY DEFAULT_MSG SNAPPY_LIBRARY SNAPPY_INCL
+ 
+ if( SNAPPY_FOUND )
+   set( SNAPPY_INCLUDE_DIRS ${SNAPPY_INCLUDE_DIR} )
+-  set( SNAPPY_LIBRARIES ${SNAPPY_LIBRARY} )
++  # If pkg-config is available on the system and snappy .pc files are installed,
++  # SNAPPY_LIBRARIES will already contain transitive dependencies such as
++  # -lstdc++ for static linking
++  list( APPEND SNAPPY_LIBRARIES ${SNAPPY_LIBRARY} )
++
+   if (WIN32)
+     set ( SNAPPY_DLL_DIR "${SNAPPY_HINTS}/bin"
+       CACHE PATH "Path to Snappy DLL"
+-- 
+2.20.1
+
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc
  2019-05-29 17:29 [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc Fabrice Fontaine
  2019-05-29 17:29 ` [Buildroot] [PATCH 2/2] package/wireshark: fix static build with snappy Fabrice Fontaine
@ 2019-12-20 14:00 ` Giulio Benetti
  2019-12-20 14:14   ` Giulio Benetti
  1 sibling, 1 reply; 6+ messages in thread
From: Giulio Benetti @ 2019-12-20 14:00 UTC (permalink / raw)
  To: buildroot

Hi Fabrice,

On 5/29/19 7:29 PM, Fabrice Fontaine wrote:
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
>   .../snappy/0001-Readd-pkgconfig-support.patch | 56 +++++++++++++++++++
>   1 file changed, 56 insertions(+)
>   create mode 100644 package/snappy/0001-Readd-pkgconfig-support.patch
> 
> diff --git a/package/snappy/0001-Readd-pkgconfig-support.patch b/package/snappy/0001-Readd-pkgconfig-support.patch
> new file mode 100644
> index 0000000000..f27df9c8e8
> --- /dev/null
> +++ b/package/snappy/0001-Readd-pkgconfig-support.patch
> @@ -0,0 +1,56 @@
> +From e2c4ae93c6f57a80a71bdcff309006efccd30f42 Mon Sep 17 00:00:00 2001
> +From: Niclas Rosenvik <youremailsarecrap@gmail.com>
> +Date: Fri, 4 Aug 2017 12:33:18 +0200
> +Subject: [PATCH] Readd pkgconfig support.
> +
> +Readd pkgconfig support to support usage of snappy with other build systems.
> +
> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> +[Retrieved (and updated to add Libs.private) from:
> +https://github.com/google/snappy/pull/51/commits/e2c4ae93c6f57a80a71bdcff309006efccd30f42]
> +---
> + CMakeLists.txt     |  6 ++++++
> + cmake/snappy.pc.in | 10 ++++++++++
> + 2 files changed, 16 insertions(+)
> + create mode 100644 cmake/snappy.pc.in
> +
> +diff --git a/CMakeLists.txt b/CMakeLists.txt
> +index e9e70c8..7a8dab4 100644
> +--- a/CMakeLists.txt
> ++++ b/CMakeLists.txt
> +@@ -54,6 +54,11 @@ configure_file(
> +   "${PROJECT_SOURCE_DIR}/cmake/config.h.in"
> +   "${PROJECT_BINARY_DIR}/config.h"
> + )
> ++configure_file(
> ++  "${PROJECT_SOURCE_DIR}/cmake/snappy.pc.in"
> ++  "${PROJECT_BINARY_DIR}/snappy.pc"
> ++  @ONLY
> ++)
> +
> + # We don't want to define HAVE_ macros in public headers. Instead, we use
> + # CMake's variable substitution with 0/1 variables, which will be seen by the
> +@@ -165,3 +170,4 @@ install(
> +     "${PROJECT_BINARY_DIR}/SnappyConfigVersion.cmake"
> +   DESTINATION lib/cmake/Snappy
> + )
> ++install(FILES "${PROJECT_BINARY_DIR}/snappy.pc" DESTINATION lib/pkgconfig)
> +\ No newline at end of file

No newline,

> +diff --git a/cmake/snappy.pc.in b/cmake/snappy.pc.in
> +new file mode 100644
> +index 0000000..6c43545
> +--- /dev/null
> ++++ b/cmake/snappy.pc.in
> +@@ -0,0 +1,10 @@
> ++prefix=@CMAKE_INSTALL_PREFIX@
> ++exec_prefix=${prefix}
> ++libdir=${exec_prefix}/lib
> ++includedir=${prefix}/include
> ++
> ++Name: @PROJECT_NAME@
> ++Description: A fast compression/decompression library
> ++Version: @PROJECT_VERSION@
> ++Libs: -L${libdir} -lsnappy
> ++Libs.private: -lstdc++
> ++Cflags: -I${includedir}
> +\ No newline at end of file

No newline

And, what is the goal of this patch? Does it fix a bug? I see that only 
few packages provide a .pc file that is useful for pkgconfig to retrieve 
libs/incs paths for shared/static libs deps, but can you please provide 
a commit log about this? If it's not needed by any other package as 
dependency or there is not a specific reason I would avoid it.

Best regards
-- 
Giulio Benetti
Benetti Engineering sas

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc
  2019-12-20 14:00 ` [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc Giulio Benetti
@ 2019-12-20 14:14   ` Giulio Benetti
  2019-12-20 14:27     ` Giulio Benetti
  0 siblings, 1 reply; 6+ messages in thread
From: Giulio Benetti @ 2019-12-20 14:14 UTC (permalink / raw)
  To: buildroot

Hi Fabrice,

On 12/20/19 3:00 PM, Giulio Benetti wrote:
> Hi Fabrice,
> 
> On 5/29/19 7:29 PM, Fabrice Fontaine wrote:
>> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
>> ---
>>    .../snappy/0001-Readd-pkgconfig-support.patch | 56 +++++++++++++++++++
>>    1 file changed, 56 insertions(+)
>>    create mode 100644 package/snappy/0001-Readd-pkgconfig-support.patch
>>
>> diff --git a/package/snappy/0001-Readd-pkgconfig-support.patch b/package/snappy/0001-Readd-pkgconfig-support.patch
>> new file mode 100644
>> index 0000000000..f27df9c8e8
>> --- /dev/null
>> +++ b/package/snappy/0001-Readd-pkgconfig-support.patch
>> @@ -0,0 +1,56 @@
>> +From e2c4ae93c6f57a80a71bdcff309006efccd30f42 Mon Sep 17 00:00:00 2001
>> +From: Niclas Rosenvik <youremailsarecrap@gmail.com>
>> +Date: Fri, 4 Aug 2017 12:33:18 +0200
>> +Subject: [PATCH] Readd pkgconfig support.
>> +
>> +Readd pkgconfig support to support usage of snappy with other build systems.
>> +
>> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
>> +[Retrieved (and updated to add Libs.private) from:
>> +https://github.com/google/snappy/pull/51/commits/e2c4ae93c6f57a80a71bdcff309006efccd30f42]
>> +---
>> + CMakeLists.txt     |  6 ++++++
>> + cmake/snappy.pc.in | 10 ++++++++++
>> + 2 files changed, 16 insertions(+)
>> + create mode 100644 cmake/snappy.pc.in
>> +
>> +diff --git a/CMakeLists.txt b/CMakeLists.txt
>> +index e9e70c8..7a8dab4 100644
>> +--- a/CMakeLists.txt
>> ++++ b/CMakeLists.txt
>> +@@ -54,6 +54,11 @@ configure_file(
>> +   "${PROJECT_SOURCE_DIR}/cmake/config.h.in"
>> +   "${PROJECT_BINARY_DIR}/config.h"
>> + )
>> ++configure_file(
>> ++  "${PROJECT_SOURCE_DIR}/cmake/snappy.pc.in"
>> ++  "${PROJECT_BINARY_DIR}/snappy.pc"
>> ++  @ONLY
>> ++)
>> +
>> + # We don't want to define HAVE_ macros in public headers. Instead, we use
>> + # CMake's variable substitution with 0/1 variables, which will be seen by the
>> +@@ -165,3 +170,4 @@ install(
>> +     "${PROJECT_BINARY_DIR}/SnappyConfigVersion.cmake"
>> +   DESTINATION lib/cmake/Snappy
>> + )
>> ++install(FILES "${PROJECT_BINARY_DIR}/snappy.pc" DESTINATION lib/pkgconfig)
>> +\ No newline at end of file
> 
> No newline,
> 
>> +diff --git a/cmake/snappy.pc.in b/cmake/snappy.pc.in
>> +new file mode 100644
>> +index 0000000..6c43545
>> +--- /dev/null
>> ++++ b/cmake/snappy.pc.in
>> +@@ -0,0 +1,10 @@
>> ++prefix=@CMAKE_INSTALL_PREFIX@
>> ++exec_prefix=${prefix}
>> ++libdir=${exec_prefix}/lib
>> ++includedir=${prefix}/include
>> ++
>> ++Name: @PROJECT_NAME@
>> ++Description: A fast compression/decompression library
>> ++Version: @PROJECT_VERSION@
>> ++Libs: -L${libdir} -lsnappy
>> ++Libs.private: -lstdc++
>> ++Cflags: -I${includedir}
>> +\ No newline at end of file
> 
> No newline
> 
> And, what is the goal of this patch? Does it fix a bug? I see that only
> few packages provide a .pc file that is useful for pkgconfig to retrieve
> libs/incs paths for shared/static libs deps, but can you please provide
> a commit log about this? If it's not needed by any other package as
> dependency or there is not a specific reason I would avoid it.

I've realized only now that this is part of a patchset and is needed to 
fix wireshark build failure. Sorry.

-- 
Giulio Benetti
Benetti Engineering sas

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc
  2019-12-20 14:14   ` Giulio Benetti
@ 2019-12-20 14:27     ` Giulio Benetti
  0 siblings, 0 replies; 6+ messages in thread
From: Giulio Benetti @ 2019-12-20 14:27 UTC (permalink / raw)
  To: buildroot

Hi Fabrice,

On 12/20/19 3:14 PM, Giulio Benetti wrote:
> Hi Fabrice,
> 
> On 12/20/19 3:00 PM, Giulio Benetti wrote:
>> Hi Fabrice,
>>
>> On 5/29/19 7:29 PM, Fabrice Fontaine wrote:
>>> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
>>> ---
>>>     .../snappy/0001-Readd-pkgconfig-support.patch | 56 +++++++++++++++++++
>>>     1 file changed, 56 insertions(+)
>>>     create mode 100644 package/snappy/0001-Readd-pkgconfig-support.patch
>>>
>>> diff --git a/package/snappy/0001-Readd-pkgconfig-support.patch b/package/snappy/0001-Readd-pkgconfig-support.patch
>>> new file mode 100644
>>> index 0000000000..f27df9c8e8
>>> --- /dev/null
>>> +++ b/package/snappy/0001-Readd-pkgconfig-support.patch
>>> @@ -0,0 +1,56 @@
>>> +From e2c4ae93c6f57a80a71bdcff309006efccd30f42 Mon Sep 17 00:00:00 2001
>>> +From: Niclas Rosenvik <youremailsarecrap@gmail.com>
>>> +Date: Fri, 4 Aug 2017 12:33:18 +0200
>>> +Subject: [PATCH] Readd pkgconfig support.
>>> +
>>> +Readd pkgconfig support to support usage of snappy with other build systems.
>>> +
>>> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
>>> +[Retrieved (and updated to add Libs.private) from:
>>> +https://github.com/google/snappy/pull/51/commits/e2c4ae93c6f57a80a71bdcff309006efccd30f42]
>>> +---
>>> + CMakeLists.txt     |  6 ++++++
>>> + cmake/snappy.pc.in | 10 ++++++++++
>>> + 2 files changed, 16 insertions(+)
>>> + create mode 100644 cmake/snappy.pc.in
>>> +
>>> +diff --git a/CMakeLists.txt b/CMakeLists.txt
>>> +index e9e70c8..7a8dab4 100644
>>> +--- a/CMakeLists.txt
>>> ++++ b/CMakeLists.txt
>>> +@@ -54,6 +54,11 @@ configure_file(
>>> +   "${PROJECT_SOURCE_DIR}/cmake/config.h.in"
>>> +   "${PROJECT_BINARY_DIR}/config.h"
>>> + )
>>> ++configure_file(
>>> ++  "${PROJECT_SOURCE_DIR}/cmake/snappy.pc.in"
>>> ++  "${PROJECT_BINARY_DIR}/snappy.pc"
>>> ++  @ONLY
>>> ++)
>>> +
>>> + # We don't want to define HAVE_ macros in public headers. Instead, we use
>>> + # CMake's variable substitution with 0/1 variables, which will be seen by the
>>> +@@ -165,3 +170,4 @@ install(
>>> +     "${PROJECT_BINARY_DIR}/SnappyConfigVersion.cmake"
>>> +   DESTINATION lib/cmake/Snappy
>>> + )
>>> ++install(FILES "${PROJECT_BINARY_DIR}/snappy.pc" DESTINATION lib/pkgconfig)
>>> +\ No newline at end of file
>>
>> No newline,
>>
>>> +diff --git a/cmake/snappy.pc.in b/cmake/snappy.pc.in
>>> +new file mode 100644
>>> +index 0000000..6c43545
>>> +--- /dev/null
>>> ++++ b/cmake/snappy.pc.in
>>> +@@ -0,0 +1,10 @@
>>> ++prefix=@CMAKE_INSTALL_PREFIX@
>>> ++exec_prefix=${prefix}
>>> ++libdir=${exec_prefix}/lib
>>> ++includedir=${prefix}/include
>>> ++
>>> ++Name: @PROJECT_NAME@
>>> ++Description: A fast compression/decompression library
>>> ++Version: @PROJECT_VERSION@
>>> ++Libs: -L${libdir} -lsnappy
>>> ++Libs.private: -lstdc++
>>> ++Cflags: -I${includedir}
>>> +\ No newline at end of file
>>
>> No newline
>>
>> And, what is the goal of this patch? Does it fix a bug? I see that only
>> few packages provide a .pc file that is useful for pkgconfig to retrieve
>> libs/incs paths for shared/static libs deps, but can you please provide
>> a commit log about this? If it's not needed by any other package as
>> dependency or there is not a specific reason I would avoid it.
> 
> I've realized only now that this is part of a patchset and is needed to
> fix wireshark build failure. Sorry.

I've tested it with wireshark's 2/2 patch on its build failure and it 
builds correctly, so:

Reviewed-by: Giulio Benetti <giulio.benetti@benettiengineering.com>

Best regards
-- 
Giulio Benetti
Benetti Engineering sas

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 2/2] package/wireshark: fix static build with snappy
  2019-05-29 17:29 ` [Buildroot] [PATCH 2/2] package/wireshark: fix static build with snappy Fabrice Fontaine
@ 2019-12-20 14:28   ` Giulio Benetti
  0 siblings, 0 replies; 6+ messages in thread
From: Giulio Benetti @ 2019-12-20 14:28 UTC (permalink / raw)
  To: buildroot

Hi Fabrice,

On 5/29/19 7:29 PM, Fabrice Fontaine wrote:
> Fixes:
>   - http://autobuild.buildroot.org/results/419468f0d7d3c2b64d420513aa9505c6de097ed2
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
>   .../0005-FindSNAPPY-fix-static-build.patch    | 46 +++++++++++++++++++
>   1 file changed, 46 insertions(+)
>   create mode 100644 package/wireshark/0005-FindSNAPPY-fix-static-build.patch
> 
> diff --git a/package/wireshark/0005-FindSNAPPY-fix-static-build.patch b/package/wireshark/0005-FindSNAPPY-fix-static-build.patch
> new file mode 100644
> index 0000000000..ba528cf01a
> --- /dev/null
> +++ b/package/wireshark/0005-FindSNAPPY-fix-static-build.patch
> @@ -0,0 +1,46 @@
> +From 4abe51deee1ed3daffa9042ab41ed0622856c69c Mon Sep 17 00:00:00 2001
> +From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> +Date: Tue, 28 May 2019 21:18:09 +0200
> +Subject: [PATCH] FindSNAPPY: fix static build
> +
> +On UNIX, when statically built, snappy can depends on stdc++. This
> +dependency can be retrieved through pkg-config, see:
> +https://github.com/google/snappy/pull/51
> +
> +Fixes:
> + - http://autobuild.buildroot.org/results/faa65da84ace974426e220205f4665fc0a73bdfe
> +
> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> +---
> + cmake/modules/FindSNAPPY.cmake | 8 ++++++--
> + 1 file changed, 6 insertions(+), 2 deletions(-)
> +
> +diff --git a/cmake/modules/FindSNAPPY.cmake b/cmake/modules/FindSNAPPY.cmake
> +index 7964c9d145..93fdb2bc33 100644
> +--- a/cmake/modules/FindSNAPPY.cmake
> ++++ b/cmake/modules/FindSNAPPY.cmake
> +@@ -13,7 +13,7 @@ FindWSWinLibs( "snappy-.*" "SNAPPY_HINTS" )
> +
> + if( NOT WIN32)
> +   find_package(PkgConfig)
> +-  pkg_search_module(SNAPPY libsnappy)
> ++  pkg_search_module(SNAPPY libsnappy snappy)
> + endif()
> +
> + find_path(SNAPPY_INCLUDE_DIR
> +@@ -36,7 +36,11 @@ find_package_handle_standard_args( SNAPPY DEFAULT_MSG SNAPPY_LIBRARY SNAPPY_INCL
> +
> + if( SNAPPY_FOUND )
> +   set( SNAPPY_INCLUDE_DIRS ${SNAPPY_INCLUDE_DIR} )
> +-  set( SNAPPY_LIBRARIES ${SNAPPY_LIBRARY} )
> ++  # If pkg-config is available on the system and snappy .pc files are installed,
> ++  # SNAPPY_LIBRARIES will already contain transitive dependencies such as
> ++  # -lstdc++ for static linking
> ++  list( APPEND SNAPPY_LIBRARIES ${SNAPPY_LIBRARY} )
> ++
> +   if (WIN32)
> +     set ( SNAPPY_DLL_DIR "${SNAPPY_HINTS}/bin"
> +       CACHE PATH "Path to Snappy DLL"
> +--
> +2.20.1
> +
> 

Reviewed-by: Giulio Benetti <giulio.benetti@benettiengineering.com>

Best regards
-- 
Giulio Benetti
Benetti Engineering sas

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-12-20 14:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-29 17:29 [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc Fabrice Fontaine
2019-05-29 17:29 ` [Buildroot] [PATCH 2/2] package/wireshark: fix static build with snappy Fabrice Fontaine
2019-12-20 14:28   ` Giulio Benetti
2019-12-20 14:00 ` [Buildroot] [PATCH 1/2] package/snappy: add snappy.pc Giulio Benetti
2019-12-20 14:14   ` Giulio Benetti
2019-12-20 14:27     ` Giulio Benetti

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.