0

I'm trying to build python from source and using the prefix option to control the target directory where it gets installed. After successful installation, in some files in the target directory I see the entries of the working directory from where I actually built.

Example files which has entry for abs_srcdir & abs_builddir

lib/python3.9/_sysconfigdata__linux_x86_64-linux-gnu.py
lib/python3.9/config-3.9-x86_64-linux-gnu/Makefile

How can I avoid this?

Veera
  • 65
  • 1
  • 7

1 Answers1

1

I am a bit unfamiliar with the process in Python but I can tell that these are part of the Preset Output Variables

From docs:

Some output variables are preset by the Autoconf macros. Some of the Autoconf macros set additional output variables, which are mentioned in the descriptions for those macros. See Output Variable Index, for a complete list of output variables. See Installation Directory Variables, for the list of the preset ones related to installation directories. Below are listed the other preset ones, many of which are precious variables (see Setting Output Variables, AC_ARG_VAR).

You can see the variables you mentioned here - B.2 Output Variable Index. Since these are preset variables, I don't see how you can exclude them post-installation. Manually removing or creating some sort of a script seems like the only way you can solve this.

If this was done in GNU Make then you can use the filter-out text function

AzyCrw4282
  • 7,222
  • 5
  • 19
  • 35