2012-07-04 11:59:16 +03:00
|
|
|
Summary: A DLNA/UPnP-AV compliant media server
|
|
|
|
Name: minidlna
|
2017-09-12 13:06:14 +03:00
|
|
|
Version: 1.2.1
|
2017-06-11 02:18:40 +03:00
|
|
|
Release: 1
|
2015-03-17 14:05:30 +04:00
|
|
|
License: GPLv2+
|
2012-07-04 11:59:16 +03:00
|
|
|
Group: Networking/Other
|
2015-03-17 14:05:30 +04:00
|
|
|
Url: http://sourceforge.net/projects/minidlna/
|
2014-01-16 03:39:06 -05:00
|
|
|
Source0: http://downloads.sourceforge.net/project/minidlna/minidlna/%{version}/minidlna-%{version}.tar.gz
|
2012-11-13 01:41:15 +04:00
|
|
|
Source2: minidlna-tmpfiles.conf
|
2012-07-04 11:59:16 +03:00
|
|
|
Source3: minidlna.1
|
|
|
|
Source4: minidlna.conf.5
|
|
|
|
Source5: %{name}.service
|
2016-12-03 16:14:22 +03:00
|
|
|
Patch0: minidlna-1.1.6.l10n.patch
|
2012-11-13 01:41:15 +04:00
|
|
|
BuildRequires: pkgconfig(flac)
|
2012-07-04 11:59:16 +03:00
|
|
|
BuildRequires: libid3tag-devel
|
|
|
|
BuildRequires: libexif-devel
|
2014-01-16 03:39:06 -05:00
|
|
|
BuildRequires: jpeg-devel
|
2012-11-13 01:41:15 +04:00
|
|
|
BuildRequires: pkgconfig(sqlite3)
|
2014-01-16 03:39:06 -05:00
|
|
|
BuildRequires: ffmpeg-devel >= 1.1
|
2012-11-13 01:41:15 +04:00
|
|
|
BuildRequires: pkgconfig(vorbis)
|
2016-12-03 16:14:22 +03:00
|
|
|
BuildRequires: pkgconfig(libavcodec)
|
|
|
|
BuildRequires: pkgconfig(libavformat)
|
|
|
|
BuildRequires: pkgconfig(libavutil)
|
2014-01-16 03:39:06 -05:00
|
|
|
BuildRequires: systemd
|
2016-12-03 16:14:22 +03:00
|
|
|
BuildRequires: pkgconfig
|
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
|
|
|
BuildRequires: libtool
|
|
|
|
BuildRequires: gettext-devel
|
2012-07-04 11:59:16 +03:00
|
|
|
Requires(post): rpm-helper
|
|
|
|
Requires(preun): rpm-helper
|
2014-05-21 15:27:47 +04:00
|
|
|
Requires(postun): rpm-helper
|
2012-02-01 19:43:30 +04:00
|
|
|
|
|
|
|
%description
|
|
|
|
MiniDLNA (aka ReadyDLNA) is server software with the aim of being fully
|
|
|
|
compliant with DLNA/UPnP-AV clients. MiniDLNA serves multimedia content
|
|
|
|
such as music, video and pictures to compatible clients on the network.
|
|
|
|
|
|
|
|
See http://www.upnp.org/ for more details on UPnP
|
|
|
|
and http://www.dlna.org/ for mode details on DLNA.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
2016-12-03 16:14:22 +03:00
|
|
|
%patch0 -p1
|
2012-07-04 11:59:16 +03:00
|
|
|
|
2012-02-01 19:43:30 +04:00
|
|
|
%build
|
2012-07-04 11:59:16 +03:00
|
|
|
%serverbuild
|
|
|
|
|
2016-12-03 16:14:22 +03:00
|
|
|
CPPFLAGS="`pkg-config --cflags libavcodec libavformat libavutil`"
|
|
|
|
export CPPFLAGS
|
|
|
|
./autogen.sh
|
2014-01-16 03:39:06 -05:00
|
|
|
%configure2_5x \
|
|
|
|
--with-log-path=%{_logdir} \
|
|
|
|
--with-db-path=%{_localstatedir}/cache \
|
|
|
|
--with-os-name="%{distribution}"\
|
|
|
|
--with-os-version="%{distro_release}" \
|
|
|
|
--with-os-url="%{disturl}"
|
2012-07-04 11:59:16 +03:00
|
|
|
|
2012-02-01 19:43:30 +04:00
|
|
|
%make
|
|
|
|
|
|
|
|
%install
|
2012-07-04 11:59:16 +03:00
|
|
|
%makeinstall_std
|
|
|
|
|
|
|
|
install -D -p -m 0644 %{SOURCE5} %{buildroot}%{_unitdir}/%{name}.service
|
|
|
|
install -m 644 -D minidlna.conf %{buildroot}%{_sysconfdir}/minidlna.conf
|
|
|
|
install -m 644 -D %{SOURCE3} %{buildroot}%{_mandir}/man1/minidlna.1
|
|
|
|
install -m 644 -D %{SOURCE4} %{buildroot}%{_mandir}/man5/minidlna.conf.5
|
|
|
|
|
2016-12-06 16:24:55 +04:00
|
|
|
sed 's|#friendly_name=My DLNA Server|friendly_name=Rosa|' -i %{buildroot}%{_sysconfdir}/minidlna.conf
|
|
|
|
sed 's|#db_dir=/var/cache/minidlna|db_dir=/var/cache/minidlna|' -i %{buildroot}%{_sysconfdir}/minidlna.conf
|
|
|
|
sed 's|#log_dir=/var/log|log_dir=/var/log|' -i %{buildroot}%{_sysconfdir}/minidlna.conf
|
|
|
|
sed 's|#wide_links=no|wide_links=yes|' -i %{buildroot}%{_sysconfdir}/minidlna.conf
|
|
|
|
|
2012-11-13 01:41:15 +04:00
|
|
|
mkdir -p %{buildroot}%{_sysconfdir}/tmpfiles.d
|
|
|
|
install -m 0644 %{SOURCE2} %{buildroot}%{_sysconfdir}/tmpfiles.d/%{name}.conf
|
2012-02-01 19:43:30 +04:00
|
|
|
|
2014-05-21 15:27:47 +04:00
|
|
|
install -d -m 0755 %{buildroot}%{_localstatedir}/cache/%{name}/
|
|
|
|
touch %{buildroot}%{_localstatedir}/cache/%{name}/files.db
|
|
|
|
|
2014-01-16 03:39:06 -05:00
|
|
|
%find_lang %{name}
|
|
|
|
|
|
|
|
%pre
|
2014-05-21 15:27:47 +04:00
|
|
|
%_pre_useradd %{name} /run/%{name} /sbin/nologin
|
2014-01-16 03:39:06 -05:00
|
|
|
%_pre_groupadd minidlna minidlna
|
|
|
|
|
2012-02-01 19:43:30 +04:00
|
|
|
%post
|
2014-05-21 15:27:47 +04:00
|
|
|
%create_ghostfile %{_localstatedir}/cache/%{name}/files.db %{name} %{name} 0644
|
2012-02-01 19:43:30 +04:00
|
|
|
%_post_service minidlna
|
2014-01-16 03:39:06 -05:00
|
|
|
%tmpfiles_create %{name}.conf
|
2012-02-01 19:43:30 +04:00
|
|
|
|
|
|
|
%preun
|
|
|
|
%_preun_service minidlna
|
|
|
|
|
2014-01-16 03:39:06 -05:00
|
|
|
%postun
|
|
|
|
%_postun_userdel minidlna
|
|
|
|
%_postun_groupdel minidlna minidlna
|
|
|
|
|
|
|
|
%files -f %{name}.lang
|
2012-02-01 19:43:30 +04:00
|
|
|
%doc README
|
2014-05-21 15:27:47 +04:00
|
|
|
%dir %attr(-,minidlna,minidlna) %{_localstatedir}/cache/%{name}/
|
|
|
|
%ghost %attr(-,minidlna,minidlna) %{_localstatedir}/cache/%{name}/files.db
|
2014-01-16 03:39:06 -05:00
|
|
|
%attr(755,-,-) %{_sbindir}/minidlna*
|
2012-07-04 11:59:16 +03:00
|
|
|
%{_unitdir}/%{name}.service
|
2012-02-01 19:43:30 +04:00
|
|
|
%config(noreplace) %{_sysconfdir}/minidlna.conf
|
2014-05-21 15:27:47 +04:00
|
|
|
%{_sysconfdir}/tmpfiles.d/%{name}.conf
|
2012-02-01 19:43:30 +04:00
|
|
|
%{_mandir}/man1/minidlna.1*
|
|
|
|
%{_mandir}/man5/minidlna.conf.5*
|