aboutsummaryrefslogtreecommitdiff
path: root/scripts/boost/post-source-stubs
diff options
context:
space:
mode:
authorRobert Schumacher <roschuma@microsoft.com>2019-11-22 09:47:40 -0800
committerGitHub <noreply@github.com>2019-11-22 09:47:40 -0800
commit45f4b820e5743b89bca3508ba2028cdd5d8bbd17 (patch)
treef874a8c4a7392309bdbb86447288597ec0a4a281 /scripts/boost/post-source-stubs
parent62d67d3bf8eeff1afa8009041fd08b8822676b7b (diff)
parent8831e8f25f1ff6546ee4a5291b91d599421637b3 (diff)
downloadvcpkg-45f4b820e5743b89bca3508ba2028cdd5d8bbd17.tar.gz
vcpkg-45f4b820e5743b89bca3508ba2028cdd5d8bbd17.zip
Merge branch 'master' into vcpkg_nuget
Diffstat (limited to 'scripts/boost/post-source-stubs')
-rw-r--r--scripts/boost/post-source-stubs/context.cmake5
-rw-r--r--scripts/boost/post-source-stubs/fiber.cmake5
-rw-r--r--scripts/boost/post-source-stubs/iostreams.cmake18
-rw-r--r--scripts/boost/post-source-stubs/log.cmake13
-rw-r--r--scripts/boost/post-source-stubs/python.cmake5
-rw-r--r--scripts/boost/post-source-stubs/test.cmake5
6 files changed, 51 insertions, 0 deletions
diff --git a/scripts/boost/post-source-stubs/context.cmake b/scripts/boost/post-source-stubs/context.cmake
new file mode 100644
index 000000000..9ccf34233
--- /dev/null
+++ b/scripts/boost/post-source-stubs/context.cmake
@@ -0,0 +1,5 @@
+file(READ "${SOURCE_PATH}/build/Jamfile.v2" _contents)
+string(REPLACE "import ../../config/checks/config" "import config/checks/config" _contents "${_contents}")
+file(WRITE "${SOURCE_PATH}/build/Jamfile.v2" "${_contents}")
+file(COPY "${CURRENT_INSTALLED_DIR}/share/boost-config/checks" DESTINATION "${SOURCE_PATH}/build/config")
+
diff --git a/scripts/boost/post-source-stubs/fiber.cmake b/scripts/boost/post-source-stubs/fiber.cmake
new file mode 100644
index 000000000..9ccf34233
--- /dev/null
+++ b/scripts/boost/post-source-stubs/fiber.cmake
@@ -0,0 +1,5 @@
+file(READ "${SOURCE_PATH}/build/Jamfile.v2" _contents)
+string(REPLACE "import ../../config/checks/config" "import config/checks/config" _contents "${_contents}")
+file(WRITE "${SOURCE_PATH}/build/Jamfile.v2" "${_contents}")
+file(COPY "${CURRENT_INSTALLED_DIR}/share/boost-config/checks" DESTINATION "${SOURCE_PATH}/build/config")
+
diff --git a/scripts/boost/post-source-stubs/iostreams.cmake b/scripts/boost/post-source-stubs/iostreams.cmake
new file mode 100644
index 000000000..55841bb3f
--- /dev/null
+++ b/scripts/boost/post-source-stubs/iostreams.cmake
@@ -0,0 +1,18 @@
+vcpkg_download_distfile(LICENSE
+ URLS "https://raw.githubusercontent.com/boostorg/boost/boost-1.70.0/LICENSE_1_0.txt"
+ FILENAME "boost_LICENSE_1_0.txt"
+ SHA512 d6078467835dba8932314c1c1e945569a64b065474d7aced27c9a7acc391d52e9f234138ed9f1aa9cd576f25f12f557e0b733c14891d42c16ecdc4a7bd4d60b8
+)
+
+file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
+
+vcpkg_configure_cmake(
+ SOURCE_PATH ${SOURCE_PATH}
+ PREFER_NINJA
+)
+
+vcpkg_install_cmake()
+vcpkg_copy_pdbs()
+
+file(COPY ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR})
+file(INSTALL ${LICENSE} DESTINATION ${CURRENT_PACKAGES_DIR}/share/boost-iostreams RENAME copyright)
diff --git a/scripts/boost/post-source-stubs/log.cmake b/scripts/boost/post-source-stubs/log.cmake
new file mode 100644
index 000000000..78500ddc3
--- /dev/null
+++ b/scripts/boost/post-source-stubs/log.cmake
@@ -0,0 +1,13 @@
+file(READ "${SOURCE_PATH}/build/Jamfile.v2" _contents)
+string(REPLACE "import ../../config/checks/config" "import config/checks/config" _contents "${_contents}")
+string(REPLACE " <conditional>@select-arch-specific-sources" "#<conditional>@select-arch-specific-sources" _contents "${_contents}")
+file(WRITE "${SOURCE_PATH}/build/Jamfile.v2" "${_contents}")
+file(COPY "${CURRENT_INSTALLED_DIR}/share/boost-config/checks" DESTINATION "${SOURCE_PATH}/build/config")
+
+file(READ ${SOURCE_PATH}/build/log-architecture.jam _contents)
+string(REPLACE
+ "\nproject.load [ path.join [ path.make $(here:D) ] ../../config/checks/architecture ] ;"
+ "\nproject.load [ path.join [ path.make $(here:D) ] config/checks/architecture ] ;"
+ _contents "${_contents}")
+file(WRITE ${SOURCE_PATH}/build/log-architecture.jam "${_contents}")
+
diff --git a/scripts/boost/post-source-stubs/python.cmake b/scripts/boost/post-source-stubs/python.cmake
new file mode 100644
index 000000000..40b8e0a0b
--- /dev/null
+++ b/scripts/boost/post-source-stubs/python.cmake
@@ -0,0 +1,5 @@
+# Find Python. Can't use find_package here, but we already know where everything is
+file(GLOB PYTHON_INCLUDE_PATH "${CURRENT_INSTALLED_DIR}/include/python[0-9.]*")
+set(PYTHONLIBS_RELEASE "${CURRENT_INSTALLED_DIR}/lib")
+set(PYTHONLIBS_DEBUG "${CURRENT_INSTALLED_DIR}/debug/lib")
+string(REGEX REPLACE ".*python([0-9\.]+)$" "\\1" PYTHON_VERSION "${PYTHON_INCLUDE_PATH}")
diff --git a/scripts/boost/post-source-stubs/test.cmake b/scripts/boost/post-source-stubs/test.cmake
new file mode 100644
index 000000000..b2872338d
--- /dev/null
+++ b/scripts/boost/post-source-stubs/test.cmake
@@ -0,0 +1,5 @@
+file(READ "${SOURCE_PATH}/build/Jamfile.v2" _contents)
+string(REPLACE "import ../../predef/check/predef" "import predef/check/predef" _contents "${_contents}")
+file(WRITE "${SOURCE_PATH}/build/Jamfile.v2" "${_contents}")
+file(COPY "${CURRENT_INSTALLED_DIR}/share/boost-predef/check" DESTINATION "${SOURCE_PATH}/build/predef")
+