0 1 1
default
Michalis Adamidis (gsnerf) - 4 months ago 2018-01-03 13:56:32
gsnerf@gsnerf.de
added emby-server ebuild for version 3.2.60.0
2 files changed with 118 insertions and 0 deletions:
↑ Collapse Diff ↑
...
 
@@ -33,6 +33,7 @@ DIST 3.2.26.0.tar.gz 83167045 SHA256 8d1
33 33
 
DIST 3.2.27.0.tar.gz 82933828 SHA256 3bee55d5e14865c59ff6e7d2f9a110b209efd0751584c51273bd0b6fb19989b3 SHA512 40437a9de8d8bc1b3adabb76ac97634aad5f60b0b20ec8032815d42d944ea54fcde04ab64256ed0bc07b48d721ab8ec78df59a567e71528e7bb4bfdeba2a0874 WHIRLPOOL c1459c62614e11e4d40de84a6595db27f2b65997b2d01f0f991c014f1a6377b4c568af43fecedb2c2a94104b2e151f3fa69b302ac5b974f83cb1b2c9a2d61d0a
34 34
 
DIST 3.2.33.0.tar.gz 77455867 SHA256 655a85d9aa317986f48ff451aa3ba81f0dc0a51818a3f9dab1dddedc2e102910 SHA512 e45977f46c73a98c6ea44f9e901d0ce7c64436773cd42622d36115862ce4e01688328a87eaef91c370f563635625ffd154e28dd2a9448721e403b3797a248c0f WHIRLPOOL a79d065abe35dce49a21dc80b956f72c273760df62f40f453280e88097756c0aaa5ee115fbc2b01b83ae203b30047bef0d120300e08240703a6ba6a31d89b374
35 35
 
DIST 3.2.5.tar.gz 46521369 SHA256 b310ce7a91a577b995569cbe57d73b5bd8029744faba765b00b470345b7caf48 SHA512 886e1c36fb8401239d1196d5706ea9ac52aafb6bdfcd1dd1b7c2341842dafd97d39fa37426ef346dec4b8e5fe0811fa7da4845754cd8adba30685550b099248e WHIRLPOOL 7ddbb6d339913ac7fe56337925ef12d740cd6a7c901f8f4aab93e8133dd12196f90e5e241b9fd7eea4398ea70ca1f20520384ba705417ae1db4439c0407acae7
36
 
DIST 3.2.60.0.tar.gz 69529804 SHA256 e0706253c9de3039b77c2f47bad68558624d994fe84b635cbb8ce3702916b75f SHA512 837a03fe79ad49122aab6c1e7fbe1ea0d750782fa17c8c4a74cfc9178a42d43f7260d5f74d259d16e577120d619dcb93a2d217024b5c37ef1dd9669734af8832 WHIRLPOOL 84d3870c70a6fad577edc6c45b00132d9e338ce1f37866ce4f4674c9eaa4212a0858eb22ea439db9e60343c131975f2f712c6fca11c9d972a087a0994b671e24
36 37
 
DIST 3.2.7.tar.gz 46472876 SHA256 50f57575dea4d5ea8c64afd2a8e9dfa535918400ee8fea593359c09cf74bece3 SHA512 5358d10761b6be68c1d2ed5e81626d0c99c97e49f73e3b8aa8afd1311445bd9ff7bab0b335a0b929ded166b31c866653395bcd6ac5587c51d6bb56a92a75ec66 WHIRLPOOL d4b346927030e56c73abfc3d8dcc1067e302a345d66397bbccf08c3651720de4e27616f76ff83b2e6f0ad8b646335d910f6c09485592ffd70bd1dc62b072d11c
37 38
 
DIST 3.2.8.tar.gz 46475083 SHA256 b3afee84546c3f610f0016af6ad2f5cea1ec3f662d866665753612732efcc58a SHA512 e61f91464e02c246047e38e43b209fc8af09c040633a7425515fddee5a8bccdf4b76cf988c6c1783a1283da08ce86b1b6abece8dd7c7ee132595ac42d057a989 WHIRLPOOL 2ccf7fb5467de42e7a0845847e27cb3929ff29289fa9fe028b0a41308f1654f22c54eb2e1f85722b57a35c9fb742d438c5cebf7090c99fdcc7a2c821579b6d8e
38 39
 
