# -*- 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$ PortSystem 1.0 name fortune version 6.2.0-RELEASE categories games platforms darwin freebsd maintainers gmail.com:stuartwesterman openmaintainer license BSD installs_libs no description Infamous electronic fortune-cookie generator long_description ${description} homepage http://www.freebsd.org/ master_sites macports use_bzip2 yes checksums md5 6185fe31e512e8b23ac5cc58ede27919 worksrcdir ${name} patchfiles patch-fortune-Makefile \ patch-strfile-Makefile \ patch-unstr-Makefile \ patch-datfiles-Makefile \ patch-strfile.h post-patch { reinplace "s|/usr|${prefix}|" ${worksrcpath}/fortune/pathnames.h reinplace "s|/usr/share|${prefix}/share|" ${worksrcpath}/fortune/fortune.6 reinplace "s|/usr/games/fortune|${prefix}/bin/fortune|" ${worksrcpath}/fortune/fortune.6 reinplace "s|XXPREFIX|${prefix}|" ${worksrcpath}/fortune/Makefile } use_configure no variant universal {} build.type bsd build.env-append CFLAGS="[get_canonical_archflags]" \ CC=${configure.cc} destroot { xinstall -m 755 -W ${worksrcpath} fortune/fortune strfile/strfile \ unstr/unstr ${destroot}${prefix}/bin xinstall -m 644 ${worksrcpath}/fortune/fortune.6.gz \ ${destroot}${prefix}/share/man/man6 xinstall -m 644 ${worksrcpath}/strfile/strfile.8.gz \ ${destroot}${prefix}/share/man/man8 xinstall -m 644 ${worksrcpath}/strfile/strfile.8.gz \ ${destroot}${prefix}/share/man/man8/unstr.8.gz xinstall -m 755 -d ${destroot}${prefix}/share/games/fortune xinstall -m 644 -W ${worksrcpath}/datfiles \ fortunes fortunes.dat fortunes-o fortunes-o.dat \ fortunes2-o fortunes2-o.dat limerick limerick.dat \ murphy murphy.dat murphy-o murphy-o.dat \ startrek startrek.dat zippy zippy.dat \ ${destroot}${prefix}/share/games/fortune } platform darwin { patchfiles-append patch-fortune.c patch-strfile.c patch-unstr.c }