Gentoo Archives: gentoo-commits

From: "Patrick Lauer (patrick)" <patrick@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-db/firebird: firebird-2.5.1.26351.0.ebuild ChangeLog firebird-2.5.0.26074.0-r1.ebuild firebird-2.5.0.26074.0-r2.ebuild
Date: Fri, 30 Dec 2011 06:25:17
Message-Id: 20111230062504.968822001D@flycatcher.gentoo.org
1 patrick 11/12/30 06:25:04
2
3 Modified: ChangeLog
4 Added: firebird-2.5.1.26351.0.ebuild
5 Removed: firebird-2.5.0.26074.0-r1.ebuild
6 firebird-2.5.0.26074.0-r2.ebuild
7 Log:
8 Bump for #392469
9
10 (Portage version: 2.2.0_alpha81/cvs/Linux x86_64)
11
12 Revision Changes Path
13 1.109 dev-db/firebird/ChangeLog
14
15 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/firebird/ChangeLog?rev=1.109&view=markup
16 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/firebird/ChangeLog?rev=1.109&content-type=text/plain
17 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/firebird/ChangeLog?r1=1.108&r2=1.109
18
19 Index: ChangeLog
20 ===================================================================
21 RCS file: /var/cvsroot/gentoo-x86/dev-db/firebird/ChangeLog,v
22 retrieving revision 1.108
23 retrieving revision 1.109
24 diff -u -r1.108 -r1.109
25 --- ChangeLog 15 Nov 2011 15:26:09 -0000 1.108
26 +++ ChangeLog 30 Dec 2011 06:25:04 -0000 1.109
27 @@ -1,6 +1,16 @@
28 # ChangeLog for dev-db/firebird
29 # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
30 -# $Header: /var/cvsroot/gentoo-x86/dev-db/firebird/ChangeLog,v 1.108 2011/11/15 15:26:09 jer Exp $
31 +# $Header: /var/cvsroot/gentoo-x86/dev-db/firebird/ChangeLog,v 1.109 2011/12/30 06:25:04 patrick Exp $
32 +
33 +*firebird-2.5.1.26351.0 (30 Dec 2011)
34 +
35 + 30 Dec 2011; Patrick Lauer <patrick@g.o>
36 + +files/firebird-2.5.1.26351.0-client.patch,
37 + +files/firebird-2.5.1.26351.0-deps-flags.patch,
38 + +files/firebird-2.5.1.26351.0-superclassic.patch,
39 + +firebird-2.5.1.26351.0.ebuild, -firebird-2.5.0.26074.0-r1.ebuild,
40 + -firebird-2.5.0.26074.0-r2.ebuild:
41 + Bump for #392469
42
43 15 Nov 2011; Jeroen Roovers <jer@g.o> metadata.xml:
44 Fix maintainer order to reflect description, adjust description accordingly.
45
46
47
48 1.1 dev-db/firebird/firebird-2.5.1.26351.0.ebuild
49
50 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/firebird/firebird-2.5.1.26351.0.ebuild?rev=1.1&view=markup
51 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/firebird/firebird-2.5.1.26351.0.ebuild?rev=1.1&content-type=text/plain
52
53 Index: firebird-2.5.1.26351.0.ebuild
54 ===================================================================
55 # Copyright 1999-2011 Gentoo Foundation
56 # Distributed under the terms of the GNU General Public License v2
57 # $Header: /var/cvsroot/gentoo-x86/dev-db/firebird/firebird-2.5.1.26351.0.ebuild,v 1.1 2011/12/30 06:25:04 patrick Exp $
58
59 EAPI=4
60
61 inherit flag-o-matic eutils autotools multilib versionator
62
63 MY_P=${PN/f/F}-$(replace_version_separator 4 -)
64 #MY_P=${PN/f/F}-${PV/_rc/-ReleaseCandidate}
65
66 DESCRIPTION="A relational database offering many ANSI SQL:2003 and some SQL:2008 features"
67 HOMEPAGE="http://www.firebirdsql.org/"
68 SRC_URI="mirror://sourceforge/firebird/${MY_P}.tar.bz2
69 doc? ( ftp://ftpc.inprise.com/pub/interbase/techpubs/ib_b60_doc.zip )"
70
71 LICENSE="IDPL Interbase-1.0"
72 SLOT="0"
73 KEYWORDS="~amd64 -ia64 ~x86"
74 IUSE="doc client superserver xinetd examples debug"
75 RESTRICT="userpriv"
76
77 RDEPEND="dev-libs/libedit
78 dev-libs/icu"
79 DEPEND="${RDEPEND}
80 >=dev-util/btyacc-3.0-r2
81 doc? ( app-arch/unzip )"
82 RDEPEND="${RDEPEND}
83 xinetd? ( virtual/inetd )
84 !sys-cluster/ganglia"
85
86 S="${WORKDIR}/${MY_P}"
87
88 pkg_pretend() {
89 if use client && use superserver ; then
90 die "Use flags client and superserver cannot be used together"
91 fi
92 if use client && use xinetd ; then
93 die "Use flags client and xinetd cannot be used together"
94 fi
95 if use superserver && use xinetd ; then
96 die "Use flags superserver and xinetd cannot be used together"
97 fi
98 }
99
100 pkg_setup() {
101 enewgroup firebird 450
102 enewuser firebird 450 /bin/bash /usr/$(get_libdir)/firebird firebird
103 }
104
105 function check_sed() {
106 MSG="sed of $3, required $2 lines modified $1"
107 einfo "${MSG}"
108 [[ $1 -ge $2 ]] || die "${MSG}"
109 }
110
111 src_unpack() {
112 if use doc; then
113 # Unpack docs
114 mkdir "${WORKDIR}/manuals"
115 cd "${WORKDIR}/manuals"
116 unpack ib_b60_doc.zip
117 cd "${WORKDIR}"
118 fi
119 unpack "${MY_P}.tar.bz2"
120 cd "${S}"
121 }
122
123 src_prepare() {
124 # This patch might be portable, and not need to be duplicated per version
125 # also might no longer be necessary to patch deps or libs, just flags
126 epatch "${FILESDIR}/${P}-deps-flags.patch"
127
128 use client && epatch "${FILESDIR}/${P}-client.patch"
129 if ! use superserver ; then
130 epatch "${FILESDIR}/${P}-superclassic.patch"
131 fi
132
133 # Rename references to isql to fbsql
134 # sed vs patch for portability and addtional location changes
135 check_sed "$(sed -i -e 's:"isql :"fbsql :w /dev/stdout' \
136 src/isql/isql.epp | wc -l)" "1" "src/isql/isql.epp" # 1 line
137 check_sed "$(sed -i -e 's:isql :fbsql :w /dev/stdout' \
138 src/msgs/history2.sql | wc -l)" "4" "src/msgs/history2.sql" # 4 lines
139 check_sed "$(sed -i -e 's:--- ISQL:--- FBSQL:w /dev/stdout' \
140 -e 's:isql :fbsql :w /dev/stdout' \
141 -e 's:ISQL :FBSQL :w /dev/stdout' \
142 src/msgs/messages2.sql | wc -l)" "6" "src/msgs/messages2.sql" # 6 lines
143
144 find "${S}" -name \*.sh -print0 | xargs -0 chmod +x
145 rm -rf "${S}"/extern/{btyacc,editline,icu}
146
147 eautoreconf
148 }
149
150 src_configure() {
151 filter-flags -fprefetch-loop-arrays
152 filter-mfpmath sse
153
154 econf --prefix=/usr/$(get_libdir)/firebird \
155 $(use_enable superserver superserver) \
156 $(use_enable debug) \
157 --with-editline \
158 --with-system-editline \
159 --with-system-icu \
160 --with-fbbin=/usr/bin \
161 --with-fbsbin=/usr/sbin \
162 --with-fbconf=/etc/${PN} \
163 --with-fblib=/usr/$(get_libdir) \
164 --with-fbinclude=/usr/include \
165 --with-fbdoc=/usr/share/doc/${P} \
166 --with-fbudf=/usr/$(get_libdir)/${PN}/UDF \
167 --with-fbsample=/usr/share/doc/${P}/examples \
168 --with-fbsample-db=/usr/share/doc/${P}/examples/db \
169 --with-fbhelp=/usr/$(get_libdir)/${PN}/help \
170 --with-fbintl=/usr/$(get_libdir)/${PN}/intl \
171 --with-fbmisc=/usr/share/${PN} \
172 --with-fbsecure-db=/etc/${PN} \
173 --with-fbmsg=/usr/$(get_libdir)/${PN} \
174 --with-fblog=/var/log/${PN}/ \
175 --with-fbglock=/var/run/${PN} \
176 --with-fbplugins=/usr/$(get_libdir)/${PN}/plugins \
177 --with-gnu-ld \
178 ${myconf}
179 }
180
181 src_compile() {
182 MAKEOPTS="${MAKEOPTS/-j*/-j1} ${MAKEOPTS/-j/CPU=}"
183 emake
184 }
185
186 src_install() {
187 cd "${S}/gen/${PN}"
188
189 if use doc; then
190 dodoc docs/*.pdf
191 dodoc "${WORKDIR}"/manuals/*
192 fi
193
194 insinto /usr/include
195 doins include/*
196
197 rm lib/libfbstatic.a
198
199 insinto /usr/$(get_libdir)
200 dolib.so lib/*.so*
201
202 # links for backwards compatibility
203 dosym libfbclient.so /usr/$(get_libdir)/libgds.so
204 dosym libfbclient.so /usr/$(get_libdir)/libgds.so.0
205 dosym libfbclient.so /usr/$(get_libdir)/libfbclient.so.1
206
207 insinto /usr/$(get_libdir)/${PN}
208 doins *.msg
209
210 use client && return
211
212 einfo "Renaming isql -> fbsql"
213 mv bin/isql bin/fbsql
214
215 local bins="fbsql fbsvcmgr fbtracemgr gbak gdef gfix gpre gsec gstat nbackup qli"
216 for bin in ${bins[@]}; do
217 dobin bin/${bin}
218 done
219
220 dosbin bin/fb_lock_print
221 # SuperServer
222 if use superserver ; then
223 dosbin bin/{fbguard,fbserver}
224 # ClassicServer
225 elif use xinetd ; then
226 dosbin bin/fb_inet_server
227 # SuperClassic
228 else
229 dosbin bin/{fbguard,fb_smp_server}
230
231 #Temp should not be necessary, need to patch/fix
232 dosym "${D}"/usr/$(get_libdir)/libib_util.so /usr/$(get_libdir)/${PN}/lib/libib_util.so
233 fi
234
235 exeinto /usr/bin/${PN}
236 exeopts -m0755
237 doexe bin/{changeRunUser,restoreRootRunUser,changeDBAPassword}.sh
238
239 insinto /usr/$(get_libdir)/${PN}/help
240 doins help/help.fdb
241
242 exeinto /usr/$(get_libdir)/firebird/intl
243 dolib.so intl/libfbintl.so
244 dosym "${D}"/usr/$(get_libdir)/libfbintl.so /usr/$(get_libdir)/${PN}/intl/fbintl
245 dosym "${D}"/etc/firebird/fbintl.conf /usr/$(get_libdir)/${PN}/intl/fbintl.conf
246
247 exeinto /usr/$(get_libdir)/${PN}/plugins
248 dolib.so plugins/libfbtrace.so
249 dosym "${D}"/usr/$(get_libdir)/libfbtrace.so /usr/$(get_libdir)/${PN}/plugins/libfbtrace.so
250
251 exeinto /usr/$(get_libdir)/${PN}/UDF
252 doexe UDF/*.so
253
254 insinto /usr/share/${PN}/upgrade
255 doins "${S}"/src/misc/upgrade/v2/*
256
257 insinto /etc/${PN}
258 insopts -m0644 -o firebird -g firebird
259 doins ../install/misc/*.conf
260 insopts -m0660 -o firebird -g firebird
261 doins security2.fdb
262
263 if use xinetd ; then
264 insinto /etc/xinetd.d
265 newins "${FILESDIR}/${PN}.xinetd" ${PN}
266 else
267 newinitd "${FILESDIR}/${PN}.init.d.2.5" ${PN}
268 newconfd "${FILESDIR}/${PN}.conf.d.2.5" ${PN}
269 fperms 640 /etc/conf.d/${PN}
270 fi
271
272 insinto /etc/logrotate.d
273 newins "${FILESDIR}/${PN}.logrotate" ${PN}
274
275 diropts -m 755 -o firebird -g firebird
276 dodir /var/log/${PN}
277 dodir /var/run/${PN}
278 keepdir /var/log/${PN}
279 keepdir /var/run/${PN}
280
281 use examples && docinto examples
282 }
283
284 pkg_postinst() {
285 use client && return
286
287 # Hack to fix ownership/perms
288 chown -fR firebird:firebird "${ROOT}/etc/${PN}" "${ROOT}/usr/$(get_libdir)/${PN}"
289 chmod 750 "${ROOT}/etc/${PN}"
290
291 elog
292 elog "Firebird is no longer installed in /opt. Binaries are in"
293 elog "/usr/bin. The core, udfs, etc are in /usr/lib/firebird. Logs"
294 elog "are in /var/log/firebird, and lock files in /var/run/firebird"
295 elog "The command line tool isql has been renamed to fbsql."
296 elog "Please report any problems or issues to bugs.gentoo.org."
297 elog
298 }
299
300 pkg_config() {
301 use client && return
302
303 # if found /etc/security.gdb from previous install, backup, and restore as
304 # /etc/security2.fdb
305 if [ -f "${ROOT}/etc/firebird/security.gdb" ] ; then
306 # if we have scurity2.fdb already, back it 1st
307 if [ -f "${ROOT}/etc/firebird/security2.fdb" ] ; then
308 cp "${ROOT}/etc/firebird/security2.fdb" "${ROOT}/etc/firebird/security2.fdb.old"
309 fi
310 gbak -B "${ROOT}/etc/firebird/security.gdb" "${ROOT}/etc/firebird/security.gbk"
311 gbak -R "${ROOT}/etc/firebird/security.gbk" "${ROOT}/etc/firebird/security2.fdb"
312 mv "${ROOT}/etc/firebird/security.gdb" "${ROOT}/etc/firebird/security.gdb.old"
313 rm "${ROOT}/etc/firebird/security.gbk"
314
315 # make sure they are readable only to firebird
316 chown firebird:firebird "${ROOT}/etc/firebird/{security.*,security2.*}"
317 chmod 660 "${ROOT}/etc/firebird/{security.*,security2.*}"
318
319 einfo
320 einfo "Converted old security.gdb to security2.fdb, security.gdb has been "
321 einfo "renamed to security.gdb.old. if you had previous security2.fdb, "
322 einfo "it's backed to security2.fdb.old (all under ${ROOT}/etc/firebird)."
323 einfo
324 fi
325
326 # we need to enable local access to the server
327 if [ ! -f "${ROOT}/etc/hosts.equiv" ] ; then
328 touch "${ROOT}/etc/hosts.equiv"
329 chown root:0 "${ROOT}/etc/hosts.equiv"
330 chmod u=rw,go=r "${ROOT}/etc/hosts.equiv"
331 fi
332
333 # add 'localhost.localdomain' to the hosts.equiv file...
334 if [ grep -q 'localhost.localdomain$' "${ROOT}/etc/hosts.equiv" 2>/dev/null ] ; then
335 echo "localhost.localdomain" >> "${ROOT}/etc/hosts.equiv"
336 einfo "Added localhost.localdomain to ${ROOT}/etc/hosts.equiv"
337 fi
338
339 # add 'localhost' to the hosts.equiv file...
340 if [ grep -q 'localhost$' "${ROOT}/etc/hosts.equiv" 2>/dev/null ] ; then
341 echo "localhost" >> "${ROOT}/etc/hosts.equiv"
342 einfo "Added localhost to ${ROOT}/etc/hosts.equiv"
343 fi
344
345 HS_NAME=`hostname`
346 if [ grep -q ${HS_NAME} "${ROOT}/etc/hosts.equiv" 2>/dev/null ] ; then
347 echo "${HS_NAME}" >> "${ROOT}/etc/hosts.equiv"
348 einfo "Added ${HS_NAME} to ${ROOT}/etc/hosts.equiv"
349 fi
350
351 einfo "If you're using UDFs, please remember to move them"
352 einfo "to /usr/lib/firebird/UDF"
353 }