diff options
author | Gregory M. Tuner <gmt@be-evil.net> | 2014-05-13 22:52:46 -0700 |
---|---|---|
committer | Gregory M. Tuner <gmt@be-evil.net> | 2014-05-13 22:52:46 -0700 |
commit | 188615a7e8ba94b3ef4aa6a5ce5a0f1f2de9ed21 (patch) | |
tree | 60ebddf29c52471f14567bba64610f256c3e5188 /dev-vcs | |
parent | sys-apps/util-linux: drop as multilibutized upstream (diff) | |
download | gmt-188615a7e8ba94b3ef4aa6a5ce5a0f1f2de9ed21.tar.gz gmt-188615a7e8ba94b3ef4aa6a5ce5a0f1f2de9ed21.tar.bz2 gmt-188615a7e8ba94b3ef4aa6a5ce5a0f1f2de9ed21.zip |
dev-vcs/git-1.9.3-r1: revbump/merge
Signed-off-by: Gregory M. Tuner <gmt@be-evil.net>
Diffstat (limited to 'dev-vcs')
-rw-r--r-- | dev-vcs/git/Manifest | 4 | ||||
-rw-r--r-- | dev-vcs/git/git-1.9.3-r1.ebuild | 645 |
2 files changed, 649 insertions, 0 deletions
diff --git a/dev-vcs/git/Manifest b/dev-vcs/git/Manifest index ce5dc2c..5eee7db 100644 --- a/dev-vcs/git/Manifest +++ b/dev-vcs/git/Manifest @@ -16,15 +16,19 @@ AUX git-daemon_at.service 395 SHA256 c427e37d3e859c13f9441b20c7cb6aba7bca048cb70 DIST git-1.9.0.tar.gz 4839710 SHA256 d9cdb10e013fce57eecb9287f09b31525fc7bf3ec58ea4b6a9fc2e4f5c662395 SHA512 2a663131b5055c755816522aa15690ebc382ee971f565b6e47eb4e9e0315ab1763fa2db9d543d8e167e933b7a75cc590e7ad10db0ca1914ad81b9b98d596cdb3 WHIRLPOOL e966c2db5f696318fd30d3045b0574404f33caf5b02114bf2a8d59cb1e4cfc95aaff60b3adf8e4c072d51a417af787c17f424a23c19c125d2acfae478cfffb1a DIST git-1.9.1.tar.gz 4843441 SHA256 d57f3b6448eab0eb62fe3523ff36a8043aa42593f1ebb86324601aaa2217870d SHA512 2b74280e19ca94727c2f39217669f998b75b04cf9e4020bf350fd6244de3e9c162f60b9b6f569857a66a2824db8f4a3c91aaf55b194038f9d224cafc5cac3177 WHIRLPOOL c2801cb03a2a653328985dbb564eaac022b1707164c5776e4707a53fb302508792608145d34b1badf7839bd6fa910c9ca9551f57a1767e51385a750ba6e93dbf DIST git-1.9.2.tar.gz 4845863 SHA256 d0dceb2e881f6a8f6eada128f782904b8711ea93a4c86dd38da99a7773edc25b SHA512 f18ddab53db9bf272762258f142390178b9b4f5e955cf0fb8305b9a0d3d13759599cdec9b03206c7c470da9a3213fe10d08032a39640a623c707196dabbecbf8 WHIRLPOOL 0d4bf0b34385df2aa6eb666dd009e04313817265c0ee786c4f8e5e21c3b04114cefbaec0a6a6857585eeec864714729e6327f9a82501ad89a0991e38db271e25 +DIST git-1.9.3.tar.gz 4846233 SHA256 71bca677efa3b87a060cba1de9e3512e7ab0f09197ef95d648e5280d9a6d1357 SHA512 42a774f0d2b9d0ace9e555b3d12b7a27fabdad407d5d1f342792d56cc1b7d1c9d1f921432238ec1bc61e9fd7f9dba7c5d8bcadea8b05bf73bab8c3b428f17b89 WHIRLPOOL b0cd2a18404af0856972d3ab1bad776b5c3cb5088369e5556aa2293feb6a164ef1af7a79cd4a1d7e20c37795921c05d811f9faebe57e31ea5621cc9990b8e5f3 DIST git-htmldocs-1.9.0.tar.gz 2240600 SHA256 f4a12c748a1940aaa0e69665232222ddfbb451ac751f8e5f0459ab084dd2c60d SHA512 a81561b533413f0feff18c62fedc9ea2bad5d67c6ef1f515d450d91f0b326a643f46589708e84ae8c12b981daa39bf60738255771e26a4f15c9e0dea8fb29fa5 WHIRLPOOL bc808bb9754493df0f82840a20c1f070500d327193b241ede0b8de4fe1277860e1297305b9cb5b8f082c5ca323d32647bdd81f3ae90101c4d995da5a8a311196 DIST git-htmldocs-1.9.1.tar.gz 2242108 SHA256 2f4e52fa8e92415952a347ba047b86a055490ec537f9cc078197ca9dfa29756c SHA512 bb451fa1ee7a5ebc85056d636ad048faed1350344262fc2d6fba5ea9995b2fc09116eaca7a9acc302f244e9d5587fb3a38a7b36fc76c0ec8c83ac1d443e475f4 WHIRLPOOL 9981122792fbb66e1ea0d8e5ed3884c73f97cc325c80f5714fe00d1d659651ce7614004a609bc3c7482a9b1682dd724da348fbcde350950d2a6e99ada8aa92ae DIST git-htmldocs-1.9.2.tar.gz 2242774 SHA256 ad36ec63e9d77310cd341d832eb9238cb47fde7852448b5cf63ab825973aa323 SHA512 c0cf90c8eb31939ca689f59232c5ec59572e94b1104eaf8e88c7f092e537e2b8f821cbf9e7be6865b56e692da15fc4443638d6b3c8963dd137a43abfebe0f752 WHIRLPOOL 342f4d4dfa29ed4e81a176816d5aae0a7eb365c2e91793073dea11d57f2d60c146891bf16ecda9cbcf24e1c42915f90b73c1ccea50d8a330e5890e93e937460d +DIST git-htmldocs-1.9.3.tar.gz 2243608 SHA256 d23f3f3ccd421706f8805c40ee199fb1d3dda7e6720eb8b260f3dbed20f2536f SHA512 c381f560d5f67f723920ba679665725d377b40e0074ca49826436310f7c64d9c9814ff8a3e98a9d00c0d47e9d9f613ec4ed035d15420b87221fdb17de4ebaf3d WHIRLPOOL 9437271b91b5667fa7a6e979aa86822c1824bcf786a2fad07c0a3cdb1c576bccfe2a098f0e43ebfc66f0dc54cf32443988018ce15f191747b412d200599d0af7 DIST git-manpages-1.9.0.tar.gz 571616 SHA256 8a905a433807ea94e8cd1887f98c7f0d5145c05fa153c93138083532a05a9b63 SHA512 5570c79e7d906c319694788ff192203faed56cd0094f3053cad78fd488f412d81284af5299d4c954ab598ffc81a2a17b1dfbb7f9101c0f57125b5a60b0014b93 WHIRLPOOL 814a8ed7a3f28ec4aa4db49bff3ae70ef73aa2fd7aa106025dec8c15aa73a2ca6e409465785c7daf33d93b4c31ed11814253b137d8457dcdb77e9a6ac01f99d7 DIST git-manpages-1.9.1.tar.gz 571617 SHA256 f88171a61063756b11e3fd6fbd919d77d5583d691ca2095fd5a0ac2c14f0055f SHA512 8998a17ce9db3d1ec2d119868831f8ab17bec26fff19eae2e9ecaf62923d5e8170801662e455729016918a699f520214b2dcbaf2a8623140a874b75b47b8df54 WHIRLPOOL 4a849cf74b7fc113494f3a43e18d7ce7b69e44d2bc3573aeaf214794b309baf6c1c73726ce5a1176d8bbf25f987ab28376477fcd935051866ebf336f17ef3c7c DIST git-manpages-1.9.2.tar.gz 571591 SHA256 bcf7cb8aa17885f6923c33cf420ecf249e097510079c2996396c6369014c4ca8 SHA512 4eb1a0c0cd676c3983c36f9202e3d2832b59375bd7f1c60e7a1a465e60d233112d404213648f7baddc2ead31459a34068df2ec00707a4ca83dc1eef04ce60e03 WHIRLPOOL 01936ecade547e90593c0d1117d29f25e521365c0bfc9b34600f998b7076f1eb1b3c1156ae110f87695531f1e22ea4a1db79df48cd5510a40f4721bf75670639 +DIST git-manpages-1.9.3.tar.gz 571550 SHA256 43bfb09c072ccfe0ed4b0ad30d04c8f34b6af4d2f52cd8dfdb48787cc9c8509d SHA512 3f985a4446e3ce1b8bff356585eb5f33565179517e7ba9ae53fc59399c2e4f3ee8498567ce5282e3ddafe0709e79b80877ee53166986facc1ce348495cbb254a WHIRLPOOL 21e96604e4d6581c34ccf0c1367b706e383c47e45ffe9bfb05e9998c7de45507aa72c3fe95f8fd1d81eced81cea149e6bb393a097fe95d8debbeebfbecde6efd EBUILD git-1.9.0-r1.ebuild 17993 SHA256 c987cd68e4d4b5038466d344bb62391aad92ce5fce527cfc2b484c58f6051e2d SHA512 685790c10130cf7998c58132c79ed49c3dbe2443d28ae20ee0962275336c312496b4fd83d5789efc212bc32b49c0fe32d894dd3734c0deb40418462b111d8767 WHIRLPOOL 619d2bcb1ef7784293c901d1221faef72b67d9950b5aaf9deabed54f70798db076108966504f55fd544ac8409df858256173fb40a7106bff11952442a93aae90 EBUILD git-1.9.1-r1.ebuild 17993 SHA256 c987cd68e4d4b5038466d344bb62391aad92ce5fce527cfc2b484c58f6051e2d SHA512 685790c10130cf7998c58132c79ed49c3dbe2443d28ae20ee0962275336c312496b4fd83d5789efc212bc32b49c0fe32d894dd3734c0deb40418462b111d8767 WHIRLPOOL 619d2bcb1ef7784293c901d1221faef72b67d9950b5aaf9deabed54f70798db076108966504f55fd544ac8409df858256173fb40a7106bff11952442a93aae90 EBUILD git-1.9.2-r1.ebuild 17980 SHA256 22d1c728dcec188263a710c39821d72a44ccd37ff4f5d0fb6817ab71bba9be01 SHA512 09cd4bc1ad31dd0fe2ca65d9150f81e192509b9d026288db598e5bc25e8e55f9d60131eefedf3cf14c5ac3027e1e10b7a9fe7e353298ac69e42168c3beb17358 WHIRLPOOL 46a5a45cc05c92963d7a8bc9a4ba6875d9b1d001e18a6391f92dd5b469345ba09f3a13377be89587729ed8206afee2d38481fd6342d0a43e0e31679f04ba6219 +EBUILD git-1.9.3-r1.ebuild 18093 SHA256 0e915ee64415ad6e3ffc2dce2677fda2773557db92749508bc7ffadc29ba8b81 SHA512 6f91cb6681608f41db1daf11b203e6372f7326aaa499eea828d833fad704ce6dc5c2751306823d6e8f3f749b585222c86a87450c13ca0bb8738887dc8740646a WHIRLPOOL cb6537b95bd9b12f3bb0fef2217f3d253d5f0f4764e2f9031efdb47302a93b4438cc1a2f841da57637a964fa477ceea8628a74792c12461bd86a636d7955a60a MISC ChangeLog 14640 SHA256 93e5716b0507feccca7491368318d70253258477da99b1847df3cb3591829941 SHA512 33bf68b1b61093c8e9369136a68137d26db31dc4ba812ddc73409f75ef7d0b697c7b74b763254c11b2e4e3a4affb63925d068296f2cec8247caf3d5ff4950b30 WHIRLPOOL d7350b8dd141c5abdcd140ac6fb65ee3d831502b5989dda174282fcf01c9abf9a62c90809e8aa8f2bc9db640218c79836e8f8f46a9357daa4bd66ac340d0a52b MISC ChangeLog-2012 94624 SHA256 7c8c313ea4800194191f7255023cabd205e56bb9761e8877dfab3770024b158c SHA512 f19cae0a29e8598e3bb68f1295baa56ff0edf06b2e3a95081ea2f95c4555d63dd6a0bff5a82345b274a1936104a75a69fe7862d7738a7fa2539ec9a7afd6b28f WHIRLPOOL 059ab6c542757c4524cb20cebb3cfa4bfbbe16d3a66da0805fb972d32f91f2a49bee97d1d73acf74d8e2cf3cc7a552371cf66db0580506d4b1a9e05ee52bdea4 MISC metadata.xml 1877 SHA256 74e93a953d9484c1f5806efc9c80bfa729b4d53415a00168e5ffec255750f7bd SHA512 3ef0d74206f67c27b82cefa40602cd33e432cc0f06ce900766d32f1ebd0a71d6cfa750ae77660531fc61a1117f7959d7df6ec10f439cfa2ee372d54d7ac87c5c WHIRLPOOL b9d97eb6b92a1894d965a5e9fbfbfd0d64625b31318fab2eb11b4dcb331133dbf678f62a7216c12b53a2546fa5d6a07c6240bddfa7784a925eafed602a7ffa75 diff --git a/dev-vcs/git/git-1.9.3-r1.ebuild b/dev-vcs/git/git-1.9.3-r1.ebuild new file mode 100644 index 0000000..715b2cd --- /dev/null +++ b/dev-vcs/git/git-1.9.3-r1.ebuild @@ -0,0 +1,645 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 + +GENTOO_DEPEND_ON_PERL=no + +# bug #329479: git-remote-testgit is not multiple-version aware +PYTHON_COMPAT=( python2_{6,7} ) +PYTHON_NO_MAGIC_HEADER_CFLAGS=nope +[[ ${PV} == *9999 ]] && SCM="git-2" +EGIT_REPO_URI="git://git.kernel.org/pub/scm/git/git.git" + +inherit toolchain-funcs eutils elisp-common perl-module bash-completion-r1 python-single-r1 systemd ${SCM} + +MY_PV="${PV/_rc/.rc}" +MY_P="${PN}-${MY_PV}" + +DOC_VER=${MY_PV} + +DESCRIPTION="GIT - the stupid content tracker, the revision control system heavily used by the Linux kernel team" +HOMEPAGE="http://www.git-scm.com/" +if [[ ${PV} != *9999 ]]; then + SRC_URI_SUFFIX="gz" + SRC_URI_GOOG="http://git-core.googlecode.com/files" + SRC_URI_KORG="mirror://kernel/software/scm/git" + SRC_URI="${SRC_URI_GOOG}/${MY_P}.tar.${SRC_URI_SUFFIX} + ${SRC_URI_KORG}/${MY_P}.tar.${SRC_URI_SUFFIX} + ${SRC_URI_GOOG}/${PN}-manpages-${DOC_VER}.tar.${SRC_URI_SUFFIX} + ${SRC_URI_KORG}/${PN}-manpages-${DOC_VER}.tar.${SRC_URI_SUFFIX} + doc? ( + ${SRC_URI_KORG}/${PN}-htmldocs-${DOC_VER}.tar.${SRC_URI_SUFFIX} + ${SRC_URI_GOOG}/${PN}-htmldocs-${DOC_VER}.tar.${SRC_URI_SUFFIX} + )" + KEYWORDS="~amd64" +else + SRC_URI="" + KEYWORDS="" +fi + +LICENSE="GPL-2" +SLOT="0" +IUSE="+blksha1 +curl cgi doc emacs gnome-keyring +gpg gtk highlight +iconv mediawiki +nls +pcre +perl +python ppcsha1 tk +threads +webdav xinetd cvs subversion test" + +# Common to both DEPEND and RDEPEND +CDEPEND=" + dev-libs/openssl + sys-libs/zlib + pcre? ( dev-libs/libpcre ) + perl? ( dev-lang/perl:=[-build(-)] ) + tk? ( dev-lang/tk ) + curl? ( + net-misc/curl + webdav? ( dev-libs/expat ) + ) + emacs? ( virtual/emacs ) + gnome-keyring? ( gnome-base/gnome-keyring )" + +RDEPEND="${CDEPEND} + gpg? ( app-crypt/gnupg ) + mediawiki? ( + dev-perl/HTML-Tree + dev-perl/MediaWiki-API + ) + perl? ( dev-perl/Error + dev-perl/Net-SMTP-SSL + dev-perl/Authen-SASL + cgi? ( virtual/perl-CGI highlight? ( app-text/highlight ) ) + cvs? ( >=dev-vcs/cvsps-2.1 dev-perl/DBI dev-perl/DBD-SQLite ) + subversion? ( dev-vcs/subversion[-dso,perl] dev-perl/libwww-perl dev-perl/TermReadKey ) + ) + python? ( gtk? + ( + >=dev-python/pygtk-2.8[${PYTHON_USEDEP}] + >=dev-python/pygtksourceview-2.10.1-r1:2[${PYTHON_USEDEP}] + ) + ${PYTHON_DEPS} )" + +# This is how info docs are created with Git: +# .txt/asciidoc --(asciidoc)---------> .xml/docbook +# .xml/docbook --(docbook2texi.pl)--> .texi +# .texi --(makeinfo)---------> .info +DEPEND="${CDEPEND} + app-arch/cpio + doc? ( + app-text/asciidoc + app-text/docbook2X + sys-apps/texinfo + app-text/xmlto + ) + nls? ( sys-devel/gettext ) + test? ( app-crypt/gnupg )" + +# Live ebuild builds man pages and HTML docs, additionally +if [[ ${PV} == *9999 ]]; then + DEPEND="${DEPEND} + app-text/asciidoc" +fi + +SITEFILE=50${PN}-gentoo.el +S="${WORKDIR}/${MY_P}" + +REQUIRED_USE=" + cgi? ( perl ) + cvs? ( perl ) + mediawiki? ( perl ) + subversion? ( perl ) + webdav? ( curl ) + gtk? ( python ) + python? ( ${PYTHON_REQUIRED_USE} ) +" + +pkg_setup() { + if use subversion && has_version "dev-vcs/subversion[dso]"; then + ewarn "Per Gentoo bugs #223747, #238586, when subversion is built" + ewarn "with USE=dso, there may be weird crashes in git-svn. You" + ewarn "have been warned." + fi + if use python ; then + python-single-r1_pkg_setup + fi +} + +# This is needed because for some obscure reasons future calls to make don't +# pick up these exports if we export them in src_unpack() +exportmakeopts() { + local myopts + + if use blksha1 ; then + myopts="${myopts} BLK_SHA1=YesPlease" + elif use ppcsha1 ; then + myopts="${myopts} PPC_SHA1=YesPlease" + fi + + if use curl ; then + use webdav || myopts="${myopts} NO_EXPAT=YesPlease" + else + myopts="${myopts} NO_CURL=YesPlease" + fi + + # broken assumptions, because of broken build system ... + myopts="${myopts} NO_FINK=YesPlease NO_DARWIN_PORTS=YesPlease" + myopts="${myopts} INSTALL=install TAR=tar" + myopts="${myopts} SHELL_PATH=${EPREFIX}/bin/sh" + myopts="${myopts} SANE_TOOL_PATH=" + myopts="${myopts} OLD_ICONV=" + myopts="${myopts} NO_EXTERNAL_GREP=" + + # For svn-fe + extlibs="-lz -lssl ${S}/xdiff/lib.a $(usex threads -lpthread '')" + + # can't define this to null, since the entire makefile depends on it + sed -i -e '/\/usr\/local/s/BASIC_/#BASIC_/' Makefile + + use iconv \ + || myopts="${myopts} NO_ICONV=YesPlease" + use nls \ + || myopts="${myopts} NO_GETTEXT=YesPlease" + use tk \ + || myopts="${myopts} NO_TCLTK=YesPlease" + use pcre \ + && myopts="${myopts} USE_LIBPCRE=yes" \ + && extlibs="${extlibs} -lpcre" + use perl \ + && myopts="${myopts} INSTALLDIRS=vendor" \ + || myopts="${myopts} NO_PERL=YesPlease" + use python \ + || myopts="${myopts} NO_PYTHON=YesPlease" + use subversion \ + || myopts="${myopts} NO_SVN_TESTS=YesPlease" + use threads \ + && myopts="${myopts} THREADED_DELTA_SEARCH=YesPlease" \ + || myopts="${myopts} NO_PTHREADS=YesPlease" + use cvs \ + || myopts="${myopts} NO_CVS=YesPlease" +# Disabled until ~m68k-mint can be keyworded again +# if [[ ${CHOST} == *-mint* ]] ; then +# myopts="${myopts} NO_MMAP=YesPlease" +# myopts="${myopts} NO_IPV6=YesPlease" +# myopts="${myopts} NO_STRLCPY=YesPlease" +# myopts="${myopts} NO_MEMMEM=YesPlease" +# myopts="${myopts} NO_MKDTEMP=YesPlease" +# myopts="${myopts} NO_MKSTEMPS=YesPlease" +# fi + if [[ ${CHOST} == ia64-*-hpux* ]]; then + myopts="${myopts} NO_NSEC=YesPlease" + fi + if [[ ${CHOST} == *-*-aix* ]]; then + myopts="${myopts} NO_FNMATCH_CASEFOLD=YesPlease" + fi + if [[ ${CHOST} == *-solaris* ]]; then + myopts="${myopts} NEEDS_LIBICONV=YesPlease" + fi + + has_version '>=app-text/asciidoc-8.0' \ + && myopts="${myopts} ASCIIDOC8=YesPlease" + myopts="${myopts} ASCIIDOC_NO_ROFF=YesPlease" + + # Bug 290465: + # builtin-fetch-pack.c:816: error: 'struct stat' has no member named 'st_mtim' + [[ "${CHOST}" == *-uclibc* ]] && \ + myopts="${myopts} NO_NSEC=YesPlease" + + export MY_MAKEOPTS="${myopts}" + export EXTLIBS="${extlibs}" +} + +src_unpack() { + if [[ ${PV} != *9999 ]]; then + unpack ${MY_P}.tar.${SRC_URI_SUFFIX} + cd "${S}" + unpack ${PN}-manpages-${DOC_VER}.tar.${SRC_URI_SUFFIX} + use doc && \ + cd "${S}"/Documentation && \ + unpack ${PN}-htmldocs-${DOC_VER}.tar.${SRC_URI_SUFFIX} + cd "${S}" + else + git-2_src_unpack + cd "${S}" + #cp "${FILESDIR}"/GIT-VERSION-GEN . + fi + +} + +src_prepare() { + # bug #350330 - automagic CVS when we don't want it is bad. + epatch "${FILESDIR}"/git-1.9.0_rc3-optional-cvs.patch + + # install mediawiki perl modules also in vendor_dir + # hack, needs better upstream solution + epatch "${FILESDIR}"/git-1.8.5-mw-vendor.patch + + epatch_user + + sed -i \ + -e 's:^\(CFLAGS[[:space:]]*=\).*$:\1 $(OPTCFLAGS) -Wall:' \ + -e 's:^\(LDFLAGS[[:space:]]*=\).*$:\1 $(OPTLDFLAGS):' \ + -e 's:^\(CC[[:space:]]* =\).*$:\1$(OPTCC):' \ + -e 's:^\(AR[[:space:]]* =\).*$:\1$(OPTAR):' \ + -e "s:\(PYTHON_PATH[[:space:]]\+=[[:space:]]\+\)\(.*\)$:\1${EPREFIX}\2:" \ + -e "s:\(PERL_PATH[[:space:]]\+=[[:space:]]\+\)\(.*\)$:\1${EPREFIX}\2:" \ + Makefile contrib/svn-fe/Makefile || die "sed failed" + + # Never install the private copy of Error.pm (bug #296310) + sed -i \ + -e '/private-Error.pm/s,^,#,' \ + perl/Makefile.PL + + # Fix docbook2texi command + sed -r -i 's/DOCBOOK2X_TEXI[[:space:]]*=[[:space:]]*docbook2x-texi/DOCBOOK2X_TEXI = docbook2texi.pl/' \ + Documentation/Makefile || die "sed failed" + + # Fix git-subtree missing DESTDIR + sed -i \ + -e '/$(INSTALL)/s/ $(libexecdir)/ $(DESTDIR)$(libexecdir)/g' \ + -e '/$(INSTALL)/s/ $(man1dir)/ $(DESTDIR)$(man1dir)/g' \ + contrib/subtree/Makefile +} + +git_emake() { + # bug #326625: PERL_PATH, PERL_MM_OPT + # bug #320647: PYTHON_PATH + PYTHON_PATH="" + use python && PYTHON_PATH="${PYTHON}" + emake ${MY_MAKEOPTS} \ + DESTDIR="${D}" \ + OPTCFLAGS="${CFLAGS}" \ + OPTLDFLAGS="${LDFLAGS}" \ + OPTCC="$(tc-getCC)" \ + OPTAR="$(tc-getAR)" \ + prefix="${EPREFIX}"/usr \ + htmldir="${EPREFIX}"/usr/share/doc/${PF}/html \ + sysconfdir="${EPREFIX}"/etc \ + PYTHON_PATH="${PYTHON_PATH}" \ + PERL_MM_OPT="" \ + GIT_TEST_OPTS="--no-color" \ + V=1 \ + "$@" + # This is the fix for bug #326625, but it also causes breakage, see bug + # #352693. + # PERL_PATH="${EPREFIX}/usr/bin/env perl" \ +} + +src_configure() { + exportmakeopts +} + +src_compile() { + if use perl ; then + git_emake perl/PM.stamp || die "emake perl/PM.stamp failed" + git_emake perl/perl.mak || die "emake perl/perl.mak failed" + fi + git_emake || die "emake failed" + + if use emacs ; then + elisp-compile contrib/emacs/git{,-blame}.el + fi + + if use perl && use cgi ; then + git_emake \ + gitweb/gitweb.cgi \ + || die "emake gitweb/gitweb.cgi failed" + fi + + if [[ ${CHOST} == *-darwin* ]]; then + cd "${S}"/contrib/credential/osxkeychain || die "cd credential/osxkeychain" + git_emake || die "emake credential-osxkeychain" + fi + + cd "${S}"/Documentation + if [[ ${PV} == *9999 ]] ; then + git_emake man \ + || die "emake man failed" + if use doc ; then + git_emake info html \ + || die "emake info html failed" + fi + else + if use doc ; then + git_emake info \ + || die "emake info html failed" + fi + fi + + if use subversion ; then + cd "${S}"/contrib/svn-fe + git_emake EXTLIBS="${EXTLIBS}" || die "emake svn-fe failed" + if use doc ; then + git_emake svn-fe.{1,html} || die "emake svn-fe.1 svn-fe.html failed" + fi + cd "${S}" + fi + + if use gnome-keyring ; then + cd "${S}"/contrib/credential/gnome-keyring + git_emake || die "emake git-credential-gnome-keyring failed" + fi + + cd "${S}"/contrib/subtree + git_emake + use doc && git_emake doc + + if use mediawiki ; then + cd "${S}"/contrib/mw-to-git + git_emake + fi +} + +src_install() { + git_emake \ + install || \ + die "make install failed" + + if [[ ${CHOST} == *-darwin* ]]; then + dobin contrib/credential/osxkeychain/git-credential-osxkeychain + fi + + # Depending on the tarball and manual rebuild of the documentation, the + # manpages may exist in either OR both of these directories. + find man?/*.[157] >/dev/null 2>&1 && doman man?/*.[157] + find Documentation/*.[157] >/dev/null 2>&1 && doman Documentation/*.[157] + + dodoc README Documentation/{SubmittingPatches,CodingGuidelines} + use doc && dodir /usr/share/doc/${PF}/html + for d in / /howto/ /technical/ ; do + docinto ${d} + dodoc Documentation${d}*.txt + use doc && dohtml -p ${d} Documentation${d}*.html + done + docinto / + # Upstream does not ship this pre-built :-( + use doc && doinfo Documentation/{git,gitman}.info + + newbashcomp contrib/completion/git-completion.bash ${PN} + # Not really a bash-completion file (bug #477920) + dodoc contrib/completion/git-prompt.sh + # but still needed uncompressed (bug #507480) + insinto /usr/share/${PN} + doins contrib/completion/git-prompt.sh + + if use emacs ; then + elisp-install ${PN} contrib/emacs/git.{el,elc} + elisp-install ${PN} contrib/emacs/git-blame.{el,elc} + #elisp-install ${PN}/compat contrib/emacs/vc-git.{el,elc} + # don't add automatically to the load-path, so the sitefile + # can do a conditional loading + touch "${ED}${SITELISP}/${PN}/compat/.nosearch" + elisp-site-file-install "${FILESDIR}"/${SITEFILE} + fi + + if use python && use gtk ; then + python_doscript "${S}"/contrib/gitview/gitview + dodoc "${S}"/contrib/gitview/gitview.txt + fi + + #dobin contrib/fast-import/git-p4 # Moved upstream + #dodoc contrib/fast-import/git-p4.txt # Moved upstream + newbin contrib/fast-import/import-tars.perl import-tars + exeinto /usr/libexec/git-core/ + newexe contrib/git-resurrect.sh git-resurrect + + # git-subtree + cd "${S}"/contrib/subtree + git_emake install || die "Failed to emake install git-subtree" + if use doc ; then + git_emake install-man install-doc || die "Failed to emake install-doc install-mangit-subtree" + fi + newdoc README README.git-subtree + dodoc git-subtree.txt + cd "${S}" + + if use mediawiki ; then + cd "${S}"/contrib/mw-to-git + git_emake install + cd "${S}" + fi + + # git-diffall + dobin contrib/diffall/git-diffall + newdoc contrib/diffall/README git-diffall.txt + + # diff-highlight + dobin contrib/diff-highlight/diff-highlight + newdoc contrib/diff-highlight/README README.diff-highlight + + # git-jump + exeinto /usr/libexec/git-core/ + doexe contrib/git-jump/git-jump + newdoc contrib/git-jump/README git-jump.txt + + # git-contacts + exeinto /usr/libexec/git-core/ + doexe contrib/contacts/git-contacts + dodoc contrib/contacts/git-contacts.txt + + if use gnome-keyring ; then + cd "${S}"/contrib/credential/gnome-keyring + dobin git-credential-gnome-keyring + fi + + if use subversion ; then + cd "${S}"/contrib/svn-fe + dobin svn-fe + dodoc svn-fe.txt + use doc && doman svn-fe.1 && dohtml svn-fe.html + cd "${S}" + fi + + # remote-helpers + if use python ; then + python_scriptinto /usr/libexec/git-core/ + python_doscript "${S}"/contrib/remote-helpers/git-remote-{bzr,hg} + python_optimize + fi + + dodir /usr/share/${PN}/contrib + # The following are excluded: + # completion - installed above + # credential/gnome-keyring TODO + # diff-highlight - done above + # diffall - done above + # emacs - installed above + # examples - these are stuff that is not used in Git anymore actually + # git-jump - done above + # gitview - installed above + # p4import - excluded because fast-import has a better one + # patches - stuff the Git guys made to go upstream to other places + # persistent-https - TODO + # mw-to-git - TODO + # subtree - build seperately + # svnimport - use git-svn + # thunderbird-patch-inline - fixes thunderbird + for i in \ + buildsystems convert-objects fast-import \ + hg-to-git hooks remotes2config.sh rerere-train.sh \ + stats vim workdir \ + ; do + cp -rf \ + "${S}"/contrib/${i} \ + "${ED}"/usr/share/${PN}/contrib \ + || die "Failed contrib ${i}" + done + + if use perl && use cgi ; then + # We used to install in /usr/share/${PN}/gitweb + # but upstream installs in /usr/share/gitweb + # so we will install a symlink and use their location for compat with other + # distros + dosym /usr/share/gitweb /usr/share/${PN}/gitweb + + # INSTALL discusses configuration issues, not just installation + docinto / + newdoc "${S}"/gitweb/INSTALL INSTALL.gitweb + newdoc "${S}"/gitweb/README README.gitweb + + find "${ED}"/usr/lib64/perl5/ \ + -name .packlist \ + -exec rm \{\} \; + else + rm -rf "${ED}"/usr/share/gitweb + fi + + if ! use subversion ; then + rm -f "${ED}"/usr/libexec/git-core/git-svn \ + "${ED}"/usr/share/man/man1/git-svn.1* + fi + + if use xinetd ; then + insinto /etc/xinetd.d + newins "${FILESDIR}"/git-daemon.xinetd git-daemon + fi + + if use !prefix ; then + newinitd "${FILESDIR}"/git-daemon-r1.initd git-daemon + newconfd "${FILESDIR}"/git-daemon.confd git-daemon + systemd_newunit "${FILESDIR}/git-daemon_at.service" "git-daemon@.service" + systemd_dounit "${FILESDIR}/git-daemon.socket" + fi + + fixlocalpod +} + +src_test() { + local disabled="" + local tests_cvs="t9200-git-cvsexportcommit.sh \ + t9400-git-cvsserver-server.sh \ + t9401-git-cvsserver-crlf.sh \ + t9402-git-cvsserver-refs.sh \ + t9600-cvsimport.sh \ + t9601-cvsimport-vendor-branch.sh \ + t9602-cvsimport-branches-tags.sh \ + t9603-cvsimport-patchsets.sh \ + t9604-cvsimport-timestamps.sh" + local tests_perl="t3701-add-interactive.sh \ + t5502-quickfetch.sh \ + t5512-ls-remote.sh \ + t5520-pull.sh \ + t7106-reset-unborn-branch.sh \ + t7501-commit.sh" + # Bug #225601 - t0004 is not suitable for root perm + # Bug #219839 - t1004 is not suitable for root perm + # t0001-init.sh - check for init notices EPERM* fails + local tests_nonroot="t0001-init.sh \ + t0004-unwritable.sh \ + t0070-fundamental.sh \ + t1004-read-tree-m-u-wf.sh \ + t3700-add.sh \ + t7300-clean.sh" + # t9100 still fails with symlinks in SVN 1.7 + local test_svn="t9100-git-svn-basic.sh" + + # Unzip is used only for the testcase code, not by any normal parts of Git. + if ! has_version app-arch/unzip ; then + einfo "Disabling tar-tree tests" + disabled="${disabled} t5000-tar-tree.sh" + fi + + cvs=0 + use cvs && let cvs=$cvs+1 + if [[ ${EUID} -eq 0 ]]; then + if [[ $cvs -eq 1 ]]; then + ewarn "Skipping CVS tests because CVS does not work as root!" + ewarn "You should retest with FEATURES=userpriv!" + disabled="${disabled} ${tests_cvs}" + fi + einfo "Skipping other tests that require being non-root" + disabled="${disabled} ${tests_nonroot}" + else + [[ $cvs -gt 0 ]] && \ + has_version dev-vcs/cvs && \ + let cvs=$cvs+1 + [[ $cvs -gt 1 ]] && \ + has_version "dev-vcs/cvs[server]" && \ + let cvs=$cvs+1 + if [[ $cvs -lt 3 ]]; then + einfo "Disabling CVS tests (needs dev-vcs/cvs[USE=server])" + disabled="${disabled} ${tests_cvs}" + fi + fi + + if ! use perl ; then + einfo "Disabling tests that need Perl" + disabled="${disabled} ${tests_perl}" + fi + + einfo "Disabling tests that fail with SVN 1.7" + disabled="${disabled} ${test_svn}" + + # Reset all previously disabled tests + cd "${S}/t" + for i in *.sh.DISABLED ; do + [[ -f "${i}" ]] && mv -f "${i}" "${i%.DISABLED}" + done + einfo "Disabled tests:" + for i in ${disabled} ; do + [[ -f "${i}" ]] && mv -f "${i}" "${i}.DISABLED" && einfo "Disabled $i" + done + + # Avoid the test system removing the results because we want them ourselves + sed -e '/^[[:space:]]*$(MAKE) clean/s,^,#,g' \ + -i "${S}"/t/Makefile + + # Clean old results first, must always run + cd "${S}/t" + nonfatal git_emake clean + + # Now run the tests, keep going if we hit an error, and don't terminate on + # failure + cd "${S}" + einfo "Start test run" + #MAKEOPTS=-j1 + nonfatal git_emake --keep-going test + rc=$? + + # Display nice results, now print the results + cd "${S}/t" + nonfatal git_emake aggregate-results + + # And bail if there was a problem + [ $rc -eq 0 ] || die "tests failed. Please file a bug." +} + +showpkgdeps() { + local pkg=$1 + shift + elog " $(printf "%-17s:" ${pkg}) ${@}" +} + +pkg_postinst() { + use emacs && elisp-site-regen + einfo "Please read /usr/share/bash-completion/git for Git bash command completion" + einfo "Please read /usr/share/bash-completion/git-prompt for Git bash prompt" + einfo "Note that the prompt bash code is now in the seperate script" + elog "These additional scripts need some dependencies:" + echo + showpkgdeps git-quiltimport "dev-util/quilt" + showpkgdeps git-instaweb \ + "|| ( www-servers/lighttpd www-servers/apache www-servers/nginx )" + echo +} + +pkg_postrm() { + use emacs && elisp-site-regen +} |