View | Details | Raw Unified | Return to bug 136199
Collapse All | Expand All

(-)Makefile (-2 / +8 lines)
Lines 24-32 Link Here
24
USE_PYDISTUTILS=yes
24
USE_PYDISTUTILS=yes
25
PYDISTUTILS_PKGVERSION=	0.0.0
25
PYDISTUTILS_PKGVERSION=	0.0.0
26
WRKSRC=		${PYTHON_WRKSRC}/Modules
26
WRKSRC=		${PYTHON_WRKSRC}/Modules
27
MD5_FILE=	${PORTSDIR}/lang/python/distinfo
27
MD5_FILE=	${PORTSDIR}/lang/python${PYTHON_SUFFIX}/distinfo
28
29
.include <bsd.port.pre.mk>
28
30
29
post-extract:
31
post-extract:
32
.if ${PYTHON_REL} < 300
30
	@${CP} ${FILESDIR}/setup.py ${WRKSRC}
33
	@${CP} ${FILESDIR}/setup.py ${WRKSRC}
34
.else
35
	@${CP} ${FILESDIR}/setup3.py ${WRKSRC}/setup.py
36
.endif
31
37
32
.include <bsd.port.mk>
38
.include <bsd.port.post.mk>
(-)files/setup3.py (+28 lines)
Added Link Here
1
#!/usr/bin/env python
2
# To use:
3
#       python setup.py install
4
#
5
6
__version__ = "$FreeBSD$"
7
8
try:
9
    import distutils
10
    from distutils import sysconfig
11
    from distutils.command.install import install
12
    from distutils.core import setup, Extension
13
except:
14
    raise SystemExit("Distutils problem")
15
16
prefix = sysconfig.PREFIX
17
inc_dirs = [prefix + "/include"]
18
lib_dirs = [prefix + "/lib"]
19
libs = ["gdbm"]
20
21
setup(name = "gdbm",
22
      description = "GDBM Extension to Python",
23
      
24
      ext_modules = [Extension('gdbm', ['_gdbmmodule.c'],
25
                               include_dirs = inc_dirs,
26
                               libraries = libs,
27
                               library_dirs = lib_dirs)]
28
      )

Return to bug 136199