[hackers] [slstatus] Makefile: move OS-specific libs to configure script || Quentin Rameau
commit 2ea3d46f1341716daa1370f0f19d1fc571c3e63a
Author: Quentin Rameau <quinq_AT_fifth.space>
AuthorDate: Mon Apr 30 16:13:12 2018 +0200
Commit: Aaron Marcher <me_AT_drkhsh.at>
CommitDate: Mon Apr 30 16:27:07 2018 +0200
Makefile: move OS-specific libs to configure script
diff --git a/Makefile b/Makefile
index a2c49c8..e046597 100644
--- a/Makefile
+++ b/Makefile
_AT_@ -29,7 +29,7 @@ COM =\
SLSCFLAGS = -I$(X11INC) -D_DEFAULT_SOURCE $(CFLAGS)
SLSLDFLAGS = -L$(X11LIB) $(LDFLAGS)
-SLSLIBS = -lX11 $(OSSLIBS) $(LIBS)
+SLSLIBS = -lX11 $(OSLIBS) $(LIBS)
all: slstatus
diff --git a/config.mk b/config.mk
index bb2324f..6fbf696 100644
--- a/config.mk
+++ b/config.mk
_AT_@ -10,9 +10,6 @@ MANPREFIX = ${PREFIX}/share/man
X11INC = /usr/X11R6/include
X11LIB = /usr/X11R6/lib
-# OpenBSD (uncomment)
-#OSSLIBS = -lossaudio
-
# flags
CFLAGS = -std=c99 -pedantic -Wall -Wextra -Os
LDFLAGS = -s
diff --git a/configure b/configure
index ee57a7f..2a510c7 100755
--- a/configure
+++ b/configure
_AT_@ -1,3 +1,10 @@
#!/bin/sh
-printf 'OS = %s\n' "$(uname)" > os.mk
+os="$(uname)"
+
+printf 'OS = %s\n' "$os" > os.mk
+
+if [ "$os" = "OpenBSD" ]
+then
+ printf 'OSLIBS = -lossaudio\n' >> os.mk
+fi
Received on Mon Apr 30 2018 - 16:30:20 CEST
This archive was generated by hypermail 2.3.0
: Mon Apr 30 2018 - 16:36:47 CEST