[pulseaudio-commits] [Git][pulseaudio/pulseaudio][master] 3 commits: meson: Fix build of padsp

Arun Raghavan gitlab at gitlab.freedesktop.org
Thu Jul 25 17:01:23 UTC 2019



Arun Raghavan pushed to branch master at PulseAudio / pulseaudio


Commits:
09231eae by Jan Alexander Steffens (heftig) at 2019-07-25T16:53:01Z
meson: Fix build of padsp

 - Rename "pulsedspdir" to the same "padsplibdir" that Autotools uses.

 - Add a new option "pulsedsp-location" that is only used for padsp.in,
   just like Autotools' --with-pulsedsp-location.

 - Use 'set' instead of 'set_quoted' to avoid PULSEDSP_LOCATION getting
   quoted twice.

- - - - -
8e98ed94 by Jan Alexander Steffens (heftig) at 2019-07-25T16:53:01Z
meson: Fix library versioning to match Autotools

For ease of maintaining both build systems, use the same version info
sequences as configure.ac. This should be simplified after Autotools has
been dropped.

- - - - -
9f946d2d by Jan Alexander Steffens (heftig) at 2019-07-25T16:53:01Z
meson: Fix installation of headers

To match Autotools:
 - internal.h should not be installed
 - Install simple.h and version.h

- - - - -


4 changed files:

- meson.build
- meson_options.txt
- src/pulse/meson.build
- src/utils/meson.build


Changes:

=====================================
meson.build
=====================================
@@ -21,20 +21,35 @@ pa_version_major_minor = pa_version_major + '.' + pa_version_minor
 pa_api_version = 12
 pa_protocol_version = 33
 
-apiversion = '1.0'
-soversion = 0
-# FIXME: this doesn't actually do what we want it to
-# maintaining compatibility with the previous libtool versioning
-# current = minor * 100 + micro
-libversion = '@0 at .@1 at .0'.format(soversion, pa_version_minor.to_int() * 100 + pa_version_micro.to_int())
+# The stable ABI for client applications, for the version info x:y:z
+# always will hold y=z
+libpulse_version_info = [21, 0, 21]
+
+# A simplified, synchronous, ABI-stable interface for client
+# applications, for the version info x:y:z always will hold y=z
+libpulse_simple_version_info = [1, 1, 1]
+
+# The ABI-stable GLib adapter for client applications, for the version
+# info x:y:z always will hold y=z
+libpulse_mainloop_glib_version_info = [0, 5, 0]
+
+libpulse_version = '@0 at .@1 at .@2@'.format(
+  libpulse_version_info[0] - libpulse_version_info[2],
+  libpulse_version_info[0],
+  libpulse_version_info[1],
+)
 
-# A simplified, synchronous, ABI-stable interface for client applications.
-# For the version x:y:z always will hold y=z.
-libpulse_simple_version = '1.1.1'
+libpulse_simple_version = '@0 at .@1 at .@2@'.format(
+  libpulse_simple_version_info[0] - libpulse_simple_version_info[2],
+  libpulse_simple_version_info[0],
+  libpulse_simple_version_info[1],
+)
 
-# The ABI-stable GLib adapter for client applications.
-# For the version x:y:z always will hold y=z.
-libpulse_mainloop_glib_version = '0.5.0'
+libpulse_mainloop_glib_version = '@0 at .@1 at .@2@'.format(
+  libpulse_mainloop_glib_version_info[0] - libpulse_mainloop_glib_version_info[2],
+  libpulse_mainloop_glib_version_info[0],
+  libpulse_mainloop_glib_version_info[1],
+)
 
 # Paths
 
@@ -50,7 +65,7 @@ datadir = join_paths(prefix, get_option('datadir'))
 localedir = join_paths(prefix, get_option('localedir'))
 localstatedir = join_paths(prefix, get_option('localstatedir'))
 sysconfdir = join_paths(prefix, get_option('sysconfdir'))
-privlibdir = join_paths(get_option('libdir'), 'pulseaudio')
+privlibdir = join_paths(libdir, 'pulseaudio')
 alsadatadir = join_paths(datadir, 'pulseaudio', 'alsa-mixer')
 
 pkgconfigdir = join_paths(libdir, 'pkgconfig')
@@ -62,9 +77,14 @@ if modlibexecdir == ''
   modlibexecdir = join_paths(libdir, 'pulse-' + pa_version_major_minor, 'modules')
 endif
 
