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.

88 lines
3.9 KiB

  1. # Copyright 2005-2013 Intel Corporation. All Rights Reserved.
  2. #
  3. # This file is part of Threading Building Blocks.
  4. #
  5. # Threading Building Blocks is free software; you can redistribute it
  6. # and/or modify it under the terms of the GNU General Public License
  7. # version 2 as published by the Free Software Foundation.
  8. #
  9. # Threading Building Blocks is distributed in the hope that it will be
  10. # useful, but WITHOUT ANY WARRANTY; without even the implied warranty
  11. # of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. # GNU General Public License for more details.
  13. #
  14. # You should have received a copy of the GNU General Public License
  15. # along with Threading Building Blocks; if not, write to the Free Software
  16. # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  17. #
  18. # As a special exception, you may use this file as part of a free software
  19. # library without restriction. Specifically, if other files instantiate
  20. # templates or use macros or inline functions from this file, or you compile
  21. # this file and link it with other files to produce an executable, this
  22. # file does not by itself cause the resulting executable to be covered by
  23. # the GNU General Public License. This exception does not however
  24. # invalidate any other reasons why the executable file might be covered by
  25. # the GNU General Public License.
  26. tbb_root?=.
  27. include $(tbb_root)/build/common.inc
  28. .PHONY: default all tbb tbbmalloc tbbproxy test examples
  29. #workaround for non-depend targets tbb and tbbmalloc which both depend on version_string.ver
  30. #According to documentation submakes should run in parallel
  31. .NOTPARALLEL: tbb tbbmalloc tbbproxy
  32. default: tbb tbbmalloc $(if $(use_proxy),tbbproxy)
  33. all: tbb tbbmalloc tbbproxy test examples
  34. tbb: mkdir
  35. $(MAKE) -C "$(work_dir)_debug" -r -f $(tbb_root)/build/Makefile.tbb cfg=debug tbb_root=$(tbb_root)
  36. $(MAKE) -C "$(work_dir)_release" -r -f $(tbb_root)/build/Makefile.tbb cfg=release tbb_root=$(tbb_root)
  37. tbbmalloc: mkdir
  38. $(MAKE) -C "$(work_dir)_debug" -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=debug malloc tbb_root=$(tbb_root)
  39. $(MAKE) -C "$(work_dir)_release" -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=release malloc tbb_root=$(tbb_root)
  40. tbbproxy: mkdir
  41. $(MAKE) -C "$(work_dir)_debug" -r -f $(tbb_root)/build/Makefile.tbbproxy cfg=debug tbbproxy tbb_root=$(tbb_root)
  42. $(MAKE) -C "$(work_dir)_release" -r -f $(tbb_root)/build/Makefile.tbbproxy cfg=release tbbproxy tbb_root=$(tbb_root)
  43. test: tbb tbbmalloc $(if $(use_proxy),tbbproxy)
  44. -$(MAKE) -C "$(work_dir)_debug" -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=debug malloc_test tbb_root=$(tbb_root)
  45. -$(MAKE) -C "$(work_dir)_debug" -r -f $(tbb_root)/build/Makefile.test cfg=debug tbb_root=$(tbb_root)
  46. -$(MAKE) -C "$(work_dir)_release" -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=release malloc_test tbb_root=$(tbb_root)
  47. -$(MAKE) -C "$(work_dir)_release" -r -f $(tbb_root)/build/Makefile.test cfg=release tbb_root=$(tbb_root)
  48. rml: mkdir
  49. $(MAKE) -C "$(work_dir)_debug" -r -f $(tbb_root)/build/Makefile.rml cfg=debug tbb_root=$(tbb_root)
  50. $(MAKE) -C "$(work_dir)_release" -r -f $(tbb_root)/build/Makefile.rml cfg=release tbb_root=$(tbb_root)
  51. examples: tbb tbbmalloc
  52. $(MAKE) -C examples -r -f Makefile tbb_root=.. release test
  53. .PHONY: clean clean_examples mkdir info
  54. clean: clean_examples
  55. $(shell $(RM) $(work_dir)_release$(SLASH)*.* >$(NUL) 2>$(NUL))
  56. $(shell $(RD) $(work_dir)_release >$(NUL) 2>$(NUL))
  57. $(shell $(RM) $(work_dir)_debug$(SLASH)*.* >$(NUL) 2>$(NUL))
  58. $(shell $(RD) $(work_dir)_debug >$(NUL) 2>$(NUL))
  59. @echo clean done
  60. clean_examples:
  61. $(shell $(MAKE) -s -i -r -C examples -f Makefile tbb_root=.. clean >$(NUL) 2>$(NUL))
  62. mkdir:
  63. $(shell $(MD) "$(work_dir)_release" >$(NUL) 2>$(NUL))
  64. $(shell $(MD) "$(work_dir)_debug" >$(NUL) 2>$(NUL))
  65. @echo Created $(work_dir)_release and ..._debug directories
  66. info:
  67. @echo OS: $(tbb_os)
  68. @echo arch=$(arch)
  69. @echo compiler=$(compiler)
  70. @echo runtime=$(runtime)
  71. @echo tbb_build_prefix=$(tbb_build_prefix)