ccextractor icon indicating copy to clipboard operation
ccextractor copied to clipboard

build: add CMake options for system library linking

Open DhanushVarma-2 opened this issue 4 months ago • 1 comments

Partial fix for #1718

Adds CMake options for system library linking as foundation for full implementation:

  • USE_SYSTEM_ZLIB - Use system zlib instead of bundled
  • USE_SYSTEM_LIBPNG - Use system libpng instead of bundled
  • USE_SYSTEM_FREETYPE - Use system freetype instead of bundled

Current behaviour: Options are OFF by default, existing bundled libraries still used Future work: Implement actual system library detection and linking

This is phase 1 of addressing #1718 - adding the configuration framework before implementing the full system library support.

DhanushVarma-2 avatar Nov 09 '25 06:11 DhanushVarma-2

Fixed the CMake conditional nesting and cleaned up how the existing USE_SYSTEM_* options are handled. Defaults remain unchanged.

DhanushVarma-2 avatar Dec 09 '25 14:12 DhanushVarma-2

Thanks for the detailed review — all points addressed Removed duplicate USE_SYSTEM_ZLIB option Fixed misplaced source directories in ZLIB logic Completed USE_SYSTEM_FREETYPE with proper system/bundled switching Deduplicated macOS arm64 libpng handling Cleaned up formatting and conditionals Please take another look

DhanushVarma-2 avatar Dec 15 '25 16:12 DhanushVarma-2