Changeset View
Standalone View
share/mk/plain.test.mk
| Show All 37 Lines | |||||
| .for _T in ${PLAIN_TESTS_CXX} | .for _T in ${PLAIN_TESTS_CXX} | ||||
| BINDIR.${_T}= ${TESTSDIR} | BINDIR.${_T}= ${TESTSDIR} | ||||
| MAN.${_T}?= # empty | MAN.${_T}?= # empty | ||||
| SRCS.${_T}?= ${_T}.cc | SRCS.${_T}?= ${_T}.cc | ||||
| TEST_INTERFACE.${_T}= plain | TEST_INTERFACE.${_T}= plain | ||||
| .endfor | .endfor | ||||
| .endif | .endif | ||||
| .if !empty(PLAIN_TESTS_PORCH) | |||||
| SCRIPTS+= ${PLAIN_TESTS_PORCH:S/$/.orch/} | |||||
| _TESTS+= ${PLAIN_TESTS_PORCH} | |||||
| .for _T in ${PLAIN_TESTS_PORCH} | |||||
| SCRIPTSDIR_${_T}.orch= ${TESTSDIR} | |||||
| TEST_INTERFACE.${_T}= plain | |||||
| TEST_METADATA.${_T}+= required_programs="porch" | |||||
| .endfor | |||||
ngie: Is this needed? It seems like just adding `PLAIN_TESTS_PORCH` to `SCRIPTS` should be enough. | |||||
Done Inline ActionsI was mainly looking to chop off the suffix for consistency with other binary test programs, but I don't think I actually feel that strongly about it if we'd prefer to just add PLAIN_TESTS_ORCH:S/$/.orch/ and call it a day -- I don't see anything that would break from retainin the suffix. kevans: I was mainly looking to chop off the suffix for consistency with other binary test programs… | |||||
Not Done Inline Actions
bsd.prog.mk chops off the suffix for you: % cat Makefile SCRIPTS+= foo.orch .include <bsd.prog.mk> % make -n install install -o root -g wheel -m 555 /usr/home/ngie/foo.orch /foo You have to use a pattern like SCRIPTSNAME_foo.orch=foo.orch to retain the extension ;). That's why I asked if this was needed (it seems like unnecessary logic). ngie: > I was mainly looking to chop off the suffix for consistency with other binary test programs… | |||||
| .endif | |||||
| .if !empty(PLAIN_TESTS_SH) | .if !empty(PLAIN_TESTS_SH) | ||||
Done Inline ActionsCould we do it in one step with install(1)? 0mp: Could we do it in one step with install(1)? | |||||
| SCRIPTS+= ${PLAIN_TESTS_SH} | SCRIPTS+= ${PLAIN_TESTS_SH} | ||||
| _TESTS+= ${PLAIN_TESTS_SH} | _TESTS+= ${PLAIN_TESTS_SH} | ||||
| .for _T in ${PLAIN_TESTS_SH} | .for _T in ${PLAIN_TESTS_SH} | ||||
| SCRIPTSDIR_${_T}= ${TESTSDIR} | SCRIPTSDIR_${_T}= ${TESTSDIR} | ||||
| TEST_INTERFACE.${_T}= plain | TEST_INTERFACE.${_T}= plain | ||||
| CLEANFILES+= ${_T} ${_T}.tmp | CLEANFILES+= ${_T} ${_T}.tmp | ||||
| # TODO(jmmv): It seems to me that this SED and SRC functionality should | # TODO(jmmv): It seems to me that this SED and SRC functionality should | ||||
| # exist in bsd.prog.mk along the support for SCRIPTS. Move it there if | # exist in bsd.prog.mk along the support for SCRIPTS. Move it there if | ||||
| Show All 14 Lines | |||||
Is this needed? It seems like just adding PLAIN_TESTS_PORCH to SCRIPTS should be enough.