File:  [Coherent Logic Development] / ChivanetAimPidgin / purple-config.cmake
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Mon Jan 27 19:48:25 2025 UTC (6 months ago) by snw
Branches: MAIN, CoherentLogicDevelopment
CVS tags: test-tag, start, HEAD
Pidgin AIM Plugin for ChivaNet

    1: cmake_minimum_required(VERSION 3.16...3.24)
    2: 
    3: set(Purple "purple" CACHE STRING "Purple version to build against.")
    4: set_property(CACHE Purple PROPERTY STRINGS "purple" "purple-3")
    5: 
    6: # Try pkg-config first (the default on Linux).
    7: # Note: On win32, pkg-config may be provided by MinGW or MSYS.
    8: find_package(PkgConfig QUIET)
    9: if (${PKG_CONFIG_FOUND})
   10:     pkg_check_modules(PURPLE ${Purple})
   11:     pkg_get_variable(_PURPLE_PLUGIN_DIR ${Purple} plugindir)
   12:     pkg_get_variable(_PURPLE_DATA_DIR ${Purple} datarootdir)
   13: endif()
   14: if(WIN32 AND NOT "${PURPLE_FOUND}" AND "${Purple}" STREQUAL "purple")
   15:     message(STATUS "Trying win32 auto-configuration...")
   16:     include(${CMAKE_CURRENT_LIST_DIR}/win32/purple-fetch.cmake) # Note: This needs cmake 3.18
   17: endif()
   18: if(NOT "${PURPLE_FOUND}")
   19:     message(FATAL_ERROR "Purple not found.")
   20: else()
   21:     # these are set intermediately so the user can override them
   22:     set(PURPLE_PLUGIN_DIR ${_PURPLE_PLUGIN_DIR} CACHE PATH "Where to put the plug-in.")
   23:     set(PURPLE_DATA_DIR ${_PURPLE_DATA_DIR} CACHE PATH "Data directory (pixmaps for the protocol icons is a sub-directory).")
   24: endif()

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>