Skip to content

Commit 491224d

Browse files
committed
Fix compilation on FreeBSD
On FreeBSD, we need to set _XOPEN_SOURCE_EXTENDED (or __BSD_VISIBLE) to access everything we need.
1 parent ec32294 commit 491224d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ttyplot.c

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
// Apache License 2.0
88
//
99

10-
// This is needed on macOS to get the ncurses widechar API, and pkg-config fails to
11-
// define it.
12-
#ifdef __APPLE__
10+
// This is needed on FreeBSD and macOS to get the ncurses widechar API,
11+
// and pkg-config fails to define it.
12+
#if defined(__APPLE__) || defined(__FreeBSD__)
1313
#define _XOPEN_SOURCE_EXTENDED
1414
#else
1515
// This is needed for musl libc

0 commit comments

Comments
 (0)