Skip to content

remove unused variables from .pc files

Kipp Cannon requested to merge (removed):pkgconfig_remove_unused_vars into master

Description

the .pc files contain a number of variable definitions that are not required by pkg-config. the configure script sets two of these of these unused variables to values that, in turn, depend on other variable definitions that are not included in the .pc file and are not expanded at configure time. this causes pkg-config to report an undefined variable error, and makes software that links to lal impossible to compile if pkg-config is relied upon to supply compiler and linker falgs.

the cause of the problem is an incompatibility between some versions of the AM_PATH_PYTHON script and some versions of autoconf/automake/autosomething. the bug has been reported in numerous forums for example https://debbugs.gnu.org/cgi/bugreport.cgi?bug=35322 and I believe it has been fixed upstream (https://github.com/autotools-mirror/automake/blob/fee9a828bcc968656edfc89e38b157c28d6335f0/NEWS#L42), however it is not fixed in lalsuite and/or the versions of the build tools installed on some user's computers, and it likely won't be for some time.

one option would be to figure out how to get lalsuite's build scripts to work around the problem ... or ... just remove the offending variables from the .pc files because they aren't used for anything.

this patch does the latter.

API Changes and Justification

Backwards Compatible Changes

  • This change does not modify any class/function/struct/type definitions in a public C header file or any Python class/function definitions
  • This change adds new classes/functions/structs/types to a public C header file or Python module

Backwards Incompatible Changes

  • This change modifies an existing class/function/struct/type definition in a public C header file or Python module
  • This change removes an existing class/function/struct/type from a public C header file or Python module

If any of the Backwards Incompatible check boxes are ticked please provide a justification why this change is necessary and why it needs to be done in a backwards incompatible way.

Review Status

Not reviewed. "works for me".

Edited by Kipp Cannon

Merge request reports