-
Notifications
You must be signed in to change notification settings - Fork 7.4k
[libcpplocate] New port #23173
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
[libcpplocate] New port #23173
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
ae0ef8a
[libcpplocate] New port
ekilmer c8d5589
UWP unsupported
ekilmer 0fe471d
Add version
ekilmer 9a29531
Apply suggestions from code review
ekilmer eaa957c
Simplify patch
ekilmer 0960846
Update version
ekilmer 8a894a4
Use tagged v2.3.0
ekilmer 357d6c9
Update version
ekilmer 6be6aa5
Merge branch 'master' into cpplocate
ekilmer File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
| index 854214c..9c4d98a 100644 | ||
| --- a/CMakeLists.txt | ||
| +++ b/CMakeLists.txt | ||
| @@ -124,7 +124,7 @@ if("${CMAKE_INSTALL_PREFIX}" STREQUAL "/usr" OR "${CMAKE_INSTALL_PREFIX}" STREQU | ||
| endif() | ||
|
|
||
| # Installation paths | ||
| -if(UNIX AND SYSTEM_DIR_INSTALL) | ||
| +if(1) | ||
| # Install into the system (/usr/bin or /usr/local/bin) | ||
| set(INSTALL_ROOT "share/${project}") # /usr/[local]/share/<project> | ||
| set(INSTALL_CMAKE "share/${project}/cmake") # /usr/[local]/share/<project>/cmake | ||
| diff --git a/cpplocate-config.cmake b/cpplocate-config.cmake | ||
| index 8693fa4..cdb2828 100644 | ||
| --- a/cpplocate-config.cmake | ||
| +++ b/cpplocate-config.cmake | ||
| @@ -26,7 +26,7 @@ macro(find_modules PREFIX) | ||
| if(TARGET ${module_name}) | ||
| set(MODULE_FOUND TRUE) | ||
| else() | ||
| - find_module("${CMAKE_CURRENT_LIST_DIR}/${PREFIX}/${module_name}/${module_name}-export.cmake") | ||
| + find_module("${CMAKE_CURRENT_LIST_DIR}/${module_name}-export.cmake") | ||
| endif() | ||
| endforeach(module_name) | ||
| endmacro() | ||
| diff --git a/liblocate-config.cmake b/liblocate-config.cmake | ||
| index 3bf4823..7245353 100644 | ||
| --- a/liblocate-config.cmake | ||
| +++ b/liblocate-config.cmake | ||
| @@ -25,7 +25,7 @@ macro(find_modules PREFIX) | ||
| if(TARGET ${module_name}) | ||
| set(MODULE_FOUND TRUE) | ||
| else() | ||
| - find_module("${CMAKE_CURRENT_LIST_DIR}/${PREFIX}/${module_name}/${module_name}-export.cmake") | ||
| + find_module("${CMAKE_CURRENT_LIST_DIR}/${module_name}-export.cmake") | ||
| endif() | ||
| endforeach(module_name) | ||
| endmacro() | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| vcpkg_from_github( | ||
| OUT_SOURCE_PATH SOURCE_PATH | ||
| REPO cginternals/cpplocate | ||
| REF v2.3.0 | ||
| SHA512 4028d552d0c3c0161d5dd5aea27bb22f0c61297a4b461a067c082cfcf84e3a709c9895453e750d819433529089011c2512293b2064c42bb5ba11f957eebc2206 | ||
| HEAD_REF master | ||
| PATCHES | ||
| fix-install-paths.patch | ||
| ) | ||
|
|
||
| vcpkg_cmake_configure( | ||
| SOURCE_PATH "${SOURCE_PATH}" | ||
| OPTIONS | ||
| -DOPTION_BUILD_TESTS=OFF | ||
| ) | ||
|
|
||
| vcpkg_cmake_install() | ||
ekilmer marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| vcpkg_copy_pdbs() | ||
|
|
||
| vcpkg_cmake_config_fixup( | ||
| PACKAGE_NAME cpplocate | ||
| CONFIG_PATH share/cpplocate/cmake/cpplocate | ||
| DO_NOT_DELETE_PARENT_CONFIG_PATH | ||
| ) | ||
|
|
||
| vcpkg_cmake_config_fixup( | ||
| PACKAGE_NAME liblocate | ||
| CONFIG_PATH share/cpplocate/cmake/liblocate | ||
| ) | ||
|
|
||
| file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") | ||
| file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share") | ||
| file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/share/cpplocate/cmake") | ||
|
|
||
| # Patched liblocate config file needs moving to the correct directory | ||
| file(RENAME | ||
| "${CURRENT_PACKAGES_DIR}/share/cpplocate/liblocate-config.cmake" | ||
| "${CURRENT_PACKAGES_DIR}/share/liblocate/liblocate-config.cmake" | ||
JackBoosY marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ) | ||
|
|
||
| file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| { | ||
| "name": "libcpplocate", | ||
| "version-semver": "2.3.0", | ||
| "description": "Cross-platform C++ library providing tools for applications to locate themselves, their data assets as well as dependent modules.", | ||
| "homepage": "https://cpplocate.org/", | ||
| "license": "MIT", | ||
| "supports": "!uwp", | ||
| "dependencies": [ | ||
| { | ||
| "name": "vcpkg-cmake", | ||
| "host": true | ||
| }, | ||
| { | ||
| "name": "vcpkg-cmake-config", | ||
| "host": true | ||
| } | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| { | ||
| "versions": [ | ||
| { | ||
| "git-tree": "5f15b69e558a8774ebbc5bde4f5ddf70da27611c", | ||
| "version-semver": "2.3.0", | ||
| "port-version": 0 | ||
| } | ||
| ] | ||
| } |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.