EBUILD emby-server-3.0.5724.6.ebuild 4100 SHA256 b7e637339ba68f179ee5aa694223cce076769822d5a3a63726d849bdb35b61f6 SHA512 c92b420fe86e13ae121b4b0af12de6135715ce68185633d10c819d46d89f2c9eef9a501b6cdd1617f88fd724d139f450875ea6e7bb26fc1d9856722a39245a63 WHIRLPOOL 462227dae187bfb58760dfd6b37ccf413b1135f094f4f863e523c8d48c58cabbdcbc437f13a3e45a14f5a195454450768c0b77bdb676ab9c30f5b121119965f3
...
 
@@ -70,6 +71,7 @@ EBUILD emby-server-3.2.26.0.ebuild 4183 
70 71
 
EBUILD emby-server-3.2.27.0.ebuild 4183 SHA256 d01f57b563626441d4d9d74d2dbe386ac86e2b4f5a0f50f611811b95f369b1f2 SHA512 5d66a93f7be97e665cdb54337fbc8f97185ddd5eec01cc79c1a4041fccd7f8d6b9b5ba408b75c352b0cb204d00db16877f91034273f0298e8d2369e32ed60afb WHIRLPOOL cce514751981381c70f61bae2c443a19f32ca4ab6f3233b7f7b0e444c05674e5b6c3a62785ac3783706e1cdaa72436a04859b9e2bef888427193a1bb451b52e3
71 72
 
EBUILD emby-server-3.2.33.0.ebuild 4183 SHA256 d01f57b563626441d4d9d74d2dbe386ac86e2b4f5a0f50f611811b95f369b1f2 SHA512 5d66a93f7be97e665cdb54337fbc8f97185ddd5eec01cc79c1a4041fccd7f8d6b9b5ba408b75c352b0cb204d00db16877f91034273f0298e8d2369e32ed60afb WHIRLPOOL cce514751981381c70f61bae2c443a19f32ca4ab6f3233b7f7b0e444c05674e5b6c3a62785ac3783706e1cdaa72436a04859b9e2bef888427193a1bb451b52e3
72 73
 
EBUILD emby-server-3.2.5.ebuild 3966 SHA256 ea80f17937b3b402c585563f74a4e60d14d14733b1a78e80ad09ae38989cfb35 SHA512 61c4c14d1f0cd5732ae14d3162bacf60510560ae678fc956b1eb8684ff5b9366ffe95f03d258f64e54b0af883a97aa59649b9be91dde08dcd8ec1654a78bad3f WHIRLPOOL 7e4d288429211ad89daf787f0ac726d21631b4f6a5d44a9ec00383d2cc43e9f589474988d6868c55ebd0c7da91ac829cf26c4a61f0c8c4928a8ab2059153b5fe
74
 
EBUILD emby-server-3.2.60.0.ebuild 4183 SHA256 d01f57b563626441d4d9d74d2dbe386ac86e2b4f5a0f50f611811b95f369b1f2 SHA512 5d66a93f7be97e665cdb54337fbc8f97185ddd5eec01cc79c1a4041fccd7f8d6b9b5ba408b75c352b0cb204d00db16877f91034273f0298e8d2369e32ed60afb WHIRLPOOL cce514751981381c70f61bae2c443a19f32ca4ab6f3233b7f7b0e444c05674e5b6c3a62785ac3783706e1cdaa72436a04859b9e2bef888427193a1bb451b52e3
73 75
 
