aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcomex2015-08-07 17:03:51 -0400
committercomex2015-08-07 17:08:31 -0400
commita4f89a7327e5b5dc2a64e51840aa19c7ac89071d (patch)
treead8f4887c7b7047af85d40a98b598fd3ad134c61
parentfuture proofing (diff)
downloadsubstitute-a4f89a7327e5b5dc2a64e51840aa19c7ac89071d.tar.gz
fixes
-rwxr-xr-xscript/gen-deb.sh2
-rw-r--r--script/mconfig.py9
2 files changed, 7 insertions, 4 deletions
diff --git a/script/gen-deb.sh b/script/gen-deb.sh
index 999765c..23bfcf0 100755
--- a/script/gen-deb.sh
+++ b/script/gen-deb.sh
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
set -e
debroot=out/debroot
version="$(git describe --always --dirty)"
diff --git a/script/mconfig.py b/script/mconfig.py
index 1afcd0d..4afccad 100644
--- a/script/mconfig.py
+++ b/script/mconfig.py
@@ -591,8 +591,11 @@ class UnixToolchain(object):
def find_tool(self, tool, failure_notes):
# special cases
if tool.name == 'cpp':
- cc = self.machine.c_tools().cc()
- if cc is not None:
+ try:
+ cc = self.machine.c_tools().cc.argv()
+ except DependencyNotFoundException:
+ pass
+ else:
return cc + ['-E']
return self.find_tool_normal(tool, failure_notes)
@@ -612,7 +615,7 @@ def calc_darwin_target_conditionals(ctools, settings):
log('* Error: Darwin platform but no TargetConditionals.h?\n')
raise DependencyNotFoundException
# note: TARGET_CPU are no good because there could be multiple arches
- return {env: bool(val) for (env, val) in re.findall('^#define (TARGET_OS_[^ ]*)\s+(0|1)\s*$', so, re.M)}
+ return {env: bool(int(val)) for (env, val) in re.findall('^#define (TARGET_OS_[^ ]*)\s+(0|1)\s*$', so, re.M)}
# Reads a binary or XML plist (on OS X)
def read_plist(gunk):