makepkg: provide environment variable to disable PKGBUILD linting
On Windows based systems (e.g. msys), running PKGBUILD linting is very slow due to time taken spawning bash subshells. Additionally, some packages have extreme amounts of (usually procedurally generated) splitting, which also causes linting to be extremely slow. Provide an environment variable to disable PKGBUILD linting. Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
44b9a53b2d
commit
b013ca4221
2 changed files with 10 additions and 1 deletions
|
@ -297,6 +297,11 @@ Environment Variables
|
||||||
**BUILDTOOLVER=**"<version>"::
|
**BUILDTOOLVER=**"<version>"::
|
||||||
The version of the '$BUILDTOOL' used.
|
The version of the '$BUILDTOOL' used.
|
||||||
|
|
||||||
|
**MAKEPKG_LINT_PKGBUILD=**0
|
||||||
|
Setting to 0 disables PKGBUILD linting within makepkg. Useful on systems
|
||||||
|
with slow bash subshell operations, or on PKGBUILDs with extreme amounts of
|
||||||
|
package splitting.
|
||||||
|
|
||||||
|
|
||||||
Configuration
|
Configuration
|
||||||
-------------
|
-------------
|
||||||
|
|
|
@ -87,6 +87,8 @@ else
|
||||||
fi
|
fi
|
||||||
export SOURCE_DATE_EPOCH
|
export SOURCE_DATE_EPOCH
|
||||||
|
|
||||||
|
MAKEPKG_LINT_PKGBUILD=${MAKEPKG_LINT_PKGBUILD:-1}
|
||||||
|
|
||||||
PACMAN_OPTS=()
|
PACMAN_OPTS=()
|
||||||
|
|
||||||
shopt -s extglob
|
shopt -s extglob
|
||||||
|
@ -1151,7 +1153,9 @@ fi
|
||||||
pkgbase=${pkgbase:-${pkgname[0]}}
|
pkgbase=${pkgbase:-${pkgname[0]}}
|
||||||
|
|
||||||
# check the PKGBUILD for some basic requirements
|
# check the PKGBUILD for some basic requirements
|
||||||
|
if (( MAKEPKG_LINT_PKGBUILD != 0 )); then
|
||||||
lint_pkgbuild || exit $E_PKGBUILD_ERROR
|
lint_pkgbuild || exit $E_PKGBUILD_ERROR
|
||||||
|
fi
|
||||||
|
|
||||||
if (( !SOURCEONLY && !PRINTSRCINFO )); then
|
if (( !SOURCEONLY && !PRINTSRCINFO )); then
|
||||||
merge_arch_attrs
|
merge_arch_attrs
|
||||||
|
|
Loading…
Add table
Reference in a new issue