deps-linux.cmake 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. set(DEP_CMAKE_OPTS "-DCMAKE_POSITION_INDEPENDENT_CODE=ON")
  2. include("deps-unix-common.cmake")
  3. ExternalProject_Add(dep_boost
  4. EXCLUDE_FROM_ALL 1
  5. URL "https://dl.bintray.com/boostorg/release/1.70.0/source/boost_1_70_0.tar.gz"
  6. URL_HASH SHA256=882b48708d211a5f48e60b0124cf5863c1534cd544ecd0664bb534a4b5d506e9
  7. BUILD_IN_SOURCE 1
  8. CONFIGURE_COMMAND ./bootstrap.sh
  9. --with-libraries=system,iostreams,filesystem,thread,log,locale,regex
  10. "--prefix=${DESTDIR}/usr/local"
  11. BUILD_COMMAND ./b2
  12. -j ${NPROC}
  13. --reconfigure
  14. link=static
  15. variant=release
  16. threading=multi
  17. boost.locale.icu=off
  18. cflags=-fPIC
  19. cxxflags=-fPIC
  20. install
  21. INSTALL_COMMAND "" # b2 does that already
  22. )
  23. ExternalProject_Add(dep_libopenssl
  24. EXCLUDE_FROM_ALL 1
  25. URL "https://github.com/openssl/openssl/archive/OpenSSL_1_1_0l.tar.gz"
  26. URL_HASH SHA256=e2acf0cf58d9bff2b42f2dc0aee79340c8ffe2c5e45d3ca4533dd5d4f5775b1d
  27. BUILD_IN_SOURCE 1
  28. CONFIGURE_COMMAND ./config
  29. "--prefix=${DESTDIR}/usr/local"
  30. no-shared
  31. no-ssl3-method
  32. no-dynamic-engine
  33. -Wa,--noexecstack
  34. BUILD_COMMAND make depend && make "-j${NPROC}"
  35. INSTALL_COMMAND make install_sw
  36. )
  37. ExternalProject_Add(dep_libcurl
  38. EXCLUDE_FROM_ALL 1
  39. DEPENDS dep_libopenssl
  40. URL "https://curl.haxx.se/download/curl-7.58.0.tar.gz"
  41. URL_HASH SHA256=cc245bf9a1a42a45df491501d97d5593392a03f7b4f07b952793518d97666115
  42. BUILD_IN_SOURCE 1
  43. CONFIGURE_COMMAND ./configure
  44. --enable-static
  45. --disable-shared
  46. "--with-ssl=${DESTDIR}/usr/local"
  47. --with-pic
  48. --enable-ipv6
  49. --enable-versioned-symbols
  50. --enable-threaded-resolver
  51. --with-random=/dev/urandom
  52. --with-ca-bundle=/etc/ssl/certs/ca-certificates.crt
  53. --disable-ldap
  54. --disable-ldaps
  55. --disable-manual
  56. --disable-rtsp
  57. --disable-dict
  58. --disable-telnet
  59. --disable-pop3
  60. --disable-imap
  61. --disable-smb
  62. --disable-smtp
  63. --disable-gopher
  64. --disable-crypto-auth
  65. --without-gssapi
  66. --without-libpsl
  67. --without-libidn2
  68. --without-gnutls
  69. --without-polarssl
  70. --without-mbedtls
  71. --without-cyassl
  72. --without-nss
  73. --without-axtls
  74. --without-brotli
  75. --without-libmetalink
  76. --without-libssh
  77. --without-libssh2
  78. --without-librtmp
  79. --without-nghttp2
  80. --without-zsh-functions-dir
  81. BUILD_COMMAND make "-j${NPROC}"
  82. INSTALL_COMMAND make install "DESTDIR=${DESTDIR}"
  83. )
  84. if (DEP_WX_STABLE)
  85. set(DEP_WX_TAG "v3.0.4")
  86. else ()
  87. set(DEP_WX_TAG "v3.1.1-patched")
  88. endif()
  89. ExternalProject_Add(dep_wxwidgets
  90. EXCLUDE_FROM_ALL 1
  91. GIT_REPOSITORY "https://github.com/prusa3d/wxWidgets"
  92. GIT_TAG "${DEP_WX_TAG}"
  93. BUILD_IN_SOURCE 1
  94. # PATCH_COMMAND "${CMAKE_COMMAND}" -E copy "${CMAKE_CURRENT_SOURCE_DIR}/wxwidgets-pngprefix.h" src/png/pngprefix.h
  95. CONFIGURE_COMMAND ./configure
  96. "--prefix=${DESTDIR}/usr/local"
  97. --disable-shared
  98. --with-gtk=2
  99. --with-opengl
  100. --enable-unicode
  101. --enable-graphics_ctx
  102. --with-regex=builtin
  103. --with-libpng=builtin
  104. --with-libxpm=builtin
  105. --with-libjpeg=builtin
  106. --with-libtiff=builtin
  107. --with-zlib
  108. --with-expat=builtin
  109. --disable-precomp-headers
  110. --enable-debug_info
  111. --enable-debug_gdb
  112. --disable-debug
  113. --disable-debug_flag
  114. BUILD_COMMAND make "-j${NPROC}" && make -C locale allmo
  115. INSTALL_COMMAND make install
  116. )
  117. add_dependencies(dep_openvdb dep_boost)