# -*- 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 48673 2009-03-27 01:38:43Z mcalhoun@macports.org $

PortSystem          1.0

name                py25-pydb
version             1.25
revision            1
categories          python
maintainers         macfreek.nl:software dweber openmaintainer
description         Extended Python debugger
long_description    pydb is an expanded version of the Python debugger loosely \
                    based on the gdb command set. To use pydb in a GUI, also \
                    install the ddd packages, and run "ddd --pydb"
homepage            http://bashdb.sourceforge.net/pydb/

platforms           darwin

master_sites        sourceforge:bashdb
distname            pydb-${version}
use_bzip2           yes

checksums           md5 a4b3005f92521461eb55663a1b8d1642 \
                    sha1 c9c85d3c3003d7d2feebc081bb71bf5649d3e09c \
                    rmd160 aebba569564dac9415ef6fc3b16f32f3157d1ce3

depends_lib         port:python25

patchfiles          patch-Makefile.in.diff

# Install binaries and man pages in a different location to avoid conflict
#    with other Python versions
set python_prefix   ${frameworks_dir}/Python.framework/Versions/2.5
configure.pre_args  --prefix=${python_prefix}

configure.python    ${prefix}/bin/python2.5

# python2.5 gives the incorrect location of site-packages (see #16334).
configure.args      --with-site-packages=${prefix}/lib/python2.5

post-destroot {
    # Install binaries and man pages with version appended.
    foreach fl [glob -tails -directory ${destroot}${python_prefix}/bin *] {
        ln -s ${python_prefix}/bin/${fl} ${destroot}${prefix}/bin/${fl}-2.5
    }
    foreach fl {pydb} {
        ln -s ${python_prefix}/share/man/man1/${fl}.1 ${destroot}${prefix}/share/man/man1/${fl}-2.5.1
    }
}
