/[gentoo-x86]/net-misc/mediatomb/mediatomb-0.12.1-r5.ebuild
Gentoo

Contents of /net-misc/mediatomb/mediatomb-0.12.1-r5.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.8 - (show annotations) (download)
Sat Aug 9 17:07:12 2014 UTC (5 years, 3 months ago) by thev00d00
Branch: MAIN
CVS Tags: HEAD
Changes since 1.7: +1 -1 lines
FILE REMOVED
Add snapshot build, remove old

(Portage version: 2.2.11-r1/cvs/Linux x86_64, unsigned Manifest commit)

1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/mediatomb/mediatomb-0.12.1-r5.ebuild,v 1.7 2013/08/26 15:31:14 axs Exp $
4
5 EAPI="4"
6 inherit autotools eutils linux-info user
7
8 DEB_VER="4"
9 DESCRIPTION="MediaTomb is an open source UPnP MediaServer"
10 HOMEPAGE="http://www.mediatomb.cc/"
11 SRC_URI="mirror://sourceforge/mediatomb/${P}.tar.gz
12 mirror://debian/pool/main/${PN:0:1}/${PN}/${PN}_${PV}-${DEB_VER}.debian.tar.gz"
13
14 LICENSE="GPL-2"
15 SLOT="0"
16 KEYWORDS="amd64 ~arm ~ppc x86"
17 IUSE="+curl debug +exif +ffmpeg id3tag inotify +javascript lastfm libextractor +magic +mp4 mysql +sqlite +taglib thumbnail +zlib"
18 REQUIRED_USE="
19 || ( mysql sqlite )
20 taglib? ( !id3tag ) id3tag? ( !taglib )
21 thumbnail? ( ffmpeg !libextractor )
22 ffmpeg? ( !libextractor )
23 libextractor? ( !ffmpeg !thumbnail )
24 "
25
26 DEPEND="mysql? ( virtual/mysql )
27 id3tag? ( media-libs/id3lib )
28 javascript? ( >=dev-lang/spidermonkey-1.8.5:0 )
29 dev-libs/expat
30 taglib? ( media-libs/taglib )
31 sqlite? ( >=dev-db/sqlite-3 )
32 lastfm? ( >=media-libs/lastfmlib-0.4 )
33 exif? ( media-libs/libexif )
34 libextractor? ( media-libs/libextractor )
35 mp4? ( >=media-libs/libmp4v2-1.9.1_p479:0 )
36 ffmpeg? ( virtual/ffmpeg )
37 thumbnail? ( media-video/ffmpegthumbnailer[jpeg] )
38 curl? ( net-misc/curl )
39 magic? ( sys-apps/file )
40 sys-apps/util-linux
41 zlib? ( sys-libs/zlib )
42 virtual/libiconv"
43 RDEPEND="${DEPEND}"
44
45 pkg_setup() {
46 if use inotify ; then
47 if ! linux_config_exists || ! linux_chkconfig_present INOTIFY_USER ; then
48 ewarn "Please enable Inotify support in your kernel:"
49 ewarn " File systems --->"
50 ewarn " [*] Inotify support for userspace"
51 fi
52 fi
53 enewgroup mediatomb
54 enewuser mediatomb -1 -1 /dev/null mediatomb
55 }
56
57 src_prepare() {
58 local p dd="${WORKDIR}"/debian/patches
59 sed -i -r '/^[-+]{3} /s:[.][.]/::' "${dd}"/* || die
60 for p in $(<"${dd}"/series) ; do
61 epatch "${dd}"/${p}
62 done
63 epatch "${FILESDIR}"/${P}-libmp4v2.patch
64 epatch "${FILESDIR}"/${P}-system-uuid.patch #270830
65 if has_version "~dev-lang/spidermonkey-1.8.7" ; then
66 epatch "${FILESDIR}"/${P}-mozjs187.patch #435394
67 fi
68 epatch "${FILESDIR}"/${P}-libextractor.patch #435394
69 epatch "${FILESDIR}"/${P}-inotify-hard-links.patch
70 epatch "${FILESDIR}"/${P}-thumb-cache.patch
71 epatch "${FILESDIR}"/${P}-libav9.patch
72 epatch "${FILESDIR}"/${P}-avformatcontext-pointer.patch #446922
73 eautoreconf
74 }
75
76 src_configure() {
77 econf \
78 $(use_enable curl) $(use_enable curl youtube) \
79 $(use_enable debug tombdebug) \
80 $(use_enable exif libexif) \
81 $(use_enable ffmpeg) \
82 $(use_enable id3tag id3lib) \
83 $(use_enable inotify) \
84 $(use_enable javascript libjs) \
85 $(use_enable lastfm lastfmlib) \
86 $(use_enable libextractor) \
87 $(use_enable magic libmagic) \
88 $(use_enable mp4 libmp4v2) \
89 $(use_enable mysql) \
90 $(use_enable sqlite sqlite3) \
91 $(use_enable taglib) \
92 $(use_enable thumbnail ffmpegthumbnailer) \
93 $(use_enable zlib) \
94 --enable-external-transcoding \
95 --enable-protocolinfo-extension
96 }
97
98 src_install() {
99 default
100
101 newinitd "${FILESDIR}"/${PN}-0.12.1.initd ${PN}
102 use mysql || sed -i -e "/use mysql/d" "${ED}"/etc/init.d/${PN}
103 newconfd "${FILESDIR}"/${PN}-0.12.0.confd ${PN}
104
105 insinto /etc/mediatomb
106 newins "${FILESDIR}/${PN}-0.12.0.config" config.xml
107 fperms 0600 /etc/mediatomb/config.xml
108 fowners mediatomb:mediatomb /etc/mediatomb/config.xml
109
110 keepdir /var/lib/mediatomb
111 fowners mediatomb:mediatomb /var/lib/mediatomb
112 }
113
114 pkg_postinst() {
115 if use mysql ; then
116 elog "MediaTomb has been built with MySQL support and needs"
117 elog "to be configured before being started."
118 elog "For more information, please consult the MediaTomb"
119 elog "documentation: http://mediatomb.cc/pages/documentation"
120 elog
121 fi
122
123 elog "To configure MediaTomb edit:"
124 elog "/etc/mediatomb/config.xml"
125 elog
126 elog "The MediaTomb web interface can be reached at (after the service is started):"
127 elog "http://localhost:49152/"
128 }

  ViewVC Help
Powered by ViewVC 1.1.20