diff options
| author | Christopher Warrington <chwarr@microsoft.com> | 2017-02-08 19:35:08 -0800 |
|---|---|---|
| committer | Christopher Warrington <chwarr@microsoft.com> | 2017-02-08 19:38:10 -0800 |
| commit | cd44f885732a35f1ae9c35d1248a335c0c6ac917 (patch) | |
| tree | a56b9b69060549730c98f67b72699c997fcaf882 | |
| parent | bef39cd24f44314936d416d577a1650411d84e24 (diff) | |
| download | vcpkg-cd44f885732a35f1ae9c35d1248a335c0c6ac917.tar.gz vcpkg-cd44f885732a35f1ae9c35d1248a335c0c6ac917.zip | |
Install gbc.exe to tools/
This at least allows people to write their own codegen rules until Bond
includes its own.
| -rw-r--r-- | ports/bond/0003_rename_gbc_during_install.patch | 22 | ||||
| -rw-r--r-- | ports/bond/portfile.cmake | 6 |
2 files changed, 28 insertions, 0 deletions
diff --git a/ports/bond/0003_rename_gbc_during_install.patch b/ports/bond/0003_rename_gbc_during_install.patch new file mode 100644 index 000000000..edbce6c0a --- /dev/null +++ b/ports/bond/0003_rename_gbc_during_install.patch @@ -0,0 +1,22 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 0d743da4..72d62c5e 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -49,7 +49,14 @@ install (EXPORT bond + + # if BOND_GBC_PATH is set we must copy over that gbc to the install location + if (BOND_GBC_PATH) +- install (FILES +- ${BOND_GBC_PATH} +- DESTINATION bin) ++ if (WIN32) ++ set(INSTALLED_GBC_NAME gbc.exe) ++ else() ++ set(INSTALLED_GBC_NAME gbc) ++ endif() ++ ++ install ( ++ FILES ${BOND_GBC_PATH} ++ DESTINATION bin ++ RENAME ${INSTALLED_GBC_NAME}) + endif() diff --git a/ports/bond/portfile.cmake b/ports/bond/portfile.cmake index ca9ff156b..d806173f1 100644 --- a/ports/bond/portfile.cmake +++ b/ports/bond/portfile.cmake @@ -36,6 +36,9 @@ vcpkg_apply_patches( # Don't install rapidjson from the (empty) submodule. With vcpkg, we get # rapidjson from vcpkg ${CMAKE_CURRENT_LIST_DIR}/0002_omit_rapidjson.patch + # Temporary until this is committed upstream. See + # https://github.com/Microsoft/bond/pull/324 for details. + ${CMAKE_CURRENT_LIST_DIR}/0003_rename_gbc_during_install.patch ) vcpkg_configure_cmake( @@ -51,6 +54,9 @@ vcpkg_install_cmake() file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/bond) file(RENAME ${CURRENT_PACKAGES_DIR}/share/bond/LICENSE ${CURRENT_PACKAGES_DIR}/share/bond/copyright) +# Drop a copy of gbc in tools/ so that it can be used +file(COPY ${CURRENT_PACKAGES_DIR}/bin/gbc.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/) + # vcpkg doesn't--as of version 0.0.30--like executables such as gbc.exe in # the output. Just delete the bin/ directories for now. file(REMOVE_RECURSE |
