show a warning if a required binary isn't found, should 'fix' #2

This commit is contained in:
PoroCYon 2019-08-27 01:59:28 +02:00 committed by PoroCYon
parent 48fa48e797
commit e0bde71bd2
1 changed files with 7 additions and 0 deletions

View File

@ -46,6 +46,13 @@ def main():
args = parser.parse_args()
for x in ['nasm','cc','scanelf','readelf']:
val = args.__dict__[x]
if val is None or not os.path.isfile(val):
eprintf("'" + x + "' binary" + (" " if val is None
else " ('" + val + "')") + " not found")
sys.exit(1)
if args.libdir is None: args.libdir = []
arch = args.target.tolower() if len(args.target)!=0 \
else decide_arch(args.input)