From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: Adam Duskett <aduskett@gmail.com>
Cc: Marcus Folkesson <marcus.folkesson@gmail.com>,
Antoine Tenart <atenart@kernel.org>,
Asaf Kahlon <asafka7@gmail.com>,
Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
buildroot@buildroot.org,
Fabrice Fontaine <fontaine.fabrice@gmail.com>
Subject: Re: [Buildroot] [PATCH v2 05/13] package/libselinux: bump to version 3.5
Date: Tue, 9 May 2023 23:02:56 +0200 [thread overview]
Message-ID: <20230509210256.GF252090@scaer> (raw)
In-Reply-To: <20230425171454.48802-6-aduskett@gmail.com>
Adam, All,
On 2023-04-25 10:14 -0700, Adam Duskett spake thusly:
> - libselinux now requires pip to install the python tools.
I extended that to explain that is really is just about the
installation, while the build is still performed with setuptools.
Also, that python bindings, not python tools; python tools have their
own dedicated pachage.selinux-python (which you update in a follow-up
patch).
> - Rebase patches for version 3.5
I also backported an upstream patch to fix intsallation of the python
bindings.
Applied to master, thanks.
Regards,
Yann E. MORIN.
> Signed-off-by: Adam Duskett <aduskett@gmail.com>
> ---
> package/libselinux/0001-fix-musl-build.patch | 4 ++--
> ...CEXT-and-rely-on-the-installed-file-nam.patch | 8 ++++----
> package/libselinux/Config.in | 1 +
> package/libselinux/libselinux.hash | 2 +-
> package/libselinux/libselinux.mk | 16 +++++++++++++---
> 5 files changed, 21 insertions(+), 10 deletions(-)
>
> diff --git a/package/libselinux/0001-fix-musl-build.patch b/package/libselinux/0001-fix-musl-build.patch
> index 44189e6400..b8b16be26f 100644
> --- a/package/libselinux/0001-fix-musl-build.patch
> +++ b/package/libselinux/0001-fix-musl-build.patch
> @@ -12,13 +12,13 @@ Domain, and we want to avoid license propagation, so this macro is
> completely written from scratch, and non-optimal.
>
> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
> -[Updated for 3.0]
> +[Updated for 3.5]
> Signed-off-by: Adam Duskett <Aduskett@gmail.com>
> diff --git a/src/booleans.c b/src/booleans.c
> index ffa8d26..8569002 100644
> --- a/src/booleans.c
> +++ b/src/booleans.c
> -@@ -65,6 +65,14 @@ int security_get_boolean_names(char ***names, int *len)
> +@@ -64,6 +64,14 @@ int security_get_boolean_names(char ***names, int *len)
> goto bad;
> }
>
> diff --git a/package/libselinux/0002-Do-not-use-PYCEXT-and-rely-on-the-installed-file-nam.patch b/package/libselinux/0002-Do-not-use-PYCEXT-and-rely-on-the-installed-file-nam.patch
> index 18c79b3b4d..c744ca4069 100644
> --- a/package/libselinux/0002-Do-not-use-PYCEXT-and-rely-on-the-installed-file-nam.patch
> +++ b/package/libselinux/0002-Do-not-use-PYCEXT-and-rely-on-the-installed-file-nam.patch
> @@ -18,7 +18,7 @@ was installed.
> Signed-off-by: Antoine Tenart <antoine.tenart@bootlin.com>
> [Refreshed for 3.1]
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> -[Refreshed for 3.0]
> +[Refreshed for 3.5]
> Signed-off-by: Adam Duskett <Aduskett@gmail.com>
> ---
> src/Makefile | 3 +--
> @@ -31,14 +31,14 @@ index 190016e2af34..7ee22fd35da3 100644
> @@ -15,7 +15,6 @@ INCLUDEDIR ?= $(PREFIX)/include
> PYINC ?= $(shell $(PKG_CONFIG) --cflags $(PYPREFIX))
> PYLIBS ?= $(shell $(PKG_CONFIG) --libs $(PYPREFIX))
> - PYTHONLIBDIR ?= $(shell $(PYTHON) -c "from distutils.sysconfig import *; print(get_python_lib(plat_specific=1, prefix='$(PREFIX)'))")
> + PYTHONLIBDIR ?= $(shell $(PYTHON) -c "import sysconfig; print(sysconfig.get_path('platlib', vars={'platbase': '$(PREFIX)', 'base': '$(PREFIX)'}))")
> -PYCEXT ?= $(shell $(PYTHON) -c 'import importlib.machinery;print(importlib.machinery.EXTENSION_SUFFIXES[0])')
> RUBYINC ?= $(shell $(RUBY) -e 'puts "-I" + RbConfig::CONFIG["rubyarchhdrdir"] + " -I" + RbConfig::CONFIG["rubyhdrdir"]')
> RUBYLIBS ?= $(shell $(RUBY) -e 'puts "-L" + RbConfig::CONFIG["libdir"] + " -L" + RbConfig::CONFIG["archlibdir"] + " " + RbConfig::CONFIG["LIBRUBYARG_SHARED"]')
> RUBYINSTALL ?= $(shell $(RUBY) -e 'puts RbConfig::CONFIG["vendorarchdir"]')
> -@@ -184,7 +183,7 @@ install: all
> +@@ -189,7 +188,7 @@ install: all
> install-pywrap: pywrap
> - $(PYTHON) setup.py install --prefix=$(PREFIX) `test -n "$(DESTDIR)" && echo --root $(DESTDIR)` $(PYTHON_SETUP_ARGS)
> + $(PYTHON) -m pip install --prefix=$(PREFIX) `test -n "$(DESTDIR)" && echo --root $(DESTDIR) --ignore-installed --no-deps` $(PYTHON_SETUP_ARGS) .
> install -m 644 $(SWIGPYOUT) $(DESTDIR)$(PYTHONLIBDIR)/selinux/__init__.py
> - ln -sf --relative $(DESTDIR)$(PYTHONLIBDIR)/selinux/_selinux$(PYCEXT) $(DESTDIR)$(PYTHONLIBDIR)/_selinux$(PYCEXT)
> + ln -sf --relative $(DESTDIR)$(PYTHONLIBDIR)/selinux/_selinux*.so $(DESTDIR)$(PYTHONLIBDIR)/
> diff --git a/package/libselinux/Config.in b/package/libselinux/Config.in
> index 3098fe3ea4..bc40e32a46 100644
> --- a/package/libselinux/Config.in
> +++ b/package/libselinux/Config.in
> @@ -6,6 +6,7 @@ config BR2_PACKAGE_LIBSELINUX
> select BR2_PACKAGE_LIBSEPOL
> select BR2_PACKAGE_PCRE2
> select BR2_PACKAGE_MUSL_FTS if !BR2_TOOLCHAIN_USES_GLIBC
> + select BR2_PACKAGE_PYTHON_SETUPTOOLS if BR2_PACKAGE_PYTHON3
> help
> libselinux is the runtime SELinux library that provides
> interfaces (e.g. library functions for the SELinux kernel
> diff --git a/package/libselinux/libselinux.hash b/package/libselinux/libselinux.hash
> index a2e0083f7b..14bc627a80 100644
> --- a/package/libselinux/libselinux.hash
> +++ b/package/libselinux/libselinux.hash
> @@ -1,5 +1,5 @@
> # From: https://github.com/SELinuxProject/selinux/wiki/Releases
> -sha256 acfdee27633d2496508c28727c3d41d3748076f66d42fccde2e6b9f3463a7057 libselinux-3.3.tar.gz
> +sha256 9a3a3705ac13a2ccca2de6d652b6356fead10f36fb33115c185c5ccdf29eec19 libselinux-3.5.tar.gz
>
> # Hash for license file
> sha256 86657b4c0fe868d7cbd977cb04c63b6c667e08fa51595a7bc846ad4bed8fc364 LICENSE
> diff --git a/package/libselinux/libselinux.mk b/package/libselinux/libselinux.mk
> index db35da130f..b8de21edaa 100644
> --- a/package/libselinux/libselinux.mk
> +++ b/package/libselinux/libselinux.mk
> @@ -4,7 +4,7 @@
> #
> ################################################################################
>
> -LIBSELINUX_VERSION = 3.3
> +LIBSELINUX_VERSION = 3.5
> LIBSELINUX_SITE = https://github.com/SELinuxProject/selinux/releases/download/$(LIBSELINUX_VERSION)
> LIBSELINUX_LICENSE = Public Domain
> LIBSELINUX_LICENSE_FILES = LICENSE
> @@ -31,7 +31,11 @@ LIBSELINUX_MAKE_OPTS += FTS_LDLIBS=-lfts
> endif
>
> ifeq ($(BR2_PACKAGE_PYTHON3),y)
> -LIBSELINUX_DEPENDENCIES += python3 host-swig
> +LIBSELINUX_DEPENDENCIES += \
> + python3 \
> + python-setuptools \
> + host-python-pip \
> + host-swig
>
> LIBSELINUX_MAKE_OPTS += \
> $(PKG_PYTHON_DISTUTILS_ENV) \
> @@ -77,7 +81,13 @@ define LIBSELINUX_INSTALL_TARGET_CMDS
> endef
>
> HOST_LIBSELINUX_DEPENDENCIES = \
> - host-pkgconf host-libsepol host-pcre2 host-swig host-python3
> + host-pkgconf \
> + host-libsepol \
> + host-pcre2 \
> + host-swig \
> + host-python3 \
> + host-python-pip \
> + host-python-setuptools
>
> HOST_LIBSELINUX_MAKE_OPTS = \
> $(HOST_CONFIGURE_OPTS) \
> --
> 2.40.0
>
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2023-05-09 21:03 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-25 17:14 [Buildroot] [PATCH v2 00/13] Selinux: bump to 3.5 Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 01/13] package/libglib2/0003-disable-building-docs.patch: new patch Adam Duskett
2023-04-25 21:03 ` Peter Seiderer
2023-04-28 1:44 ` James Knight
2023-05-09 19:43 ` Yann E. MORIN
2023-04-25 17:14 ` [Buildroot] [PATCH v2 02/13] package/python-pip: add host variant Adam Duskett
2023-05-09 21:00 ` Yann E. MORIN
2023-06-12 15:52 ` Peter Korsgaard
2023-06-12 17:54 ` Yann E. MORIN
2023-06-12 19:28 ` Peter Korsgaard
2023-04-25 17:14 ` [Buildroot] [PATCH v2 03/13] package/libsepol: bump to version 3.5 Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 04/13] package/libsemanage: " Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 05/13] package/libselinux: " Adam Duskett
2023-05-09 21:02 ` Yann E. MORIN [this message]
2023-04-25 17:14 ` [Buildroot] [PATCH v2 06/13] package/policycoreutils: " Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 07/13] package/checkpolicy: " Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 08/13] package/restorecond: " Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 09/13] package/semodule-utils: " Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 10/13] package/audit: bump to version 3.1 Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 11/13] package/selinux-python: bump to version 3.5 Adam Duskett
2023-05-09 21:05 ` Yann E. MORIN
2023-04-25 17:14 ` [Buildroot] [PATCH v2 12/13] package/setools: bump to version 4.4.2 Adam Duskett
2023-04-25 17:14 ` [Buildroot] [PATCH v2 13/13] package/refpolicy: bump to version 2.20221101 Adam Duskett
2023-05-09 21:06 ` Yann E. MORIN
2023-05-09 21:00 ` [Buildroot] [PATCH v2 00/13] Selinux: bump to 3.5 Yann E. MORIN
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=20230509210256.GF252090@scaer \
--to=yann.morin.1998@free.fr \
--cc=aduskett@gmail.com \
--cc=asafka7@gmail.com \
--cc=atenart@kernel.org \
--cc=buildroot@buildroot.org \
--cc=fontaine.fabrice@gmail.com \
--cc=marcus.folkesson@gmail.com \
--cc=thomas.petazzoni@bootlin.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