# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 92357 2012-04-26 03:31:43Z rmstonecipher@macports.org $

PortSystem 1.0

name                file
version             5.11
categories          sysutils
license             BSD
maintainers         nomaintainer
description         File - determine file type
long_description \
    File tests each argument in an attempt to classify it. There are three  \
    sets of tests, performed in this order: filesystem tests, magic number  \
    tests, and language tests. The first test that succeeds causes the file \
    type to be printed. \
    Information on Mach-O binaries, it is suggested that one uses the command \
    `otool -fv`.


homepage            http://www.darwinsys.com/file/
platforms           darwin
master_sites        freebsd \
                    gentoo \
                    ftp://ftp.fu-berlin.de/unix/tools/${name}/ \
                    ftp://ftp.astron.com/pub/${name}/ \
                    ftp://ftp.gw.com/mirrors/pub/unix/${name}/
checksums           md5     16a407bd66d6c7a832f3a5c0d609c27b \
                    sha1    df8ffe8759ec8cd85a98dc98e858563ea2555f64 \
                    rmd160  68885d838c1f3836e6fada4c4ea6c88c8699fdf2

patchfiles          patch-magic-Magdir-msdos.diff \
                    patch-src-readcdf.c.diff

configure.args      --mandir=${prefix}/share/man \
                    --enable-fsect-man5
depends_lib         port:zlib

variant with_text_magic_file description (also install the plain-text magic file} {
    patchfiles-append patch-magic-Makefile.in.diff
}

livecheck.type      regex
livecheck.url       ftp://ftp.astron.com/pub/${name}/
livecheck.regex     "${name}-(\\d+(?:\\.\\d+)*)${extract.suffix}"
