summaryrefslogtreecommitdiff
blob: 505fd537ab119dc1a8e80248d89868a8c59b370a (plain)
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=7

inherit desktop virtualx

DESCRIPTION="ROX-Filer a drag and drop spatial file manager"
HOMEPAGE="http://rox.sourceforge.net/desktop/ROX-Filer.html"
SRC_URI="https://download.sourceforge.net/rox/${P}.tar.bz2"

LICENSE="GPL-2+ LGPL-2+"
SLOT="0"
KEYWORDS="amd64 ~arm ~arm64 x86"

COMMON_DEPEND="dev-lang/perl
	dev-libs/libxml2:2
	gnome-base/libglade:2.0
	x11-libs/gtk+:2
	x11-libs/libSM"
RDEPEND="${COMMON_DEPEND}
	x11-misc/shared-mime-info"
DEPEND="${COMMON_DEPEND}
	dev-util/intltool
	sys-devel/gettext"
BDEPEND="virtual/pkgconfig"

S="${WORKDIR}/${P}/ROX-Filer/src"

PATCHES=(
	"${FILESDIR}/${P}-in-source-build.patch"
	"${FILESDIR}/${P}-gcc10.patch"
)

src_prepare() {
	default

	sed -i -e 's:g_strdup(getenv("APP_DIR")):"/usr/share/rox":' \
		main.c || die "sed failed"
}

src_configure() {
	econf LIBS="-lm -ldl"
}

src_install() {
	cd "${WORKDIR}/${P}"/ROX-Filer || die
	dodir /usr/share/applications  /usr/share/pixmaps  /usr/share/rox/Help
	insinto /usr/share/rox
	doins -r Messages Options.xml ROX images style.css .DirIcon Templates.ui
	insinto /usr/share/rox/Help
	doins Help/*.html Help/README*

	doman ../rox.1

	newbin ROX-Filer rox

	dosym text-x-diff.png /usr/share/rox/ROX/MIME/text-x-patch.png
	dosym application-x-font-afm.png /usr/share/rox/ROX/MIME/application-x-font-type1.png
	dosym application-xml.png /usr/share/rox/ROX/MIME/application-xml-dtd.png
	dosym application-xml.png /usr/share/rox/ROX/MIME/application-xml-external-parsed-entity.png
	dosym application-xml.png /usr/share/rox/ROX/MIME/application-rdf+xml.png
	dosym application-xml.png /usr/share/rox/ROX/MIME/application-x-xbel.png
	dosym application-x-shellscript.png /usr/share/rox/ROX/MIME/application-javascript.png
	dosym application-x-bzip-compressed-tar.png /usr/share/rox/ROX/MIME/application-x-xz-compressed-tar.png
	dosym application-x-bzip-compressed-tar.png /usr/share/rox/ROX/MIME/application-x-lzma-compressed-tar.png
	dosym application-x-bzip-compressed-tar.png /usr/share/rox/ROX/MIME/application-x-lzo.png
	dosym application-x-bzip.png /usr/share/rox/ROX/MIME/application-x-xz.png
	dosym application-x-gzip.png /usr/share/rox/ROX/MIME/application-x-lzma.png
	dosym application-msword.png /usr/share/rox/ROX/MIME/application-rtf.png

	dosym ../rox/.DirIcon /usr/share/pixmaps/rox.png

	domenu "${FILESDIR}"/rox.desktop
}