Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 577850 | Differences between
and this patch

Collapse All | Expand All

(-)tora-3.0.0_pre20140929-r2.ebuild (-34 / +44 lines)
Lines 1-84 Link Here
1
# Copyright 1999-2016 Gentoo Foundation
1
# Copyright 1999-2017 Gentoo Foundation
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
3
4
EAPI=5
4
EAPI=6
5
5
6
inherit cmake-utils eutils
6
inherit cmake-utils eutils
7
7
8
if [[ ${PV} == 9999 ]]; then
8
if [[ ${PV} == 9999 ]]; then
9
	ESVN_REPO_URI="https://svn.code.sf.net/p/tora/code/trunk/tora"
9
	EGIT_REPO_URI="https://github.com/tora-tool/tora"
10
	inherit subversion
10
	inherit git-r3
11
	SRC_URI=""
12
else
11
else
13
	SRC_URI="https://dev.gentoo.org/~pinkbyte/distfiles/snapshots/${P}.tar.xz"
12
	SRC_URI="https://github.com/tora-tool/tora/archive/v${PV}.tar.gz -> ${P}.tar.gz"
13
	KEYWORDS="~amd64 ~x86"
14
fi
14
fi
15
15
16
DESCRIPTION="TOra - Toolkit For Oracle"
16
DESCRIPTION="SQL IDE for Oracle, MySQL and PostgreSQL dbs"
17
HOMEPAGE="http://torasql.com/"
17
HOMEPAGE="https://github.com/tora-tool/tora/wiki"
18
IUSE="debug mysql postgres"
18
IUSE="doc mysql oracle pch postgres"
19
19
20
SLOT="0"
20
SLOT="0"
21
LICENSE="GPL-2"
21
LICENSE="GPL-2"
22
KEYWORDS="~amd64 ~x86"
23
22
24
RDEPEND="
23
RDEPEND="
25
	dev-libs/ferrisloki
24
	dev-libs/ferrisloki
26
	x11-libs/qscintilla:=[qt4(-)]
25
	dev-qt/qtcore:5
27
	dev-qt/qtgui:4
26
	dev-qt/qtgui:5
28
	dev-qt/qtsql:4[mysql?,postgres?]
27
	dev-qt/qtnetwork:5
29
	dev-qt/qtxmlpatterns:4
28
	dev-qt/qtsql:5[mysql?,postgres?]
30
	=dev-db/oracle-instantclient-basic-11*
29
	dev-qt/qtwidgets:5
30
	dev-qt/qtxml:5
31
	dev-qt/qtxmlpatterns:5
32
	>=x11-libs/qscintilla-2.10.1:=[qt5(+)]
33
	oracle? ( =dev-db/oracle-instantclient-basic-11* )
31
	postgres? ( dev-db/postgresql:* )
34
	postgres? ( dev-db/postgresql:* )
32
"
35
"
33
DEPEND="
36
DEPEND="${RDEPEND}
37
	dev-qt/linguist:5
34
	virtual/pkgconfig
38
	virtual/pkgconfig
35
	${RDEPEND}
39
	doc? ( app-doc/doxygen )
36
"
40
"
37
41
38
pkg_setup() {
42
pkg_setup() {
39
	if [ -z "$ORACLE_HOME" ] ; then
43
	if use oracle && [[ -z "$ORACLE_HOME" ]]; then
40
		eerror "ORACLE_HOME variable is not set."
44
		eerror "ORACLE_HOME variable is not set."
41
		eerror
45
		eerror
42
		eerror "You must install Oracle >= 8i client for Linux in"
46
		eerror "You must install Oracle >= 8i client for Linux in"
43
		eerror "order to compile TOra with Oracle support."
47
		eerror "order to compile TOra with Oracle support."
44
		eerror
48
		eerror
45
		eerror "You can download the Oracle software from"
49
		eerror "You can download the Oracle software from"
46
		eerror "http://otn.oracle.com/software/content.html"
50
		eerror "http://www.oracle.com/technetwork/database/features/instant-client/index.html"
47
		die
51
		die
48
	fi
52
	fi
49
}
53
}
50
54
51
src_prepare() {
55
src_prepare() {
52
	sed -i \
56
	cmake-utils_src_prepare
53
		-e "/COPYING/ d" \
57
54
		CMakeLists.txt || die "Removal of COPYING file failed"
58
	# fixed in master, only care about recent qscintilla lib name:
59
	sed -e "/FIND_LIBRARY(QSCINTILLA_LIBRARY/s/qt5scintilla2/qscintilla2_qt5/" \
60
		-i cmake/modules/FindQScintilla.cmake || die "Failed to fix FindQScintilla.cmake"
61
62
	rm -r extlibs/{loki*,qscintilla2} || die # ferrisloki, bug #383109
63
64
	sed -e "/COPYING/ d" \
65
		-i CMakeLists.txt || die "Removal of COPYING file failed"
66
55
	# bug 547520
67
	# bug 547520
56
	grep -rlZ '$$ORIGIN' . | xargs -0 sed -i 's|:$$ORIGIN[^:"]*||' || \
68
	grep -rlZ '$$ORIGIN' . | xargs -0 sed -i 's|:$$ORIGIN[^:"]*||' || \
57
		die 'Removal of $$ORIGIN failed'
69
		die 'Removal of $$ORIGIN failed'
58
}
70
}
59
71
60
src_configure() {
72
src_configure() {
61
	local mycmakeargs=()
73
	local mycmakeargs=(
62
	mycmakeargs=(-DENABLE_ORACLE=ON)
74
		-DENABLE_DB2=OFF
63
	mycmakeargs+=(
75
		-DQT5_BUILD=ON
64
		-DWANT_RPM=OFF
65
		-DWANT_BUNDLE=OFF
66
		-DWANT_BUNDLE_STANDALONE=OFF
67
		-DWANT_INTERNAL_QSCINTILLA=OFF
68
		-DWANT_INTERNAL_LOKI=OFF
76
		-DWANT_INTERNAL_LOKI=OFF
77
		-DWANT_INTERNAL_QSCINTILLA=OFF
78
		-DWANT_RPM=OFF
69
		-DLOKI_LIBRARY="$(pkg-config --variable=libdir ferrisloki)/libferrisloki.so"
79
		-DLOKI_LIBRARY="$(pkg-config --variable=libdir ferrisloki)/libferrisloki.so"
70
		-DLOKI_INCLUDE_DIR="$(pkg-config --variable=includedir ferrisloki)/FerrisLoki"
80
		-DLOKI_INCLUDE_DIR="$(pkg-config --variable=includedir ferrisloki)/FerrisLoki"
71
		$(cmake-utils_use_enable postgres PGSQL)
81
		$(cmake-utils_use_find_package doc Doxygen)
72
		$(cmake-utils_use_want debug)
82
		-DENABLE_ORACLE=$(usex oracle)
73
		# path variables
83
		-DUSE_PCH=$(usex pch)
74
		-DTORA_DOC_DIR=share/doc/${PF}
84
		-DENABLE_PGSQL=$(usex postgres)
75
	)
85
	)
76
	cmake-utils_src_configure
86
	cmake-utils_src_configure
77
}
87
}
78
88
79
src_install() {
89
src_install() {
80
	cmake-utils_src_install
90
	cmake-utils_src_install
81
	#
91
82
	doicon src/icons/${PN}.xpm || die
92
	doicon src/icons/${PN}.xpm || die
83
	domenu src/${PN}.desktop || die
93
	domenu src/${PN}.desktop || die
84
}
94
}

Return to bug 577850