File: 020_libbsd.patch

package info (click to toggle)
unworkable 0.53-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 552 kB
  • sloc: ansic: 6,093; python: 443; yacc: 319; makefile: 6
file content (27 lines) | stat: -rw-r--r-- 975 bytes parent folder | download | duplicates (2)
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
Description: Use libbsd instead of shipped openbsd-compat
 This deduplicates code we already have in libbsdat build- and run-time.
Author: Guillem Jover <guillem@debian.org>
Bug-Debian: http://bugs.debian.org/675077
Forwarded: not-needed
Origin: vendor, https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=675077
Last-Update: 2024-03-17
Reviewed-By: Michael Stapelberg <stapelberg@debian.org>

--- unworkable-0.53.orig/GNUmakefile
+++ unworkable-0.53/GNUmakefile
@@ -29,13 +29,9 @@ SRCS=announce.c bencode.c buf.c ctl_serv
 LIBS=-levent -lcrypto -lpthread
 UNAME=$(shell uname)
 ifneq (, $(filter Linux GNU GNU/%, $(UNAME)))
-SRCS+=openbsd-compat/strlcpy.c
-SRCS+=openbsd-compat/strlcat.c
 SRCS+=openbsd-compat/sha1.c
-SRCS+=openbsd-compat/strtonum.c
-CFLAGS+=-DNO_STRLCPY
-CFLAGS+=-DNO_STRLCAT
-CFLAGS+=-DNO_STRTONUM
+LIBS+=$(shell pkg-config --libs libbsd-overlay)
+CFLAGS+=$(shell pkg-config --cflags libbsd-overlay)
 else
 ifeq ($(UNAME),sunos)
 SRCS+=openbsd-compat/err.c