;ò ÿ¬Ec@skdgZdklZdklZdklZdkl Z dk l Z dk l Z lZdk lZdkZdkZdkZdkZdkZdkZd „ZeeƒZeefZd „Zd „Zd „Zd „Zd„Zd„Zd„Z d„Z!d„Z"defd„ƒYZx)ei#ei$ei%fD]Z&ee&_qAWdfd„ƒYZ'dS(s Distribution(s Distribution(sRequire(sinstall(ssdist(s install_lib(sDistutilsOptionErrorsDistutilsPlatformError(sDistutilsSetupErrorNcCsWx$|iidƒo|i\}qW|iidƒ otd|ƒ‚n|SdS(s•Protect against re-patching the distutils if reloaded Also ensures that no other distutils extension monkeypatched the distutils first. s setuptoolss distutilss(distutils has already been patched by %rN(sclss __module__s startswiths __bases__sAssertionError(scls((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys_get_unpatched scCshy,tiid|ƒ}|i pt‚Wn5ttt tfj ot d||fƒ‚nXdS(Nsx=s4%r must be importable 'module:attrs' string (got %r)( s pkg_resourcess EntryPointsparsesvaluesepsextrassAssertionErrors TypeErrors ValueErrorsAttributeErrorsDistutilsSetupErrorsattr(sdistsattrsvaluesep((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pyscheck_importables cCs]y!di|ƒ|jpt‚Wn5ttttfj otd||fƒ‚nXdS(s*Verify that value is a string list or Noness%%r must be a list of strings (got %r)N(sjoinsvaluesAssertionErrors TypeErrors ValueErrorsAttributeErrorsDistutilsSetupErrorsattr(sdistsattrsvalue((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysassert_string_list*s !cCsNt|||ƒx7|D]/}|i|ƒ otdd|ƒ‚qqWdS(s(Verify that namespace packages are valids1Distribution contains no modules or packages for snamespace package %rN(sassert_string_listsdistsattrsvaluesnspshas_contents_forsDistutilsSetupError(sdistsattrsvaluesnsp((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys check_nsp3s cCscy4x-|iƒD]\}}tti|ƒƒqWWn(ttt fj ot dƒ‚nXdS(s+Verify that extras_require mapping is valids‹'extras_require' must be a dictionary whose values are strings or lists of strings containing valid project/version requirement specifiers.N( svaluesitemssksvslists pkg_resourcessparse_requirementss TypeErrors ValueErrorsAttributeErrorsDistutilsSetupError(sdistsattrsvaluesksv((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys check_extras>s cCs1t|ƒ|jotd||fƒ‚ndS(s)Verify that value is True, False, 0, or 1s#%r must be a boolean value (got %r)N(sboolsvaluesDistutilsSetupErrorsattr(sdistsattrsvalue((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys assert_boolJscCsJytti|ƒƒWn,ttfj otd|fƒ‚nXdS(s9Verify that install_requires is a valid requirements lists^%r must be a string or list of strings containing valid project/version requirement specifiersN(slists pkg_resourcessparse_requirementssvalues TypeErrors ValueErrorsDistutilsSetupErrorsattr(sdistsattrsvalue((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pyscheck_requirementsSs cCs<ytii|ƒWn!tj o}t|ƒ‚nXdS(s)Verify that entry_points map is parseableN(s pkg_resourcess EntryPoints parse_mapsvalues ValueErrorsesDistutilsSetupError(sdistsattrsvaluese((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pyscheck_entry_points]s cCs%t|tƒ otdƒ‚ndS(Nstest_suite must be a string(s isinstancesvalues basestringsDistutilsSetupError(sdistsattrsvalue((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pyscheck_test_suiteescCs„t|tƒo`x]|iƒD]G\}}t|tƒ oPnyt|ƒWqtj oPqXqWdSnt |dƒ‚dS(s@Verify that value is a dictionary of package names to glob listsNsI must be a dictionary mapping package names to lists of wildcard patterns( s isinstancesvaluesdictsitemssksvsstrsiters TypeErrorsDistutilsSetupErrorsattr(sdistsattrsvaluesksv((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pyscheck_package_datajs  cBsïtZdZeZd„Zed„Zd„Zd„Zd„Z d„Z d„Z d„Z d „Z d „Zd „Zd „Zd „Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„ZRS(sxDistribution with support for features, tests, and package data This is an enhanced version of 'distutils.dist.Distribution' that effectively adds the following new optional keyword arguments to 'setup()': 'install_requires' -- a string or sequence of strings specifying project versions that the distribution requires when installed, in the format used by 'pkg_resources.require()'. They will be installed automatically when the package is installed. If you wish to use packages that are not available in PyPI, or want to give your users an alternate download location, you can add a 'find_links' option to the '[easy_install]' section of your project's 'setup.cfg' file, and then setuptools will scan the listed web pages for links that satisfy the requirements. 'extras_require' -- a dictionary mapping names of optional "extras" to the additional requirement(s) that using those extras incurs. For example, this:: extras_require = dict(reST = ["docutils>=0.3", "reSTedit"]) indicates that the distribution can optionally provide an extra capability called "reST", but it can only be used if docutils and reSTedit are installed. If the user installs your package using EasyInstall and requests one of your extras, the corresponding additional requirements will be installed if needed. 'features' -- a dictionary mapping option names to 'setuptools.Feature' objects. Features are a portion of the distribution that can be included or excluded based on user options, inter-feature dependencies, and availability on the current system. Excluded features are omitted from all setup commands, including source and binary distributions, so you can create multiple distributions from the same source tree. Feature names should be valid Python identifiers, except that they may contain the '-' (minus) sign. Features can be included or excluded via the command line options '--with-X' and '--without-X', where 'X' is the name of the feature. Whether a feature is included by default, and whether you are allowed to control this from the command line, is determined by the Feature object. See the 'Feature' class for more information. 'test_suite' -- the name of a test suite to run for the 'test' command. If the user runs 'python setup.py test', the package will be installed, and the named test suite will be run. The format is the same as would be used on a 'unittest.py' command line. That is, it is the dotted name of an object to import and call to generate a test suite. 'package_data' -- a dictionary mapping package names to lists of filenames or globs to use to find data files contained in the named packages. If the dictionary has filenames or globs listed under '""' (the empty string), those names will be searched for in every package, in addition to any names for the specific package. Data files found using these names/globs will be installed along with the package, in the same location as the package. Note that globs are allowed to reference the contents of non-package subdirectories, as long as you use '/' as a path separator. (Globs are automatically converted to platform-specific paths at runtime.) In addition to these new keywords, this class also has several new methods for manipulating the distribution's contents. For example, the 'include()' and 'exclude()' methods can be thought of as in-place add and subtract commands that add or remove packages, modules, extensions, and so on from the distribution. They are used by the feature subsystem to configure the distribution for the included and excluded features. cCs©| pd|jp d|jodSntit|dƒƒiƒ}tiii|ƒ}|t j o|i dƒ o)ti t|dƒƒ|_ ||_ndS(NsnamesversionsPKG-INFO(sattrss pkg_resourcess safe_namesstrslowerskeys working_setsby_keysgetsdistsNones has_metadatas safe_versions_versionsselfs _patched_dist(sselfsattrssdistskey((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pyspatch_missing_pkg_infoÁs"cCsGt|dƒ}| o h|_ng|_h|_g|_|i|ƒ|t j o,|i dgƒ|_ t |d|i ƒn|o d|jo|i |i dƒƒnxBtidƒD]1}t||iƒ ot||it ƒqÃqÃWti||ƒt|iitttfƒot|iiƒ|i_ndS(Ns package_datasdependency_linksssetup_requiressdistutils.setup_keywords(shasattrsselfshave_package_datas package_datasrequire_featuressfeaturess dist_filesspatch_missing_pkg_infosattrssNonespopsdependency_linkssassert_string_listsfetch_build_eggss pkg_resourcessiter_entry_pointssepsnamessetattrs _Distributions__init__s isinstancesmetadatasversionsintslongsfloatsstr(sselfsattrsshave_package_datasep((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys__init__Îs&      cCs/ti|ƒ}|io|iƒn|SdS(s3Process features after parsing command line optionsN(s _Distributionsparse_command_linesselfsresultsfeaturess_finalize_features(sselfsresult((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysparse_command_lineäs  cCsd|iddƒSdS(s;Convert feature name to corresponding option attribute nameswith_s-s_N(snamesreplace(sselfsname((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys_feature_attrnameëscCsMdkl}l}x3|i||ƒd|iƒD]}|i|ƒq2WdS(sResolve pre-setup requirements(s working_setsparse_requirementss installerN( s pkg_resourcess working_setsparse_requirementssresolvesrequiressselfsfetch_build_eggsdistsadd(sselfsrequiressdistsparse_requirementss working_set((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysfetch_build_eggsïs cCs•ti|ƒ|io|iƒnxitidƒD]X}t||i t ƒ}|t j o0|i d|i ƒ|iƒ||i |ƒq5q5WdS(Nsdistutils.setup_keywordss installer(s _Distributionsfinalize_optionssselfsfeaturess_set_global_opts_from_featuress pkg_resourcessiter_entry_pointssepsgetattrsnamesNonesvaluesrequiresfetch_build_eggsload(sselfsvaluesep((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysfinalize_options÷s   c Cshy |i}WnGtj o;dkl}|ihddg<ƒ}|iƒ|i dƒ}ddddddf}x,|i ƒD]}||jo ||=q„q„W|ioG|i}d|jo|dd iƒ|}nd |f|d\}}|i|ƒ o!|i |ƒ|i |dƒqqWdS(s9Add/remove features and resolve dependencies between themiiN( sselfsfeaturessitemssnamesfeaturesfeature_is_includedsenabledsNonesinclude_by_defaults include_ins _set_features exclude_from(sselfsenabledsnamesfeature((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys_finalize_featuresIs !   cCs~||ijo|i|SnxXtid|ƒD]4}|id|iƒ|iƒ|i|<}|Sq2Wt i ||ƒSdS(s(Pluggable version of get_command_class()sdistutils.commandss installerN( scommandsselfscmdclasss pkg_resourcessiter_entry_pointssepsrequiresfetch_build_eggsloads _Distributionsget_command_class(sselfscommandscmdclasssep((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysget_command_class[scCsaxMtidƒD]<}|i|ijo#|itƒ}||i|i<   cCs|io|iSdS(s+Should this feature be included by default?N(sselfs availablesstandard(sself((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysinclude_by_defaultßscCsW|i ot|idƒ‚n|i|ix|iD]}|i |ƒq<WdS(sEnsure feature and its requirements are included in distribution You may override this in a subclass to perform additional operations on the distribution. Note that this method may be called more than once per feature, and so should be idempotent. s2 is required,but is not available on this platformN( sselfs availablesDistutilsPlatformErrors descriptionsdistsincludesextrassrequire_featuressfsinclude_feature(sselfsdistsf((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys include_inãs  cCsC|i|i|io%x"|iD]}|i|ƒq$WndS(s2Ensure feature is excluded from distribution You may override this in a subclass to perform additional operations on the distribution. This method will be called at most once per feature, and only after all included features have been asked to include themselves. N(sdistsexcludesselfsextrassremovesitemsexclude_package(sselfsdistsitem((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys exclude_fromús   cCsIxB|iD]7}|i|ƒ o td|i||fƒ‚q q WdS(sçVerify that feature makes sense in context of distribution This method is called by the distribution just before it parses its command line. It checks to ensure that the 'remove' attribute, if any, contains only valid package/module names that are present in the base distribution when 'setup()' is called. You may override it in a subclass to perform any other required validation of the feature against a target distribution. sg%s wants to be able to remove %s, but the distribution doesn't contain any packages or modules under %sN(sselfsremovesitemsdistshas_contents_forsDistutilsSetupErrors description(sselfsdistsitem((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysvalidate s  ( s__name__s __module__s__doc__sFalsesTrues__init__sinclude_by_defaults include_ins exclude_fromsvalidate(((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pysFeature‘s 1   ((s__all__sdistutils.cores Distributions _Distributionssetuptools.dependssRequiressetuptools.command.installsinstallssetuptools.command.sdistssdistssetuptools.command.install_libs install_libsdistutils.errorssDistutilsOptionErrorsDistutilsPlatformErrorsDistutilsSetupErrors setuptoolss pkg_resourcess distutilssdistutils.dists distutils.cmdsoss_get_unpatchedstupleslistssequencescheck_importablesassert_string_lists check_nsps check_extrass assert_boolscheck_requirementsscheck_entry_pointsscheck_test_suitescheck_package_datasdistscorescmdsmodulesFeature(sDistutilsPlatformErrorscheck_importables distutilsssequencessdistsFeaturesmodulesassert_string_lists assert_bools__all__sDistutilsSetupErrorscheck_test_suites check_nspscheck_requirementssinstallsRequirescheck_package_datas DistributionsDistutilsOptionErrors_get_unpatcheds check_extrass _Distributions pkg_resourcess setuptoolss install_libscheck_entry_pointssos((sO/mnt/gmirror/ports/devel/py-setuptools/work/setuptools-0.6c7/setuptools/dist.pys?s8       -       ÿÿ