dev-cpp/ctemplate: Bump to EAPI 6

Package-Manager: Portage-2.3.3, Repoman-2.3.1
This commit is contained in:
David Seifert
2017-01-22 23:16:18 +01:00
parent 96331b574f
commit 9ecdc3f74b
2 changed files with 107 additions and 0 deletions
+78
View File
@@ -0,0 +1,78 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI=6
PYTHON_COMPAT=( python2_7 )
inherit autotools elisp-common python-any-r1
DESCRIPTION="A simple but powerful template language for C++"
HOMEPAGE="https://github.com/olafvdspek/ctemplate"
SRC_URI="https://dev.gentoo.org/~pinkbyte/distfiles/${P}.tar.bz2"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~arm ~ppc ~x86 ~amd64-linux ~x86-linux"
IUSE="doc emacs vim-syntax static-libs test"
DEPEND="test? ( ${PYTHON_DEPS} )"
RDEPEND="
emacs? ( virtual/emacs )
vim-syntax? ( >=app-editors/vim-core-7 )"
SITEFILE="70ctemplate-gentoo.el"
# Some tests are broken in 2.3
RESTRICT="test"
PATCHES=( "${FILESDIR}"/${PN}-2.3-fix-build-system.patch )
src_prepare() {
default
eautoreconf
}
src_configure() {
econf $(use_enable static-libs static)
}
src_compile() {
default
if use emacs; then
elisp-compile contrib/tpl-mode.el
fi
}
src_install() {
default
if ! use doc; then
rm -r "${ED%/}"/usr/share/doc/${PF}/html || die
fi
if use vim-syntax; then
cd "${S}/contrib" || die
sh highlighting.vim || die "unpacking vim scripts failed"
insinto /usr/share/vim/vimfiles
doins -r .vim/.
fi
if use emacs; then
cd "${S}/contrib" || die
elisp-install ${PN} tpl-mode.el tpl-mode.elc
elisp-site-file-install "${FILESDIR}/${SITEFILE}"
fi
# package provides .pc files
find "${D}" -name '*.la' -delete || die
}
pkg_postinst() {
use emacs && elisp-site-regen
}
pkg_postrm() {
use emacs && elisp-site-regen
}
@@ -0,0 +1,29 @@
* Do not override $(docdir) as userflag in the GNU conventions
* Only build tests programs when running 'make check'
--- a/Makefile.am
+++ b/Makefile.am
@@ -54,12 +54,11 @@
src/ctemplate/per_expand_data.h.in \
src/ctemplate/str_ref.h.in
-docdir = $(prefix)/share/doc/$(PACKAGE)-$(VERSION)
## This is for HTML and other documentation you want to install.
## Add your documentation files (in doc/) in addition to these
## top-level boilerplate files. Also add a TODO file if you have one.
-dist_doc_DATA = AUTHORS COPYING ChangeLog INSTALL NEWS README README_windows.txt \
- doc/designstyle.css doc/index.html \
+dist_doc_DATA = AUTHORS ChangeLog NEWS README README_windows.txt
+dist_html_DATA = doc/designstyle.css doc/index.html \
doc/howto.html doc/guide.html doc/reference.html \
doc/tips.html doc/example.html doc/auto_escape.html \
doc/xss_resources.html
@@ -452,7 +451,7 @@
## This should always include $(TESTS), but may also include other
## binaries that you compile but don't want automatically installed.
-noinst_PROGRAMS = $(TESTS)
+check_PROGRAMS = $(TESTS)
rpm: dist-gzip packages/rpm.sh packages/rpm/rpm.spec
@cd packages && ./rpm.sh ${PACKAGE} ${VERSION}