1#! $FreeBSD$ 2 3.include <src.lua.mk> 4 5LUASRC?= ${SRCTOP}/contrib/lua/src 6.PATH: ${LUASRC} 7 8PROG= flua 9WARNS?= 2 10MAN= # No manpage; this is internal. 11 12CWARNFLAGS.gcc+= -Wno-format-nonliteral 13 14LIBADD= lua 15 16# Entry point 17SRCS+= lua.c 18 19# FreeBSD Extensions 20.PATH: ${.CURDIR}/modules 21SRCS+= linit_flua.c 22SRCS+= lfs.c lposix.c 23 24CFLAGS+= -I${SRCTOP}/lib/liblua -I${.CURDIR}/modules -I${LUASRC} 25CFLAGS+= -DLUA_PROGNAME="\"${PROG}\"" 26 27# readline bits; these aren't needed if we're building a bootstrap flua, as we 28# don't expect that one to see any REPL usage. 29.if !defined(BOOTSTRAPPING) 30CFLAGS+= -DLUA_USE_READLINE 31CFLAGS+= -I${SRCTOP}/lib/libedit -I${SRCTOP}/contrib/libedit 32LIBADD+= edit 33.endif 34 35.include <bsd.prog.mk> 36