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

[kealib] Cleanup, fix CMake config #35461

Merged
merged 3 commits into from
Dec 5, 2023
Merged

Conversation

dg0yt
Copy link
Contributor

@dg0yt dg0yt commented Dec 2, 2023

Cherry-picked from #35437.

@dg0yt dg0yt marked this pull request as draft December 2, 2023 10:10
@dg0yt dg0yt marked this pull request as ready for review December 3, 2023 16:10
@@ -4,7 +4,9 @@ vcpkg_from_github(
REF "kealib-${VERSION}"
SHA512 82399f1332ff2aeb6342732e9e5c897c813109fd18e77cfc8d866f06adf4faa7f080f1f3c0a3b777fb3a679912dacf4851b7ad09a338d6087dd1d26eb2d1689f
HEAD_REF master
PATCHES hdf5_include.patch
PATCHES
kealib-target.diff
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@@ -4,7 +4,9 @@ vcpkg_from_github(
REF "kealib-${VERSION}"
SHA512 82399f1332ff2aeb6342732e9e5c897c813109fd18e77cfc8d866f06adf4faa7f080f1f3c0a3b777fb3a679912dacf4851b7ad09a338d6087dd1d26eb2d1689f
HEAD_REF master
PATCHES hdf5_include.patch
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Pointless patch.

@MonicaLiu0311 MonicaLiu0311 added the category:port-bug The issue is with a library, which is something the port should already support label Dec 4, 2023
@MonicaLiu0311
Copy link
Contributor

When testing usage, the following error occurs:

1> [CMake] CMake Error at G:/kealib/installed/x64-windows/share/libkea/libkeaTargets.cmake:60 (set_target_properties):
1> [CMake]   The link interface of target "libkea::kea" contains:
1> [CMake] 
1> [CMake]     hdf5::hdf5-shared
1> [CMake] 
1> [CMake]   but the target was not found.  Possible reasons include:
1> [CMake] 
1> [CMake]     * There is a typo in the target name.
1> [CMake]     * A find_package call is missing for an IMPORTED target.
1> [CMake]     * An ALIAS target is missing.
1> [CMake] 
1> [CMake] Call Stack (most recent call first):
1> [CMake]   G:/kealib/installed/x64-windows/share/libkea/libkeaConfig.cmake:27 (include)
1> [CMake]   G:/kealib/scripts/buildsystems/vcpkg.cmake:859 (_find_package)
1> [CMake]   CMakeUsage/CMakeLists.txt:14 (find_package)
1> [CMake] -- Generating done (0.1s)
1> [CMake] CMake Generate step failed.  Build files cannot be regenerated correctly.
test.cpp
#include <iostream>
#include "libkea/KEACommon.h"

using namespace std;

int main()
{
cout << "Hello CMake." << endl;
return 0;
}

CMakeLists.txt
cmake_minimum_required (VERSION 3.8)

set(CMAKE_TOOLCHAIN_FILE "/home/monica/vcpkg/scripts/buildsystems/vcpkg.cmake")

project ("test")

add_library (main "test.cpp")

find_package(libkea CONFIG REQUIRED)
target_link_libraries(main PRIVATE libkea::Kealib)

@dg0yt
Copy link
Contributor Author

dg0yt commented Dec 4, 2023

@MonicaLiu0311 Please review again.

@MonicaLiu0311
Copy link
Contributor

The usage test passed on x64-windows (header files found).

@MonicaLiu0311 MonicaLiu0311 added the info:reviewed Pull Request changes follow basic guidelines label Dec 5, 2023
@BillyONeal BillyONeal merged commit 631ba72 into microsoft:master Dec 5, 2023
15 checks passed
@BillyONeal
Copy link
Member

Thanks for the fix!

@dg0yt dg0yt deleted the kealib branch December 5, 2023 04:15
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:reviewed Pull Request changes follow basic guidelines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants