aboutsummaryrefslogtreecommitdiff
path: root/devel/gpsim/Makefile
blob: 571f31df767462fef0a8d2d5f359806110a02704 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Created by: Jose Alonso Cardenas Marquez <acardenas@bsd.org.pe>
# $FreeBSD$

PORTNAME=	gpsim
PORTVERSION=	0.22.0
PORTREVISION=	8
CATEGORIES=	devel
MASTER_SITES=	SF

MAINTAINER=	acm@FreeBSD.org
COMMENT=	A software simulator for Microchip PIC microcontrollers

LIB_DEPENDS=	popt.0:${PORTSDIR}/devel/popt \
		gtkextra-x11-2.0.1:${PORTSDIR}/x11-toolkits/gtkextra2
RUN_DEPENDS=	gpasm:${PORTSDIR}/devel/gputils

USE_AUTOTOOLS=	libtool
GNU_CONFIGURE=	yes
USES=		pkgconfig
USE_LDCONFIG=	yes
CPPFLAGS+=	-I${LOCALBASE}/include
LDFLAGS+=	-L${LOCALBASE}/lib

.include <bsd.port.pre.mk>

post-patch:
	@${REINPLACE_CMD} -e 's|glib/.*\.h>|glib.h>|g' \
		${WRKSRC}/src/os_dependent.cc
	@${REINPLACE_CMD} -e 's|glibconfig.h|glib.h|g' \
		${WRKSRC}/src/bitlog.h

post-install:
.if !defined(NOPORTDOCS)
	${MKDIR} ${DOCSDIR}
.for FILE in AUTHORS ChangeLog PROCESSORS README* doc/gpsim.pdf
	${INSTALL_DATA} ${WRKSRC}/${FILE} ${DOCSDIR}
.endfor
.endif

	${MKDIR} ${EXAMPLESDIR}
	cd ${WRKSRC}/examples && \
		${FIND} * -type d -exec ${MKDIR} "${EXAMPLESDIR}/{}" \; && \
		${FIND} -E * -type f -iregex ".*\.(asm|stc|inc)" -exec ${INSTALL_DATA} "{}" "${EXAMPLESDIR}/{}" \;

.include <bsd.port.post.mk>