Old KDE building system – not used for TDE
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

64 lines
1.8 KiB

  1. #-*- mode: Fundamental; tab-width: 4; -*-
  2. # ex:ts=4
  3. # $Id$
  4. ###
  5. # This file contains non-invasive color patterns for output.
  6. ###
  7. # failsafe defaults.
  8. TMSG_BRIGHT =$1
  9. TMSG_ID =$1
  10. TMSG_ACTION =$1
  11. TMSG_SUCCESS =$1
  12. TMSG_FAIL =$1
  13. TMSG_LIB = ==> $1 $2 $3
  14. ##
  15. # If there is no $TERM variable, we don't want colors.
  16. ifneq ($(TERM),)
  17. # equivalently, we want TPUT, since it should be safe,
  18. # using valid terminfo(5), for almost any $(TERM) value.
  19. ###
  20. # if you don't have tput, we could rely on ANSI, but that
  21. # would defeat the purpose of using tput as a safe colorizer.
  22. ifneq ($(strip $(shell which tput)),)
  23. TERM_RST =$(shell tput sgr0)
  24. TERM_BOLD =$(shell tput bold)
  25. TERM_BLACK =$(shell tput setaf 0)
  26. TERM_RED =$(shell tput setaf 1)
  27. TERM_GREEN =$(shell tput setaf 2)
  28. TERM_YELLOW =$(shell tput setaf 3)
  29. TERM_BLUE =$(shell tput setaf 4)
  30. TERM_MAGENTA =$(shell tput setaf 5)
  31. TERM_CYAN =$(shell tput setaf 6)
  32. TERM_WHITE =$(shell tput setaf 7)
  33. # some functional color substitutions; these
  34. # were designed on a white background; YMMV.
  35. # If they are ugly, an if condition that checks
  36. # the background color(?) of the terminal could
  37. # select more appropriate colors.
  38. #
  39. # use these likeso:
  40. # $(call TMSG_BRIGHT,bright message)
  41. # these are all unary functions.
  42. TMSG_BRIGHT =$(TERM_YELLOW)$1$(TERM_RST)
  43. TMSG_ID =$(TERM_BLUE)$1$(TERM_RST)
  44. TMSG_ACTION =$(TERM_RED)$1$(TERM_RST)
  45. TMSG_SUCCESS =$(TERM_GREEN)$1$(TERM_RST)
  46. TMSG_FAIL =$(TERM_RED)$(TERM_BOLD)$1$(TERM_RST)
  47. # $(call TMSG_LIB,building|grabbing source|...,file|package,as a dependency|as build dep|...)
  48. # eg.
  49. # $(call TMSG_LIB,building,$*,as a dependency)
  50. # or, alternatively, just 2 arguments
  51. # $(call TMSG_LIB,extracting,some_file)
  52. TMSG_LIB =$(call TMSG_BRIGHT,==>) $1 $(call TMSG_ID,$2) $3
  53. endif # tput?
  54. endif # TERM?