import catalyst.config
import catalyst.util
from catalyst.support import CatalystError, find_binary, LockInUse
-from catalyst.defaults import required_build_targets, valid_build_targets
+from catalyst.defaults import (required_build_targets, valid_build_targets,
+ confdefaults)
from hash_utils import HashMap, HASH_DEFINITIONS
from contents import ContentsMap, CONTENTS_DEFINITIONS
myconf={}
config_file=""
- confdefaults = {
- "distdir": "/usr/portage/distfiles",
- "hash_function": "crc32",
- "icecream": "/var/cache/icecream",
- "local_overlay": "/usr/local/portage",
- "options": "",
- "packagedir": "/usr/portage/packages",
- "portdir": "/usr/portage",
- "repo_name": "portage",
- "sharedir": "/usr/share/catalyst",
- "snapshot_name": "portage-",
- "snapshot_cache": "/var/tmp/catalyst/snapshot_cache",
- "storedir": "/var/tmp/catalyst",
- }
-
# first, try the one passed (presumably from the cmdline)
if myconfig:
if os.path.exists(myconfig):
sys.exit(1)
# now, load up the values into conf_values so that we can use them
- for x in confdefaults.keys():
+ for x in list(confdefaults):
if x in myconf:
print "Setting",x,"to config file value \""+myconf[x]+"\""
conf_values[x]=myconf[x]