aboutsummaryrefslogtreecommitdiffstats
path: root/databases/py-sqlobject/Makefile
blob: 3c49ce715268463a8b7ec9fcd74e28de02398873 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# Ports collection makefile for:    py-sqlobject
# Date created:             24 June 2004
# Whom:                 "Choe, Cheng-Dae" whitekid
#
# $FreeBSD$
#

PORTNAME=   sqlobject
PORTVERSION=    0.10.6
CATEGORIES= databases python
MASTER_SITES=   CHEESESHOP
PKGNAMEPREFIX=  ${PYTHON_PKGNAMEPREFIX}
DISTNAME=   SQLObject-${PORTVERSION}

MAINTAINER= wenheping@gmail.com
COMMENT=    A python object for manipulation with SQL table row

USE_PYTHON= yes
USE_PYDISTUTILS=    easy_install
PYDISTUTILS_PKGNAME=    SQLObject
PYDISTUTILS_NOEGGINFO=  yes # XXX convert easy_install support to bsd.python.mk's

PORTDOCS=   *

OPTIONS=    MYSQL   "MySQL supports" off \
        PGSQL   "PostgreSQL Supports" off \
        SQLITE  "SQLite Supports" off \
        MSSQL   "MSSQL Supports" off

# bypass infrastructure bug
OPTIONSFILE=    ${PORT_DBDIR}/py-${PORTNAME}/options

.include <bsd.port.pre.mk>

PYSQLOBJECT_EGG=    SQLObject-${SQLOBJECTVER}-py${PYTHONVER}.egg
PYFORMENCODE_EGG!=  ${MAKE} -f ${PORTSDIR}/www/py-formencode/Makefile -V PYFORMENCODE_EGG

RUN_DEPENDS+=   ${PYTHON_SITELIBDIR}/${PYFORMENCODE_EGG}:${PORTSDIR}/www/py-formencode

.if defined(WITH_MYSQL)
RUN_DEPENDS+=   ${PYTHON_SITELIBDIR}/MySQLdb/__init__.py:${PORTSDIR}/databases/py-MySQLdb
.endif

.if defined(WITH_PGSQL)
RUN_DEPENDS+=   ${PYTHON_SITELIBDIR}/psycopg2/__init__.py:${PORTSDIR}/databases/py-psycopg2
.endif

.if defined(WITH_SQLITE)
RUN_DEPENDS+=   ${PYTHON_SITELIBDIR}/pysqlite2/__init__.py:${PORTSDIR}/databases/py-pysqlite20
.endif

.if defined(WITH_MSSQL)
RUN_DEPENDS+=   ${PYTHON_SITELIBDIR}/pymssql.py:${PORTSDIR}/databases/py-mssql
.endif

# currently FireBird, MaxDB(SAP), Sybase, ADODB are not supported

post-install:
.if !defined(NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_MAN} ${WRKSRC}/README.txt ${DOCSDIR}
    ${CP} -r ${WRKSRC}/docs/* ${DOCSDIR}
.endif

.include <bsd.port.post.mk>