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.
 
 
 
 
 
 

42 rivejä
1.2 KiB

  1. cmake_minimum_required (VERSION 2.8.8)
  2. project (BoringSSL)
  3. if(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
  4. set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Werror -ggdb -std=c89")
  5. set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror -ggdb -std=c++0x")
  6. elseif(MSVC)
  7. # Disable warnings for implicit integer narrowing.
  8. set(CMAKE_C_FLAGS "/wd4267")
  9. endif()
  10. add_definitions(-DBORINGSSL_IMPLEMENTATION)
  11. if (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "x86_64")
  12. set(ARCH "x86_64")
  13. elseif (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "amd64")
  14. set(ARCH "x86_64")
  15. elseif (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "AMD64")
  16. # cmake reports AMD64 on Windows, but we might be building for 32-bit.
  17. if (CMAKE_CL_64)
  18. set(ARCH "x86_64")
  19. else()
  20. set(ARCH "x86")
  21. endif()
  22. elseif (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "x86")
  23. set(ARCH "x86")
  24. elseif (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "i386")
  25. set(ARCH "x86")
  26. elseif (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "i686")
  27. set(ARCH "x86")
  28. elseif (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm")
  29. set(ARCH "arm")
  30. else()
  31. message(FATAL_ERROR "Unknown processor:" ${CMAKE_SYSTEM_PROCESSOR})
  32. endif()
  33. add_subdirectory(crypto)
  34. add_subdirectory(ssl)
  35. add_subdirectory(ssl/test)
  36. add_subdirectory(tool)