summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorphintuka <phintuka>2008-04-02 20:17:24 +0000
committerphintuka <phintuka>2008-04-02 20:17:24 +0000
commit472c6349f3e3e5369ac36e6952756f716f21fd8a (patch)
tree8bbda7d7437f5bcb751caabede1074f73d7f4651
parentd269947498145585d058abe6f9de985d85a4a5b4 (diff)
downloadxineliboutput-472c6349f3e3e5369ac36e6952756f716f21fd8a.tar.gz
xineliboutput-472c6349f3e3e5369ac36e6952756f716f21fd8a.tar.bz2
Reduce number of build-time configuration test runs
(tests are now executed only once)
-rw-r--r--Makefile28
1 files changed, 17 insertions, 11 deletions
diff --git a/Makefile b/Makefile
index 69f36e6e..f60b001f 100644
--- a/Makefile
+++ b/Makefile
@@ -4,7 +4,7 @@
# See the main source file 'xineliboutput.c' for copyright information and
# how to reach the author.
#
-# $Id: Makefile,v 1.32 2008-04-01 14:18:13 phintuka Exp $
+# $Id: Makefile,v 1.33 2008-04-02 20:17:24 phintuka Exp $
#
# The official name of this plugin.
@@ -23,18 +23,22 @@ XINELIBOUTPUT_FB = 0
XINELIBOUTPUT_X11 = 0
HAVE_XRENDER = 0
HAVE_EXTRACTOR_H = 0
-XINELIBOUTPUT_XINEPLUGIN = $(shell (pkg-config libxine && echo 1 || echo 0))
-ifeq ($(XINELIBOUTPUT_XINEPLUGIN), 0)
- XINELIBOUTPUT_XINEPLUGIN = $(shell (xine-config --cflags >/dev/null 2>&1 && echo "1") || echo "0")
+APPLE_DARWIN = 0
+XINELIBOUTPUT_XINEPLUGIN = 0
+ifeq ($(shell (pkg-config libxine && echo 1 || echo 0)), 1)
+ XINELIBOUTPUT_XINEPLUGIN = 1
+else
+ ifeq ($(shell (xine-config --cflags >/dev/null 2>&1 && echo "1") || echo "0"), 1)
+ XINELIBOUTPUT_XINEPLUGIN = 1
+ endif
endif
ifeq ($(XINELIBOUTPUT_XINEPLUGIN), 1)
XINELIBOUTPUT_FB = $(XINELIBOUTPUT_XINEPLUGIN)
- XINELIBOUTPUT_X11 = $(shell (((echo "\#include <X11/Xlib.h>";echo "int main(int c,char* v[]) {return 0;}") > testx.c && gcc -c testx.c -o testx.o >/dev/null 2>&1) && echo "1") || echo "0" ; rm -f testx.* >/dev/null)
-
- ifeq ($(XINELIBOUTPUT_X11), 1)
- #$(warning Detected X11)
- HAVE_XRENDER = $(shell (((echo "\#include <X11/extensions/Xrender.h>";echo "int main(int c,char* v[]) {return 0;}") > testx.c && gcc -c testx.c -o testx.o >/dev/null 2>&1) && echo "1") || echo "0" ; rm -f testx.* >/dev/null)
- ifeq ($(HAVE_XRENDER), 0)
+ ifeq ($(shell (((echo "\#include <X11/Xlib.h>";echo "int main(int c,char* v[]) {return 0;}") > testx.c && gcc -c testx.c -o testx.o >/dev/null 2>&1) && echo "1") || echo "0" ; rm -f testx.* >/dev/null), 1)
+ XINELIBOUTPUT_X11 = 1
+ ifeq ($(shell (((echo "\#include <X11/extensions/Xrender.h>";echo "int main(int c,char* v[]) {return 0;}") > testx.c && gcc -c testx.c -o testx.o >/dev/null 2>&1) && echo "1") || echo "0" ; rm -f testx.* >/dev/null), 1)
+ HAVE_XRENDER = 1
+ else
$(warning ********************************************************)
$(warning XRender extension not detected ! HUD OSD disabled. )
$(warning ********************************************************)
@@ -50,7 +54,9 @@ else
$(warning ********************************************************)
endif
-APPLE_DARWIN = $(shell gcc -dumpmachine | grep -q 'apple-darwin' && echo "1" || echo "0")
+ifeq ($(shell gcc -dumpmachine | grep -q 'apple-darwin' && echo "1" || echo "0"), 1)
+ APPLE_DARWIN = 1
+endif
#
# Override configuration here or in ../../../Make.config