# Copyright 1999-2002 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: $ #NOTE: To build a light GMT you could compile without some resources like: HIGH and FULL data base resolution and PDF documentation. For so, use something like export NO_FULL="YES"; export NO_HIGH="YES"; export NO_PDF="YES"; ... DESCRIPTION="Powerfull map generator" HOMEPAGE="http://gmt.soest.hawaii.edu/" #The line above is necessary to work in _beta, _pre, _rc... releases My_P="$(echo ${PV}|cut -d '_' -f 1)" SRC_URI="ftp://gmt.soest.hawaii.edu/pub/gmt/GMT${My_P}_progs.tar.bz2 ftp://gmt.soest.hawaii.edu/pub/gmt/GMT_share.tar.bz2 ftp://gmt.soest.hawaii.edu/pub/gmt/GMT${My_P}_man.tar.bz2 ftp://gmt.soest.hawaii.edu/pub/gmt/GMT${My_P}_tut.tar.bz2 ftp://gmt.soest.hawaii.edu/pub/gmt/GMT${My_P}_scripts.tar.bz2" #Without PDF documentation if [ "${NO_PDF}" != "YES" ] | [ "${NO_PDF}" != "yes" ] then SRC_URI=${SRC_URI}" ftp://gmt.soest.hawaii.edu/pub/gmt/GMT${My_P}_pdf.tar.bz2" fi #Without FULL data base resolution if [ "${NO_FULL}" != "YES" ] | [ "${NO_FULL}" != "yes" ] then SRC_URI=${SRC_URI}" ftp://gmt.soest.hawaii.edu/pub/gmt/GMT_full.tar.bz2" fi #Without HIGH data base resolution if [ "${NO_HIGH}" != "YES" ] | [ "${NO_HIGH}" != "yes" ] then SRC_URI=${SRC_URI}" ftp://gmt.soest.hawaii.edu/pub/gmt/GMT_high.tar.bz2" fi LICENSE="GPL2" SLOT="0" KEYWORDS="x86" IUSE="" #Need to include gcc and bzip?? DEPEND=">=sys-devel/gcc >=app-sci/netcdf-3.5.0" #RDEPEND="" #S=${WORKDIR}/${P} S="${WORKDIR}/GMT${My_P}" #Maybe the next line could be removed and so the env-update and the include in the env.d too! INSTALLDIR="/usr/local" src_unpack() { unpack ${A} || die; cp ${WORKDIR}/share/* ${S}/share/ || die } src_compile() { ./configure \ --prefix=$INSTALLDIR make all || die } src_install() { make \ prefix=${D}$INSTALLDIR \ bindir=${D}$INSTALLDIR/bin \ libdir=${D}$INSTALLDIR/lib \ includedir=${D}$INSTALLDIR/include \ mandir=${D}$INSTALLDIR/man \ datadir=${D}$INSTALLDIR/share \ install install-data install-man || die dodir /etc/env.d echo -e "PATH=${INSTALLDIR}/bin\nMANPATH=${INSTALLDIR}/man" > \ ${D}/etc/env.d/40gmt } pkg_postinst() { env-update }