this allows to use mpd without mpfire installed.
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
--- /dev/null
+/etc/asound.state
+/var/ipfire/mpd/db/
+/var/ipfire/mpd/mpd.conf
+/var/ipfire/mpd/mpd_state
-/etc/asound.state
-/var/ipfire/mpfire/db/
-/var/ipfire/mpfire/mpd.conf
-/var/ipfire/mpfire/mpd_state
/var/ipfire/mpfire/settings
/var/ipfire/mpfire/webradio
##################### REQUIRED ###########################
port "6600"
music_directory "/var/mp3"
-playlist_directory "/var/ipfire/mpfire"
+playlist_directory "/var/ipfire/mpd"
log_file "/var/log/mpd.log"
pid_file "/var/run/mpd.pid"
##########################################################
#
# Location of DB file
#
-db_file "/var/ipfire/mpfire/db/mpd.db"
+db_file "/var/ipfire/mpd/db/mpd.db"
#
# The state file (if set) will be a file
# for storing all current information
# to recreate your last MPD session after
# restart.
#
-state_file "/var/ipfire/mpfire/mpd_state"
+state_file "/var/ipfire/mpd/mpd_state"
#
##########################################################
#
audio_buffer_size "2048"
#
-# This means exactly what it says, it will
-# buffer your file up to the percentage of
-# the buffer before it begins playing.
-#
-buffer_before_play "25%"
-#
##########################################################
#
filesystem_charset "UTF-8"
#
-# The encoding that ID3v1 tags should be converted from.
-#
-id3v1_encoding "UTF-8"
metadata_to_use "artist,album,title,track,name,comment,date,genre"
#
################################################################
}
sub checkplaylist(){
- my $Datei = "/var/ipfire/mpfire/playlist.m3u";
+ my $Datei = "/var/ipfire/mpd/playlist.m3u";
my @Info = stat($Datei);
if ( $Info[7] eq '' || $Info[7] eq '0' ){print "There is no playlist";exit(1);}
}
var/cache/gnump3d
var/cache/gnump3d/serving
var/log/gnump3d
+#var/mp3
var/mp3/info
#usr/share/icons/hicolor/scalable/apps/mpd.svg
var/log/mpd.error.log
var/log/mpd.log
+var/ipfire/backup/addons/includes/mpd
+#var/ipfire/mpd
+#var/ipfire/mpd/db
+var/ipfire/mpd/db/info
+var/ipfire/mpd/mpd.conf
+var/ipfire/mpd/playlist.m3u
+var/mp3/info
var/ipfire/mpfire
var/ipfire/mpfire/bin
var/ipfire/mpfire/bin/mpfire.pl
-#var/ipfire/mpfire/db
-var/ipfire/mpfire/db/info
-var/ipfire/mpfire/mpd.conf
-var/ipfire/mpfire/playlist.m3u
var/ipfire/mpfire/settings
var/ipfire/mpfire/webradio
-var/mp3/info
usr/local/bin/mpfirectrl
srv/web/ipfire/cgi-bin/mpfire.cgi
srv/web/ipfire/html/images/mpfire
var/ipfire/menu.d/EX-mpfire.menu
-#var/mp3
delete $mpfiresettings{'PAGE'}; delete $mpfiresettings{'FRAME'};
&General::writehash("${General::swroot}/mpfire/settings", \%mpfiresettings);
- open(DATEI, "<${General::swroot}/mpfire/mpd.conf") || die "Datei nicht gefunden";
+ open(DATEI, "<${General::swroot}/mpd/mpd.conf") || die "Datei nicht gefunden";
my @Zeilen = <DATEI>;
close(DATEI);
- open(DATEI, ">${General::swroot}/mpfire/mpd.conf") || die "Datei nicht gefunden";
+ open(DATEI, ">${General::swroot}/mpd/mpd.conf") || die "Datei nicht gefunden";
foreach (@Zeilen){
if ( $_ =~ /music_directory/){
print DATEI "music_directory \"".$mpfiresettings{'MUSICDIR'}."\"\n";
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2023 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2024 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
DIR_APP = $(DIR_SRC)/${THISAPP}
TARGET = $(DIR_INFO)/$(THISAPP)
PROG = mpd
-PAK_VER = 33
+PAK_VER = 35
# SUP_ARCH = aarch64 x86_64
DEPS = alsa avahi faad2 ffmpeg flac lame libmad libshout libogg libid3tag libvorbis opus soxr fmt
#install initscripts
$(call INSTALL_INITSCRIPTS,$(SERVICES))
+ -mkdir -p /var/ipfire/mpd/db
+ touch /var/ipfire/mpd/playlist.m3u
+ install -v -m 664 $(DIR_SRC)/config/mpd/mpd.conf /var/ipfire/mpd/
+ echo "Folder for mpd database" > /var/ipfire/mpd/db/info
+ -mkdir -p /var/mp3
+ echo "Folder for music files" > /var/mp3/info
+ chown root.nobody /var/ipfire/mpd/{mpd.conf,playlist.m3u}
+ chmod 664 /var/ipfire/mpd/playlist.m3u
+ install -v -m 644 $(DIR_SRC)/config/backup/includes/mpd /var/ipfire/backup/addons/includes/mpd
+
@rm -rf $(DIR_APP)
touch /var/log/mpd.error.log
touch /var/log/mpd.log
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2019 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2024 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(THISAPP)
PROG = mpfire
-PAK_VER = 16
+PAK_VER = 17
DEPS = mpd mpc
$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
@$(PREBUILD)
- -mkdir -p /var/ipfire/mpfire/{bin,db}
- touch /var/ipfire/mpfire/{settings,playlist.m3u}
+ -mkdir -p /var/ipfire/mpfire/bin
+ touch /var/ipfire/mpfire/settings
install -v -m 755 $(DIR_SRC)/config/mpfire/mpfire.pl /var/ipfire/mpfire/bin
- install -v -m 664 $(DIR_SRC)/config/mpfire/mpd.conf /var/ipfire/mpfire/
install -v -m 644 $(DIR_SRC)/config/mpfire/webradio /var/ipfire/mpfire/
- echo "Folder for mpd database" > /var/ipfire/mpfire/db/info
- -mkdir -p /var/mp3
- echo "Folder for music files" > /var/mp3/info
- chown root.nobody /var/ipfire/mpfire/{mpd.conf,playlist.m3u}
chown nobody.nobody /var/ipfire/mpfire/{settings,webradio}
- chmod 664 /var/ipfire/mpfire/playlist.m3u
chmod 755 /srv/web/ipfire/html/images/mpfire
install -v -m 644 $(DIR_SRC)/config/backup/includes/mpfire /var/ipfire/backup/addons/includes/mpfire
-mkdir -p /usr/lib/perl5/site_perl/5.36.0/Audio/
--- /dev/null
+#!/bin/bash
+############################################################################
+# #
+# This file is part of the IPFire Firewall. #
+# #
+# IPFire is free software; you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation; either version 2 of the License, or #
+# (at your option) any later version. #
+# #
+# IPFire is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with IPFire; if not, write to the Free Software #
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
+# #
+# Copyright (C) 2007-2024 IPFire-Team <info@ipfire.org>. #
+# #
+############################################################################
+#
+. /opt/pakfire/lib/functions.sh
+extract_files
+ln -svf /etc/init.d/mpd /etc/rc.d/rc3.d/S65mpd
+ln -svf /etc/init.d/mpd /etc/rc.d/rc0.d/K35mpd
+ln -svf /etc/init.d/mpd /etc/rc.d/rc6.d/K35mpd
+ln -svf /var/ipfire/mpd/mpd.conf /etc/mpd.conf
+touch /var/log/mpd.log
+restore_backup ${NAME}
+/etc/init.d/mpd start
--- /dev/null
+#!/bin/bash
+############################################################################
+# #
+# This file is part of the IPFire Firewall. #
+# #
+# IPFire is free software; you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation; either version 2 of the License, or #
+# (at your option) any later version. #
+# #
+# IPFire is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with IPFire; if not, write to the Free Software #
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
+# #
+# Copyright (C) 2007-2024 IPFire-Team <info@ipfire.org>. #
+# #
+############################################################################
+#
+. /opt/pakfire/lib/functions.sh
+/etc/init.d/mpd stop
+make_backup ${NAME}
+remove_files
+rm -f /etc/rc.d/rc*.d/???mpd /var/log/mpd.error.log /var/log/mpd.log /etc/mpd.conf
--- /dev/null
+#!/bin/bash
+############################################################################
+# #
+# This file is part of the IPFire Firewall. #
+# #
+# IPFire is free software; you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation; either version 2 of the License, or #
+# (at your option) any later version. #
+# #
+# IPFire is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with IPFire; if not, write to the Free Software #
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
+# #
+# Copyright (C) 2007-2024 IPFire-Team <info@ipfire.org>. #
+# #
+############################################################################
+#
+. /opt/pakfire/lib/functions.sh
+extract_backup_includes
+./uninstall.sh
+./install.sh
# along with IPFire; if not, write to the Free Software #
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
# #
-# Copyright (C) 2007-2011 IPFire-Team <info@ipfire.org>. #
+# Copyright (C) 2007-2024 IPFire-Team <info@ipfire.org>. #
# #
############################################################################
#
. /opt/pakfire/lib/functions.sh
extract_files
-ln -svf /etc/init.d/mpd /etc/rc.d/rc3.d/S65mpd
-ln -svf /etc/init.d/mpd /etc/rc.d/rc0.d/K35mpd
-ln -svf /etc/init.d/mpd /etc/rc.d/rc6.d/K35mpd
-ln -svf /var/ipfire/mpfire/mpd.conf /etc/mpd.conf
chmod 755 /srv/web/ipfire/html/images/mpfire
-touch /var/log/mpd.log
restore_backup ${NAME}
-# comment removed option from config
-sed -i -e "s|^error_file|#error_file|g" /var/ipfire/mpfire/mpd.conf
-#
-/etc/init.d/mpd start
# along with IPFire; if not, write to the Free Software #
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
# #
-# Copyright (C) 2007 IPFire-Team <info@ipfire.org>. #
+# Copyright (C) 2007-2024 IPFire-Team <info@ipfire.org>. #
# #
############################################################################
#
. /opt/pakfire/lib/functions.sh
-/etc/init.d/mpd stop
make_backup ${NAME}
remove_files
-rm -f /etc/rc.d/rc*.d/???mpd /var/log/mpd.error.log /var/log/mpd.log /etc/mpd.conf
# along with IPFire; if not, write to the Free Software #
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
# #
-# Copyright (C) 2007-2020 IPFire-Team <info@ipfire.org>. #
+# Copyright (C) 2007-2024 IPFire-Team <info@ipfire.org>. #
# #
############################################################################
#