picp-0.6.8.ebuild 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. # Copyright 1999-2014 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=4
  4. inherit toolchain-funcs eutils
  5. DESCRIPTION="A commandline interface to Microchip's PICSTART+ programmer"
  6. HOMEPAGE="http://home.pacbell.net/theposts/picmicro/"
  7. SRC_URI="http://home.pacbell.net/theposts/picmicro/${P}.tar.gz"
  8. LICENSE="GPL-2"
  9. SLOT="0"
  10. KEYWORDS="~amd64 x86"
  11. IUSE=""
  12. src_prepare() {
  13. sed -i -e '/strip/d' \
  14. -e 's:$(CC):\0 $(LDFLAGS):' \
  15. {.,fixchksum,picsnoop}/Makefile || die "sed failed"
  16. rm -f picsnoop/{picsnoop,*.o}
  17. epatch "${FILESDIR}"/${P}-errno.patch
  18. }
  19. src_compile() {
  20. emake CC=$(tc-getCC) OPTIONS="${CFLAGS} -x c++"
  21. emake -C picsnoop CC=$(tc-getCC) OPTIONS="${CFLAGS} -x c++"
  22. emake -C fixchksum CC=$(tc-getCC) OPTIONS="${CFLAGS}"
  23. }
  24. src_install() {
  25. dobin picp
  26. dobin picsnoop/picsnoop
  27. dobin fixchksum/fixchksum
  28. dodoc README HISTORY LICENSE.TXT NOTES PSCOMMANDS.TXT BugReports.txt TODO
  29. newdoc picsnoop/README.TXT PICSNOOP.txt
  30. newdoc fixchksum/README fixchksum.txt
  31. dohtml PICPmanual.html
  32. }