Gentoo Archives: gentoo-commits

From: "Robin H. Johnson (robbat2)" <robbat2@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-vcs/git: git-1.7.4.ebuild ChangeLog
Date: Tue, 01 Feb 2011 01:24:45
Message-Id: 20110201012433.66F2F20054@flycatcher.gentoo.org
1 robbat2 11/02/01 01:24:33
2
3 Modified: ChangeLog
4 Added: git-1.7.4.ebuild
5 Log:
6 Version bump.
7
8 (Portage version: 2.2.0_alpha19/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.85 dev-vcs/git/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-vcs/git/ChangeLog?rev=1.85&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-vcs/git/ChangeLog?rev=1.85&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-vcs/git/ChangeLog?r1=1.84&r2=1.85
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/dev-vcs/git/ChangeLog,v
20 retrieving revision 1.84
21 retrieving revision 1.85
22 diff -p -w -b -B -u -u -r1.84 -r1.85
23 --- ChangeLog 24 Jan 2011 23:45:35 -0000 1.84
24 +++ ChangeLog 1 Feb 2011 01:24:33 -0000 1.85
25 @@ -1,6 +1,11 @@
26 # ChangeLog for dev-vcs/git
27 # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/dev-vcs/git/ChangeLog,v 1.84 2011/01/24 23:45:35 robbat2 Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/dev-vcs/git/ChangeLog,v 1.85 2011/02/01 01:24:33 robbat2 Exp $
30 +
31 +*git-1.7.4 (01 Feb 2011)
32 +
33 + 01 Feb 2011; Robin H. Johnson <robbat2@g.o> +git-1.7.4.ebuild:
34 + Version bump.
35
36 *git-1.7.4_rc3 (24 Jan 2011)
37
38
39
40
41 1.1 dev-vcs/git/git-1.7.4.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-vcs/git/git-1.7.4.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-vcs/git/git-1.7.4.ebuild?rev=1.1&content-type=text/plain
45
46 Index: git-1.7.4.ebuild
47 ===================================================================
48 # Copyright 1999-2011 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/dev-vcs/git/git-1.7.4.ebuild,v 1.1 2011/02/01 01:24:33 robbat2 Exp $
51
52 EAPI=3
53
54 GENTOO_DEPEND_ON_PERL=no
55
56 # bug #329479: git-remote-testgit is not multiple-version aware
57 PYTHON_DEPEND="python? 2"
58
59 inherit toolchain-funcs eutils elisp-common perl-module bash-completion python
60 [ "$PV" == "9999" ] && inherit git
61
62 MY_PV="${PV/_rc/.rc}"
63 MY_P="${PN}-${MY_PV}"
64
65 DOC_VER=${MY_PV}
66
67 DESCRIPTION="GIT - the stupid content tracker, the revision control system heavily used by the Linux kernel team"
68 HOMEPAGE="http://www.git-scm.com/"
69 if [ "$PV" != "9999" ]; then
70 SRC_URI="mirror://kernel/software/scm/git/${MY_P}.tar.bz2
71 mirror://kernel/software/scm/git/${PN}-manpages-${DOC_VER}.tar.bz2
72 doc? ( mirror://kernel/software/scm/git/${PN}-htmldocs-${DOC_VER}.tar.bz2 )"
73 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~sparc-fbsd ~x86-fbsd ~x86-freebsd ~ia64-hpux ~x86-interix ~amd64-linux ~ia64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
74 else
75 SRC_URI=""
76 EGIT_BRANCH="master"
77 EGIT_REPO_URI="git://git.kernel.org/pub/scm/git/git.git"
78 # EGIT_REPO_URI="http://www.kernel.org/pub/scm/git/git.git"
79 KEYWORDS=""
80 fi
81
82 LICENSE="GPL-2"
83 SLOT="0"
84 IUSE="+blksha1 +curl cgi doc emacs gtk iconv +perl +python ppcsha1 tk +threads +webdav xinetd cvs subversion"
85
86 # Common to both DEPEND and RDEPEND
87 CDEPEND="
88 !blksha1? ( dev-libs/openssl )
89 sys-libs/zlib
90 perl? ( dev-lang/perl[-build] )
91 tk? ( dev-lang/tk )
92 curl? (
93 net-misc/curl
94 webdav? ( dev-libs/expat )
95 )
96 emacs? ( virtual/emacs )"
97
98 RDEPEND="${CDEPEND}
99 perl? ( dev-perl/Error
100 dev-perl/Net-SMTP-SSL
101 dev-perl/Authen-SASL
102 cgi? ( virtual/perl-CGI )
103 cvs? ( >=dev-vcs/cvsps-2.1 dev-perl/DBI dev-perl/DBD-SQLite )
104 subversion? ( dev-vcs/subversion[-dso,perl] dev-perl/libwww-perl dev-perl/TermReadKey )
105 )
106 python? ( gtk?
107 (
108 >=dev-python/pygtk-2.8
109 || ( dev-python/pygtksourceview:2 dev-python/gtksourceview-python )
110 ) )"
111
112 # This is how info docs are created with Git:
113 # .txt/asciidoc --(asciidoc)---------> .xml/docbook
114 # .xml/docbook --(docbook2texi.pl)--> .texi
115 # .texi --(makeinfo)---------> .info
116 DEPEND="${CDEPEND}
117 app-arch/cpio
118 doc? (
119 app-text/asciidoc
120 app-text/docbook2X
121 sys-apps/texinfo
122 )"
123
124 # Live ebuild builds man pages and HTML docs, additionally
125 if [ "$PV" == "9999" ]; then
126 DEPEND="${DEPEND}
127 app-text/asciidoc
128 app-text/xmlto"
129 fi
130
131 SITEFILE=50${PN}-gentoo.el
132 S="${WORKDIR}/${MY_P}"
133
134 pkg_setup() {
135 if ! use perl ; then
136 use cgi && ewarn "gitweb needs USE=perl, ignoring USE=cgi"
137 use cvs && ewarn "CVS integration needs USE=perl, ignoring USE=cvs"
138 use subversion && ewarn "git-svn needs USE=perl, it won't work"
139 fi
140 if use webdav && ! use curl ; then
141 ewarn "USE=webdav needs USE=curl. Ignoring"
142 fi
143 if use subversion && has_version dev-vcs/subversion && built_with_use --missing false dev-vcs/subversion dso ; then
144 ewarn "Per Gentoo bugs #223747, #238586, when subversion is built"
145 ewarn "with USE=dso, there may be weird crashes in git-svn. You"
146 ewarn "have been warned."
147 fi
148 if use python ; then
149 python_set_active_version 2
150 python_pkg_setup
151 fi
152 }
153
154 # This is needed because for some obscure reasons future calls to make don't
155 # pick up these exports if we export them in src_unpack()
156 exportmakeopts() {
157 local myopts
158
159 if use blksha1 ; then
160 myopts="${myopts} BLK_SHA1=YesPlease"
161 elif use ppcsha1 ; then
162 myopts="${myopts} PPC_SHA1=YesPlease"
163 fi
164
165 if use curl ; then
166 use webdav || myopts="${myopts} NO_EXPAT=YesPlease"
167 else
168 myopts="${myopts} NO_CURL=YesPlease"
169 fi
170
171 # broken assumptions, because of broken build system ...
172 myopts="${myopts} NO_FINK=YesPlease NO_DARWIN_PORTS=YesPlease"
173 myopts="${myopts} INSTALL=install TAR=tar"
174 myopts="${myopts} SHELL_PATH=${EPREFIX}/bin/sh"
175 myopts="${myopts} SANE_TOOL_PATH="
176 myopts="${myopts} OLD_ICONV="
177 myopts="${myopts} NO_EXTERNAL_GREP="
178
179 # can't define this to null, since the entire makefile depends on it
180 sed -i -e '/\/usr\/local/s/BASIC_/#BASIC_/' Makefile
181
182 use iconv \
183 || einfo "Forcing iconv for ${PVR} due to bugs #321895, #322205."
184 # || myopts="${myopts} NO_ICONV=YesPlease"
185 # because, above, we need to do this unconditionally (no "&& use iconv")
186 use !elibc_glibc && myopts="${myopts} NEEDS_LIBICONV=YesPlease"
187
188 use tk \
189 || myopts="${myopts} NO_TCLTK=YesPlease"
190 use perl \
191 && myopts="${myopts} INSTALLDIRS=vendor" \
192 || myopts="${myopts} NO_PERL=YesPlease"
193 use python \
194 || myopts="${myopts} NO_PYTHON=YesPlease"
195 use subversion \
196 || myopts="${myopts} NO_SVN_TESTS=YesPlease"
197 use threads \
198 && myopts="${myopts} THREADED_DELTA_SEARCH=YesPlease"
199 use cvs \
200 || myopts="${myopts} NO_CVS=YesPlease"
201 # Disabled until ~m68k-mint can be keyworded again
202 # if [[ ${CHOST} == *-mint* ]] ; then
203 # myopts="${myopts} NO_MMAP=YesPlease"
204 # myopts="${myopts} NO_IPV6=YesPlease"
205 # myopts="${myopts} NO_STRLCPY=YesPlease"
206 # myopts="${myopts} NO_MEMMEM=YesPlease"
207 # myopts="${myopts} NO_MKDTEMP=YesPlease"
208 # myopts="${myopts} NO_MKSTEMPS=YesPlease"
209 # fi
210 if [[ ${CHOST} == ia64-*-hpux* ]]; then
211 myopts="${myopts} NO_NSEC=YesPlease"
212 fi
213 if [[ ${CHOST} == *-*-aix* ]]; then
214 myopts="${myopts} NO_FNMATCH_CASEFOLD=YesPlease"
215 fi
216
217 has_version '>=app-text/asciidoc-8.0' \
218 && myopts="${myopts} ASCIIDOC8=YesPlease"
219 myopts="${myopts} ASCIIDOC_NO_ROFF=YesPlease"
220
221 # Bug 290465:
222 # builtin-fetch-pack.c:816: error: 'struct stat' has no member named 'st_mtim'
223 [[ "${CHOST}" == *-uclibc* ]] && \
224 myopts="${myopts} NO_NSEC=YesPlease"
225
226 export MY_MAKEOPTS="${myopts}"
227 }
228
229 src_unpack() {
230 if [ "${PV}" != "9999" ]; then
231 unpack ${MY_P}.tar.bz2
232 cd "${S}"
233 unpack ${PN}-manpages-${DOC_VER}.tar.bz2
234 use doc && \
235 cd "${S}"/Documentation && \
236 unpack ${PN}-htmldocs-${DOC_VER}.tar.bz2
237 cd "${S}"
238 else
239 git_src_unpack
240 cd "${S}"
241 #cp "${FILESDIR}"/GIT-VERSION-GEN .
242 fi
243
244 }
245
246 src_prepare() {
247 # Noperl is being merged to upstream as of 2009/04/05
248 #epatch "${FILESDIR}"/20090305-git-1.6.2-noperl.patch
249
250 # GetOpt-Long v2.38 is strict
251 # Merged in 1.6.3 final 2009/05/07
252 #epatch "${FILESDIR}"/20090505-git-1.6.2.5-getopt-fixes.patch
253
254 # JS install fixup
255 epatch "${FILESDIR}"/git-1.7.2-always-install-js.patch
256
257 # USE=-iconv causes segfaults, fixed post 1.7.1
258 # Gentoo bug #321895
259 #epatch "${FILESDIR}"/git-1.7.1-noiconv-segfault-fix.patch
260
261 # Fix false positives with t3404 due to SHELL=/bin/false for the portage
262 # user.
263 # Merged upstream
264 #epatch "${FILESDIR}"/git-1.7.3.4-avoid-shell-issues.patch
265
266 # bug #350075: t9001: fix missing prereq on some tests
267 # Merged upstream
268 #epatch "${FILESDIR}"/git-1.7.3.4-fix-perl-test-prereq.patch
269
270 # bug #350330 - automagic CVS when we don't want it is bad.
271 epatch "${FILESDIR}"/git-1.7.3.5-optional-cvs.patch
272
273 sed -i \
274 -e 's:^\(CFLAGS =\).*$:\1 $(OPTCFLAGS) -Wall:' \
275 -e 's:^\(LDFLAGS =\).*$:\1 $(OPTLDFLAGS):' \
276 -e 's:^\(CC = \).*$:\1$(OPTCC):' \
277 -e 's:^\(AR = \).*$:\1$(OPTAR):' \
278 -e "s:\(PYTHON_PATH = \)\(.*\)$:\1${EPREFIX}\2:" \
279 -e "s:\(PERL_PATH = \)\(.*\)$:\1${EPREFIX}\2:" \
280 Makefile || die "sed failed"
281
282 # Never install the private copy of Error.pm (bug #296310)
283 sed -i \
284 -e '/private-Error.pm/s,^,#,' \
285 perl/Makefile.PL
286
287 # Fix docbook2texi command
288 sed -i 's/DOCBOOK2X_TEXI=docbook2x-texi/DOCBOOK2X_TEXI=docbook2texi.pl/' \
289 Documentation/Makefile || die "sed failed"
290
291 # bug #318289
292 # Merged upstream
293 #epatch "${FILESDIR}"/git-1.7.3.2-interix.patch
294 }
295
296 git_emake() {
297 # bug #326625: PERL_PATH, PERL_MM_OPT
298 # bug #320647: PYTHON_PATH
299 PYTHON_PATH=""
300 use python && PYTHON_PATH="$(PYTHON -a)"
301 emake ${MY_MAKEOPTS} \
302 DESTDIR="${D}" \
303 OPTCFLAGS="${CFLAGS}" \
304 OPTLDFLAGS="${LDFLAGS}" \
305 OPTCC="$(tc-getCC)" \
306 OPTAR="$(tc-getAR)" \
307 prefix="${EPREFIX}"/usr \
308 htmldir="${EPREFIX}"/usr/share/doc/${PF}/html \
309 sysconfdir="${EPREFIX}"/etc \
310 PYTHON_PATH="${PYTHON_PATH}" \
311 PERL_PATH="${EPREFIX}/usr/bin/env perl" \
312 PERL_MM_OPT="" \
313 GIT_TEST_OPTS="--no-color" \
314 "$@"
315 }
316
317 src_configure() {
318 exportmakeopts
319 }
320
321 src_compile() {
322 git_emake || die "emake failed"
323
324 if use emacs ; then
325 elisp-compile contrib/emacs/git{,-blame}.el \
326 || die "emacs modules failed"
327 fi
328
329 if use perl && use cgi ; then
330 git_emake \
331 gitweb/gitweb.cgi \
332 || die "emake gitweb/gitweb.cgi failed"
333 fi
334
335 cd "${S}"/Documentation
336 if [[ "$PV" == "9999" ]] ; then
337 git_emake man \
338 || die "emake man failed"
339 if use doc ; then
340 git_emake info html \
341 || die "emake info html failed"
342 fi
343 else
344 if use doc ; then
345 git_emake info \
346 || die "emake info html failed"
347 fi
348 fi
349 }
350
351 src_install() {
352 git_emake \
353 install || \
354 die "make install failed"
355
356 # Depending on the tarball and manual rebuild of the documentation, the
357 # manpages may exist in either OR both of these directories.
358 find man?/*.[157] >/dev/null 2>&1 && doman man?/*.[157]
359 find Documentation/*.[157] >/dev/null 2>&1 && doman Documentation/*.[157]
360
361 dodoc README Documentation/{SubmittingPatches,CodingGuidelines}
362 use doc && dodir /usr/share/doc/${PF}/html
363 for d in / /howto/ /technical/ ; do
364 docinto ${d}
365 dodoc Documentation${d}*.txt
366 use doc && dohtml -p ${d} Documentation${d}*.html
367 done
368 docinto /
369 # Upstream does not ship this pre-built :-(
370 use doc && doinfo Documentation/{git,gitman}.info
371
372 dobashcompletion contrib/completion/git-completion.bash ${PN}
373
374 if use emacs ; then
375 elisp-install ${PN} contrib/emacs/git.{el,elc} || die
376 elisp-install ${PN} contrib/emacs/git-blame.{el,elc} || die
377 #elisp-install ${PN}/compat contrib/emacs/vc-git.{el,elc} || die
378 # don't add automatically to the load-path, so the sitefile
379 # can do a conditional loading
380 touch "${ED}${SITELISP}/${PN}/compat/.nosearch"
381 elisp-site-file-install "${FILESDIR}"/${SITEFILE} || die
382 fi
383
384 if use python && use gtk ; then
385 dobin "${S}"/contrib/gitview/gitview
386 python_convert_shebangs ${PYTHON_ABI} "${ED}"/usr/bin/gitview
387 dodoc "${S}"/contrib/gitview/gitview.txt
388 fi
389
390 dobin contrib/fast-import/git-p4
391 dodoc contrib/fast-import/git-p4.txt
392 newbin contrib/fast-import/import-tars.perl import-tars
393 newbin contrib/git-resurrect.sh git-resurrect
394
395 dodir /usr/share/${PN}/contrib
396 # The following are excluded:
397 # completion - installed above
398 # emacs - installed above
399 # examples - these are stuff that is not used in Git anymore actually
400 # gitview - installed above
401 # p4import - excluded because fast-import has a better one
402 # patches - stuff the Git guys made to go upstream to other places
403 # svnimport - use git-svn
404 # thunderbird-patch-inline - fixes thunderbird
405 for i in \
406 blameview buildsystems ciabot continuous convert-objects fast-import \
407 hg-to-git hooks remotes2config.sh remotes2config.sh rerere-train.sh \
408 stats svn-fe vim workdir \
409 ; do
410 cp -rf \
411 "${S}"/contrib/${i} \
412 "${ED}"/usr/share/${PN}/contrib \
413 || die "Failed contrib ${i}"
414 done
415
416 if use perl && use cgi ; then
417 # We used to install in /usr/share/${PN}/gitweb
418 # but upstream installs in /usr/share/gitweb
419 # so we will install a symlink and use their location for compat with other
420 # distros
421 dosym /usr/share/gitweb /usr/share/${PN}/gitweb
422
423 # INSTALL discusses configuration issues, not just installation
424 docinto /
425 newdoc "${S}"/gitweb/INSTALL INSTALL.gitweb
426 newdoc "${S}"/gitweb/README README.gitweb
427
428 find "${ED}"/usr/lib64/perl5/ \
429 -name .packlist \
430 -exec rm \{\} \;
431 else
432 rm -rf "${ED}"/usr/share/gitweb
433 fi
434
435 if ! use subversion ; then
436 rm -f "${ED}"/usr/libexec/git-core/git-svn \
437 "${ED}"/usr/share/man/man1/git-svn.1*
438 fi
439
440 if use xinetd ; then
441 insinto /etc/xinetd.d
442 newins "${FILESDIR}"/git-daemon.xinetd git-daemon
443 fi
444
445 newinitd "${FILESDIR}"/git-daemon.initd git-daemon
446 newconfd "${FILESDIR}"/git-daemon.confd git-daemon
447
448 fixlocalpod
449 }
450
451 src_test() {
452 local disabled=""
453 local tests_cvs="t9200-git-cvsexportcommit.sh \
454 t9400-git-cvsserver-server.sh \
455 t9401-git-cvsserver-crlf.sh \
456 t9600-cvsimport.sh \
457 t9601-cvsimport-vendor-branch.sh \
458 t9602-cvsimport-branches-tags.sh \
459 t9603-cvsimport-patchsets.sh"
460 local tests_perl="t5502-quickfetch.sh \
461 t5512-ls-remote.sh \
462 t5520-pull.sh"
463 # Bug #225601 - t0004 is not suitable for root perm
464 # Bug #219839 - t1004 is not suitable for root perm
465 # t0001-init.sh - check for init notices EPERM* fails
466 local tests_nonroot="t0001-init.sh \
467 t0004-unwritable.sh \
468 t1004-read-tree-m-u-wf.sh \
469 t3700-add.sh \
470 t7300-clean.sh"
471
472 # Unzip is used only for the testcase code, not by any normal parts of Git.
473 if ! has_version app-arch/unzip ; then
474 einfo "Disabling tar-tree tests"
475 disabled="${disabled} t5000-tar-tree.sh"
476 fi
477
478 cvs=0
479 use cvs && let cvs=$cvs+1
480 if [[ ${EUID} -eq 0 ]]; then
481 if [[ $cvs -eq 1 ]]; then
482 ewarn "Skipping CVS tests because CVS does not work as root!"
483 ewarn "You should retest with FEATURES=userpriv!"
484 disabled="${disabled} ${tests_cvs}"
485 fi
486 einfo "Skipping other tests that require being non-root"
487 disabled="${disabled} ${tests_nonroot}"
488 else
489 [[ $cvs -gt 0 ]] && \
490 has_version dev-vcs/cvs && \
491 let cvs=$cvs+1
492 [[ $cvs -gt 1 ]] && \
493 built_with_use dev-vcs/cvs server && \
494 let cvs=$cvs+1
495 if [[ $cvs -lt 3 ]]; then
496 einfo "Disabling CVS tests (needs dev-vcs/cvs[USE=server])"
497 disabled="${disabled} ${tests_cvs}"
498 fi
499 fi
500
501 if ! use perl ; then
502 einfo "Disabling tests that need Perl"
503 disabled="${disabled} ${tests_perl}"
504 fi
505
506 # Reset all previously disabled tests
507 cd "${S}/t"
508 for i in *.sh.DISABLED ; do
509 [[ -f "${i}" ]] && mv -f "${i}" "${i%.DISABLED}"
510 done
511 einfo "Disabled tests:"
512 for i in ${disabled} ; do
513 [[ -f "${i}" ]] && mv -f "${i}" "${i}.DISABLED" && einfo "Disabled $i"
514 done
515
516 # Avoid the test system removing the results because we want them ourselves
517 sed -e '/^[[:space:]]*$(MAKE) clean/s,^,#,g' \
518 -i "${S}"/t/Makefile
519
520 # Clean old results first
521 cd "${S}/t"
522 git_emake clean
523
524 # Now run the tests
525 cd "${S}"
526 einfo "Start test run"
527 git_emake test
528 rc=$?
529
530 # Display nice results
531 cd "${S}/t"
532 git_emake aggregate-results
533
534 # And exit
535 [ $rc -eq 0 ] || die "tests failed. Please file a bug."
536 }
537
538 showpkgdeps() {
539 local pkg=$1
540 shift
541 elog " $(printf "%-17s:" ${pkg}) ${@}"
542 }
543
544 pkg_postinst() {
545 use emacs && elisp-site-regen
546 use python && python_mod_optimize git_remote_helpers
547 if use subversion && has_version dev-vcs/subversion && ! built_with_use --missing false dev-vcs/subversion perl ; then
548 ewarn "You must build dev-vcs/subversion with USE=perl"
549 ewarn "to get the full functionality of git-svn!"
550 fi
551 elog "These additional scripts need some dependencies:"
552 echo
553 showpkgdeps git-quiltimport "dev-util/quilt"
554 showpkgdeps git-instaweb \
555 "|| ( www-servers/lighttpd www-servers/apache )"
556 echo
557 }
558
559 pkg_postrm() {
560 use emacs && elisp-site-regen
561 use python && python_mod_cleanup git_remote_helpers
562 }