2004-05-10 01:26:39 +02:00
|
|
|
# New ports collection makefile for: sdcc
|
|
|
|
# Date created: 3 May 2004
|
|
|
|
# Whom: Tijl Coosemans <tijl@ulyssis.org>
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= sdcc
|
2007-09-29 23:37:22 +02:00
|
|
|
PORTVERSION= 2.7.3.2007.09.28
|
2004-05-10 01:26:39 +02:00
|
|
|
CATEGORIES= lang
|
2005-04-17 14:25:50 +02:00
|
|
|
MASTER_SITES= http://sdcc.sourceforge.net/snapshots/sdcc-src/ \
|
2007-09-29 23:37:22 +02:00
|
|
|
http://tijl.ulyssis.be/mirror/
|
|
|
|
DISTNAME= ${PORTNAME}-src-20070928-4920
|
2004-05-10 01:26:39 +02:00
|
|
|
|
|
|
|
MAINTAINER= tijl@ulyssis.org
|
|
|
|
COMMENT= Small Device C Compiler
|
|
|
|
|
|
|
|
WRKSRC= ${WRKDIR}/sdcc
|
|
|
|
|
|
|
|
GNU_CONFIGURE= yes
|
2005-04-17 14:25:50 +02:00
|
|
|
NO_LATEST_LINK= yes
|
2006-08-11 22:42:55 +02:00
|
|
|
USE_BZIP2= yes
|
2004-05-10 01:26:39 +02:00
|
|
|
USE_GMAKE= yes
|
|
|
|
|
|
|
|
OPTIONS= MCS51 "Intel mcs51 port" on \
|
2006-08-11 22:42:55 +02:00
|
|
|
Z80 "Zilog Z80 port" on \
|
2004-05-10 01:26:39 +02:00
|
|
|
AVR "AVR port" on \
|
2006-08-11 22:42:55 +02:00
|
|
|
DS390 "Maxim DS390/DS400 port" on \
|
|
|
|
PIC "Microchip PIC port" on \
|
|
|
|
PIC16 "Microchip PIC16 port" on \
|
|
|
|
XA51 "Philips XA51 port" on \
|
|
|
|
HC08 "Motorola 68HC08 port" on \
|
2006-06-30 07:02:43 +02:00
|
|
|
DEVLIB "Device libraries" on \
|
2004-05-10 01:26:39 +02:00
|
|
|
UCSIM "The ucSim simulator" on \
|
|
|
|
PACKIHX "A tool to pack (compress) Intel hex files" on
|
|
|
|
|
2007-09-29 23:37:22 +02:00
|
|
|
CONFIGURE_ARGS= CPPFLAGS="-I${LOCALBASE}/include" \
|
|
|
|
LDFLAGS="-L${LOCALBASE}/lib" \
|
|
|
|
--datarootdir=${DATADIR} \
|
|
|
|
--docdir=${DOCSDIR} \
|
|
|
|
include_dir_suffix=include \
|
|
|
|
lib_dir_suffix=lib
|
|
|
|
|
2004-05-10 01:26:39 +02:00
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
|
2006-12-14 14:49:55 +01:00
|
|
|
.if !defined(WITHOUT_MCS51) && !defined(WITHOUT_UCSIM) && ${OSVERSION} < 500019
|
2007-09-29 23:37:22 +02:00
|
|
|
LIB_DEPENDS+= readline.5:${PORTSDIR}/devel/readline
|
2006-12-14 14:49:55 +01:00
|
|
|
.endif
|
|
|
|
|
2006-06-30 07:02:43 +02:00
|
|
|
.if defined(WITHOUT_MCS51) && defined(WITHOUT_DS390)
|
|
|
|
CONFIGURE_ARGS+= --disable-51
|
|
|
|
PLIST_SUB+= MCS51DS390="@comment "
|
|
|
|
.else
|
2007-09-29 23:37:22 +02:00
|
|
|
USE_AUTOTOOLS+= autoconf:261
|
2006-06-30 07:02:43 +02:00
|
|
|
PLIST_SUB+= MCS51DS390=""
|
|
|
|
.endif
|
|
|
|
|
2004-05-10 01:26:39 +02:00
|
|
|
.if defined(WITHOUT_MCS51)
|
|
|
|
CONFIGURE_ARGS+= --disable-mcs51-port
|
|
|
|
PLIST_SUB+= MCS51="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= MCS51=""
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_Z80)
|
2006-06-30 07:02:43 +02:00
|
|
|
CONFIGURE_ARGS+= --disable-gbz80-port --disable-z80-port --disable-z80
|
2004-05-10 01:26:39 +02:00
|
|
|
PLIST_SUB+= Z80="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= Z80=""
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_AVR)
|
2006-06-30 07:02:43 +02:00
|
|
|
CONFIGURE_ARGS+= --disable-avr-port --disable-avr
|
|
|
|
PLIST_SUB+= AVR="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= AVR=""
|
2004-05-10 01:26:39 +02:00
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_DS390)
|
2005-04-13 09:53:25 +02:00
|
|
|
CONFIGURE_ARGS+= --disable-ds390-port --disable-ds400-port
|
2004-05-10 01:26:39 +02:00
|
|
|
PLIST_SUB+= DS390="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= DS390=""
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_PIC)
|
|
|
|
CONFIGURE_ARGS+= --disable-pic-port
|
2005-11-16 16:26:50 +01:00
|
|
|
PLIST_SUB+= PIC="@comment "
|
|
|
|
.else
|
2006-06-30 07:02:43 +02:00
|
|
|
BUILD_DEPENDS+= gpasm:${PORTSDIR}/devel/gputils
|
2005-11-16 16:26:50 +01:00
|
|
|
PLIST_SUB+= PIC=""
|
2004-05-10 01:26:39 +02:00
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_PIC16)
|
|
|
|
CONFIGURE_ARGS+= --disable-pic16-port
|
|
|
|
PLIST_SUB+= PIC16="@comment "
|
|
|
|
.else
|
2005-04-13 09:53:25 +02:00
|
|
|
BUILD_DEPENDS+= gpasm:${PORTSDIR}/devel/gputils
|
2004-05-10 01:26:39 +02:00
|
|
|
PLIST_SUB+= PIC16=""
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_XA51)
|
|
|
|
CONFIGURE_ARGS+= --disable-xa51-port
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_HC08)
|
2006-06-30 07:02:43 +02:00
|
|
|
CONFIGURE_ARGS+= --disable-hc08-port --disable-hc08
|
2004-05-10 01:26:39 +02:00
|
|
|
PLIST_SUB+= HC08="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= HC08=""
|
|
|
|
.endif
|
|
|
|
|
2006-06-30 07:02:43 +02:00
|
|
|
.if defined(WITHOUT_DEVLIB)
|
|
|
|
CONFIGURE_ARGS+= --disable-device-lib
|
|
|
|
PLIST_SUB+= DEVLIB="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= DEVLIB=""
|
|
|
|
.endif
|
|
|
|
|
2004-05-10 01:26:39 +02:00
|
|
|
.if defined(WITHOUT_UCSIM)
|
|
|
|
CONFIGURE_ARGS+= --disable-ucsim
|
|
|
|
PLIST_SUB+= UCSIM="@comment "
|
|
|
|
.else
|
2006-06-30 07:02:43 +02:00
|
|
|
USE_AUTOTOOLS+= libtool:15
|
|
|
|
LIBTOOLFILES= sim/ucsim/configure
|
2004-05-10 01:26:39 +02:00
|
|
|
PLIST_SUB+= UCSIM=""
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITHOUT_PACKIHX)
|
|
|
|
CONFIGURE_ARGS+= --disable-packihx
|
|
|
|
PLIST_SUB+= PACKIHX="@comment "
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= PACKIHX=""
|
|
|
|
.endif
|
|
|
|
|
2007-09-29 23:37:22 +02:00
|
|
|
post-patch:
|
|
|
|
@${REINPLACE_CMD} 's,ARCH,PICARCH,g' \
|
|
|
|
${WRKSRC}/device/lib/pic/Makefile.common.in \
|
|
|
|
${WRKSRC}/device/lib/pic/Makefile.rules \
|
|
|
|
${WRKSRC}/device/lib/pic16/Makefile.common.in \
|
|
|
|
${WRKSRC}/device/lib/pic16/Makefile.rules \
|
|
|
|
${WRKSRC}/device/lib/pic16/libio/Makefile.in
|
|
|
|
|
2004-05-10 01:26:39 +02:00
|
|
|
.include <bsd.port.post.mk>
|