/[gentoo-x86]/app-misc/lcdproc/lcdproc-0.5.0-r1.ebuild
Gentoo

Contents of /app-misc/lcdproc/lcdproc-0.5.0-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Wed Oct 11 21:16:40 2006 UTC (14 years, 1 month ago) by jokey
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +1 -1 lines
FILE REMOVED
Fixing doc generation, adding CVS snapshot and new dep: g15
(Portage version: 2.1.2_pre2-r7)
 (Signed Manifest commit)

1 # Copyright 1999-2006 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/app-misc/lcdproc/lcdproc-0.5.0-r1.ebuild,v 1.2 2006/09/25 16:36:46 jokey Exp $
4
5 inherit flag-o-matic
6
7 DESCRIPTION="Client/Server suite to drive all kinds of LCD (-like) devices"
8 HOMEPAGE="http://lcdproc.org/"
9 SRC_URI="mirror://sourceforge/lcdproc/${P}.tar.gz"
10
11 LICENSE="GPL-2"
12 SLOT="0"
13 KEYWORDS="~ppc64 ~x86"
14
15 # general use keywords in first line, drivers in line 2
16 IUSE="doc debug ldap nfs samba usb
17 graphlcd irman lirc ncurses svga ula200 xosd"
18
19 DEPEND="sys-apps/sed
20 >=sys-kernel/linux-headers-2.6.11
21 doc? ( app-text/docbook-sgml-utils )
22 ldap? ( net-nds/openldap )
23 usb? ( dev-libs/libusb )
24
25 graphlcd? ( app-misc/graphlcd-base )
26 irman? ( media-libs/libirman )
27 lirc? ( app-misc/lirc )
28 ncurses? ( sys-libs/ncurses )
29 svga? ( media-libs/svgalib )
30 ula200? ( dev-embedded/libftdi dev-libs/libusb )
31 xosd? ( x11-libs/xosd ) "
32 RDEPEND=${DEPEND}
33
34 USE_DRIVERS="curses glcdlib irman lirc svga ula200 xosd"
35 EXTRA_DRIVERS="bayrad CFontz CFontz633 CFontzPacket CwLnx \
36 glk hd44780 icp_a106 imon IOWarrior joy lb216 lcdm001 \
37 lcterm ms6931 mtc_s16209x MtxOrb NoritakeVFD pyramid sed1330 \
38 sed1520 serialVFD sli stv5730 t6963 text tyan "
39 ALL_DRIVERS="${USE_DRIVERS} ${EXTRA_DRIVERS}"
40
41
42 # compatibility with 1.4-ebuild format
43 LCDPROC_DRIVERS=${LCDPROC_DRIVERS//,/ }
44
45 # if no drivers or all are set, select the defaults
46 has all ${LCDPROC_DRIVERS} \
47 && LCDPROC_DRIVERS="${EXTRA_DRIVERS}"
48 [ -z "${LCDPROC_DRIVERS}" ] \
49 && LCDPROC_DRIVERS="${EXTRA_DRIVERS}"
50 has none ${LCDPROC_DRIVERS} \
51 && LCDPROC_DRIVERS=""
52
53 pkg_setup() {
54
55 echo
56 einfo "If you are updating from lcdproc-0.4, note that the setup of drivers has changed:"
57 einfo "The drivers curses, glcdlib, irman, lirc, svga, ula200 and xosd are controlled by use flags."
58 einfo "All other drivers are built by default, or in respect to the env variable"
59 einfo "LCDPROC_DRIVERS which can be a space separated list. Example:"
60 einfo " LCDPROC_DRIVERS=\"text CFontz\" emerge lcdproc"
61 einfo "You can also set this variable in your make.conf."
62 echo
63 einfo "Possible choices for LCDPROC_DRIVERS are:"
64 einfo " bayrad CFontz CFontz633 CFontzPacket CwLnx glk hd44780 "
65 einfo " icp_a106 imon IOWarrior joy lb216 lcdm001 lcterm "
66 einfo " ms6931 mtc_s16209x MtxOrb NoritakeVFD pyramid sed1330 "
67 einfo " sed1520 serialVFD sli stv5730 t6963 text tyan"
68 einfo " 'all' if you want to include all drivers (default)."
69 einfo " 'none' will not include any extra drivers."
70 echo
71
72 local FILTERED_DRIVERS
73 for driver in ${LCDPROC_DRIVERS}; do
74 if has ${driver} ${EXTRA_DRIVERS} ; then
75 FILTERED_DRIVERS="${FILTERED_DRIVERS} ${driver}"
76 else
77 eerror "The extra driver '${driver}' is not available or has to be enabled by a USE flag."
78 eerror "Please check your LCDPROC_DRIVERS-variable!"
79 echo
80 fi
81 done
82 LCDPROC_DRIVERS="${FILTERED_DRIVERS}"
83
84 einfo "The following drivers will be built: "
85 echo
86
87 # add use-flag specific drivers to LCDPROC_DRIVERS
88 use graphlcd && LCDPROC_DRIVERS="${LCDPROC_DRIVERS} glcdlib"
89 use irman && LCDPROC_DRIVERS="${LCDPROC_DRIVERS} irman"
90 use lirc && LCDPROC_DRIVERS="${LCDPROC_DRIVERS} lirc"
91 use ncurses && LCDPROC_DRIVERS="${LCDPROC_DRIVERS} curses"
92 use svga && LCDPROC_DRIVERS="${LCDPROC_DRIVERS} svga"
93 use ula200 && LCDPROC_DRIVERS="${LCDPROC_DRIVERS} ula200"
94 use xosd && LCDPROC_DRIVERS="${LCDPROC_DRIVERS} xosd"
95
96 for driver in ${ALL_DRIVERS}; do
97 has ${driver} ${LCDPROC_DRIVERS} && einfo $driver
98 done
99 echo
100
101 has glcdlib ${LCDPROC_DRIVERS} || has all ${LCDPROC_DRIVERS} \
102 && ewarn "Support for glcdlib might not work if you do not manually install" \
103 && ewarn "GLCDprocDriver from http://www.muresan.de/graphlcd/lcdproc/"
104 }
105
106 src_unpack() {
107 unpack ${A}
108 cd "${S}"
109 epatch "${FILESDIR}/${PV}-LCDd-conf-driver-path.patch"
110 }
111
112 src_compile() {
113 # avoid executable stack as mentioned
114 # in http://www.gentoo.org/proj/en/hardened/gnu-stack.xml
115 append-ldflags -Wl,-z,noexecstack
116
117 # convert space separated LCDPROC_DRIVERS to comma separated COMMA_DRIVERS
118 local COMMA_DRIVERS
119 for driver in ${LCDPROC_DRIVERS}; do
120 if [ -z "${COMMA_DRIVERS}" ] ; then
121 COMMA_DRIVERS="${driver}"
122 else
123 COMMA_DRIVERS="${COMMA_DRIVERS},${driver}"
124 fi
125 done
126
127 # CPPFLAGS to get CF-635 working
128 append-flags -DSEAMLESS_HBARS -DCFONTZ633_WRITE_DELAY=50
129
130 econf \
131 $(use_enable debug) \
132 $(use_enable ldap) \
133 $(use_enable nfs stat-nfs) \
134 $(use_enable samba stat-smbfs ) \
135 $(use_enable usb libusb) \
136 "--enable-drivers=${COMMA_DRIVERS}" \
137 || die "configure failed"
138
139 if use doc; then
140 cd ${S}/docs/lcdproc-user
141 docbook2html lcdproc-user.docbook
142 fi
143
144 emake || die "make failed"
145 }
146
147 src_install() {
148 dosbin server/LCDd
149 dobin clients/lcdproc/lcdproc clients/lcdexec/lcdexec
150
151 insinto /usr/share/lcdproc/drivers
152 doins server/drivers/*.so
153
154 insinto /usr/share/lcdproc/clients
155 doins clients/examples/*.pl
156 doins clients/metar/lcdmetar.pl
157 doins clients/headlines/lcdheadlines
158
159 insinto /etc
160 doins LCDd.conf
161 doins scripts/lcdproc.conf
162
163 newinitd "${FILESDIR}/${PV}-LCDd" LCDd
164 newinitd "${FILESDIR}/lcdproc" lcdproc
165
166 doman docs/*.1 docs/*.8
167 dodoc README CREDITS ChangeLog INSTALL
168 dodoc docs/README.* docs/*.txt
169
170 if use doc; then
171 insinto /usr/share/doc/${PF}/lcdproc-user
172 doins docs/lcdproc-user/*.html
173 fi
174 }

  ViewVC Help
Powered by ViewVC 1.1.20