Commit f4be189a authored by Łukasz Nowak's avatar Łukasz Nowak

Replace zc.buildout requirements with slapos.buildout.

Thanks to simulating real zc.buildout it will be possible to use
slapos.buildout as easy replacement.
parent f0d0ef63
...@@ -205,7 +205,7 @@ env = dict( ...@@ -205,7 +205,7 @@ env = dict(
os.environ, os.environ,
PYTHONPATH=setup_requirement_path) PYTHONPATH=setup_requirement_path)
requirement = 'zc.buildout' requirement = 'slapos.buildout'
version = options.version version = options.version
if version is None and not options.accept_buildout_test_releases: if version is None and not options.accept_buildout_test_releases:
# Figure out the most recent final version of zc.buildout. # Figure out the most recent final version of zc.buildout.
......
...@@ -68,7 +68,7 @@ debug = %(name)s.testrecipes:Debug ...@@ -68,7 +68,7 @@ debug = %(name)s.testrecipes:Debug
""" % dict(name=name) """ % dict(name=name)
setup( setup(
name = name, name = 'slapos.buildout',
version = version, version = version,
author = "Jim Fulton", author = "Jim Fulton",
author_email = "jim@zope.com", author_email = "jim@zope.com",
......
...@@ -344,7 +344,7 @@ class Buildout(UserDict.DictMixin): ...@@ -344,7 +344,7 @@ class Buildout(UserDict.DictMixin):
# Get a base working set for our distributions that corresponds to the # Get a base working set for our distributions that corresponds to the
# stated desires in the configuration. # stated desires in the configuration.
distributions = ['setuptools', 'zc.buildout'] distributions = ['setuptools', 'slapos.buildout']
if options.get('offline') == 'true': if options.get('offline') == 'true':
ws = zc.buildout.easy_install.working_set( ws = zc.buildout.easy_install.working_set(
distributions, options['executable'], distributions, options['executable'],
...@@ -366,7 +366,7 @@ class Buildout(UserDict.DictMixin): ...@@ -366,7 +366,7 @@ class Buildout(UserDict.DictMixin):
# Now copy buildout and setuptools eggs, and record destination eggs: # Now copy buildout and setuptools eggs, and record destination eggs:
entries = [] entries = []
for name in 'setuptools', 'zc.buildout': for name in 'setuptools', 'slapos.buildout':
r = pkg_resources.Requirement.parse(name) r = pkg_resources.Requirement.parse(name)
dist = ws.find(r) dist = ws.find(r)
if dist.precedence == pkg_resources.DEVELOP_DIST: if dist.precedence == pkg_resources.DEVELOP_DIST:
...@@ -388,7 +388,7 @@ class Buildout(UserDict.DictMixin): ...@@ -388,7 +388,7 @@ class Buildout(UserDict.DictMixin):
# Ideally the (possibly) new version of buildout would get a # Ideally the (possibly) new version of buildout would get a
# chance to write the script. Not sure how to do that. # chance to write the script. Not sure how to do that.
ws = pkg_resources.WorkingSet(entries) ws = pkg_resources.WorkingSet(entries)
ws.require('zc.buildout') ws.require('slapos.buildout')
partsdir = os.path.join(options['parts-directory'], 'buildout') partsdir = os.path.join(options['parts-directory'], 'buildout')
if not os.path.exists(partsdir): if not os.path.exists(partsdir):
os.mkdir(partsdir) os.mkdir(partsdir)
...@@ -409,7 +409,7 @@ class Buildout(UserDict.DictMixin): ...@@ -409,7 +409,7 @@ class Buildout(UserDict.DictMixin):
script_initialization = '' script_initialization = ''
zc.buildout.easy_install.sitepackage_safe_scripts( zc.buildout.easy_install.sitepackage_safe_scripts(
options['bin-directory'], ws, options['executable'], partsdir, options['bin-directory'], ws, options['executable'], partsdir,
reqs=['zc.buildout'], relative_paths=relative_paths, reqs=['slapos.buildout'], relative_paths=relative_paths,
include_site_packages=self.include_site_packages, include_site_packages=self.include_site_packages,
script_initialization=script_initialization, script_initialization=script_initialization,
exec_sitecustomize=self.exec_sitecustomize, exec_sitecustomize=self.exec_sitecustomize,
......
...@@ -78,7 +78,7 @@ setuptools_loc = pkg_resources.working_set.find( ...@@ -78,7 +78,7 @@ setuptools_loc = pkg_resources.working_set.find(
# Include buildout and setuptools eggs in paths. We prevent dupes just to # Include buildout and setuptools eggs in paths. We prevent dupes just to
# keep from duplicating any log messages about them. # keep from duplicating any log messages about them.
buildout_loc = pkg_resources.working_set.find( buildout_loc = pkg_resources.working_set.find(
pkg_resources.Requirement.parse('zc.buildout')).location pkg_resources.Requirement.parse('slapos.buildout')).location
buildout_and_setuptools_path = [setuptools_loc] buildout_and_setuptools_path = [setuptools_loc]
if os.path.normpath(setuptools_loc) != os.path.normpath(buildout_loc): if os.path.normpath(setuptools_loc) != os.path.normpath(buildout_loc):
buildout_and_setuptools_path.append(buildout_loc) buildout_and_setuptools_path.append(buildout_loc)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment