CMakeLists.txt 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. # ***** BEGIN GPL LICENSE BLOCK *****
  2. #
  3. # This program is free software; you can redistribute it and/or
  4. # modify it under the terms of the GNU General Public License
  5. # as published by the Free Software Foundation; either version 2
  6. # of the License, or (at your option) any later version.
  7. #
  8. # This program is distributed in the hope that it will be useful,
  9. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. # GNU General Public License for more details.
  12. #
  13. # You should have received a copy of the GNU General Public License
  14. # along with this program; if not, write to the Free Software Foundation,
  15. # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  16. #
  17. # The Original Code is Copyright (C) 2016, Blender Foundation
  18. # All rights reserved.
  19. # ***** END GPL LICENSE BLOCK *****
  20. set(INC
  21. src
  22. ../gflags/src
  23. )
  24. set(INC_SYS
  25. )
  26. set(SRC
  27. src/logging.cc
  28. src/raw_logging.cc
  29. src/utilities.cc
  30. src/vlog_is_on.cc
  31. src/utilities.h
  32. src/config.h
  33. src/config_freebsd.h
  34. src/config_haiku.h
  35. src/config_hurd.h
  36. src/config_linux.h
  37. src/config_mac.h
  38. src/base/commandlineflags.h
  39. src/base/googleinit.h
  40. src/base/mutex.h
  41. src/stacktrace.h
  42. src/stacktrace_generic-inl.h
  43. src/stacktrace_libunwind-inl.h
  44. src/stacktrace_powerpc-inl.h
  45. src/stacktrace_x86_64-inl.h
  46. src/stacktrace_x86-inl.h
  47. )
  48. set(LIB
  49. )
  50. if(NOT WITH_SYSTEM_GFLAGS)
  51. list(APPEND LIB
  52. extern_gflags
  53. )
  54. endif()
  55. if(WIN32)
  56. list(APPEND SRC
  57. src/windows/port.cc
  58. src/windows/glog/raw_logging.h
  59. src/windows/glog/vlog_is_on.h
  60. src/windows/glog/logging.h
  61. src/windows/glog/log_severity.h
  62. src/windows/port.h
  63. src/windows/config.h
  64. )
  65. list(APPEND INC
  66. src/windows
  67. )
  68. else()
  69. list(APPEND INC
  70. include
  71. )
  72. list(APPEND SRC
  73. src/demangle.cc
  74. src/signalhandler.cc
  75. src/symbolize.cc
  76. src/demangle.h
  77. src/symbolize.h
  78. include/glog/logging.h
  79. include/glog/log_severity.h
  80. include/glog/raw_logging.h
  81. include/glog/vlog_is_on.h
  82. )
  83. endif()
  84. add_definitions(${GFLAGS_DEFINES})
  85. add_definitions(${GLOG_DEFINES})
  86. blender_add_lib(extern_glog "${SRC}" "${INC}" "${INC_SYS}" "${LIB}")