From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from ptx.hi.pengutronix.de ([2001:6f8:1178:2:5054:ff:fec0:8e10] ident=Debian-exim) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1VH7DK-0000Ed-Rk for ptxdist@pengutronix.de; Wed, 04 Sep 2013 09:09:18 +0200 Received: from mol by ptx.hi.pengutronix.de with local (Exim 4.80) (envelope-from ) id 1VH7DK-0000Ov-QK for ptxdist@pengutronix.de; Wed, 04 Sep 2013 09:09:18 +0200 Date: Wed, 4 Sep 2013 09:09:18 +0200 From: Michael Olbrich Message-ID: <20130904070918.GA31225@pengutronix.de> References: <1377953841-2263-1-git-send-email-s.hauer@pengutronix.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1377953841-2263-1-git-send-email-s.hauer@pengutronix.de> Subject: Re: [ptxdist] [PATCH] Add Music Player Daemon (MPD) support Reply-To: ptxdist@pengutronix.de List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: ptxdist-bounces@pengutronix.de Errors-To: ptxdist-bounces@pengutronix.de To: ptxdist@pengutronix.de On Sat, Aug 31, 2013 at 02:57:21PM +0200, Sascha Hauer wrote: > Signed-off-by: Sascha Hauer > --- > rules/mpd.in | 55 ++++++++++++++++++++++++++ > rules/mpd.make | 121 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ > 2 files changed, 176 insertions(+) > create mode 100644 rules/mpd.in > create mode 100644 rules/mpd.make > > diff --git a/rules/mpd.in b/rules/mpd.in > new file mode 100644 > index 0000000..24d63fb > --- /dev/null > +++ b/rules/mpd.in > @@ -0,0 +1,55 @@ > +## SECTION=multimedia_sound > + > +menuconfig MPD > + tristate > + prompt "Music Player Daemon (MPD) " > + select ALSA_LIB if MPD_ALSA > + select LIBID3TAG if MPD_ID3 > + select LIBMAD if MPD_MAD > + select MPG123 if MPD_MPG123 > + select LIBOGG if MPD_VORBIS > + select LIBVORBIS if MPD_VORBIS > + select FLAC if MPD_FLAC > + select LIBCURL if MPD_CURL > + select SQLITE if MPD_SQLITE Please align the 'if's > + help > + Music Player Daemon (MPD) is a flexible, powerful, server-side > + application for playing music. Through plugins and libraries it > + can play a variety of sound files while being controlled by its > + network protocol. > + > +if MPD > + > +config MPD_ALSA > + prompt "MPD Alsa support" > + bool Hmmm, it's the MPD submenu, so saying "MPD ..." everywhere seems a bit redundant. > + > +config MPD_ID3 > + prompt "MPD ID3 support" > + bool > + > +config MPD_MAD > + prompt "MPD MAD support" > + bool > + > +config MPD_MPG123 > + prompt "MPD MPG123 support" > + bool > + > +config MPD_VORBIS > + prompt "MPD Vorbis support" > + bool > + > +config MPD_FLAC > + prompt "MPD FLAC support" > + bool > + > +config MPD_CURL > + prompt "MPD curl support" > + bool > + > +config MPD_SQLITE > + prompt "MPD SQLite support" > + bool > + > +endif > diff --git a/rules/mpd.make b/rules/mpd.make > new file mode 100644 > index 0000000..d63c325 > --- /dev/null > +++ b/rules/mpd.make > @@ -0,0 +1,121 @@ > +# -*-makefile-*- > +# > +# Copyright (C) 2013 by Sascha Hauer > +# > +# See CREDITS for details about who has contributed to this project. > +# > +# For further information about the PTXdist project and license conditions > +# see the README file. > +# > + > +# > +# We provide this package > +# > +PACKAGES-$(PTXCONF_MPD) += mpd > + > +# > +# Paths and names > +# > +MPD_VERSION := 0.17.5 > +MPD_MD5 := b70230c1c810ce85a824332f0ac40a8f > +MPD := mpd-$(MPD_VERSION) > +MPD_SUFFIX := tar.gz > +MPD_URL := http://www.musicpd.org/download/mpd/0.17/$(MPD).$(MPD_SUFFIX) > +MPD_SOURCE := $(SRCDIR)/$(MPD).$(MPD_SUFFIX) > +MPD_DIR := $(BUILDDIR)/$(MPD) > +MPD_LICENSE := unknown > + > +# ---------------------------------------------------------------------------- > +# Get > +# ---------------------------------------------------------------------------- > + > +#$(MPD_SOURCE): > +# @$(call targetinfo) > +# @$(call get, MPD) > + remove. > +# ---------------------------------------------------------------------------- > +# Prepare > +# ---------------------------------------------------------------------------- > + > +MPD_ENABLE-$(PTXCONF_MPD_ALSA) += alsa > +MPD_ENABLE-$(PTXCONF_MPD_FFMPEG) += ffmpeg > +MPD_ENABLE-$(PTXCONF_MPD_ID3) += id3 > +MPD_ENABLE-$(PTXCONF_MPD_MAD) += mad > +MPD_ENABLE-$(PTXCONF_MPD_MPG123) += mpg123 > +MPD_ENABLE-$(PTXCONF_MPD_CURL) += curl > +MPD_ENABLE-$(PTXCONF_MPD_SQLITE) += sqlite > + > +MPD_ENABLEC-y += $(MPD_ENABLE-y) > +MPD_ENABLEC- += $(MPD_ENABLE-) > +MPD_ENABLEP-y += $(MPD_ENABLE-y) You copied that from gstreamer or something like that right? You don't need this here. just use MPD_ENABLE-* everywhere. The C/P stuff is for packages with configure switches and modules that are mostly but not always the same. > + > +MPD_CONF_ENV := $(CROSS_ENV) > + > +# > +# autoconf > +# > +MPD_CONF_TOOL := autoconf > +MPD_CONF_OPT := $(CROSS_AUTOCONF_USR) > + > +ifneq ($(call remove_quotes,$(MPD_ENABLEC-y)),) > +MPD_CONF_OPT += --enable-$(subst $(space),$(space)--enable-,$(strip $(MPD_ENABLEC-y))) > +endif MPD_CONF_OPT += $(addprefix --enable-,$(MPD_ENABLE-y)) Is probably simpler. > + > +ifneq ($(call remove_quotes,$(MPD_ENABLEC-)),) > +MPD_CONF_OPT += --disable-$(subst $(space),$(space)--disable-,$(strip $(MPD_ENABLEC-))) > +endif The same here. > + > +$(STATEDIR)/mpd.prepare: > + @$(call targetinfo) > + @$(call clean, $(MPD_DIR)/config.cache) > + cd $(MPD_DIR) && \ > + $(MPD_PATH) $(MPD_CONF_ENV) \ > + ./configure $(MPD_CONF_OPT) > + @$(call touch) remove > + > +# ---------------------------------------------------------------------------- > +# Compile > +# ---------------------------------------------------------------------------- > + > +#$(STATEDIR)/mpd.compile: > +# @$(call targetinfo) > +# @$(call world/compile, MPD) > +# @$(call touch) > + remove > +# ---------------------------------------------------------------------------- > +# Install > +# ---------------------------------------------------------------------------- > + > +#$(STATEDIR)/mpd.install: > +# @$(call targetinfo) > +# @$(call world/install, MPD) > +# @$(call touch) > + remove > +# ---------------------------------------------------------------------------- > +# Target-Install > +# ---------------------------------------------------------------------------- > + > +$(STATEDIR)/mpd.targetinstall: > + @$(call targetinfo) > + > + @$(call install_init, mpd) > + @$(call install_fixup, mpd,PRIORITY,optional) > + @$(call install_fixup, mpd,SECTION,base) > + @$(call install_fixup, mpd,AUTHOR,"Sascha Hauer ") > + @$(call install_fixup, mpd,DESCRIPTION,missing) > + > + @$(call install_copy, mpd, 0, 0, 0755, $(MPD_DIR)/src/mpd, /usr/bin/mpd) > + > + @$(call install_finish, mpd) > + > + @$(call touch) > + > +# ---------------------------------------------------------------------------- > +# Clean > +# ---------------------------------------------------------------------------- > + > +#$(STATEDIR)/mpd.clean: > +# @$(call targetinfo) > +# @$(call clean_pkg, MPD) > + remove Michael > +# vim: syntax=make > -- > 1.8.4.rc3 > > > -- > ptxdist mailing list > ptxdist@pengutronix.de > -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | -- ptxdist mailing list ptxdist@pengutronix.de