<commit_before># Copyright (C) 2012 Tresys Technology, LLC
#
# Authors: <NAME> <<EMAIL>>
#

# The name of the package
PKGNAME := clip-selinux-policy

# These two are typically set by the top-level CONFIG_BUILD file.
BUILD_CONFIG_ENFORCING_MODE ?= y
BUILD_CONFIG_TOOR ?= n

# This is the version number of the RPM that will be
# generated.  Typically you bump this for delivery.
VERSION := 6.2.0

# bump this if creating multiple releases from the same
# version (think about this... why are you doing this?)
RELEASE := 1

# The name of the Vendor
VENDOR := Tresys Technology, LLC

# The name of the Packager
PACKAGER ?= Tresys Technology, LLC

# snag the architecture, hard code an arch if cross-compiling or going noarch
ARCH ?= noarch

# the filename of the tarball
TARBALL = $(SRPM_OUTPUT_DIR)/$(PKGNAME)-$(VERSION).tar.gz

# spec file name
RPM_SPEC = $(CURDIR)/$(PKGNAME).spec

####################################################
## things below this line should rarely change
ROOT_DIR ?= $(CURDIR)
OUTPUT_DIR ?= $(ROOT_DIR)
SRPM_OUTPUT_DIR ?= $(OUTPUT_DIR)

# exhaustive list of deps for the RPM, used to determine if RPM needs to be rebuilt
TAR_DEPS := $(shell find $(PKGNAME)/)
RPM_DEPS := $(TARBALL) $(RPM_SPEC) $(CURDIR)/Makefile

RPM_TMPDIR ?= $(ROOT_DIR)/tmp
RPM_TOPDIR ?= $(RPM_TMPDIR)/src/redhat
RPM_BUILDROOT ?= $(RPM_TMPDIR)/rpm-buildroot

MKDIR = test -d $(1) || mkdir -p $(1)

RPMBUILD_ARGS := --define '_topdir $(RPM_TOPDIR)'  --define '_tmppath $(RPM_TMPDIR)' --buildroot $(RPM_BUILDROOT)

define rpm-prep
	$(call MKDIR,$(RPM_TOPDIR)/SOURCES)
	$(call MKDIR,$(RPM_TOPDIR)/SPECS)
	$(call MKDIR,$(RPM_TOPDIR)/BUILD)
	$(call MKDIR,$(RPM_TOPDIR)/RPMS/$(ARCH))
	$(call MKDIR,$(RPM_TOPDIR)/SRPMS)
endef


# Note: due to remediation content, overriding this may not work the way you expect.
# Look at the bottom of the stock clip-rhel6--ks %post for an example.
ifneq ($(CONFIG_BUILD_ENFORCING_MODE),n)
	ENFORCING_MODE := enforcing
else
	ENFORCING_MODE := permissive
endif
ifneq ($(CONFIG_BUILD_UNCONFINED_TOOR),n)
	ENABLE_MODULES := toor
else
	ENABLE_MODULES := %{nil}
endif
ENABLE_MODULES := toor

RPMQ_DEFS := --query --define 'pkgname $(PKGNAME)' --define '_sysconfdir /etc' --define 'version $(VERSION)' --define 'release $(RELEASE)' --define 'vendor $(VENDOR)' --define 'packager $(PACKAGER)' --qf '%{NAME}\n'

ifneq ($(ENABLE_MODULES),)
RPM_DEFS := --define 'enable_modules $(ENABLE_MODULES)' $(RPM_DEFS)
endif<commit_msg>Stop forcing unconfined toor in policy Makefile.<commit_after># Copyright (C) 2012 Tresys Technology, LLC
#
# Authors: <NAME> <<EMAIL>>
#

# The name of the package
PKGNAME := clip-selinux-policy

# These two are typically set by the top-level CONFIG_BUILD file.
BUILD_CONFIG_ENFORCING_MODE ?= y
BUILD_CONFIG_TOOR ?= n

# This is the version number of the RPM that will be
# generated.  Typically you bump this for delivery.
VERSION := 6.2.0

# bump this if creating multiple releases from the same
# version (think about this... why are you doing this?)
RELEASE := 1

# The name of the Vendor
VENDOR := Tresys Technology, LLC

# The name of the Packager
PACKAGER ?= Tresys Technology, LLC

# snag the architecture, hard code an arch if cross-compiling or going noarch
ARCH ?= noarch

# the filename of the tarball
TARBALL = $(SRPM_OUTPUT_DIR)/$(PKGNAME)-$(VERSION).tar.gz

# spec file name
RPM_SPEC = $(CURDIR)/$(PKGNAME).spec

####################################################
## things below this line should rarely change
ROOT_DIR ?= $(CURDIR)
OUTPUT_DIR ?= $(ROOT_DIR)
SRPM_OUTPUT_DIR ?= $(OUTPUT_DIR)

# exhaustive list of deps for the RPM, used to determine if RPM needs to be rebuilt
TAR_DEPS := $(shell find $(PKGNAME)/)
RPM_DEPS := $(TARBALL) $(RPM_SPEC) $(CURDIR)/Makefile

RPM_TMPDIR ?= $(ROOT_DIR)/tmp
RPM_TOPDIR ?= $(RPM_TMPDIR)/src/redhat
RPM_BUILDROOT ?= $(RPM_TMPDIR)/rpm-buildroot

MKDIR = test -d $(1) || mkdir -p $(1)

RPMBUILD_ARGS := --define '_topdir $(RPM_TOPDIR)'  --define '_tmppath $(RPM_TMPDIR)' --buildroot $(RPM_BUILDROOT)

define rpm-prep
	$(call MKDIR,$(RPM_TOPDIR)/SOURCES)
	$(call MKDIR,$(RPM_TOPDIR)/SPECS)
	$(call MKDIR,$(RPM_TOPDIR)/BUILD)
	$(call MKDIR,$(RPM_TOPDIR)/RPMS/$(ARCH))
	$(call MKDIR,$(RPM_TOPDIR)/SRPMS)
endef


# Note: due to remediation content, overriding this may not work the way you expect.
# Look at the bottom of the stock clip-rhel6--ks %post for an example.
ifneq ($(CONFIG_BUILD_ENFORCING_MODE),n)
	ENFORCING_MODE := enforcing
else
	ENFORCING_MODE := permissive
endif
ifneq ($(CONFIG_BUILD_UNCONFINED_TOOR),n)
	ENABLE_MODULES := toor
else
	ENABLE_MODULES := %{nil}
endif

RPMQ_DEFS := --query --define 'pkgname $(PKGNAME)' --define '_sysconfdir /etc' --define 'version $(VERSION)' --define 'release $(RELEASE)' --define 'vendor $(VENDOR)' --define 'packager $(PACKAGER)' --qf '%{NAME}\n'

ifneq ($(ENABLE_MODULES),)
RPM_DEFS := --define 'enable_modules $(ENABLE_MODULES)' $(RPM_DEFS)
endif
{'fraction_non_alphanumeric': 0.15467919901920718, 'fraction_numerical': 0.004495300367797303, 'mean_word_length': 5.050679851668727, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6944215', 'n_tokens_mistral': 1777, 'n_tokens_neox': 1745, 'n_words': 525}