aja-video / libajantv2

Open-source library for AJA Video Systems desktop IO cards.
MIT License
22 stars 16 forks source link

Build doesn't work with default CMake setup #21

Open mbechard opened 5 months ago

mbechard commented 5 months ago

Using CMake GUI on Windows and not changing any settings, I get the following link error when trying to compile ntv2player4k

Error LNK2001 unresolved external symbol "struct poptOption * poptHelpOptionsAutoHelp" (?poptHelpOptionsAutoHelp@@3PEAUpoptOption@@EA) ntv2player4k D:\devel\libajantv2\Build\demos\ntv2player4k\main.obj

paulh-aja commented 5 months ago

Malcom, Which branch did you check out? Which CMake generator are you using? Could you pastebin your CMake settings so I can take a look?

I just tested building libajantv2, including ntv2player4k, with a VS2022 solution generated by CMake GUI. I used the default CMake options presented after running the Configure step, and then ran the Generate step for VS2022. Upon running cmake --build <build-dir> everything built successfully. I didn't see any errors of any kind.

mbechard commented 5 months ago

Hey Paul,

Thanks for the quick reply. This happened both using the head of main today, as well as tag ntv2_17_0_1. Sorry, I realize AJANTV2_BUILD_SHARED needs to be turned on to get this error.

I'm using CMake 2.28.1, Visual Studio 2019. I compiled using the Visual Studio project directly, not via cmake --build

Here is the CMakeCache.txt from that configuration. CMakeCache.txt