# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=portfile:et:sw=4:ts=4:sts=4

PortSystem          1.0

name                sc
version             7.16
revision            2
maintainers         nomaintainer

categories          finance
description         sc is the Venerable Spreadsheet Calculator
long_description    sc is a free curses-based spreadsheet program that uses key bindings similar to vi and less.

platforms           darwin

homepage            http://www.ibiblio.org/pub/Linux/apps/financial/spreadsheet/

master_sites        ${homepage}

checksums           rmd160  bcaffd292bc3d0868e5be870fee743c6b3294377 \
                    sha256  1997a00b6d82d189b65f6fd2a856a34992abc99e50d9ec463bbf1afb750d1765

patchfiles          Makefile.diff

depends_lib         port:ncurses \
                    port:bison

use_configure       no

# TODO: This is a real bug that clang is complaining about.
#       Fix it rather than just working around it
if {[string match "*clang*" ${configure.compiler}]} {
    configure.cflags-append -Wno-error=return-type
}

variant universal {}

build.args-append   CC="${configure.cc} ${configure.cppflags} ${configure.cflags} [get_canonical_archflags]"

destroot.destdir-append    prefix=${prefix}

livecheck.type      none