fix prerequisites due to libc changes
[buildroot.git] / package / mplayer / mplayer.mk
blob0f7f19d7f4377c62edfad83fc1b167273ef23185
1 #############################################################
3 # mplayer
5 #############################################################
6 MPLAYER_VERSION:=1.0rc1
7 MPLAYER_SOURCE:=MPlayer-$(MPLAYER_VERSION).tar.bz2
8 MPLAYER_SITE:=http://www7.mplayerhq.hu/MPlayer/releases
9 MPLAYER_DIR:=$(BUILD_DIR)/MPlayer-$(MPLAYER_VERSION)
10 MPLAYER_CAT:=$(BZCAT)
11 MPLAYER_BINARY:=mplayer
12 MPLAYER_TARGET_BINARY:=usr/bin/$(MPLAYER_BINARY)
14 ifeq ($(BR2_ENDIAN),"BIG")
15 MPLAYER_ENDIAN:=--enable-big-endian
16 else
17 MPLAYER_ENDIAN:=--disable-big-endian
18 endif
20 $(DL_DIR)/$(MPLAYER_SOURCE):
21 $(WGET) -P $(DL_DIR) $(MPLAYER_SITE)/$(MPLAYER_SOURCE)
23 $(MPLAYER_DIR)/.unpacked: $(DL_DIR)/$(MPLAYER_SOURCE)
24 $(MPLAYER_CAT) $(DL_DIR)/$(MPLAYER_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
25 toolchain/patch-kernel.sh $(MPLAYER_DIR) package/mplayer/ mplayer-$(MPLAYER_VERSION)\*.patch\*
26 touch $@
28 $(MPLAYER_DIR)/.configured: $(MPLAYER_DIR)/.unpacked
29 (cd $(MPLAYER_DIR); rm -rf config.cache; \
30 $(TARGET_CONFIGURE_OPTS) \
31 $(TARGET_CONFIGURE_ARGS) \
32 CFLAGS="$(TARGET_CFLAGS)" \
33 LDFLAGS="$(TARGET_LDFLAGS)" \
34 ./configure \
35 --prefix=/usr \
36 --confdir=/etc \
37 --target=$(GNU_TARGET_NAME) \
38 --host-cc=$(HOSTCC) \
39 --cc=$(TARGET_CC) \
40 --as=$(TARGET_CROSS)as \
41 --with-extraincdir=$(STAGING_DIR)/usr/include \
42 --with-extralibdir=$(STAGING_DIR)/lib \
43 --enable-mad \
44 --enable-fbdev \
45 $(MPLAYER_ENDIAN) \
46 --disable-mpdvdkit \
47 --disable-tv \
48 --enable-dynamic-plugins \
50 touch $@
52 $(MPLAYER_DIR)/$(MPLAYER_BINARY): $(MPLAYER_DIR)/.configured
53 $(MAKE) -C $(MPLAYER_DIR)
54 touch -c $@
56 $(TARGET_DIR)/$(MPLAYER_TARGET_BINARY): $(MPLAYER_DIR)/$(MPLAYER_BINARY)
57 $(INSTALL) -m 0755 -D $(MPLAYER_DIR)/$(MPLAYER_BINARY) $(TARGET_DIR)/$(MPLAYER_TARGET_BINARY)
58 -$(STRIPCMD) $(STRIP_STRIP_UNNEEDED) $(TARGET_DIR)/$(MPLAYER_TARGET_BINARY)
59 touch -c $@
61 mplayer: libmad $(TARGET_DIR)/$(MPLAYER_TARGET_BINARY)
63 mplayer-source: $(DL_DIR)/$(MPLAYER_SOURCE)
65 mplayer-unpacked: $(MPLAYER_DIR)/.unpacked
67 mplayer-clean:
68 rm -f $(TARGET_DIR)/$(MPLAYER_TARGET_BINARY)
69 -$(MAKE) -C $(MPLAYER_DIR) clean
71 mplayer-dirclean:
72 rm -rf $(MPLAYER_DIR)
73 #############################################################
75 # Toplevel Makefile options
77 #############################################################
78 ifeq ($(BR2_PACKAGE_MPLAYER),y)
79 TARGETS+=mplayer
80 endif