summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-02-03 15:13:00 +0000
committerCarl Hetherington <cth@carlh.net>2016-02-03 15:13:00 +0000
commit501b015c76b12ff180b97d73fb1946bb041cd1d2 (patch)
treecb4cd225a4bb2dff59ff686c22f8dd1a8f79073a
parent1bfc5eb4180a5647c549411d9119fbcbdc6045aa (diff)
Fix previous commit.
-rwxr-xr-xcdist4
1 files changed, 2 insertions, 2 deletions
diff --git a/cdist b/cdist
index adb19c6..04b62ef 100755
--- a/cdist
+++ b/cdist
@@ -551,17 +551,17 @@ def target_factory(s, debug, work):
elif s == 'raspbian':
target = ChrootTarget(s, None, None, work)
elif s == 'host':
- l = f.readline().strip().split()
if command_and_read('uname -m').read().strip() == 'x86_64':
bits = 64
else:
bits = 32
try:
f = open('/etc/fedora-release', 'r')
+ l = f.readline().strip().split()
target = HostTarget("fedora", l[2], bits, work)
except Exception as e:
if os.path.exists('/etc/arch-release'):
- target = HostTarget("arch", None, l[2], bits, work)
+ target = HostTarget("arch", None, bits, work)
else:
raise Error("could not identify distribution for `host' target (%s)" % e)
elif s.startswith('osx-'):