# Generated by vmodtool.py --boilerplate.

vmod_unix_vcc ?= $(srcdir)/vmod_unix.vcc

vmod_vcc_files += $(vmod_unix_vcc)

vmod_LTLIBRARIES += libvmod_unix.la

libvmod_unix_la_SOURCES = \
	vmod_unix.c \
	vmod_unix_cred_compat.h

libvmod_unix_la_CFLAGS =

vmodtoolargs_unix ?= --strict --boilerplate -o vcc_unix_if
vmod_unix_symbols_regex ?= Vmod_unix_Data

libvmod_unix_la_LDFLAGS = \
	-export-symbols-regex $(vmod_unix_symbols_regex) \
	$(AM_LDFLAGS) \
	$(VMOD_LDFLAGS)

nodist_libvmod_unix_la_SOURCES = vcc_unix_if.c vcc_unix_if.h

EXTRA_libvmod_unix_la_DEPENDENCIES = $(nodist_libvmod_unix_la_SOURCES)

EXTRA_DIST += automake_boilerplate_unix.am

$(libvmod_unix_la_OBJECTS): vcc_unix_if.h

vcc_unix_if.h vmod_unix.rst vmod_unix.man.rst: vcc_unix_if.c

# A doc-change will not update mtime on the .h and .c files, so a
# touch(1) is necessary to signal that vmodtool was in fact run.
vcc_unix_if.c: $(VMODTOOL) $(srcdir)/vmod_unix.vcc
	@PYTHON@ $(VMODTOOL) $(vmodtoolargs_unix) $(srcdir)/vmod_unix.vcc
	touch vcc_unix_if.c

clean-local: clean-vmod-unix

clean-vmod-unix:
	rm -f $(nodist_libvmod_unix_la_SOURCES)
	rm -f vmod_unix.rst vmod_unix.man.rst
