ts_tsc.conf 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. TS_TSC_CMD=$TOUCH_UNIT \
  2. && $_TS_FILES_COPY_CMD \
  3. && $NOTS_TOOL $NOTS_TOOL_BASE_ARGS build-tsc $NOTS_TOOL_COMMON_BUILDER_ARGS \
  4. $_NODE_MODULES_INOUTS ${hide:PEERS} \
  5. ${input;hide:"package.json"} ${TS_CONFIG_FILES} $_AS_HIDDEN_INPUTS(IN $TS_INPUT_FILES) \
  6. ${output;hide:"package.json"} \
  7. ${kv;hide:"pc magenta"} ${kv;hide:"p TS_TSC"}
  8. ### @usage: TS_TSC([name])
  9. ###
  10. ### The TypeScript/JavaScript library module, compiles TypeScript sources to JavaScript using tsc.
  11. ### Build results are JavaScript files, typings and source mappings (depending on local tsconfig.json settings).
  12. ###
  13. ### @example
  14. ###
  15. ### TS_TSC()
  16. ###
  17. ### END()
  18. ###
  19. multimodule TS_TSC {
  20. module BUILD: _TS_BASE_UNIT {
  21. .CMD=TS_TSC_CMD
  22. .EPILOGUE=_TS_CONFIG_EPILOGUE
  23. .PEERDIRSELF=TS_PREPARE_DEPS
  24. # by default multimodule overrides inherited MODULE_TAG to submodule name (BUILD in this case)
  25. # but we have to set it to TS for include processor to work
  26. SET(MODULE_TAG TS)
  27. SET(MODULE_LANG TS)
  28. _PEERDIR_TS_RESOURCE(typescript)
  29. DISABLE(TS_CONFIG_DEDUCE_OUT)
  30. ENABLE(TS_CONFIG_USE_OUTDIR)
  31. _TS_CONFIGURE()
  32. SET_APPEND(_MAKEFILE_INCLUDE_LIKE_DEPS ${CURDIR}/package.json ${CURDIR}/pnpm-lock.yaml ${CURDIR}/${TS_CONFIG_PATH})
  33. _TS_ADD_NODE_MODULES_FOR_BUILDER()
  34. }
  35. module TS_PREPARE_DEPS: _PREPARE_DEPS_BASE {
  36. }
  37. }