aboutsummaryrefslogtreecommitdiffstats
path: root/media-video/droidcam/droidcam-3.5.4.ebuild
blob: 1ae0fca664f53d94e54a6d20edbed7b2cdb94349 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI=5

inherit eutils linux-mod user

DESCRIPTION="Use your Android phone as a wireless webcam"
HOMEPAGE="http://www.dev47apps.com/"
SRC_URI="x86? ( http://www.dev47apps.com/files/droidcam-v4l2-x86.tar.gz )
	amd64? ( http://www.dev47apps.com/files/droidcam-v4l2-x64.tar.gz )"

LICENSE="as-is"

SLOT="0"
KEYWORDS="~x86 ~amd64"
IUSE=""
DEPEND="net-wireless/bluez"
RDEPEND="${DEPEND}"

BUILD_TARGETS="all"
BUILD_TARGET_ARCH="${ARCH}"
MODULE_NAMES="v4l2loopback-dc(droid:${S})"

src_unpack() {
	if use x86 ; then 
		unpack droidcam-v4l2-x86.tar.gz
	fi

	if use amd64 ; then
		unpack droidcam-v4l2-x64.tar.gz
	fi
	mkdir "${WORKDIR}"/droidcam-3.5.4
	mv v4l2loopback/* "${WORKDIR}"/droidcam-3.5.4
	rmdir v4l2loopback
	mv README droidcam icon.png install "${WORKDIR}"/droidcam-3.5.4
}

src_install() {
	cd "${S}"
	mv icon.png droidcam.png
	dobin droidcam
	doicon droidcam.png
	linux-mod_src_install
	dodoc README
	domenu "${FILESDIR}"/droidcam.desktop
}