# -*- coding: utf-8; mode: tcl; tab-width: 4; truncate-lines: t; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4
# $Id: Portfile 57740 2009-09-15 23:21:09Z toby@macports.org $

PortSystem 1.0

name                sdcc
version             2.9.0
categories          lang
platforms           darwin
#license             GPLv3
maintainers         snc openmaintainer
description         ANSI C compiler targeting Intel 8051, Maxim 80DS390, Zilog Z80
long_description    SDCC is a freeware, retargettable, optimizing ANSI C \
                    compiler that targets the Intel 8051, Maxim 80DS390, and \
                    Zilog Z80 based MCUs. Work is in progress on supporting \
                    Motorola 68HC08 as well as Microchip PIC16 and PIC18 series.

homepage            http://sdcc.sourceforge.net/
master_sites        sourceforge
checksums           md5     a6151ed328fd3bc48305ffbc628dc122 \
                    sha1    03308a233a67e7fdce3f7e4972acb8731ae42666 \
                    rmd160  38f23365b676132651f0322779bff498eb7e2b8d
use_bzip2           yes
distfiles           ${name}-src-${version}${extract.suffix}

worksrcdir          ${name}

# Setting CPP explicitly is bad, because 'cpp' and 'gcc -E' are not the same.
configure.cpp       {}

build.type          gnu

destroot.destdir    prefix=${destroot}${prefix} \
                    docdir=${destroot}${prefix}/share/doc/${name}

platform darwin 8 {
    depends_build-append    port:gmake
    build.cmd               ${prefix}/bin/gmake
}
