add notes for building on Alpine

This commit is contained in:
2024-01-26 07:34:34 -08:00
committed by Scott Alfter
parent 343431bcb4
commit 00753313ac
2 changed files with 20 additions and 0 deletions

View File

@@ -52,3 +52,7 @@ ENV{ID_SERIAL}=="?*", SYMLINK+="lp/printers/$env{ID_BUS}-$env{ID_SERIAL}"
LABEL="persistent_printer_end" LABEL="persistent_printer_end"
``` ```
extra steps for building on Alpine Linux:
```doas apk add gcc musl-dev autoconf make patch && patch -p0 <lp_server-no-glibc.patch```

16
lp_server-no-glibc.patch Normal file
View File

@@ -0,0 +1,16 @@
patch to enable compilation on systems that don't use glibc, such as Alpine
--- src/stty.c
+++ src/stty.c
@@ -34,6 +34,12 @@
extern int errorcode;
+#if !defined(EXTA)
+#define EXTA B19200
+#endif
+#if !defined(EXTB)
+#define EXTB B38400
+#endif
#if USE_STTY == SGTTYB