public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] Does anyone still rely on the CONF_LIBDIR variable?
@ 2023-05-03 19:26 Ulrich Mueller
  2023-05-05 16:37 ` [gentoo-dev] " Ulrich Mueller
  0 siblings, 1 reply; 3+ messages in thread
From: Ulrich Mueller @ 2023-05-03 19:26 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1886 bytes --]

I wonder about the CONF_LIBDIR variable and the implementation of the
dolib* commands in Portage. These commands normally use the ABI and
LIBDIR_${ABI} variables from the profile to determine the library
directory (e.g. "lib" or "lib64").

However, if either ABI or LIBDIR_${ABI} happens to be unset, there is a
two-stage fallback in place, first to the value of CONF_LIBDIR, then to
literal "lib" [1]:

   LIBDIR_VAR="LIBDIR_${ABI}"
   if [[ -n ${ABI} && -n ${!LIBDIR_VAR} ]] ; then
           CONF_LIBDIR=${!LIBDIR_VAR}
   fi
   CONF_LIBDIR=${CONF_LIBDIR:-lib}

AFAICS the CONF_LIBDIR variable had been introduced in the 2004.3
profile [2], but was replaced already in 2005 by the present
LIBDIR_${ABI} mechanism [3]. CONF_LIBDIR hasn't been assigned in
profiles ever since.

Presently there are some relics of CONF_LIBDIR in Portage's dolib* (see
above) , but it is not used in its econf or get_libdir functions.
Pkgcore doesn't use CONF_LIBDIR at all. PMS defines dolib in yet another
way [4] with an additional CONF_LIBDIR_OVERRIDE variable, which isn't
implemented in either of the two package managers.

Clearly this situation is not ideal, because a) dolib* and get_libdir
are not consistent with each other, and b) PMS, Portage, and Pkgcore
don't agree with each other.

Before we decide on possible ways to proceed with the issue, I want to
ask whether anyone still relies on CONF_LIBDIR for any purpose?

There is also bug 267159 [5] with some more details.

Ulrich

[1] https://gitweb.gentoo.org/proj/portage.git/tree/bin/ebuild-helpers/dolib?h=portage-3.0.47#n25
[2] https://gitweb.gentoo.org/archive/repo/gentoo-2.git/commit/?id=1482b856ad2a301c8eb2245a7c7265350af2691d
[3] https://gitweb.gentoo.org/archive/repo/gentoo-2.git/commit/?id=054e484d8717a18622615e019e7cd62495365192
[4] https://projects.gentoo.org/pms/8/pms.html#x1-129001r3
[5] https://bugs.gentoo.org/267159

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 507 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-05-06 15:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-05-03 19:26 [gentoo-dev] Does anyone still rely on the CONF_LIBDIR variable? Ulrich Mueller
2023-05-05 16:37 ` [gentoo-dev] " Ulrich Mueller
2023-05-06 15:13   ` [gentoo-dev] [PATCH] multilib.eclass: Drop CONF_LIBDIR Ulrich Müller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox