2003-12-03 23:56:58 +01:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# mpg123
|
|
|
|
#
|
|
|
|
#############################################################
|
2007-07-28 19:05:38 +02:00
|
|
|
MPG123_VERSION=0.66
|
|
|
|
MPG123_SOURCE=mpg123-$(MPG123_VERSION).tar.bz2
|
|
|
|
MPG123_CAT:=$(BZCAT)
|
|
|
|
MPG123_SITE:=http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/sourceforge/mpg123
|
|
|
|
MPG123_DIR:=$(BUILD_DIR)/mpg123-$(MPG123_VERSION)
|
2007-09-23 16:24:13 +02:00
|
|
|
MPG123_BIN:=src/mpg123
|
|
|
|
MPG123_TARGET_BIN:=usr/bin/mpg123
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2007-07-28 19:05:38 +02:00
|
|
|
# Check if ALSA is built, then we should configure after alsa-lib so
|
|
|
|
# ./configure can find alsa-lib.
|
2009-02-05 14:24:01 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
|
2007-07-28 19:05:38 +02:00
|
|
|
MPG123_USE_ALSA:=--with-audio=alsa
|
|
|
|
MPG123_ALSA_DEP:=alsa-lib
|
|
|
|
endif
|
2003-12-03 23:56:58 +01:00
|
|
|
|
|
|
|
$(DL_DIR)/$(MPG123_SOURCE):
|
2009-01-16 12:42:52 +01:00
|
|
|
$(call DOWNLOAD,$(MPG123_SITE),$(MPG123_SOURCE))
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2007-08-20 19:21:16 +02:00
|
|
|
$(MPG123_DIR)/.unpacked: $(DL_DIR)/$(MPG123_SOURCE)
|
2006-11-17 16:43:51 +01:00
|
|
|
$(MPG123_CAT) $(DL_DIR)/$(MPG123_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
|
2008-11-15 22:33:07 +01:00
|
|
|
toolchain/patch-kernel.sh $(MPG123_DIR) package/multimedia/mpg123/ mpg123-$(MPG123_VERSION)\*.patch
|
2007-07-28 19:05:38 +02:00
|
|
|
$(CONFIG_UPDATE) $(MPG123_DIR)/build
|
2007-05-31 17:42:33 +02:00
|
|
|
touch $@
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2007-07-28 19:05:38 +02:00
|
|
|
$(MPG123_DIR)/.configured: $(MPG123_DIR)/.unpacked
|
|
|
|
(cd $(MPG123_DIR); rm -rf config.cache; \
|
2007-07-30 20:17:13 +02:00
|
|
|
$(TARGET_CONFIGURE_ARGS) \
|
2007-07-28 19:05:38 +02:00
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
2009-02-05 14:24:18 +01:00
|
|
|
CFLAGS="$(TARGET_CFLAGS)" \
|
2007-07-28 19:05:38 +02:00
|
|
|
LDFLAGS="$(TARGET_LDFLAGS)" \
|
|
|
|
./configure \
|
|
|
|
--target=$(REAL_GNU_TARGET_NAME) \
|
|
|
|
--host=$(REAL_GNU_TARGET_NAME) \
|
|
|
|
--build=$(GNU_HOST_NAME) \
|
|
|
|
--prefix=/usr \
|
|
|
|
--sysconfdir=/etc \
|
|
|
|
--with-cpu=generic_nofpu \
|
|
|
|
$(MPG123_USE_ALSA) \
|
|
|
|
$(DISABLE_NLS) \
|
|
|
|
$(DISABLE_LARGEFILE) \
|
2007-08-21 21:20:18 +02:00
|
|
|
)
|
2007-07-28 19:05:38 +02:00
|
|
|
touch $@
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2007-07-28 19:05:38 +02:00
|
|
|
$(MPG123_DIR)/$(MPG123_BIN): $(MPG123_DIR)/.configured
|
|
|
|
$(MAKE) -C $(MPG123_DIR)
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2007-07-28 19:05:38 +02:00
|
|
|
$(TARGET_DIR)/$(MPG123_TARGET_BIN): $(MPG123_DIR)/$(MPG123_BIN)
|
2007-09-23 16:24:13 +02:00
|
|
|
$(INSTALL) -D $(MPG123_DIR)/$(MPG123_BIN) $(TARGET_DIR)/$(MPG123_TARGET_BIN)
|
2007-10-01 18:15:31 +02:00
|
|
|
$(STRIPCMD) $(STRIP_STRIP_UNNEEDED) $(TARGET_DIR)/$(MPG123_TARGET_BIN)
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2007-08-20 19:21:16 +02:00
|
|
|
mpg123: uclibc $(MPG123_ALSA_DEP) $(TARGET_DIR)/$(MPG123_TARGET_BIN)
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2009-01-24 11:15:05 +01:00
|
|
|
mpg123-unpacked: $(MPG123_DIR)/.unpacked
|
|
|
|
|
2003-12-03 23:56:58 +01:00
|
|
|
mpg123-clean:
|
2007-08-01 10:54:56 +02:00
|
|
|
-$(MAKE) -C $(MPG123_DIR) clean
|
2003-12-03 23:56:58 +01:00
|
|
|
|
|
|
|
mpg123-dirclean:
|
2007-07-28 19:05:38 +02:00
|
|
|
rm -rf $(MPG123_DIR) $(MPG123_DIR)
|
|
|
|
|
|
|
|
mpg123-source: $(DL_DIR)/$(MPG123_SOURCE)
|
2003-12-03 23:56:58 +01:00
|
|
|
|
2005-02-10 04:06:39 +01:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# Toplevel Makefile options
|
|
|
|
#
|
|
|
|
#############################################################
|
2008-12-08 09:15:27 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_MPG123),y)
|
2005-02-10 04:06:39 +01:00
|
|
|
TARGETS+=mpg123
|
|
|
|
endif
|