Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 90466
Collapse All | Expand All

(-)/usr/portage/sci-libs/libticables/libticables-3.8.6.ebuild (-17 / +85 lines)
Lines 1-42 Link Here
1
# Copyright 1999-2005 Gentoo Foundation
1
# Copyright 1999-2005 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
# $Header: /var/cvsroot/gentoo-x86/sci-libs/libticables/libticables-3.8.6.ebuild,v 1.3 2005/03/11 11:46:10 sekretarz Exp $
3
# $Header: $
4
5
inherit eutils linux-info
4
6
5
DESCRIPTION="Link cables support for the TiLP calculator linking program"
7
DESCRIPTION="Link cables support for the TiLP calculator linking program"
6
HOMEPAGE="http://tilp.info/"
8
HOMEPAGE="http://tilp.info/"
7
SRC_URI="mirror://gentoo/${P}-gentoo.tar.bz2"
9
SRC_URI="mirror://sourceforge/tilp/${P}.tar.gz"
8
LICENSE="GPL-2"
10
LICENSE="GPL-2"
9
11
10
SLOT="0"
12
SLOT="0"
11
KEYWORDS="x86 ppc ~amd64"
13
KEYWORDS="x86 ~ppc ~amd64"
12
IUSE="debug nls"
14
IUSE="debug nls usb serial parallel"
13
15
14
RDEPEND="virtual/libc
16
RDEPEND="virtual/libc
15
	nls? ( sys-devel/gettext )"
17
	nls? ( sys-devel/gettext )
18
	usb? ( dev-libs/libusb )"
19
#	serial? ( )
16
20
17
DEPEND="${RDEPEND}
21
DEPEND="${RDEPEND}
18
	sys-devel/bison"
22
	sys-devel/bison"
19
23
20
S=${WORKDIR}/${P}-gentoo
24
pkg_setup() {
25
	if ! use usb &&	! use serial && ! use parallel ; then
26
		eerror "You have not selected any link cable support"
27
		eerror "(usb, serial or paralell)"
28
		eerror "You are going to be unable to use \"${PN}\" properly!"
29
		ebeep
30
	fi
31
32
	if use parallel && ! linux_chkconfig_present TIPAR ; then
33
		eerror "You have chosen by selecting 'USE=parallel' to have"
34
		eerror "parallel cable support but you dont have CONFIG_TIPAR"
35
		eerror "inside your kernel configuration. Please enable parallel"
36
		eerror "link cable support inside your kernel config, found at:"
37
		echo
38
		eerror " Device Drivers"
39
		eerror "   Character devices"
40
		eerror "      <*> Texas Instruments parallel link cable support"
41
		echo
42
		eerror "and then recompile your kernel ..."
43
		die "parallel link cable support not detected"
44
	fi
45
46
# This condition should be made by the tiser module ebuild
47
#
48
#	if use serial && ! linux_chkconfig_present SERIAL_8250 ; then
49
#		eerror "You have chosen by selecting 'USE=serial' to have"
50
#		eerror "parallel cable support but you dont have CONFIG_SERIAL_8250"
51
#		eerror "inside your kernel configuration. Please enable serial ports"
52
#		eerror "support inside your kernel config, found at:"
53
#		echo
54
#		eerror " Device Drivers"
55
#		eerror "   Character devices"
56
#		eerror "      Serial drivers"
57
#		eerror "        <*> 8250/16550 and compatible serial support"
58
#		echo
59
#		eerror "and then recompile your kernel ..."
60
#		die "serial ports support not detected"
61
#	fi
62
}
21
63
22
src_compile() {
64
src_compile() {
23
	local myconf="$(use_enable nls) $(use_enable debug logging)"
65
	local myconf
24
	econf ${myconf} || die
66
25
	emake || die
67
	myconf="${myconf} $(use_enable nls)"
68
	myconf="${myconf} $(use_enable debug logging)"
69
	# Make sure that usb kernel module support is not
70
	# used, its deprecated, not supported and Portage
71
	# Tree do not provide the external module.
72
	# Use libusb instead (USE=usb)
73
	myconf="${myconf} --disable-direct-usb"
74
75
	econf ${myconf} || die "econf died"
76
	emake || die "emake died"
26
}
77
}
27
78
28
src_install() {
79
src_install() {
29
	make install DESTDIR=${D}
80
	make install DESTDIR=${D}
30
	dobin ticables-config
31
	dodoc AUTHORS ChangeLog LOGO README
81
	dodoc AUTHORS ChangeLog LOGO README
32
	doman ticables-config.1
33
}
82
}
34
83
35
pkg_postinst() {
84
pkg_postinst() {
36
	einfo "To use \"${PN}\", you might need one of the following"
85
	if ! use usb ; then
37
	einfo "kernel modules: \"tipar\", \"tiser\" or \"tiusb\". If you install"
86
		ewarn "In order to use \"${PN}\" with an USB/SilverLink cable, you"
38
	einfo "one of these modules, you might have to reinstall"
87
		ewarn "need to compile it with USE=usb and then rebuild \"${PN}\""
39
	einfo "\"${PN}\". Please read the file:"
88
		ewarn "Note that the use of direct-usb (tiusb) is depecrated"
40
	einfo "\"/usr/share/doc/${PF}/README.gz\" for more"
89
		ewarn "Please read the file: \"/usr/share/doc/${PF}/README.gz\""
41
	einfo "details."
90
		ewarn "for more details."
91
		echo ""
92
	fi
93
94
	if ! use serial ; then
95
		ewarn "In order to use \"${PN}\" with a serial/BlackLink cable,"
96
		ewarn "you need to compile it with USE=serial and then rebuild"
97
		ewarn "\"${PN}\""
98
		ewarn "Please read the file: \"/usr/share/doc/${PF}/README.gz\""
99
		ewarn "for more details."
100
		echo ""
101
	fi
102
103
	if ! use parallel; then
104
		ewarn "In order to use \"${PN}\" with a parallel link cable you need to"
105
		ewarn "have CONFIG_TIPAR in your kernel config and select"
106
		ewarn "'USE=parallel' then rebuild \"${PN}\""
107
		ewarn "Please read the file: \"/usr/share/doc/${PF}/README.gz\""
108
		ewarn "for more details."
109
	fi
42
}
110
}

Return to bug 90466