-pulsedspdir = get_option('pulsedspdir')
-if pulsedspdir == ''
-  pulsedspdir = join_paths(libdir, 'pulseaudio')
+padsplibdir = get_option('padsplibdir')
+if padsplibdir == ''
+  padsplibdir = privlibdir
+endif
+
+pulsedsp_location = get_option('pulsedsp-location')
+if pulsedsp_location == ''
+  pulsedsp_location = join_paths(prefix, padsplibdir)
 endif
 
 systemduserunitdir = get_option('systemduserunitdir')
@@ -419,7 +439,7 @@ endif
 if cc.has_header('sys/soundcard.h')
   cdata.set('HAVE_OSS_OUTPUT', 1)
   cdata.set('HAVE_OSS_WRAPPER', 1)
-  cdata.set_quoted('PULSEDSP_LOCATION',	pulsedspdir)
+  cdata.set('PULSEDSP_LOCATION', pulsedsp_location)
 endif
 
 if get_option('hal-compat')


=====================================
meson_options.txt
=====================================
@@ -30,9 +30,15 @@ option('running-from-build-tree',
 
 # Paths
 
-option('pulsedspdir',
+option('padsplibdir',
        type : 'string',
-       description : 'Specify location where OSS wrapper will be installed')
+       description : 'Specify location where OSS wrapper library will be installed')
+# This one gets inserted into a shell double-quoted string, so needs to be escaped (\$LIB). Meson
+# removes a layer of escapes when parsing the description string, so we need to double the
+# backslashes for "meson configure" to display the right text.
+option('pulsedsp-location',
+       type : 'string',
+       description : 'Specify location where OSS wrapper library will be loaded from; can use \\$LIB')
 option('modlibexecdir',
        type : 'string',
        description : 'Specify location where modules will be installed')


=====================================
src/pulse/meson.build
=====================================
@@ -1,4 +1,9 @@
-configure_file(input : 'version.h.in', output :  'version.h', configuration : cdata)
+configure_file(
+  input : 'version.h.in',
+  output : 'version.h',
+  configuration : cdata,
+  install_dir : join_paths(includedir, 'pulse'),
+)
 
 libpulse_sources = [
   'channelmap.c',
@@ -9,6 +14,7 @@ libpulse_sources = [
   'ext-device-restore.c',
   'ext-stream-restore.c',
   'format.c',
+  'internal.h',
   'introspect.c',
   'mainloop-api.c',
   'mainloop-signal.c',
@@ -40,7 +46,6 @@ libpulse_headers = [
   'ext-stream-restore.h',
   'format.h',
   'gccmacro.h',
-  'internal.h',
   'introspect.h',
   'mainloop-api.h',
   'mainloop-signal.h',
@@ -68,17 +73,17 @@ endif
 libpulse = shared_library('pulse',
   libpulse_sources,
   libpulse_headers,
-  version : libversion,
+  version : libpulse_version,
   include_directories : [configinc, topinc],
   c_args : [pa_c_args],
-  soversion : soversion,
   install : true,
   dependencies : [libm_dep, thread_dep, libpulsecommon_dep, dbus_dep],
   implicit_include_directories : false)
 
 libpulse_dep = declare_dependency(link_with: libpulse)
 
-install_data(libpulse_headers,
+install_data(
+  libpulse_headers, 'simple.h',
   install_dir : join_paths(includedir, 'pulse')
 )
 


=====================================
src/utils/meson.build
=====================================
@@ -85,7 +85,7 @@ if cc.has_header('sys/soundcard.h')
   libpulsedsp = shared_library('pulsedsp',
     libpulsecommon_sources,
     install: true,
-    install_dir : pulsedspdir,
+    install_dir : padsplibdir,
     include_directories : [configinc, topinc],
     link_with : [libpulsecommon, libpulse],
     link_args : ['-ldl'],



View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/compare/9e70d0520182700b66438bebacb4570b7c56aa59...9f946d2d11f293bebc826889e829364fcad711a9

-- 
View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/compare/9e70d0520182700b66438bebacb4570b7c56aa59...9f946d2d11f293bebc826889e829364fcad711a9
You're receiving this email because of your account on gitlab.freedesktop.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/pulseaudio-commits/attachments/20190725/60349a0d/attachment-0001.html>


More information about the pulseaudio-commits mailing list