deps-linux.cmake 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. set(DEP_CMAKE_OPTS "-DCMAKE_POSITION_INDEPENDENT_CODE=ON")
  2. include("deps-unix-common.cmake")
  3. find_package(PNG QUIET)
  4. if (NOT PNG_FOUND)
  5. message(WARNING "No PNG dev package found in system, building static library. You should install the system package.")
  6. endif ()
  7. #TODO UDEV
  8. ExternalProject_Add(dep_boost
  9. EXCLUDE_FROM_ALL 1
  10. URL "https://dl.bintray.com/boostorg/release/1.70.0/source/boost_1_70_0.tar.gz"
  11. URL_HASH SHA256=882b48708d211a5f48e60b0124cf5863c1534cd544ecd0664bb534a4b5d506e9
  12. BUILD_IN_SOURCE 1
  13. CONFIGURE_COMMAND ./bootstrap.sh
  14. --with-libraries=system,iostreams,filesystem,thread,log,locale,regex
  15. "--prefix=${DESTDIR}/usr/local"
  16. BUILD_COMMAND ./b2
  17. -j ${NPROC}
  18. --reconfigure
  19. link=static
  20. variant=release
  21. threading=multi
  22. boost.locale.icu=off
  23. cflags=-fPIC
  24. cxxflags=-fPIC
  25. install
  26. INSTALL_COMMAND "" # b2 does that already
  27. )
  28. ExternalProject_Add(dep_libopenssl
  29. EXCLUDE_FROM_ALL 1
  30. URL "https://github.com/openssl/openssl/archive/OpenSSL_1_1_0l.tar.gz"
  31. URL_HASH SHA256=e2acf0cf58d9bff2b42f2dc0aee79340c8ffe2c5e45d3ca4533dd5d4f5775b1d
  32. BUILD_IN_SOURCE 1
  33. CONFIGURE_COMMAND ./config
  34. "--prefix=${DESTDIR}/usr/local"
  35. "--libdir=lib"
  36. no-shared
  37. no-ssl3-method
  38. no-dynamic-engine
  39. -Wa,--noexecstack
  40. BUILD_COMMAND make depend && make "-j${NPROC}"
  41. INSTALL_COMMAND make install_sw
  42. )
  43. ExternalProject_Add(dep_libcurl
  44. EXCLUDE_FROM_ALL 1
  45. DEPENDS dep_libopenssl
  46. URL "https://curl.haxx.se/download/curl-7.58.0.tar.gz"
  47. URL_HASH SHA256=cc245bf9a1a42a45df491501d97d5593392a03f7b4f07b952793518d97666115
  48. BUILD_IN_SOURCE 1
  49. CONFIGURE_COMMAND ./configure
  50. --enable-static
  51. --disable-shared
  52. "--with-ssl=${DESTDIR}/usr/local"
  53. --with-pic
  54. --enable-ipv6
  55. --enable-versioned-symbols
  56. --enable-threaded-resolver
  57. --with-random=/dev/urandom
  58. # CA root certificate paths will be set for openssl at runtime.
  59. --without-ca-bundle
  60. --without-ca-path
  61. --with-ca-fallback # to look for the ssl backend's ca store
  62. --disable-ldap
  63. --disable-ldaps
  64. --disable-manual
  65. --disable-rtsp
  66. --disable-dict
  67. --disable-telnet
  68. --disable-pop3
  69. --disable-imap
  70. --disable-smb
  71. --disable-smtp
  72. --disable-gopher
  73. --disable-crypto-auth
  74. --without-gssapi
  75. --without-libpsl
  76. --without-libidn2
  77. --without-gnutls
  78. --without-polarssl
  79. --without-mbedtls
  80. --without-cyassl
  81. --without-nss
  82. --without-axtls
  83. --without-brotli
  84. --without-libmetalink
  85. --without-libssh
  86. --without-libssh2
  87. --without-librtmp
  88. --without-nghttp2
  89. --without-zsh-functions-dir
  90. BUILD_COMMAND make "-j${NPROC}"
  91. INSTALL_COMMAND make install "DESTDIR=${DESTDIR}"
  92. )
  93. add_dependencies(dep_openvdb dep_boost)