meson.build 2.73 KB
Newer Older
1 2 3 4 5 6
configure_file(
  input : 'version.h.in',
  output : 'version.h',
  configuration : cdata,
  install_dir : join_paths(includedir, 'pulse'),
)
7

8 9 10 11 12 13 14 15 16
libpulse_sources = [
  'channelmap.c',
  'context.c',
  'direction.c',
  'error.c',
  'ext-device-manager.c',
  'ext-device-restore.c',
  'ext-stream-restore.c',
  'format.c',
17
  'internal.h',
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
  'introspect.c',
  'mainloop-api.c',
  'mainloop-signal.c',
  'mainloop.c',
  'operation.c',
  'proplist.c',
  'rtclock.c',
  'sample.c',
  'scache.c',
  'stream.c',
  'subscribe.c',
  'thread-mainloop.c',
  'timeval.c',
  'utf8.c',
  'util.c',
  'volume.c',
  'xmalloc.c',
]

libpulse_headers = [
  'cdecl.h',
  'channelmap.h',
  'context.h',
  'def.h',
  'direction.h',
  'error.h',
  'ext-device-manager.h',
  'ext-device-restore.h',
  'ext-stream-restore.h',
  'format.h',
  'gccmacro.h',
  'introspect.h',
  'mainloop-api.h',
  'mainloop-signal.h',
  'mainloop.h',
  'operation.h',
  'proplist.h',
  'pulseaudio.h',
  'rtclock.h',
  'sample.h',
  'scache.h',
  'stream.h',
  'subscribe.h',
  'thread-mainloop.h',
  'timeval.h',
  'utf8.h',
  'util.h',
  'volume.h',
  'xmalloc.h',
]

69 70 71 72
if glib_dep.found()
  libpulse_headers += 'glib-mainloop.h'
endif

73 74 75
libpulse = shared_library('pulse',
  libpulse_sources,
  libpulse_headers,
76
  version : libpulse_version,
77 78
  include_directories : [configinc, topinc],
  c_args : [pa_c_args],
79
  link_args : [nodelete_link_args],
80 81 82 83 84
  install : true,
  dependencies : [libm_dep, thread_dep, libpulsecommon_dep, dbus_dep],
  implicit_include_directories : false)

libpulse_dep = declare_dependency(link_with: libpulse)
85

86 87
install_data(
  libpulse_headers, 'simple.h',
Arnaud Rebillout's avatar
Arnaud Rebillout committed
88 89 90
  install_dir : join_paths(includedir, 'pulse')
)

Arnaud Rebillout's avatar
Arnaud Rebillout committed
91 92 93 94 95
libpulse_simple = shared_library('pulse-simple',
  'simple.c',
  'simple.h',
  version : libpulse_simple_version,
  c_args : [pa_c_args],
96
  link_args : [nodelete_link_args],
Arnaud Rebillout's avatar
Arnaud Rebillout committed
97 98 99 100 101 102 103
  include_directories : [configinc, topinc],
  dependencies : [libpulse_dep, libpulsecommon_dep],
  install : true,
)

libpulse_simple_dep = declare_dependency(link_with: libpulse_simple)

104 105 106 107 108 109
if glib_dep.found()
  libpulse_mainloop_glib = shared_library('pulse-mainloop-glib',
    'glib-mainloop.c',
    'glib-mainloop.h',
    version : libpulse_mainloop_glib_version,
    c_args : [pa_c_args],
110
    link_args : [nodelete_link_args],
111 112 113 114
    include_directories : [configinc, topinc],
    dependencies : [libpulse_dep, libpulsecommon_dep, glib_dep],
    install : true,
  )
115 116

  libpulse_mainloop_glib_dep = declare_dependency(link_with: libpulse_mainloop_glib)
117
endif
118 119 120 121 122 123 124 125 126 127 128 129

# Configuration files

client_conf = configuration_data()
client_conf.set('PA_BINARY', cdata.get_unquoted('PA_BINARY'))

client_conf_file = configure_file(
  input : 'client.conf.in',
  output : 'client.conf',
  configuration : client_conf,
  install_dir : pulsesysconfdir,
)