Skip to content

libircclient not found #10738

@andy5995

Description

@andy5995

On Ubuntu 22.04 and Manjaro, meson can't find libircclient using dependency() (The libircclient upstream project doesn't include a '.pc' file). Here's my (amateur) code to workaround this:

inc_ircclient = []
dep_irclient = []
dep_ircclient = dependency('libircclient', required: false)
if not dep_ircclient.found()
  dep_ircclient = cc.find_library('libircclient', has_headers: 'libircclient.h', required: false)
  if not dep_ircclient.found()
    inc_ircclient = '/usr/include/libircclient'
    dep_ircclient = cc.find_library(
      'libircclient',
      has_headers: 'libircclient.h',
      header_include_directories: include_directories(inc_ircclient)
    )
  endif
endif

On Manjaro, the headers are in '/usr/include/libircclient' and Ubuntu they are in '/usr/include'.

@astavale maybe this affects you, too. I saw you're using libirc... in #4702

When I used only find_package() for libircclient on Manjaro the header wasn't found until I added the extra code (above)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions