You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
waf_old/demos/asm/wscript

28 lines
578 B
Python

#! /usr/bin/env python
# encoding: utf-8
import sys
def configure(conf):
conf.load('gcc gas')
try:
size = sys.maxint
except AttributeError:
size = sys.maxsize # python 3.2
if size < 4**21:
conf.fatal('this example is for 64-bit systems only')
def build(bld):
# https://waf.io/apidocs/tools/asm.html
bld.program(
source = 'main.c test.S',
target = 'asmtest',
defines = 'foo=12',
includes = '.')
def disp(ctx):
node = ctx.bldnode.ant_glob('asmtest*', remove=False)[0]
ctx.exec_command('%s' % node.abspath(), shell=False)
bld.add_post_fun(disp)