aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2013-01-03 15:22:14 -0500
committerDave Reisner <dreisner@archlinux.org>2013-01-03 15:22:14 -0500
commit648525dc88eb37f102ae588ad152b1ff7c18b9c8 (patch)
tree05624fbe8f928194e81a7f0fb88fb04ef13122bd /Makefile
parentd5eeab41f026d97b25efe00e3df9d7ee75e8d04a (diff)
parent270910b82218a840b99b72859b308451c73c5c1b (diff)
downloadmirror-ponymix-648525dc88eb37f102ae588ad152b1ff7c18b9c8.tar.gz
mirror-ponymix-648525dc88eb37f102ae588ad152b1ff7c18b9c8.tar.bz2
mirror-ponymix-648525dc88eb37f102ae588ad152b1ff7c18b9c8.zip
Merge remote-tracking branch 'pwnymix/master'
* pwnymix/master: (25 commits) show description in list-short properly clamp values in Set{Balance,Volume} resolve the card choice as late as possible allow card lookup by index Cleanup manpage, reintroduce application commands section add manpage reorg usage output remove defunct enum implement -short variations of list verbs A dash of color... fix abort on set-profile after removing profile whitespace police remove string_to_device; PulseClient can do this now always defined behaviors for devices Derive the card from the targetted device ponymix: validate arg count before invoking function rename class Pulse to PulseClient makefile: CFLAGS -> CXXFLAGS eschew _unused_ attribute alias sane types to --device flags ... Conflicts: Makefile ponymix.1
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile29
1 files changed, 21 insertions, 8 deletions
diff --git a/Makefile b/Makefile
index a6b89f2..b41b05c 100644
--- a/Makefile
+++ b/Makefile
@@ -1,15 +1,28 @@
-CC = gcc -std=gnu99
-CFLAGS := -Wall -Wextra -pedantic -O2 -g -D_REENTRANT $(CFLAGS)
-LDLIBS := -lpulse -lm
+CXX = g++ -std=c++11
-ponymix: ponymix.o
+base_CXXFLAGS = -Wall -Wextra -pedantic -O2 -g
+base_LIBS = -lm
+
+libpulse_CXXFLAGS = $(shell pkg-config --cflags libpulse)
+libpulse_LIBS = $(shell pkg-config --libs libpulse)
+
+CXXFLAGS := \
+ $(base_CXXFLAGS) \
+ $(libpulse_CXXFLAGS) \
+ $(CXXFLAGS)
+
+LDLIBS := \
+ $(base_LIBS) \
+ $(libpulse_LIBS)
+
+all: ponymix
+
+ponymix: ponymix.cc pulse.o
+pulse.o: pulse.cc pulse.h
install: ponymix
install -Dm755 ponymix $(DESTDIR)/usr/bin/ponymix
install -Dm644 ponymix.1 $(DESTDIR)/usr/share/man/man1/ponymix.1
-check: ponymix
- ./runtests ./ponymix
-
clean:
- $(RM) ponymix ponymix.o
+ $(RM) ponymix pulse.o