# -*- 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

PortSystem      1.0

name            fgen
version         0.3
revision        2
categories      devel
platforms       any
supported_archs noarch
license         GPL-2+
maintainers     {@kamischi web.de:karl-michael.schindler} openmaintainer
homepage        http://hpux.connect.org.uk/hppd/hpux/Misc/${name}-${version}
master_sites    https://www.ibiblio.org/pub/Linux/devel/lang/fortran/
extract.suffix  .tgz
checksums       rmd160  2bdd6d8b2f7625a2005b9bbd5eff103fe7b47ac6 \
                sha256  1513f326ebc95c7116f7d34ddb535eeec6e39ec27a089ba19f4ca6f00afc6541 \
                size    38088

description     Makefile generator for fortran 77/90 code

long_description \
FGEN - makefile generator (for GNU make) for fortran 77/90 code \
\n- Configuration of fgen (file ~/.fgenrc_alt) \
\n\t\t$> fgen -c -f ~/.fgenrc_alt \
\n\
\n- Your project is divided in 2 directories: a library (./lib) and the \
\n\tcore program (./src). To create the makefiles: \
\n\t\t$> fgen -m -s ./src -l ./lib \
\n

# This is required to rebuild the tools with substitutions and build the man files.
post-build {
    system -W ${worksrcpath} "sleep 2 && touch stamp-file && make all"
}

destroot {
    xinstall -m 0755 -W ${worksrcpath} fgen   f2html   ${destroot}${prefix}/bin
    xinstall -m 0644 -W ${worksrcpath} fgen.1 f2html.1 ${destroot}${prefix}/share/man/man1
    xinstall -d ${destroot}${prefix}/share/doc/${name}
    xinstall -m 0644 -W ${worksrcpath} README INSTALL CHANGES TODO ${destroot}${prefix}/share/doc/${name}
}
