Blame


1 dd038bc6 2021-09-21 thomas.ad noinst_LIBRARIES = libopenbsd-compat.a
2 dd038bc6 2021-09-21 thomas.ad
3 0ca5b679 2021-10-09 thomas include $(top_builddir)/Makefile.common
4 dd038bc6 2021-09-21 thomas.ad
5 dd038bc6 2021-09-21 thomas.ad libopenbsd_compat_a_SOURCES = \
6 dd038bc6 2021-09-21 thomas.ad asprintf.c \
7 dd038bc6 2021-09-21 thomas.ad base64.c \
8 dd038bc6 2021-09-21 thomas.ad fmt_scaled.c \
9 dd038bc6 2021-09-21 thomas.ad freezero.c \
10 dd038bc6 2021-09-21 thomas.ad getdtablecount.c \
11 dd038bc6 2021-09-21 thomas.ad getopt.c \
12 dd038bc6 2021-09-21 thomas.ad getprogname.c \
13 dd038bc6 2021-09-21 thomas.ad merge.c \
14 dd038bc6 2021-09-21 thomas.ad reallocarray.c \
15 dd038bc6 2021-09-21 thomas.ad recallocarray.c \
16 dd038bc6 2021-09-21 thomas.ad strndup.c \
17 dd038bc6 2021-09-21 thomas.ad strnlen.c \
18 dd038bc6 2021-09-21 thomas.ad strsep.c \
19 dd038bc6 2021-09-21 thomas.ad strtonum.c \
20 dd514345 2021-09-21 thomas.ad imsg.h \
21 dd514345 2021-09-21 thomas.ad tree.h
22 d24ddaa6 2022-02-26 thomas
23 d24ddaa6 2022-02-26 thomas # For MacOS, don't build the compat versions of strl{cat,cpy}, but do for all
24 d24ddaa6 2022-02-26 thomas # other systems.
25 d24ddaa6 2022-02-26 thomas if !HOST_DARWIN
26 d24ddaa6 2022-02-26 thomas libopenbsd_compat_a_SOURCES += strlcat.c strlcpy.c
27 d24ddaa6 2022-02-26 thomas endif
28 d24ddaa6 2022-02-26 thomas
29 d24ddaa6 2022-02-26 thomas if HOST_DARWIN
30 d24ddaa6 2022-02-26 thomas libopenbsd_compat_a_SOURCES += uuid.c bsd-poll.c bsd-poll.h
31 d24ddaa6 2022-02-26 thomas endif
32 d24ddaa6 2022-02-26 thomas
33 4fccd2fe 2023-03-08 thomas if !HAVE_CLOSEFROM
34 4fccd2fe 2023-03-08 thomas libopenbsd_compat_a_SOURCES += closefrom.c
35 4fccd2fe 2023-03-08 thomas endif
36 4fccd2fe 2023-03-08 thomas
37 a3732bb6 2022-02-26 thomas if HOST_NETBSD
38 a3732bb6 2022-02-26 thomas libopenbsd_compat_a_SOURCES += bsd-poll.c bsd-poll.h
39 a3732bb6 2022-02-26 thomas endif
40 a3732bb6 2022-02-26 thomas
41 d24ddaa6 2022-02-26 thomas if HOST_LINUX
42 92a9e85d 2021-09-24 thomas libopenbsd_compat_a_SOURCES += uuid.c
43 92a9e85d 2021-09-24 thomas endif
44 dd038bc6 2021-09-21 thomas.ad
45 97799ccd 2022-02-06 thomas if HAVE_LINUX_LANDLOCK
46 97799ccd 2022-02-06 thomas libopenbsd_compat_a_SOURCES += landlock.c
47 97799ccd 2022-02-06 thomas endif
48 97799ccd 2022-02-06 thomas
49 ddd12270 2022-04-22 thomas if !HAVE_SIPHASH
50 ddd12270 2022-04-22 thomas libopenbsd_compat_a_SOURCES += siphash.c siphash.h
51 ddd12270 2022-04-22 thomas endif
52 ddd12270 2022-04-22 thomas
53 c4e2e0d0 2022-07-16 thomas if !HAVE_SETPROCTITLE
54 c4e2e0d0 2022-07-16 thomas libopenbsd_compat_a_SOURCES += setproctitle.c
55 c4e2e0d0 2022-07-16 thomas endif
56 c4e2e0d0 2022-07-16 thomas
57 f600ad76 2023-01-06 thomas if !HAVE_IMSG
58 f600ad76 2023-01-06 thomas libopenbsd_compat_a_SOURCES += imsg-buffer.c imsg.c
59 f600ad76 2023-01-06 thomas endif
60 f600ad76 2023-01-06 thomas
61 b1ec8cee 2023-02-25 thomas if !HOST_DARWIN
62 b1ec8cee 2023-02-25 thomas # Fake an assigment here. It does nothing, but you cannot have consecutive
63 b1ec8cee 2023-02-25 thomas # nested if statements in Makefiles, so we have to do something here, even if
64 b1ec8cee 2023-02-25 thomas # it's a dummy assignment.
65 b1ec8cee 2023-02-25 thomas NOTING=something
66 b1ec8cee 2023-02-25 thomas if !HAVE_SHA2
67 b1ec8cee 2023-02-25 thomas libopenbsd_compat_a_SOURCES += sha2.c sha2.h
68 b1ec8cee 2023-02-25 thomas endif
69 b1ec8cee 2023-02-25 thomas endif
70 b1ec8cee 2023-02-25 thomas
71 4fccd2fe 2023-03-08 thomas LDADD = $(libbsd_LIBS)
72 4fccd2fe 2023-03-08 thomas AM_CPPFLAGS = $(libbsd_CFLAGS)
73 4fccd2fe 2023-03-08 thomas
74 dd038bc6 2021-09-21 thomas.ad EXTRA_DIST = \
75 dd038bc6 2021-09-21 thomas.ad $(top_srcdir)/include/got_compat.h \
76 dd038bc6 2021-09-21 thomas.ad imsg.h \
77 d24ddaa6 2022-02-26 thomas tree.h \
78 d24ddaa6 2022-02-26 thomas bsd-poll.h