waf/demos/asm/wscript

27 lines
578 B
Plaintext
Raw Normal View History

2011-09-10 11:13:51 +02:00
#! /usr/bin/env python
# encoding: utf-8
2012-05-06 00:08:50 +02:00
import sys
2011-09-10 11:13:51 +02:00
def configure(conf):
conf.load('gcc gas')
2012-05-13 16:13:44 +02:00
try:
size = sys.maxint
except AttributeError:
size = sys.maxsize # python 3.2
if size < 4**21:
2012-05-06 00:08:50 +02:00
conf.fatal('this example is for 64-bit systems only')
2011-09-10 11:13:51 +02:00
def build(bld):
# http://docs.waf.googlecode.com/git/apidocs_16/tools/asm.html
2011-09-10 11:13:51 +02:00
bld.program(
2012-05-02 09:23:58 +02:00
source = 'main.c test.S',
target = 'asmtest',
includes = '.')
2011-09-10 11:13:51 +02:00
2012-05-06 00:08:50 +02:00
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)