EBUILD emby-server-3.2.7.ebuild 3966 SHA256 ea80f17937b3b402c585563f74a4e60d14d14733b1a78e80ad09ae38989cfb35 SHA512 61c4c14d1f0cd5732ae14d3162bacf60510560ae678fc956b1eb8684ff5b9366ffe95f03d258f64e54b0af883a97aa59649b9be91dde08dcd8ec1654a78bad3f WHIRLPOOL 7e4d288429211ad89daf787f0ac726d21631b4f6a5d44a9ec00383d2cc43e9f589474988d6868c55ebd0c7da91ac829cf26c4a61f0c8c4928a8ab2059153b5fe
74 76
 
EBUILD emby-server-3.2.8.ebuild 3966 SHA256 ea80f17937b3b402c585563f74a4e60d14d14733b1a78e80ad09ae38989cfb35 SHA512 61c4c14d1f0cd5732ae14d3162bacf60510560ae678fc956b1eb8684ff5b9366ffe95f03d258f64e54b0af883a97aa59649b9be91dde08dcd8ec1654a78bad3f WHIRLPOOL 7e4d288429211ad89daf787f0ac726d21631b4f6a5d44a9ec00383d2cc43e9f589474988d6868c55ebd0c7da91ac829cf26c4a61f0c8c4928a8ab2059153b5fe
75 77
 
EBUILD emby-server-9999.ebuild 3079 SHA256 61f90ec7c2d49d3ebeb5887201542572a27b543e99bf3cd3f6c89609d9ea4f6c SHA512 1febd22bfe38090668cc391fbebee8cd5a71f9ec678a224a9ed0bf29f76a9940c3016b7d20b5209d9e8d871cdd185c0ab0f2642ce4653407497233f1e3b9207e WHIRLPOOL f598d558a94bc20193cd0cb1fde156ae38043eddcf85a5f5440408c18e21c68c56f50bd758515a90b676d41f99bb72f6c6b7a0bc4cd6fe28cfb5cdfdfafda76f
 
new file 100644
1
 
# Copyright 1999-2015 Gentoo Foundation
2
 
# Distributed under the terms of the GNU General Public License v2
3
 
# $Header: $
4
 

	
5
 
EAPI="5"
6
 

	
7
 
inherit eutils user git-r3 dotnet
8
 

	
9
 
DESCRIPTION="Emby Server (formerly known as MediaBrowser Server) is a software that indexes a lot of different kinds of media and allows for them to be retrieved and played through the DLNA protocol on any device capable of processing them."
10
 
HOMEPAGE="http://emby.media/"
11
 
KEYWORDS="-* ~arm ~amd64 ~x86"
12
 
SRC_URI="https://github.com/MediaBrowser/Emby/archive/${PV}.tar.gz"
13
 
SLOT="0"
14
 
LICENSE="GPL-2"
15
 
IUSE=""
16
 
RESTRICT="mirror test"
17
 

	
18
 
RDEPEND=">=dev-lang/mono-4.6.0
19
 
	>=media-video/ffmpeg-2[vpx]
20
 
	media-gfx/imagemagick[jpeg,jpeg2k,webp,png]
21
 
	!media-tv/mediabrowser-server
22
 
	>=dev-db/sqlite-3.0.0
23
 
	dev-dotnet/referenceassemblies-pcl
24
 
	app-misc/ca-certificates"
25
 
DEPEND="app-arch/unzip ${RDEPEND}"
26
 

	
27
 
INSTALL_DIR="/opt/emby-server"
28
 
DATA_DIR="/var/lib/emby-server"
29
 
STARTUP_LOG="/var/log/emby-server_start.log"
30
 
INIT_SCRIPT="${ROOT}/etc/init.d/emby-server"
31
 

	
32
 
# INSTALL
33
 
# #######################################################################################################
34
 

	
35
 
pkg_setup() {
36
 
	einfo "creating user for Emby"
37
 
	enewgroup emby
38
 
	enewuser emby -1 /bin/bash ${INSTALL_DIR} "emby"
39
 

	
40
 
	einfo "updating root certificates for mono certificate store"
41
 
        addwrite "/usr/share/.mono/keypairs"
42
 
	dotnet_pkg_setup
43
 
        cert-sync /etc/ssl/certs/ca-certificates.crt
44
 
}
45
 

	
46
 
