summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Seifert <soap@gentoo.org>2020-09-16 20:18:00 +0200
committerDavid Seifert <soap@gentoo.org>2020-09-16 20:18:00 +0200
commitb40447c39470be93739c443eec590434df922b27 (patch)
tree45f355fc7407159c1328347d76607e6b14a270ea /dev-embedded/picasm
parentdev-embedded/libdisasm: Port to EAPI 7 (diff)
downloadgentoo-b40447c39470be93739c443eec590434df922b27.tar.gz
gentoo-b40447c39470be93739c443eec590434df922b27.tar.bz2
gentoo-b40447c39470be93739c443eec590434df922b27.zip
dev-embedded/picasm: Port to EAPI 7
Closes: https://bugs.gentoo.org/742194 Package-Manager: Portage-3.0.7, Repoman-3.0.1 Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'dev-embedded/picasm')
-rw-r--r--dev-embedded/picasm/files/picasm-1.14-makefile.patch27
-rw-r--r--dev-embedded/picasm/picasm-1.14.ebuild23
2 files changed, 38 insertions, 12 deletions
diff --git a/dev-embedded/picasm/files/picasm-1.14-makefile.patch b/dev-embedded/picasm/files/picasm-1.14-makefile.patch
new file mode 100644
index 000000000000..0ac5bacd7305
--- /dev/null
+++ b/dev-embedded/picasm/files/picasm-1.14-makefile.patch
@@ -0,0 +1,27 @@
+--- a/Makefile
++++ b/Makefile
+@@ -5,21 +5,19 @@
+ # See the file LICENSE for license terms.
+ #
+
+-DEFS=-DBUILTIN_INCLUDE1=\"/usr/local/share/picasm/include\"
++CPPFLAGS += -DBUILTIN_INCLUDE1=\"/usr/share/picasm/include\"
+ #DEFS=-DBUILTIN_INCLUDE1=\"/home/trossi/bin/picasm-include\"
+
+-CC = gcc
+-CFLAGS = -Wall -Wshadow -W -Werror -O2 $(DEFS)
++CFLAGS += -Wall -Wshadow -W
+ RM = /bin/rm -f
+
+ VERSION=114
+
+-OBJS = picasm.o config.o token.o symtab.o expr.o \
++OBJS = config.o token.o symtab.o expr.o \
+ pic12bit.o pic14bit.o pic16bit.o \
+ util.o
+
+ picasm: $(OBJS)
+- $(CC) $(CFLAGS) $(OBJS) -o $@
+
+ clean:
+ $(RM) picasm *.o examples/*.hex examples/*.lst
diff --git a/dev-embedded/picasm/picasm-1.14.ebuild b/dev-embedded/picasm/picasm-1.14.ebuild
index c8fa9d90d9a6..b0ac54ba35ee 100644
--- a/dev-embedded/picasm/picasm-1.14.ebuild
+++ b/dev-embedded/picasm/picasm-1.14.ebuild
@@ -1,12 +1,13 @@
-# Copyright 1999-2012 Gentoo Foundation
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=4
+EAPI=7
-inherit toolchain-funcs flag-o-matic
+inherit toolchain-funcs
MY_PV="${PV//.}"
MY_P="${PN}${MY_PV}"
+
DESCRIPTION="An assembler and disassembler for 12 and 14-bit PIC chips"
HOMEPAGE="http://www.iki.fi/trossi/pic/"
SRC_URI="http://www.iki.fi/trossi/pic/${MY_P}.tar.bz2"
@@ -14,17 +15,13 @@ SRC_URI="http://www.iki.fi/trossi/pic/${MY_P}.tar.bz2"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 x86"
-IUSE=""
-S=${WORKDIR}/${MY_P}
+S="${WORKDIR}/${MY_P}"
-src_prepare() {
- sed -i -e 's:$(CC):\0 $(LDFLAGS):' Makefile || die
-}
+PATCHES=( "${FILESDIR}"/${P}-makefile.patch )
-src_compile() {
- append-cflags -DBUILTIN_INCLUDE1=\\\"/usr/share/picasm/include\\\"
- emake CFLAGS="${CFLAGS}" CC="$(tc-getCC)"
+src_configure() {
+ tc-export CC
}
src_install() {
@@ -34,8 +31,10 @@ src_install() {
insinto /usr/share/picasm/include
doins device_definitions/*.i
- dohtml picasm.html
docinto examples
dodoc examples/*.*
docompress -x /usr/share/doc/${PF}/examples
+
+ docinto html
+ dodoc picasm.html
}