File: use-system-libzstd.patch

package info (click to toggle)
golang-github-valyala-gozstd 1.17.0%2Bds1-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 280 kB
  • sloc: makefile: 77
file content (77 lines) | stat: -rw-r--r-- 1,523 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
Description: Use system libzstd
Author: Guillem Jover <gjover@sipwise.com>
Origin: other, Sipwise
Forwarded: no
Last-Update: 2020-12-26

---
 dict.go    |    4 ++--
 gozstd.go  |    4 ++--
 libzstd.go |    6 ++++++
 reader.go  |    4 ++--
 writer.go  |    4 ++--
 5 files changed, 14 insertions(+), 8 deletions(-)

--- a/dict.go
+++ b/dict.go
@@ -4,10 +4,10 @@ package gozstd
 #cgo CFLAGS: -O3
 
 #define ZSTD_STATIC_LINKING_ONLY
-#include "zstd.h"
+#include <zstd.h>
 
 #define ZDICT_STATIC_LINKING_ONLY
-#include "zdict.h"
+#include <zdict.h>
 
 #include <stdint.h>  // for uintptr_t
 
--- a/gozstd.go
+++ b/gozstd.go
@@ -4,8 +4,8 @@ package gozstd
 #cgo CFLAGS: -O3
 
 #define ZSTD_STATIC_LINKING_ONLY
-#include "zstd.h"
-#include "zstd_errors.h"
+#include <zstd.h>
+#include <zstd_errors.h>
 
 #include <stdint.h>  // for uintptr_t
 
--- a/reader.go
+++ b/reader.go
@@ -4,8 +4,8 @@ package gozstd
 #cgo CFLAGS: -O3
 
 #define ZSTD_STATIC_LINKING_ONLY
-#include "zstd.h"
-#include "zstd_errors.h"
+#include <zstd.h>
+#include <zstd_errors.h>
 
 #include <stdlib.h>  // for malloc/free
 #include <stdint.h>  // for uintptr_t
--- a/writer.go
+++ b/writer.go
@@ -4,8 +4,8 @@ package gozstd
 #cgo CFLAGS: -O3
 
 #define ZSTD_STATIC_LINKING_ONLY
-#include "zstd.h"
-#include "zstd_errors.h"
+#include <zstd.h>
+#include <zstd_errors.h>
 
 #include <stdlib.h>  // for malloc/free
 #include <stdint.h>  // for uintptr_t
--- /dev/null
+++ b/libzstd.go
@@ -0,0 +1,6 @@
+package gozstd
+
+/*
+#cgo LDFLAGS: -lzstd
+*/
+import "C"