# gentoo expects a specific subfolder in the working directory for the extracted source, so simply extracting won't work here
47
 
src_unpack() {
48
 
        unpack ${A}
49
 
        mv Emby-${PV} emby-server-${PV}
50
 
}
51
 

	
52
 
src_prepare() {
53
 
	# the user can define the quality of the imagemagic himself, here we try to figure out the correct files to use in our configuration
54
 
	MAGICKWAND=$(ldconfig -p | grep MagickWand.*.so$ | cut -d" " -f4)
55
 
	MAGICKWAND=${MAGICKWAND##*/}
56
 
	einfo "adapting to imagemagick library to: ${MAGICKWAND}"
57
 
	sed -i -e "s/\"libMagickWand-6.Q8.so\"/\"${MAGICKWAND}\"/" MediaBrowser.Server.Mono/ImageMagickSharp.dll.config || die "could not update libMagickWand reference!"
58
 
}
59
 

	
60
 

	
61
 
src_compile() {
62
 
	xbuild /p:Configuration="Release Mono" /p:Platform="Any CPU" MediaBrowser.sln || die "building failed"
63
 
}
64
 

	
65
 
src_install() {
66
 
	einfo "preparing startup scripts"
67
 
	newinitd "${FILESDIR}"/emby-server.init_3  ${PN}
68
 
	newconfd "${FILESDIR}"/emby-server.conf ${PN}
69
 

	
70
 
	einfo "preparing startup log file"
71
 
	dodir /var/log/
72
 
	touch ${D}${STARTUP_LOG}
73
 
	chown emby:emby ${D}${STARTUP_LOG}
74
 

	
75
 
	einfo "installing compiled files"
76
 
	diropts -oemby -gemby
77
 
	dodir ${INSTALL_DIR}
78
 
	cp -R ${S}/MediaBrowser.Server.Mono/bin/Release/* ${D}${INSTALL_DIR}/ || die "install failed, possibly compile did not succeed earlier?"
79
 
	chown emby:emby -R ${D}${INSTALL_DIR}
80
 

	
81
 
	einfo "prepare data directory"
82
 
	dodir ${DATA_DIR}
83
 
}
84
 

	
85
 
pkg_postinst() {
86
 
	einfo "emby-server was installed to ${INSTALL_DIR}, to start please use the init script provided."
87
 
	einfo "All data generated and used by Emby can be found at ${DATA_DIR} after the first start."
88
 
	einfo ""
89
 

	
90
 
	if [[ -d "/usr/lib/mediabrowser-server" || -h "/usr/lib/mediabrowser-server" ]]; then
91
 
		ewarn "ATTENTION: You seem to have moved from the former mediabrowser-server package:"
92
 
		ewarn "don't forget to migrate your original data directory before the first start!"
93
 
		ewarn "To do that move"
94
 
		ewarn "     /usr/lib/mediabrowser-server"
95
 
		ewarn "to"
96
 
		ewarn "     ${DATA_DIR}"
97
 
		ewarn "and change owner status from mediabrowser:mediabrowser to emby:emby!"
98
 
		ewarn "     chown -R emby:emby ${DATA_DIR}"
99
 
	fi
100
 

	
101
 
	if [[ -d "/usr/lib/emby-server" || -h "/usr/lib/emby-server"  ]]; then
102
 
		ewarn "ATTENTION: You seem to have existing program data at /usr/lib/emby-server!"
103
 
		ewarn "Please move that folder to ${DATA_DIR} before the first start and make sure the folder is owned by emby:emby"
104
 
		ewarn "The folder /usr/lib/emby-server will be repurposed in one of the next releases, so make sure to clean that directory up!"
105
 
	fi
106
 
}
107
 

	
108
 
# UNINSTALL
109
 
# #######################################################################################################
110
 

	
111
 
pkg_prerm() {
112
 
	einfo "Stopping running instances of Emby Server"
113
 
	if [ -e "${INIT_SCRIPT}" ]; then
114
 
		${INIT_SCRIPT} stop
115
 
	fi
116
 
}
0 comments (0 inline, 0 general)