cook-1.0.2-r1.ebuild 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. # Copyright 1999-2017 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. inherit toolchain-funcs
  4. DESCRIPTION="Embedded language which can be used as a macro preprocessor"
  5. HOMEPAGE="http://cook.sourceforge.net/"
  6. SRC_URI="mirror://sourceforge/cook/${P}.tar.gz"
  7. LICENSE="GPL-2"
  8. SLOT="0"
  9. KEYWORDS="~amd64 ppc x86 ~x86-linux ~ppc-macos ~sparc-solaris"
  10. IUSE=""
  11. DEPEND=""
  12. src_compile() {
  13. emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" || die "emake failed"
  14. }
  15. src_install() {
  16. use prefix || EPREFIX=
  17. dodoc README doc/cook.txt doc/cook.html || die "dodoc failed"
  18. insinto /usr/share/doc/${PF}/example
  19. doins test/pcb.dbdef test/pcb.dg test/pcbprol.ps test/tempsens.pcb || die "doins failed"
  20. newbin src/cook cookproc || die "newbin failed"
  21. cat > "${T}"/README.Gentoo <<EOF
  22. NOTICE:
  23. ${EPREFIX}/usr/bin/cook has been renamed to ${EPREFIX}/usr/bin/cookproc in Gentoo
  24. -- Karl Trygve Kalleberg <karltk@gentoo.org>
  25. EOF
  26. dodoc "${T}"/README.Gentoo || die "dodoc failed"
  27. }
  28. pkg_postinst() {
  29. ewarn "${EPREFIX}/usr/bin/cook has been renamed to ${EPREFIX}/usr/bin/cookproc"
  30. }