1
0
Fork 0

Quoting all path arguments in Makefile

- Protect those crazy users from themselves
closure/master
Mike Gerwitz 2011-03-09 19:12:16 -05:00
parent 08a58dba82
commit cfa60655cd
1 changed files with 14 additions and 14 deletions

View File

@ -26,14 +26,14 @@ all: combine doc
# create build dir # create build dir
mkbuild: mkbuild:
@mkdir -p ${PATH_BUILD} @mkdir -p "${PATH_BUILD}"
# combine all modules into easily redistributable ease.js file (intended for # combine all modules into easily redistributable ease.js file (intended for
# browser) # browser)
combine: mkbuild combine: mkbuild
${COMBINE} > ${PATH_COMBINE_OUTPUT} ${COMBINE} > "${PATH_COMBINE_OUTPUT}"
INC_TEST=1 ${COMBINE} > ${PATH_COMBINE_OUTPUT_FULL} INC_TEST=1 "${COMBINE}" > "${PATH_COMBINE_OUTPUT_FULL}"
@cp ${PATH_BROWSER_TEST} ${PATH_BUILD} @cp "${PATH_BROWSER_TEST}" "${PATH_BUILD}"
# run tests # run tests
test: default test: default
@ -49,25 +49,25 @@ test: default
# #
# generates: pdf, HTML (multiple pages), HTML (single page) # generates: pdf, HTML (multiple pages), HTML (single page)
doc: doc:
@mkdir -p ${PATH_DOC_OUTPUT} @mkdir -p "${PATH_DOC_OUTPUT}"
pdftex -output-directory "${PATH_DOC}" ${PATH_MANUAL_TEXI} pdftex -output-directory "${PATH_DOC}" "${PATH_MANUAL_TEXI}"
pdftex -output-directory "${PATH_DOC}" ${PATH_MANUAL_TEXI} pdftex -output-directory "${PATH_DOC}" "${PATH_MANUAL_TEXI}"
find ${PATH_DOC} -type f \ find "${PATH_DOC}" -type f \
! -name '*.texi' -a \ ! -name '*.texi' -a \
! -name '.*' -a \ ! -name '.*' -a \
! -name '*.pdf' -a \ ! -name '*.pdf' -a \
! -name '*.css' \ ! -name '*.css' \
| xargs rm | xargs rm
@mv -f ${PATH_DOC}/*.pdf ${PATH_DOC_OUTPUT} @mv -f "${PATH_DOC}"/*.pdf "${PATH_DOC_OUTPUT}"
cd ${PATH_DOC}; \ cd "${PATH_DOC}"; \
makeinfo -o ${PATH_DOC_OUTPUT_INFO} ${PATH_MANUAL_TEXI}; \ makeinfo -o "${PATH_DOC_OUTPUT_INFO}" "${PATH_MANUAL_TEXI}"; \
makeinfo --plain ${PATH_MANUAL_TEXI} > ${PATH_DOC_OUTPUT_PLAIN}; \ makeinfo --plain "${PATH_MANUAL_TEXI}" > "${PATH_DOC_OUTPUT_PLAIN}"; \
makeinfo --html --css-include="${PATH_DOC_CSS}" \ makeinfo --html --css-include="${PATH_DOC_CSS}" \
-o "${PATH_DOC_OUTPUT_HTML}" "${PATH_MANUAL_TEXI}"; \ -o "${PATH_DOC_OUTPUT_HTML}" "${PATH_MANUAL_TEXI}"; \
makeinfo --no-split --html --css-include="${PATH_DOC_CSS}" \ makeinfo --no-split --html --css-include="${PATH_DOC_CSS}" \
-o ${PATH_DOC_OUTPUT_HTML1} ${PATH_MANUAL_TEXI}; -o "${PATH_DOC_OUTPUT_HTML1}" "${PATH_MANUAL_TEXI}";
# clean up build dir # clean up build dir
clean: clean:
rm -rf ${PATH_BUILD} rm -rf "${PATH_BUILD}"