1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-13 13:18:06 +03:00
samba-mirror/buildtools/wafsamba/samba_errtable.py
Stefan Metzmacher 988bc0cdc2 build: make use on_results=True for some build rules
This makes sure we generate a checksum over the result.
In practice it means we no longer recompile when a proto header
is triggers a rebuild if it hasn't changed its md5sum.

metze
2010-04-06 20:27:05 +10:00

28 lines
901 B
Python

# waf build tool for building .et files with compile_et
import Build, os
from samba_utils import *
def SAMBA_ERRTABLE(bld, name, source):
'''Build a heimdal errtable from a .et file'''
bname = source[0:-3]; # strip off the .et suffix
if not SET_TARGET_TYPE(bld, name, 'ET'):
return
bld.SET_BUILD_GROUP('build_source')
out_files = []
out_files.append('%s.c' % bname)
out_files.append('%s.h' % bname)
t = bld(rule='${SRC[0].abspath(env)} . ${TGT[0].parent.abspath(env)} default/source4/heimdal_build/compile_et ${SRC[2].abspath(env)} ${TGT[0].bldpath(env)}',
ext_out = '.c',
before = 'cc',
on_results = True,
shell = True,
source = ['et_compile_wrapper.sh', 'compile_et', source],
target = out_files,
name = name)
Build.BuildContext.SAMBA_ERRTABLE = SAMBA_ERRTABLE