conda-forge / libarchive-feedstock

A conda-smithy repository for libarchive.
BSD 3-Clause "New" or "Revised" License
2 stars 26 forks source link

Do not override CMake's platform-dependent CFLAGS #91

Open hattne opened 2 months ago

hattne commented 2 months ago

Checklist

The need to build libarchive with /MD to use a multithreaded DLL runtime has been recognized before: the repository has 0009-CMake-Force-Multi-threaded-DLL-runtime.patch which adds /MD to the cl command line, but that patch is currently not applied. This PR addresses the problem by omitting CMAKE_C_FLAGS_RELEASE in the CMake invocation. CMake will then honor default flags for the platform (Modules\Platform\Windows-MSVC.cmake, in this case) in addition to CFLAGS from the environment.

This also means that NDEBUG will be defined for a release build, which, according to a comment in build_libarchive.dat will break the tests. However, the tests are disabled, and several of them fail, regardless of whether NDEBUG is defined or not. Defining NDEBUG seems inconsequential.

conda-forge-webservices[bot] commented 2 months ago

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.