mirror of
https://gitlab.freedesktop.org/upower/power-profiles-daemon.git
synced 2026-05-09 02:28:17 +02:00
build: Make pylint test optional
As power-profiles-daemon keeps getting built with slightly different versions of pylint with newer warnings, disable pylint test by default to avoid getting bug reports about it. Closes: #52
This commit is contained in:
parent
ea3faa1eab
commit
f83685732b
4 changed files with 10 additions and 4 deletions
|
|
@ -22,7 +22,7 @@ build_stable:
|
|||
- dnf upgrade -y --nogpgcheck fedora-release fedora-repos*
|
||||
- dnf update -y && dnf install -y $DEPENDENCIES
|
||||
script:
|
||||
- meson -Dgtk_doc=true _build
|
||||
- meson -Dgtk_doc=true -Dpylint=true _build
|
||||
- ninja -v -C _build
|
||||
- ninja -v -C _build install
|
||||
- ninja -v -C _build uninstall
|
||||
|
|
|
|||
|
|
@ -42,8 +42,10 @@ gnome = import('gnome')
|
|||
add_global_arguments('-D_GNU_SOURCE=1', language: 'c')
|
||||
add_global_arguments(common_cflags, language: 'c')
|
||||
|
||||
pylint = find_program('pylint-3', 'pylint3', 'pylint', required: false)
|
||||
pylint_flags = ['-d', 'C0116', '-d', 'C0114', '-d', 'W0707']
|
||||
if get_option('pylint')
|
||||
pylint = find_program('pylint-3', 'pylint3', 'pylint', required: true)
|
||||
pylint_flags = ['-d', 'C0116', '-d', 'C0114', '-d', 'W0707']
|
||||
endif
|
||||
xmllint = find_program('xmllint', required: false)
|
||||
|
||||
subdir('src')
|
||||
|
|
|
|||
|
|
@ -6,3 +6,7 @@ option('gtk_doc',
|
|||
type: 'boolean',
|
||||
value: false,
|
||||
description: 'Build docs')
|
||||
option('pylint',
|
||||
type: 'boolean',
|
||||
value: false,
|
||||
description: 'Run pylint checks, for developers only')
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ script = configure_file(
|
|||
install_dir: get_option('bindir')
|
||||
)
|
||||
|
||||
if pylint.found()
|
||||
if get_option('pylint')
|
||||
test('pylint-powerprofilesctl',
|
||||
pylint,
|
||||
args: pylint_flags + [ script ],
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue