mirror of
https://github.com/flatcar/scripts.git
synced 2025-08-15 17:06:58 +02:00
eclass/prefix: Sync with gentoo
It's from gentoo commit 448a97d25a56d8c3e23666aa8f74eaaa77560d86.
This commit is contained in:
parent
1b5ce589f9
commit
c9b5f89903
@ -1,16 +1,25 @@
|
|||||||
# Copyright 1999-2017 Gentoo Foundation
|
# Copyright 1999-2021 Gentoo Authors
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
# @ECLASS: prefix.eclass
|
# @ECLASS: prefix.eclass
|
||||||
# @MAINTAINER:
|
# @MAINTAINER:
|
||||||
# Feel free to contact the Prefix team through <prefix@gentoo.org> if
|
# Feel free to contact the Prefix team through <prefix@gentoo.org> if
|
||||||
# you have problems, suggestions or questions.
|
# you have problems, suggestions or questions.
|
||||||
|
# @SUPPORTED_EAPIS: 5 6 7 8
|
||||||
# @BLURB: Eclass to provide Prefix functionality
|
# @BLURB: Eclass to provide Prefix functionality
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
# Gentoo Prefix allows users to install into a self defined offset
|
# Gentoo Prefix allows users to install into a self defined offset
|
||||||
# located somewhere in the filesystem. Prefix ebuilds require
|
# located somewhere in the filesystem. Prefix ebuilds require
|
||||||
# additional functions and variables which are defined by this eclass.
|
# additional functions and variables which are defined by this eclass.
|
||||||
|
|
||||||
|
case ${EAPI:-0} in
|
||||||
|
[5678]) ;;
|
||||||
|
*) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${_PREFIX_ECLASS} ]]; then
|
||||||
|
_PREFIX_ECLASS=1
|
||||||
|
|
||||||
# @ECLASS-VARIABLE: EPREFIX
|
# @ECLASS-VARIABLE: EPREFIX
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
# The offset prefix of a Gentoo Prefix installation. When Gentoo Prefix
|
# The offset prefix of a Gentoo Prefix installation. When Gentoo Prefix
|
||||||
@ -111,7 +120,7 @@ hprefixify() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
# @FUNCTION: prefixify_ro
|
# @FUNCTION: prefixify_ro
|
||||||
# @USAGE: prefixify_ro <file>.
|
# @USAGE: <file>
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
# prefixify a read-only file.
|
# prefixify a read-only file.
|
||||||
# copies the files to ${T}, prefixies it, echos the new file.
|
# copies the files to ${T}, prefixies it, echos the new file.
|
||||||
@ -136,3 +145,5 @@ prefixify_ro() {
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
# vim: tw=72:
|
# vim: tw=72:
|
||||||
|
|
||||||
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user