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

[netcdf-c] Fix link error. #6971

Merged
merged 2 commits into from Jun 21, 2019
Merged

Conversation

NancyLi1013
Copy link
Contributor

When building this port on x64-windows or x86-windows, it failed with some error LNK2001, like this:

nc4hdf.c.obj : error LNK2001: unresolved external symbol H5T_IEEE_F32BE_g
nc4hdf.c.obj : error LNK2001: unresolved external symbol H5T_IEEE_F32LE_g
nc4hdf.c.obj : error LNK2001: unresolved external symbol H5T_IEEE_F64BE_g
nc4hdf.c.obj : error LNK2001: unresolved external symbol H5T_IEEE_F64LE_g
nc4hdf.c.obj : error LNK2001: unresolved external symbol H5T_STD_I8BE_g
...
nc4hdf.c.obj : error LNK2001: unresolved external symbol H5P_CLS_GROUP_CREATE_ID_g
hdf5create.c.obj : error LNK2001: unresolved external symbol H5P_CLS_FILE_CREATE_ID_g
hdf5create.c.obj : error LNK2001: unresolved external symbol H5P_CLS_FILE_ACCESS_ID_g
hdf5open.c.obj : error LNK2001: unresolved external symbol H5P_CLS_FILE_ACCESS_ID_g
nc4memcb.c.obj : error LNK2001: unresolved external symbol H5P_CLS_FILE_ACCESS_ID_g
hdf5var.c.obj : error LNK2001: unresolved external symbol H5P_CLS_DATASET_XFER_ID_g
liblib\netcdf.dll : fatal error LNK1120: 37 unresolved externals

As hdf5 doesn't link correctly, I added target_link_libraries() to fix it.

@NancyLi1013 NancyLi1013 added the info:internal This PR or Issue was filed by the vcpkg team. label Jun 20, 2019
@NancyLi1013 NancyLi1013 marked this pull request as ready for review June 21, 2019 00:54
@Rastaban Rastaban merged commit edf3d75 into microsoft:master Jun 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
info:internal This PR or Issue was filed by the vcpkg team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants