Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 516092 - Eclasses using function and variable names reserved for package manager use
Summary: Eclasses using function and variable names reserved for package manager use
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal QA (vote)
Assignee: Gentoo Quality Assurance Team
URL: http://dev.gentoo.org/~ulm/pms/5/pms....
Whiteboard:
Keywords: QAcanfix
Depends on:
Blocks: 843680
  Show dependency tree
 
Reported: 2014-07-03 06:58 UTC by Ulrich Müller
Modified: 2022-05-11 07:20 UTC (History)
16 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ulrich Müller gentoo-dev 2014-07-03 06:58:22 UTC
According to PMS, function and variable names beginning with __ (two underscores) are reserved for package manager use.

The following eclasses are using such reserved names for functions or variables:

autotools.eclass:
  ___ECLASS_ONCE_AUTOTOOLS

base.eclass:
  ___ECLASS_ONCE_BASE

cdrom.eclass:
  ___ECLASS_ONCE_CDROM

cmake-utils.eclass:
  ___ECLASS_ONCE_CMAKE_UTILS

cvs.eclass:
  ___ECLASS_ONCE_CVS

enlightenment.eclass:
  ___ECLASS_ONCE_ENLIGHTENMENT

eutils.eclass:
  ___ECLASS_ONCE_EUTILS
  __estack_i
  __estack_name
  __estack_retvar

fcaps.eclass:
  __FCAPS_WARNED
  ___ECLASS_ONCE_FCAPS

fixheadtails.eclass:
  __do_sed_fix()

flag-o-matic.eclass:
  ___ECLASS_ONCE_FLAG_O_MATIC

games.eclass:
  ___ECLASS_ONCE_GAMES

kde4-base.eclass:
  ___ECLASS_ONCE_KDE4_BASE

kde4-functions.eclass:
  ___ECLASS_ONCE_KDE4_FUNCTIONS

kde4-meta.eclass:
  __list_needed_subdirectories()
  ___ECLASS_ONCE_KDE4_META

kde4-meta-pkg.eclass:
  ___ECLASS_ONCE_KDE4_META_PKG

libtool.eclass:
  __ELT_NOTED_TMP
  ___ECLASS_ONCE_LIBTOOL

multilib.eclass:
  __DEFAULT_ABI_SAVED
  ___ECLASS_ONCE_MULTILIB

multiprocessing.eclass:
  ___ECLASS_ONCE_MULTIPROCESSING

pam.eclass:
  ___ECLASS_ONCE_PAM

pax-utils.eclass:
  ___ECLASS_ONCE_PAX_UTILS

portability.eclass:
  ___ECLASS_ONCE_PORTABILITY

qmake-utils.eclass:
  ___ECLASS_ONCE_QMAKE_UTILS

readme.gentoo.eclass:
  ___ECLASS_ONCE_README_GENTOO

toolchain-funcs.eclass:
  ___ECLASS_ONCE_TOOLCHAIN_FUNCS
  __thread

unpacker.eclass:
  ___ECLASS_ONCE_UNPACKER

user.eclass:
  ___ECLASS_ONCE_USER

versionator.eclass:
  ___ECLASS_ONCE_VERSIONATOR


I suggest to change all ___ECLASS_ONCE_<eclassname> to _<eclassname> (already used e.g. in git-r3.eclass and python eclasses). All other names can be truncated to start with one underscore only.
Comment 1 Ulrich Müller gentoo-dev 2014-07-03 09:17:40 UTC
> I suggest to change all ___ECLASS_ONCE_<eclassname> to _<eclassname>

Let's make this _<eclassname>_ECLASS, in order to avoid names like _USER or _PAM which look a bit dangerous.
Comment 2 Ulrich Müller gentoo-dev 2014-07-11 08:22:54 UTC
Fixed.