selinux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ondrej Mosnacek <omosnace@redhat.com>
To: selinux@vger.kernel.org
Cc: Stephen Smalley <stephen.smalley.work@gmail.com>
Subject: [PATCH testsuite] travis: fix `make conf` invocation
Date: Fri, 26 Jun 2020 13:43:59 +0200	[thread overview]
Message-ID: <20200626114359.80134-1-omosnace@redhat.com> (raw)

In refpolicy when a module is added/removed, the policy build config
may need to be rebuilt. Currently we run `make conf` just once and then
reuse it via cache. Instead, we need to run it unconditionally, since
the other targets won't trigger that implictly.

In Fedora policy the default module config is included and maintained in
git, so we don't need to (and must not) call make conf at all.

Reported-by: Stephen Smalley <stephen.smalley.work@gmail.com>
Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
---
 travis-ci/setup-policy-fedora.sh    | 2 --
 travis-ci/setup-policy-refpolicy.sh | 2 +-
 2 files changed, 1 insertion(+), 3 deletions(-)

diff --git a/travis-ci/setup-policy-fedora.sh b/travis-ci/setup-policy-fedora.sh
index bce8698..a07c990 100644
--- a/travis-ci/setup-policy-fedora.sh
+++ b/travis-ci/setup-policy-fedora.sh
@@ -26,8 +26,6 @@ cd selinux-policy
 
 grep -q refpolicy build.conf && sed -i 's/refpolicy/targeted/' build.conf
 
-[ -f policy/modules.conf ] || make conf
-
 make -j`nproc --all` BINDIR=/usr/local/bin SBINDIR=/usr/local/sbin
 sudo make install install-headers
 
diff --git a/travis-ci/setup-policy-refpolicy.sh b/travis-ci/setup-policy-refpolicy.sh
index 3010467..d63e7e4 100644
--- a/travis-ci/setup-policy-refpolicy.sh
+++ b/travis-ci/setup-policy-refpolicy.sh
@@ -12,7 +12,7 @@ cd refpolicy
 
 git checkout origin/master
 
-[ -f policy/modules.conf ] || make conf
+make conf
 
 make -j`nproc --all` BINDIR=/usr/local/bin SBINDIR=/usr/local/sbin
 sudo make install install-headers
-- 
2.26.2


             reply	other threads:[~2020-06-26 11:44 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-26 11:43 Ondrej Mosnacek [this message]
2020-06-26 12:49 ` [PATCH testsuite] travis: fix `make conf` invocation Stephen Smalley
2020-06-29  8:31   ` Ondrej Mosnacek
2020-06-29 12:37   ` Ondrej Mosnacek
2020-06-29 19:13   ` Ondrej Mosnacek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200626114359.80134-1-omosnace@redhat.com \
    --to=omosnace@redhat.com \
    --cc=selinux@vger.kernel.org \
    --cc=stephen.smalley.work@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).