summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorVille Skyttä <ville.skytta@iki.fi>2009-01-11 11:20:36 +0200
committerVille Skyttä <ville.skytta@iki.fi>2009-01-11 11:20:36 +0200
commit692099302d01b1b41884dcaed355601b45017691 (patch)
tree620cf978a9d209c3aca9aad17580a7424f81064a /Makefile
parentce4ed8350245ab26acf3ca568b23a614de25fe57 (diff)
downloadvdr-plugin-dxr3-692099302d01b1b41884dcaed355601b45017691.tar.gz
vdr-plugin-dxr3-692099302d01b1b41884dcaed355601b45017691.tar.bz2
Better defaults for FFmpeg and EM8300 in Makefile (#53).
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile22
1 files changed, 16 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 08dd57f..72f6505 100644
--- a/Makefile
+++ b/Makefile
@@ -23,8 +23,18 @@ CXXFLAGS = -O2 -Wall -Woverloaded-virtual
VDRDIR = ../../..
LIBDIR = ../../lib
TMPDIR = /tmp
-FFMDIR = /usr/local/include/ffmpeg
-EM8300 = /usr/include
+
+# Usually something like -I/path/to/ffmpeg, should work as is if FFmpeg was
+# installed properly and pkg-config is available.
+FFMPEG_INC = $(shell pkg-config --cflags-only-I libavcodec)
+
+# Usually something like -L/path/to/ffmpeg/libavcodec -lavcodec, should work
+# as is if FFmpeg was installed properly and pkg-config is available.
+FFMPEG_LIBS = $(shell pkg-config --libs libavcodec)
+
+# Usually something like -I/path/to/em8300/include,should work as is (empty)
+# if em8300 headers were installed properly.
+EM8300_INC =
### Allow user defined options to overwrite defaults:
@@ -41,10 +51,10 @@ PACKAGE = $(shell echo vdr-$(ARCHIVE) | sed -e 's/git$$/git'`date +%Y%m%d`/)
### Includes and Defines (add further entries here):
-INCLUDES += -I$(VDRDIR)/include -I$(FFMDIR) -I$(FFMDIR)/libavcodec -I$(EM8300)
-LIBS = -L$(FFMDIR)/libavcodec -lavcodec
-DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"'
-DEFINES += -D_GNU_SOURCE
+INCLUDES += -I$(VDRDIR)/include $(FFMPEG_INC) $(EM8300_INC)
+LIBS = $(FFMPEG_LIBS)
+DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"'
+DEFINES += -D_GNU_SOURCE
# where is the microcode for the dxr3 located? em8300 driver version 0.15.2
# and later installs it by default to /lib/firmware/em8300.bin, and earlier