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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (show annotations) (download)
Sun Jan 28 15:19:14 2007 UTC (13 years, 10 months ago) by rbu
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +1 -1 lines
FILE REMOVED
Cleaning out old 0.5.0 version
(Portage version: 2.1.1-r2)
 (Signed Manifest commit)

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

  ViewVC Help
Powered by ViewVC 1.1.20