Skip to content
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

[shapelib] Fix shapelib usage #22633

Merged
merged 4 commits into from
Mar 21, 2022
Merged

Conversation

JonLiu1993
Copy link
Member

Describe the pull request

Shapelib unable to find shp-config.cmake when including in build

[cmake] CMake Error at external/vcpkg/scripts/buildsystems/vcpkg.cmake:650 (_find_package):
[cmake]   Could not find a package configuration file provided by "shp" with any of
[cmake]   the following names:
[cmake] 
[cmake]     shpConfig.cmake
[cmake]     shp-config.cmake
[cmake] 

Export the shpConfig file can solved the bug

I have test the usage successfully on my local machine:

PS F:\test9\test\build> F:\test9\vcpkg\downloads\tools\cmake-3.21.1-windows\cmake-3.21.1-windows-i386\bin\cmake.exe -G "Visual Studio 16 2019" -A Win32 -DCMAKE_TOOLCHAIN_FILE=F:/test9/vcpkg/scripts/buildsystems/vcpkg.cmake ..
-- Selecting Windows SDK version 10.0.19041.0 to target Windows 10.0.19042.
-- Configuring done
-- Generating done
-- Build files have been written to: F:/test9/test/build
PS F:\test9\test\build> F:\test9\vcpkg\downloads\tools\cmake-3.21.1-windows\cmake-3.21.1-windows-i386\bin\cmake.exe --build .
Microsoft (R) Build Engine version 16.11.2+f32259642 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.

  main.cpp
  main.vcxproj -> F:\test9\test\build\Debug\main.exe
  Building Custom Rule F:/test9/test/CMakeLists.txt

@JonLiu1993 JonLiu1993 added category:port-bug The issue is with a library, which is something the port should already support info:internal This PR or Issue was filed by the vcpkg team. labels Jan 19, 2022
@JonLiu1993 JonLiu1993 marked this pull request as ready for review January 20, 2022 01:14
@JonLiu1993 JonLiu1993 requested a review from JackBoosY January 27, 2022 10:11
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have modified or added at least one vcpkg.json where a "license" field is missing.
If you feel able to do so, please consider adding a "license" field to the following files:

  • ports/shapelib/vcpkg.json

Valid values for the license field are listed at https://spdx.org/licenses/

@JonLiu1993 JonLiu1993 marked this pull request as draft February 16, 2022 08:44
@JonLiu1993 JonLiu1993 marked this pull request as ready for review February 24, 2022 08:13
-# for the export_shp name.
-install(EXPORT export_shp DESTINATION ${CMAKE_INSTALL_SHP_DATADIR})
+# for the shpConfig name.
+install(EXPORT shpConfig DESTINATION ${CMAKE_INSTALL_SHP_DATADIR})
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also please report this to the upstream plase.

@JonLiu1993 JonLiu1993 added the info:reviewed Pull Request changes follow basic guidelines label Mar 18, 2022
@BillyONeal BillyONeal merged commit ce5fa83 into microsoft:master Mar 21, 2022
@BillyONeal
Copy link
Member

Thanks for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:port-bug The issue is with a library, which is something the port should already support info:internal This PR or Issue was filed by the vcpkg team. info:reviewed Pull Request changes follow basic guidelines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[shapelib] Unable to find shp-config.cmake when including in build
3 participants