summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan Cholasta <jcholast@redhat.com>2016-10-12 13:27:16 +0200
committerDavid Kupka <dkupka@redhat.com>2016-10-24 14:11:08 +0200
commit1077743d90902fc776f837f8486fa7f08b560673 (patch)
tree8ad4c741a946811ca87e57706128ef9eb25d845f
parent21395d1724e6bf044438a8bc25ba028ed38cde8c (diff)
downloadfreeipa-1077743d90902fc776f837f8486fa7f08b560673.tar.gz
freeipa-1077743d90902fc776f837f8486fa7f08b560673.tar.xz
freeipa-1077743d90902fc776f837f8486fa7f08b560673.zip
spec file: do not include BuildRequires for lint by default
Lint is never executed from rpmbuild, so the BuildRequires for lint are purely informational. Include them only if %with_lint RPM macro is specified. Update .travis.yml accordingly. https://fedorahosted.org/freeipa/ticket/6418 Reviewed-By: Petr Spacek <pspacek@redhat.com> Reviewed-By: Martin Basti <mbasti@redhat.com>
-rw-r--r--.travis.yml2
-rw-r--r--BUILD.txt2
-rw-r--r--freeipa.spec.in5
3 files changed, 7 insertions, 2 deletions
diff --git a/.travis.yml b/.travis.yml
index f221e820a..d95eb25db 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -13,4 +13,4 @@ script:
- >
docker run -v $PWD:/freeipa -w /freeipa
martbab/freeipa-fedora-builder:${TRAVIS_BRANCH}-latest
- /bin/bash -c 'dnf builddep -y --spec freeipa.spec.in && make rpms'
+ /bin/bash -c 'dnf builddep -y -D "with_lint 1" --spec freeipa.spec.in && make rpms'
diff --git a/BUILD.txt b/BUILD.txt
index b5660aacc..10faa6fff 100644
--- a/BUILD.txt
+++ b/BUILD.txt
@@ -7,7 +7,7 @@ For more information, see http://www.freeipa.org/page/Build
The quickest way to get the dependencies needed for building is:
-# dnf builddep -b --spec freeipa.spec.in
+# dnf builddep -b -D "with_lint 1" --spec freeipa.spec.in
or
diff --git a/freeipa.spec.in b/freeipa.spec.in
index 2dfe9da57..c730b325b 100644
--- a/freeipa.spec.in
+++ b/freeipa.spec.in
@@ -8,6 +8,9 @@
%global with_python3 1
%endif
+# lint is not executed during rpmbuild
+# %global with_lint 1
+
%global alt_name ipa
%if 0%{?rhel}
%global samba_version 4.0.5-1
@@ -108,6 +111,7 @@ BuildRequires: python-cffi
#
# Build dependencies for lint
#
+%if 0%{?with_lint}
BuildRequires: samba-python
BuildRequires: pylint >= 1.0
# workaround for https://bugzilla.redhat.com/show_bug.cgi?id=1096506
@@ -131,6 +135,7 @@ BuildRequires: python-sssdconfig
BuildRequires: python-nose
BuildRequires: python-paste
BuildRequires: systemd-python
+%endif # with_lint
#
# Build dependencies for unit tests