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

CMake MSVC error #98

Open
1 of 4 tasks
Alvazz opened this issue Dec 7, 2023 · 11 comments
Open
1 of 4 tasks

CMake MSVC error #98

Alvazz opened this issue Dec 7, 2023 · 11 comments

Comments

@Alvazz
Copy link

Alvazz commented Dec 7, 2023

Select your issue type: (check at least one)

  • Bug
  • Question
  • Suggestion
  • Other (please describe):

Describe your issue:

1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_next_header2 referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_new referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_bytes_per_block referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_add_filter_bzip2 referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_add_filter_gzip referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_add_filter_none referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_add_filter_xz referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_add_filter_zstd referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_format_7zip referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_format_gnutar referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_format_iso9660 referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_format_xar referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_format_zip referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_open_fd referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_header referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2001: unresolved external symbol __imp_archive_write_header
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_data referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_options referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_set_passphrase referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_disk_new referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_disk_set_standard_lookup referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_disk_open referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_disk_descend referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_new referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_set_atime referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_set_birthtime referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_set_filetype referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_set_mtime referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_set_pathname referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchivecompressor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_set_size referenced in function "private: short __cdecl QArchive::CompressorPrivate::compress(void)" (?compress@CompressorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_new referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_support_filter_all referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_support_format_all referenced in function "private: void __cdecl QArchive::ExtractorPrivate::toggleArchiveFormat(struct archive *)" (?toggleArchiveFormat@ExtractorPrivate@QArchive@@AEAAXPEAUarchive@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_support_format_empty referenced in function "private: void __cdecl QArchive::ExtractorPrivate::toggleArchiveFormat(struct archive *)" (?toggleArchiveFormat@ExtractorPrivate@QArchive@@AEAAXPEAUarchive@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_support_format_raw referenced in function "private: void __cdecl QArchive::ExtractorPrivate::toggleArchiveFormat(struct archive *)" (?toggleArchiveFormat@ExtractorPrivate@QArchive@@AEAAXPEAUarchive@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_next_header referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_data_block referenced in function "private: short __cdecl QArchive::ExtractorPrivate::writeData(struct archive_entry *)" (?writeData@ExtractorPrivate@QArchive@@AEAAFPEAUarchive_entry@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_add_passphrase referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_close referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2001: unresolved external symbol __imp_archive_read_close
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_free referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2001: unresolved external symbol __imp_archive_read_free
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_data_block referenced in function "private: short __cdecl QArchive::ExtractorPrivate::writeData(struct archive_entry *)" (?writeData@ExtractorPrivate@QArchive@@AEAAFPEAUarchive_entry@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_finish_entry referenced in function "private: short __cdecl QArchive::ExtractorPrivate::writeData(struct archive_entry *)" (?writeData@ExtractorPrivate@QArchive@@AEAAFPEAUarchive_entry@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_disk_new referenced in function "private: short __cdecl QArchive::ExtractorPrivate::extract(void)" (?extract@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_disk_set_options referenced in function "private: short __cdecl QArchive::ExtractorPrivate::extract(void)" (?extract@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_error_string referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_match_new referenced in function "public: __cdecl QArchive::ArchiveFilter::ArchiveFilter(void)" (??0ArchiveFilter@QArchive@@qeaa@XZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_match_free referenced in function "public: __cdecl QArchive::ArchiveFilter::ArchiveFilter(void)" (??0ArchiveFilter@QArchive@@qeaa@XZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_match_excluded referenced in function "public: bool __cdecl QArchive::ArchiveFilter::isEntryExcluded(struct archive_entry *)const " (?isEntryExcluded@ArchiveFilter@QArchive@@QEBA_NPEAUarchive_entry@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_match_exclude_pattern_w referenced in function "public: short __cdecl QArchive::ArchiveFilter::addExcludePattern(class QString const &)" (?addExcludePattern@ArchiveFilter@QArchive@@QEAAFAEBVQString@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_match_include_pattern_w referenced in function "public: short __cdecl QArchive::ArchiveFilter::addIncludePattern(class QString const &)" (?addIncludePattern@ArchiveFilter@QArchive@@QEAAFAEBVQString@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_clear referenced in function "private: short __cdecl QArchive::ExtractorPrivate::processArchiveInformation(void)" (?processArchiveInformation@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_atime referenced in function "class QJsonObject __cdecl anonymous namespace'::getArchiveEntryInformation(struct archive_entry *,bool)" (?getArchiveEntryInformation@?A0xbf53cf51@@YA?AVQJsonObject@@PEAUarchive_entry@@_N@Z) 1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_ctime referenced in function "class QJsonObject __cdecl anonymous namespace'::getArchiveEntryInformation(struct archive_entry *,bool)" (?getArchiveEntryInformation@?A0xbf53cf51@@ya?AVQJsonObject@@PEAUarchive_entry@@_N@Z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_filetype referenced in function "public: __cdecl class QJsonObject __cdecl anonymous namespace'::getArchiveEntryInformation(struct archive_entry *,bool)'::2'::<lambda_1>::operator()(void)const " (??R<lambda_1>@?1??getArchiveEntryInformation@?A0xbf53cf51@@YA?AVQJsonObject@@PEAUarchive_entry@@_N@Z@QEBA@XZ) 1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_mtime referenced in function "class QJsonObject __cdecl anonymous namespace'::getArchiveEntryInformation(struct archive_entry *,bool)" (?getArchiveEntryInformation@?A0xbf53cf51@@ya?AVQJsonObject@@PEAUarchive_entry@@_N@Z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_pathname referenced in function "private: short __cdecl QArchive::ExtractorPrivate::processArchiveInformation(void)" (?processArchiveInformation@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_pathname_w referenced in function "private: short __cdecl QArchive::ExtractorPrivate::writeData(struct archive_entry *)" (?writeData@ExtractorPrivate@QArchive@@AEAAFPEAUarchive_entry@@@z)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_size referenced in function "private: short __cdecl QArchive::ExtractorPrivate::getTotalEntriesCount(void)" (?getTotalEntriesCount@ExtractorPrivate@QArchive@@AEAAFXZ)
1>QArchive.lib(qarchiveextractor_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_copy_pathname_w referenced in function "private: short __cdecl QArchive::ExtractorPrivate::writeData(struct archive_entry *)" (?writeData@ExtractorPrivate@QArchive@@AEAAFPEAUarchive_entry@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_set_open_callback referenced in function "int __cdecl archiveReadOpenQIODevice(struct archive *,int,class QIODevice *)" (?archiveReadOpenQIODevice@@YAHPEAUarchive@@HPEAVQIODevice@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_set_read_callback referenced in function "int __cdecl archiveReadOpenQIODevice(struct archive *,int,class QIODevice *)" (?archiveReadOpenQIODevice@@YAHPEAUarchive@@HPEAVQIODevice@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_set_seek_callback referenced in function "int __cdecl archiveReadOpenQIODevice(struct archive *,int,class QIODevice *)" (?archiveReadOpenQIODevice@@YAHPEAUarchive@@HPEAVQIODevice@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_set_close_callback referenced in function "int __cdecl archiveReadOpenQIODevice(struct archive *,int,class QIODevice *)" (?archiveReadOpenQIODevice@@YAHPEAUarchive@@HPEAVQIODevice@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_set_callback_data referenced in function "int __cdecl archiveReadOpenQIODevice(struct archive *,int,class QIODevice *)" (?archiveReadOpenQIODevice@@YAHPEAUarchive@@HPEAVQIODevice@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_read_open1 referenced in function "int __cdecl archiveReadOpenQIODevice(struct archive *,int,class QIODevice *)" (?archiveReadOpenQIODevice@@YAHPEAUarchive@@HPEAVQIODevice@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_open2 referenced in function "int __cdecl archiveWriteOpenQIODevice(struct archive *,class QIODevice *)" (?archiveWriteOpenQIODevice@@YAHPEAUarchive@@PEAVQIODevice@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_close referenced in function "void __cdecl ArchiveWriteDestructor(struct archive *)" (?ArchiveWriteDestructor@@YAXPEAUarchive@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_write_free referenced in function "void __cdecl ArchiveWriteDestructor(struct archive *)" (?ArchiveWriteDestructor@@YAXPEAUarchive@@@z)
1>QArchive.lib(qarchiveutils_p.obj) : error LNK2019: unresolved external symbol __imp_archive_entry_free referenced in function "void __cdecl ArchiveEntryDestructor(struct archive_entry *)" (?ArchiveEntryDestructor@@YAXPEAUarchive_entry@@@z)

Ways to Reproduce the issue (optional):

@Alvazz
Copy link
Author

Alvazz commented Dec 7, 2023

image

@Alvazz
Copy link
Author

Alvazz commented Dec 7, 2023

When I build the QArchive Examples, also got this error.
image

MSVC 2022, Qt6.5.1

@antony-jr
Copy link
Owner

@Alvazz is libarchive installed properly? it seems like it's trying to link to libarchive but can't find it. To install libarchive, download prebuilt libarchive for msvc and copy paste the libs to the Qt folder. (Note if you use prebuilts, then see if it's debug build or release build, if it's release build then you have to build your project in release mode also)

@antony-jr
Copy link
Owner

@Alvazz can you try an experimental fix? (I have been meaning to make QArchive install easily in windows). Follow the below steps, (This only works for msvc2019_64 kit, make sure you are using that, select it in QtCreator)

  • Go to C:\Qt or the directory where you installed Qt under Windows
  • Open "Maintenancetool.exe", create a account and continue, now you will see add or remove components.
  • Before clicking on Next, click on the settings icon on the bottom left corner.
  • Now go to "Repositories" tab and add a user defined repository with the following url,
 https://qt.antonyjr.in/qt5_15_2/windows/
  • Now click on Ok and the maintenance tool will restart
  • Now continue into Add or Remove Components
  • Now you will see "QArchive (Windows MSVC)" under the list box
  • Select that, make sure you are using msvc2019_64 kit and have Qt 5.15.2 or above (not Qt 6 though)
  • Click on Next
  • Click Update and Confirm License
  • Finish

No restart your QtCreator, open your project, simply add find_package(QArchive) to your Cmake file and try to build your app, it should build. Make sure you use Release mode, since the prebuilt binaries are only meant for Release build type.

@Alvazz
Copy link
Author

Alvazz commented Dec 11, 2023

OK, I'm traveling these days, I'll try it later

@antony-jr
Copy link
Owner

OK, I'm traveling these days, I'll try it later

no problem, try whenever you have time, I will release a detailed documentation on this method soon. Thanks.

@neheb
Copy link
Contributor

neheb commented Dec 18, 2023

Could alternatively try meson. libarchive is available as a subproject.

@antony-jr
Copy link
Owner

Could alternatively try meson. libarchive is available as a subproject.

I think pre-built libraries are much easier for windows users, but meson is much better for *nix users. Well it's the choice of the user, need more documentation for using meson under Windows with MSVC. With the new prebuilts, the user don't even need to care about compiling libarchive or QArchive. I think that's a good thing. For now I'm using Conan to build prebuilts for windows but zstd tests are failing for some reason, maybe we need to build using Meson, I tried but I'm lacking knowledge to compile with MSVC with meson (windows tests has some pointers but it uses msys)

@neheb
Copy link
Contributor

neheb commented Dec 18, 2023

Maybe @eli-schwartz has more info. I don’t really use MSVC.

@eli-schwartz
Copy link

maybe we need to build using Meson, I tried but I'm lacking knowledge to compile with MSVC with meson (windows tests has some pointers but it uses msys)

Not entirely sure I understand what the snag here is, but in general, Meson and MSVC should be more or less out of the box.

  • if you run meson from a MSVC dev command prompt, meson simply uses MSVC
  • if you run meson setup --vsenv meson simply uses MSVC
  • if you run meson and MSVC is the only compiler available, meson uses MSVC
  • if you run meson and MSVC is not set up, but you have mingw GCC (e.g. msys2) set up and in your path, meson uses GCC

@antony-jr
Copy link
Owner

maybe we need to build using Meson, I tried but I'm lacking knowledge to compile with MSVC with meson (windows tests has some pointers but it uses msys)

Not entirely sure I understand what the snag here is, but in general, Meson and MSVC should be more or less out of the box.

* if you run meson from a MSVC dev command prompt, meson simply uses MSVC

* if you run `meson setup --vsenv` meson simply uses MSVC

* if you run meson and MSVC is the only compiler available, meson uses MSVC

* if you run meson and MSVC is _not_ set up, but you have mingw GCC (e.g. msys2) set up and in your path, meson uses GCC

Thanks for the info, It's not that I don't understand meson, its simply because I could not figure out how to build and install the binaries into a directory to package it to the users to use it as prebuilt library (this is clearly a skill issue, will have to read more docs), thanks for chiming in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants