head 1.7; access; symbols pkgsrc-2013Q2:1.7.0.10 pkgsrc-2013Q2-base:1.7 pkgsrc-2012Q4:1.7.0.8 pkgsrc-2012Q4-base:1.7 pkgsrc-2011Q4:1.7.0.6 pkgsrc-2011Q4-base:1.7 pkgsrc-2011Q2:1.7.0.4 pkgsrc-2011Q2-base:1.7 pkgsrc-2009Q4:1.7.0.2 pkgsrc-2009Q4-base:1.7 pkgsrc-2009Q2:1.6.0.18 pkgsrc-2009Q2-base:1.6 pkgsrc-2009Q1:1.6.0.16 pkgsrc-2009Q1-base:1.6 pkgsrc-2008Q4:1.6.0.14 pkgsrc-2008Q4-base:1.6 pkgsrc-2008Q3:1.6.0.12 pkgsrc-2008Q3-base:1.6 cube-native-xorg:1.6.0.10 cube-native-xorg-base:1.6 pkgsrc-2008Q2:1.6.0.8 pkgsrc-2008Q2-base:1.6 cwrapper:1.6.0.6 pkgsrc-2008Q1:1.6.0.4 pkgsrc-2008Q1-base:1.6 pkgsrc-2007Q4:1.6.0.2 pkgsrc-2007Q4-base:1.6 pkgsrc-2007Q3:1.5.0.28 pkgsrc-2007Q3-base:1.5 pkgsrc-2007Q2:1.5.0.26 pkgsrc-2007Q2-base:1.5 pkgsrc-2007Q1:1.5.0.24 pkgsrc-2007Q1-base:1.5 pkgsrc-2006Q4:1.5.0.22 pkgsrc-2006Q4-base:1.5 pkgsrc-2006Q3:1.5.0.20 pkgsrc-2006Q3-base:1.5 pkgsrc-2006Q2:1.5.0.18 pkgsrc-2006Q2-base:1.5 pkgsrc-2006Q1:1.5.0.16 pkgsrc-2006Q1-base:1.5 pkgsrc-2005Q4:1.5.0.14 pkgsrc-2005Q4-base:1.5 pkgsrc-2005Q3:1.5.0.12 pkgsrc-2005Q3-base:1.5 pkgsrc-2005Q2:1.5.0.10 pkgsrc-2005Q2-base:1.5 pkgsrc-2005Q1:1.5.0.8 pkgsrc-2005Q1-base:1.5 pkgsrc-2004Q4:1.5.0.6 pkgsrc-2004Q4-base:1.5 pkgsrc-2004Q3:1.5.0.4 pkgsrc-2004Q3-base:1.5 pkgsrc-2004Q2:1.5.0.2 pkgsrc-2004Q2-base:1.5 pkgsrc-2004Q1:1.4.0.2 pkgsrc-2004Q1-base:1.4 pkgsrc-2003Q4:1.1.0.2 pkgsrc-2003Q4-base:1.1; locks; strict; comment @# @; 1.7 date 2009.09.07.18.17.29; author joerg; state dead; branches; next 1.6; 1.6 date 2007.12.24.01.19.48; author minskim; state Exp; branches; next 1.5; 1.5 date 2004.04.13.22.48.41; author recht; state Exp; branches; next 1.4; 1.4 date 2004.03.22.06.33.58; author minskim; state Exp; branches; next 1.3; 1.3 date 2003.12.23.17.24.42; author recht; state Exp; branches; next 1.2; 1.2 date 2003.12.08.21.13.56; author recht; state Exp; branches; next 1.1; 1.1 date 2003.09.14.14.04.31; author recht; state Exp; branches; next ; desc @@ 1.7 log @Remove py22-html-docs, py23-html-docs and Python 2.3. @ text @$NetBSD: patch-am,v 1.6 2007/12/24 01:19:48 minskim Exp $ --- setup.py.orig 2005-01-17 13:07:49.000000000 -0800 +++ setup.py @@@@ -15,7 +15,7 @@@@ from distutils.command.install import in from distutils.command.install_lib import install_lib # This global variable is used to hold the list of modules to be disabled. -disabled_module_list = [] +disabled_module_list = ["_bsddb", "_curses", "_curses_panel", "_tkinter", "gdbm", "mpz", "pyexpat", "readline"] def add_dir_to_list(dirlist, dir): """Add the directory 'dir' to the list 'dirlist' (at the front) if @@@@ -240,9 +240,15 @@@@ class PyBuildExt(build_ext): return sys.platform def detect_modules(self): - # Ensure that /usr/local is always used - add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib') - add_dir_to_list(self.compiler.include_dirs, '/usr/local/include') + # Add the buildlink directories for pkgsrc + if os.environ.has_key('BUILDLINK_DIR'): + dir = os.environ['BUILDLINK_DIR'] + libdir = dir + '/lib' + incdir = dir + '/include' + if libdir not in self.compiler.library_dirs: + self.compiler.library_dirs.insert(0, libdir) + if incdir not in self.compiler.include_dirs: + self.compiler.include_dirs.insert(0, incdir) # fink installs lots of goodies in /sw/... - make sure we # check there @@@@ -436,9 +442,7 @@@@ class PyBuildExt(build_ext): depends = ['socketmodule.h']) ) # Detect SSL support for the socket module (via _ssl) ssl_incs = find_file('openssl/ssl.h', inc_dirs, - ['/usr/local/ssl/include', - '/usr/contrib/ssl/include/' - ] + [] ) if ssl_incs is not None: krb5_h = find_file('krb5.h', inc_dirs, @@@@ -446,9 +450,7 @@@@ class PyBuildExt(build_ext): if krb5_h: ssl_incs += krb5_h ssl_libs = find_library_file(self.compiler, 'ssl',lib_dirs, - ['/usr/local/ssl/lib', - '/usr/contrib/ssl/lib/' - ] ) + [] ) if (ssl_incs is not None and ssl_libs is not None): @@@@ -479,116 +481,162 @@@@ class PyBuildExt(build_ext): # when sorted in reverse order, keys for this dict must appear in the # order you wish to search - e.g., search for db4 before db3 - db_try_this = { - 'db4': {'libs': ('db-4.2', 'db42', 'db-4.1', 'db41', 'db-4.0', 'db4',), - 'libdirs': ('/usr/local/BerkeleyDB.4.2/lib', - '/usr/local/BerkeleyDB.4.1/lib', - '/usr/local/BerkeleyDB.4.0/lib', - '/usr/local/lib', - '/opt/sfw', - '/sw/lib', - ), - 'incdirs': ('/usr/local/BerkeleyDB.4.2/include', - '/usr/local/include/db42', - '/usr/local/BerkeleyDB.4.1/include', - '/usr/local/include/db41', - '/usr/local/BerkeleyDB.4.0/include', - '/usr/local/include/db4', - '/opt/sfw/include/db4', - '/sw/include/db4', - '/usr/include/db4', - )}, - 'db3': {'libs': ('db-3.3', 'db-3.2', 'db-3.1', 'db3',), - 'libdirs': ('/usr/local/BerkeleyDB.3.3/lib', - '/usr/local/BerkeleyDB.3.2/lib', - '/usr/local/BerkeleyDB.3.1/lib', - '/usr/local/lib', - '/opt/sfw/lib', - '/sw/lib', - ), - 'incdirs': ('/usr/local/BerkeleyDB.3.3/include', - '/usr/local/BerkeleyDB.3.2/include', - '/usr/local/BerkeleyDB.3.1/include', - '/usr/local/include/db3', - '/opt/sfw/include/db3', - '/sw/include/db3', - '/usr/include/db3', - )}, - } - - db_search_order = db_try_this.keys() - db_search_order.sort() - db_search_order.reverse() + #db_try_this = { + #'db4': {'libs': ('db-4.2', 'db42', 'db-4.1', 'db41', 'db-4.0', 'db4',), + #'libdirs': ('/usr/local/BerkeleyDB.4.2/lib', + #'/usr/local/BerkeleyDB.4.1/lib', + #'/usr/local/BerkeleyDB.4.0/lib', + #'/usr/local/lib', + #'/opt/sfw', + #'/sw/lib', + #), + #'incdirs': ('/usr/local/BerkeleyDB.4.2/include', + #'/usr/local/include/db42', + #'/usr/local/BerkeleyDB.4.1/include', + #'/usr/local/include/db41', + #'/usr/local/BerkeleyDB.4.0/include', + #'/usr/local/include/db4', + #'/opt/sfw/include/db4', + #'/sw/include/db4', + #'/usr/include/db4', + #)}, + #'db3': {'libs': ('db-3.3', 'db-3.2', 'db-3.1', 'db3',), + #'libdirs': ('/usr/local/BerkeleyDB.3.3/lib', + #'/usr/local/BerkeleyDB.3.2/lib', + #'/usr/local/BerkeleyDB.3.1/lib', + #'/usr/local/lib', + #'/opt/sfw/lib', + #'/sw/lib', + #), + #'incdirs': ('/usr/local/BerkeleyDB.3.3/include', + #'/usr/local/BerkeleyDB.3.2/include', + #'/usr/local/BerkeleyDB.3.1/include', + #'/usr/local/include/db3', + #'/opt/sfw/include/db3', + #'/sw/include/db3', + #'/usr/include/db3', + #)}, + #} + + #db_search_order = db_try_this.keys() + #db_search_order.sort() + #db_search_order.reverse() + + #class found(Exception): pass + #try: + ## See whether there is a Sleepycat header in the standard + ## search path. + #std_dbinc = None + #for d in inc_dirs: + #f = os.path.join(d, "db.h") + #if os.path.exists(f): + #f = open(f).read() + #m = re.search(r"#define\WDB_VERSION_MAJOR\W([1-9]+)", f) + #if m: + #std_dbinc = 'db' + m.group(1) + #for dbkey in db_search_order: + #dbd = db_try_this[dbkey] + #for dblib in dbd['libs']: + ## Prefer version-specific includes over standard + ## include locations. + #db_incs = find_file('db.h', [], dbd['incdirs']) + #dblib_dir = find_library_file(self.compiler, + #dblib, + #lib_dirs, + #list(dbd['libdirs'])) + #if (db_incs or dbkey == std_dbinc) and \ + #dblib_dir is not None: + #dblibs = [dblib] + #raise found + #except found: + #dblibs = [dblib] + ## A default source build puts Berkeley DB in something like + ## /usr/local/Berkeley.3.3 and the lib dir under that isn't + ## normally on ld.so's search path, unless the sysadmin has hacked + ## /etc/ld.so.conf. We add the directory to runtime_library_dirs + ## so the proper -R/--rpath flags get passed to the linker. This + ## is usually correct and most trouble free, but may cause problems + ## in some unusual system configurations (e.g. the directory is on + ## an NFS server that goes away). + #exts.append(Extension('_bsddb', ['_bsddb.c'], + #library_dirs=dblib_dir, + #runtime_library_dirs=dblib_dir, + #include_dirs=db_incs, + #libraries=dblibs)) + #else: + #db_incs = None + #dblibs = [] + #dblib_dir = None - class found(Exception): pass + # Look for Berkeley db 1.85. Note that it is built as a different + # module name so it can be included even when later versions are + # available. A very restrictive search is performed to avoid + # accidentally building this module with a later version of the + # underlying db library. May BSD-ish Unixes incorporate db 1.85 + # symbols into libc and place the include file in /usr/include. + #f = "/usr/include/db.h" + #if os.path.exists(f): + #data = open(f).read() + #m = re.search(r"#s*define\s+HASHVERSION\s+2\s*", data) + #if m is not None: + ## bingo - old version used hash file format version 2 + #### XXX this should be fixed to not be platform-dependent + #### but I don't have direct access to an osf1 platform and + #### seemed to be muffing the search somehow + #libraries = platform == "osf1" and ['db'] or None + #if libraries is not None: + #exts.append(Extension('bsddb185', ['bsddbmodule.c'], + #libraries=libraries)) + #else: + #exts.append(Extension('bsddb185', ['bsddbmodule.c'])) + + # rely on pkgsrc for Berkeley DB + class NotFound(Exception): pass try: - # See whether there is a Sleepycat header in the standard - # search path. - std_dbinc = None - for d in inc_dirs: - f = os.path.join(d, "db.h") + bdb_type = os.environ['PY_BDB_TYPE'] + db_incs = [os.environ['PY_BDB_INCDIRS']] + dblib_dir = None + dblibs = None + + # check if need to use the db_185.h compat header + bsddb185_define_macros=[] + if bdb_type == "db2" or bdb_type == "db3" or bdb_type == "db4": + bsddb185_define_macros=[('HAVE_DB_185_H',1)] + dblib_dir = [os.environ['PY_BDB_LIBDIRS']] + + else: + # check if db_incs/db.h really is db 1.85 + f = "%s/db.h" % db_incs[0] + if os.path.exists(f): - f = open(f).read() - m = re.search(r"#define\WDB_VERSION_MAJOR\W([1-9]+)", f) - if m: - std_dbinc = 'db' + m.group(1) - for dbkey in db_search_order: - dbd = db_try_this[dbkey] - for dblib in dbd['libs']: - # Prefer version-specific includes over standard - # include locations. - db_incs = find_file('db.h', [], dbd['incdirs']) - dblib_dir = find_library_file(self.compiler, - dblib, - lib_dirs, - list(dbd['libdirs'])) - if (db_incs or dbkey == std_dbinc) and \ - dblib_dir is not None: - dblibs = [dblib] - raise found - except found: - dblibs = [dblib] - # A default source build puts Berkeley DB in something like - # /usr/local/Berkeley.3.3 and the lib dir under that isn't - # normally on ld.so's search path, unless the sysadmin has hacked - # /etc/ld.so.conf. We add the directory to runtime_library_dirs - # so the proper -R/--rpath flags get passed to the linker. This - # is usually correct and most trouble free, but may cause problems - # in some unusual system configurations (e.g. the directory is on - # an NFS server that goes away). - exts.append(Extension('_bsddb', ['_bsddb.c'], + data = open(f).read() + m = re.search(r"#s*define\s+HASHVERSION\s+2\s*", data) + if m is None: + # check for 1.85 compat header + if os.path.exists("%s/db_185.h" % db_incs[0]): + bsddb185_define_macros=[('HAVE_DB_185_H',1)] + else: + raise NotFound + try: + bdblib = os.environ['PY_BDB_LIBS'] + m = re.search(r"-l(db.)\s*", bdblib) + if m is not None and m.group(1) is not None: + dblibs = [m.group(1)] + except: + pass + + # build the bsddb185 extension module + exts.append(Extension('bsddb185', ['bsddbmodule.c'], library_dirs=dblib_dir, runtime_library_dirs=dblib_dir, include_dirs=db_incs, + define_macros=bsddb185_define_macros, libraries=dblibs)) - else: + except: db_incs = None dblibs = [] - dblib_dir = None - - - # Look for Berkeley db 1.85. Note that it is built as a different - # module name so it can be included even when later versions are - # available. A very restrictive search is performed to avoid - # accidentally building this module with a later version of the - # underlying db library. May BSD-ish Unixes incorporate db 1.85 - # symbols into libc and place the include file in /usr/include. - f = "/usr/include/db.h" - if os.path.exists(f): - data = open(f).read() - m = re.search(r"#s*define\s+HASHVERSION\s+2\s*", data) - if m is not None: - # bingo - old version used hash file format version 2 - ### XXX this should be fixed to not be platform-dependent - ### but I don't have direct access to an osf1 platform and - ### seemed to be muffing the search somehow - libraries = platform == "osf1" and ['db'] or None - if libraries is not None: - exts.append(Extension('bsddb185', ['bsddbmodule.c'], - libraries=libraries)) - else: - exts.append(Extension('bsddb185', ['bsddbmodule.c'])) - + dblib_dir = None + # The standard Unix dbm module: if platform not in ['cygwin']: if find_file("ndbm.h", inc_dirs, []) is not None: @@@@ -600,6 +648,13 @@@@ class PyBuildExt(build_ext): exts.append( Extension('dbm', ['dbmmodule.c'], define_macros=[('HAVE_NDBM_H',None)], libraries = ndbm_libs ) ) + elif find_file("ndbm.h", db_incs, []) is not None: + exts.append( Extension('dbm', ['dbmmodule.c'], + library_dirs=dblib_dir, + runtime_library_dirs=dblib_dir, + include_dirs=db_incs, + define_macros=[('HAVE_NDBM_H',None)], + libraries=dblibs)) elif (self.compiler.find_library_file(lib_dirs, 'gdbm') and find_file("gdbm/ndbm.h", inc_dirs, []) is not None): exts.append( Extension('dbm', ['dbmmodule.c'], @@@@ -770,7 +825,7 @@@@ class PyBuildExt(build_ext): # Linux-specific modules exts.append( Extension('linuxaudiodev', ['linuxaudiodev.c']) ) - if platform in ('linux2', 'freebsd4'): + if platform in ('linux2', 'freebsd4', 'freebsd5'): exts.append( Extension('ossaudiodev', ['ossaudiodev.c']) ) if platform == 'sunos5': @@@@ -1148,7 +1203,7 @@@@ def main(): ext_modules=[Extension('struct', ['structmodule.c'])], # Scripts to install - scripts = ['Tools/scripts/pydoc', 'Tools/scripts/idle'] + scripts = ['Tools/scripts/pydoc2.3'] ) # --install-platlib @ 1.6 log @Use BDB_LIBS to obtain the BDB library name, instead of guessing it from BUILDLINK_TRANSFORM. This fixes PR 37297. @ text @d1 1 a1 1 $NetBSD$ @ 1.5 log @Rework bdb detection: Since we're using buildlink we could save rely on the variables it sets (eg. BDB_TYPE). While at bl3ify. Thanks to minskim@@ for fixes and testing. @ text @d3 1 a3 1 --- setup.py.orig 2003-10-21 15:01:21.000000000 -0500 d271 2 a272 2 + bltransform = os.environ['PY_BDB_TRANSFORM'] + m = re.search(r"l:db:(db.)\s*", bltransform) d342 1 a342 1 @@@@ -1140,7 +1195,7 @@@@ def main(): @ 1.4 log @Disable db3 and db4 detection in python23 and python23-pth, so as to prevent them from picking up a wrong db library on systems that have native db3 or db4. @ text @d55 227 a281 9 @@@@ -515,6 +517,7 @@@@ class PyBuildExt(build_ext): '/usr/include/db3', )}, } + db_try_this = {} db_search_order = db_try_this.keys() db_search_order.sort() @@@@ -562,9 +565,11 @@@@ class PyBuildExt(build_ext): d283 1 d285 4 a288 3 else: - db_incs = None - dblibs = [] d290 8 a297 12 + db_incs =['%%DB185_INCS%%'] + dblibs = ['%%DB185_LIBS%%'] + dblib_dir = ['%%DB185_LIBDIR%%'] + if len(dblibs) > 0 and dblibs[0] == '': + dblibs = [] # Look for Berkeley db 1.85. Note that it is built as a different @@@@ -573,21 +578,30 @@@@ class PyBuildExt(build_ext): # accidentally building this module with a later version of the # underlying db library. May BSD-ish Unixes incorporate db 1.85 # symbols into libc and place the include file in /usr/include. d299 8 a306 12 + f = "%%DB185_H%%" if os.path.exists(f): data = open(f).read() m = re.search(r"#s*define\s+HASHVERSION\s+2\s*", data) if m is not None: + bsddb185_define_macros = [] + if f.split("/")[-1] == "db_185.h": + bsddb185_define_macros=[('HAVE_DB_185_H',1)] # bingo - old version used hash file format version 2 ### XXX this should be fixed to not be platform-dependent ### but I don't have direct access to an osf1 platform and ### seemed to be muffing the search somehow d308 4 a311 10 + #libraries = platform == "osf1" and ['db'] or None + libraries = dblibs if libraries is not None: exts.append(Extension('bsddb185', ['bsddbmodule.c'], + library_dirs=dblib_dir, + runtime_library_dirs=dblib_dir, + include_dirs=db_incs, + define_macros=bsddb185_define_macros, libraries=libraries)) else: d313 3 a315 3 + exts.append(Extension('bsddb185', ['bsddbmodule.c'], + define_macros=bsddb185_define_macros)) d318 16 a333 1 @@@@ -770,7 +784,7 @@@@ class PyBuildExt(build_ext): d342 1 a342 1 @@@@ -1140,7 +1154,7 @@@@ def main(): @ 1.3 log @update to 2.3.3 This is a bug-fix release for Python 2.3 that fixes a number of bugs, including a couple of serious errors with weakrefs and the cyclic garbage collector. There are also a number of fixes to the standard library - see the release notes ( http://www.python.org/2.3.3/NEWS.html )for details. @ text @d1 1 a1 1 $NetBSD: patch-am,v 1.2 2003/12/08 21:13:56 recht Exp $ d3 3 a5 3 --- setup.py.orig 2003-10-21 22:01:21.000000000 +0200 +++ setup.py 2003-12-23 12:43:32.000000000 +0100 @@@@ -15,7 +15,7 @@@@ d14 1 a14 1 @@@@ -240,9 +240,15 @@@@ d33 1 a33 1 @@@@ -436,9 +442,7 @@@@ d44 1 a44 1 @@@@ -446,9 +450,7 @@@@ d55 9 a63 1 @@@@ -562,9 +564,11 @@@@ d78 1 a78 1 @@@@ -573,21 +577,30 @@@@ d112 1 a112 1 @@@@ -770,7 +783,7 @@@@ d121 1 a121 1 @@@@ -1140,7 +1153,7 @@@@ @ 1.2 log @Update to Python 2.3.2 Changes in Python: Quite a few fixes.. See NEWS for details. Changes in the pkg: - add FreeBSD patches from the FreeBSD port - add fix for a fatal bug in type's GC handling causes segfaults (via FreeBSD port) see http://cvs.sourceforge.net/viewcvs.py/python/python/dist/src/Misc/NEWS?r1=1.831.4.75&r2=1.831.4.76&diff_format=u - always build the db 1.85 module (on all platforms) @ text @d1 1 a1 1 $NetBSD$ d3 2 a4 2 --- setup.py.orig 2003-09-22 03:19:45.000000000 +0200 +++ setup.py 2003-12-08 21:33:30.000000000 +0100 d104 1 a104 1 @@@@ -765,7 +778,7 @@@@ d113 1 a113 1 @@@@ -1135,7 +1148,7 @@@@ @ 1.1 log @Avoid redefinition of redefinition of wchar_t and wint_ if _XOPEN_SOURCE_EXTENDED is defined. This fixes py-curses on NetBSD > 1.6T. Bumb PKGREVSION to 2, because of the header change. @ text @d3 119 a121 24 --- Include/py_curses.h.orig 2003-09-14 13:55:07.000000000 +0200 +++ Include/py_curses.h 2003-09-14 14:10:49.000000000 +0200 @@@@ -39,6 +39,21 @@@@ #endif #endif +#ifdef __NetBSD__ +/* +** On NetBSD, [n]curses.h and stdlib.h/wchar.h use different guards +** against multiple definition of wchar_t and wint_t. +*/ +#ifdef _XOPEN_SOURCE_EXTENDED +#ifndef _WCHAR_T +#define _WCHAR_T +#endif +#ifndef _WINT_T +#define _WINT_T +#endif +#endif +#endif + #ifdef HAVE_NCURSES_H #include #else @