Gentoo Archives: gentoo-commits

From: "Steve Arnold (nerdboy)" <nerdboy@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-misc/hylafax: ChangeLog hylafax-6.0.3.ebuild
Date: Mon, 28 Sep 2009 03:52:20
Message-Id: E1Ms7Hd-0001xn-3K@stork.gentoo.org
1 nerdboy 09/09/28 03:52:17
2
3 Modified: ChangeLog
4 Added: hylafax-6.0.3.ebuild
5 Log:
6 Updated to newest upstream release (closes bug 267984).
7 (Portage version: 2.2_rc33/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.97 net-misc/hylafax/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/hylafax/ChangeLog?rev=1.97&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/hylafax/ChangeLog?rev=1.97&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/hylafax/ChangeLog?r1=1.96&r2=1.97
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/net-misc/hylafax/ChangeLog,v
19 retrieving revision 1.96
20 retrieving revision 1.97
21 diff -u -r1.96 -r1.97
22 --- ChangeLog 29 Aug 2009 18:22:54 -0000 1.96
23 +++ ChangeLog 28 Sep 2009 03:52:16 -0000 1.97
24 @@ -1,6 +1,12 @@
25 # ChangeLog for net-misc/hylafax
26 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/net-misc/hylafax/ChangeLog,v 1.96 2009/08/29 18:22:54 betelgeuse Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/net-misc/hylafax/ChangeLog,v 1.97 2009/09/28 03:52:16 nerdboy Exp $
29 +
30 +*hylafax-6.0.3 (28 Sep 2009)
31 +
32 + 28 Sep 2009; Steve Arnold <nerdboy@g.o> +hylafax-6.0.3.ebuild:
33 + Updated to newest upstream release (closes bug 267984). The locale stuff
34 + is new, so could use some testing...
35
36 29 Aug 2009; Petteri Räty <betelgeuse@g.o>
37 hylafax-4.4.4-r2.ebuild:
38
39
40
41 1.1 net-misc/hylafax/hylafax-6.0.3.ebuild
42
43 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/hylafax/hylafax-6.0.3.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/hylafax/hylafax-6.0.3.ebuild?rev=1.1&content-type=text/plain
45
46 Index: hylafax-6.0.3.ebuild
47 ===================================================================
48 # Copyright 1999-2009 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/net-misc/hylafax/hylafax-6.0.3.ebuild,v 1.1 2009/09/28 03:52:16 nerdboy Exp $
51
52 EAPI="2"
53
54 inherit eutils multilib pam toolchain-funcs
55
56 DESCRIPTION="Enterprise client-server fax package for class 1 and 2 fax modems."
57 HOMEPAGE="http://www.hylafax.org"
58 SRC_URI="ftp://ftp.hylafax.org/source/${P}.tar.gz"
59
60 SLOT="0"
61 LICENSE="hylafax"
62 KEYWORDS="~amd64 ~hppa ~ppc ~sparc ~x86"
63
64 IUSE="jbig pam mgetty html"
65
66 DEPEND=">=sys-libs/zlib-1.1.4
67 virtual/ghostscript
68 >=media-libs/tiff-3.9.1[jbig?]
69 media-libs/jpeg
70 jbig? ( media-libs/jbigkit )
71 sys-apps/gawk
72 pam? ( virtual/pam )
73 mgetty? ( net-dialup/mgetty[-fax] )"
74
75 RDEPEND="${DEPEND}
76 net-mail/metamail
77 !net-dialup/sendpage"
78
79 export CONFIG_PROTECT="${CONFIG_PROTECT} /var/spool/fax/etc /usr/lib/fax"
80
81 src_prepare() {
82 # force it not to strip binaries
83 for dir in etc util faxalter faxcover faxd faxmail faxrm faxstat \
84 hfaxd sendfax sendpage ; do
85 sed -i -e "s:-idb:-idb \"nostrip\" -idb:g" \
86 "${dir}"/Makefile.in || die "sed failed"
87 done
88
89 sed -i -e "s|-fpic|-fPIC|g" \
90 configure || die
91
92 # new locale stuff lacks DESTDIR
93 sed -i -e "s|\${LOCALEDIR}|\${DESTDIR}\${LOCALEDIR}|g" \
94 po/nls.mk || die
95 }
96
97 src_configure() {
98 # update TIFF check to allow 3.9.x
99 sed -i \
100 -e "s|5678|56789|" \
101 -e "s|3.8.|3.9.|" \
102 configure || die
103
104 local my_conf="
105 --with-DIR_BIN=/usr/bin
106 --with-DIR_SBIN=/usr/sbin
107 --with-DIR_LIB=/usr/$(get_libdir)
108 --with-DIR_LIBEXEC=/usr/sbin
109 --with-DIR_LIBDATA=/usr/$(get_libdir)/fax
110 --with-DIR_LOCALE=/usr/share/locale
111 --with-DIR_LOCKS=/var/lock
112 --with-DIR_MAN=/usr/share/man
113 --with-DIR_SPOOL=/var/spool/fax
114 --with-DIR_HTML=/usr/share/doc/${P}/html
115 --with-DIR_CGI="${WORKDIR}"
116 --with-PATH_DPSRIP=/var/spool/fax/bin/ps2fax
117 --with-PATH_IMPRIP=\"\"
118 --with-SYSVINIT=no
119 --with-REGEX=yes
120 --with-LIBTIFF=\"-ltiff -ljpeg -lz\"
121 --with-OPTIMIZER=\"${CFLAGS}\"
122 --with-DSO=auto"
123
124 if use html; then
125 my_conf="${my_conf} --with-HTML=yes"
126 else
127 my_conf="${my_conf} --with-HTML=no"
128 fi
129
130 if use mgetty; then
131 my_conf="${my_conf} \
132 --with-PATH_GETTY=/sbin/mgetty \
133 --with-PATH_EGETTY=/sbin/mgetty \
134 --with-PATH_VGETTY=/usr/sbin/vgetty"
135 else
136 # GETTY defaults to /sbin/agetty
137 my_conf="${my_conf} \
138 --with-PATH_EGETTY=/bin/false \
139 --with-PATH_VGETTY=/bin/false"
140 fi
141
142 if [ -h /etc/localtime ]; then
143 local continent=$(readlink /etc/localtime | cut -d / -f 5)
144 if [ "${continent}" == "Europe" ]; then
145 my_conf="${my_conf} --with-PAGESIZE=A4"
146 fi
147 fi
148
149 #--enable-pam isn't valid
150 use pam || my_conf="${my_conf} $(use_enable pam)"
151
152 myconf="CC=$(tc-getCC) CXX=$(tc-getCXX) ${my_conf}"
153
154 # eval required for quoting in ${my_conf} to work properly, better way?
155 eval ./configure --nointeractive ${my_conf} || die "./configure failed"
156 }
157
158 src_compile() {
159 emake -j1 || die "emake failed"
160 }
161
162 src_install() {
163 dodir /usr/{bin,sbin} /usr/$(get_libdir)/fax /usr/share/man
164 dodir /var/spool /var/spool/recvq
165 fowners uucp:uucp /var/spool/fax
166 fperms 0600 /var/spool/fax
167 dodir /usr/share/doc/${P}/html
168
169 emake \
170 BIN=${D}/usr/bin \
171 SBIN=${D}/usr/sbin \
172 LIBDIR=${D}/usr/$(get_libdir) \
173 LIB=${D}/usr/$(get_libdir) \
174 LIBEXEC=${D}/usr/sbin \
175 LIBDATA=${D}/usr/$(get_libdir)/fax \
176 DIR_LOCALE=${D}/usr/share/locale \
177 MAN=${D}/usr/share/man \
178 SPOOL=${D}/var/spool/fax \
179 HTMLDIR=${D}/usr/share/doc/${P}/html \
180 install DESTDIR="${D}" || die "make install failed"
181
182 keepdir /var/spool/fax/{archive,client,etc,pollq,recvq,tmp}
183 keepdir /var/spool/fax/{status,sendq,log,info,doneq,docq,dev}
184
185 dosed "s:hostname:hostname -f:g" /var/spool/fax/bin/{faxrcvd,pollrcvd} \
186 || die "dosed hostname failed"
187
188 generate_files # in this case, it only generates the env.d entry
189
190 einfo "Adding env.d entry for Hylafax"
191 doenvd 99${P}
192
193 einfo "Adding init.d and conf.d entries for Hylafax"
194 newconfd "${FILESDIR}"/${PN}.conf ${PN}
195 newinitd "${FILESDIR}"/${PN}.init ${PN}
196
197 use pam && pamd_mimic_system hylafax auth account session
198
199 dodoc CONTRIBUTORS README TODO
200 }
201
202 pkg_postinst() {
203 elog
204 elog "The faxonly USE flag has been removed; since Hylafax does not"
205 elog "require mgetty, and certain fax files conflict, you must build"
206 elog "mgetty without fax support if you wish to use them both. You"
207 elog "may want to add both to package.use so any future updates are"
208 elog "correctly built:"
209 elog
210 elog " net-dialup/mgetty -fax"
211 elog " net-misc/hylafax [-mgetty|mgetty]"
212 elog
213 elog "There are additional files included in the hylafax/files dir."
214 elog
215 elog "Note 1: hylafax.cron is provided for vixie-cron users and"
216 elog "should be placed in /etc/cron.d. Use as-is or adapt it to"
217 elog "your system config."
218 elog
219 elog "Note 2: if you need to use hylafax with iptables, then you"
220 elog "need to specify the port and use ip_conntrack_ftp as shown"
221 elog "in the included example modules file."
222 elog
223 elog "If you have clients that still use the old protocol (not the"
224 elog "common FTP style protocol), they will no longer work with the"
225 elog "new hfaxd daemon."
226 elog
227 elog "See the docs and man pages for detailed configuration info."
228 elog
229 elog "Now run faxsetup and (if necessary) faxaddmodem."
230 elog
231 }
232
233 generate_files() {
234 cat <<-EOF > 99${P}
235 PATH="/var/spool/fax/bin"
236 CONFIG_PROTECT="/var/spool/fax/etc /usr/$(get_libdir)/fax"
237 EOF
238 }