Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 704878 - sys-libs/libapparmor-2.13.3 - add python3_7 python3_8 support, LICENSE change, EAPI=7
Summary: sys-libs/libapparmor-2.13.3 - add python3_7 python3_8 support, LICENSE change...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Michael Palimaka (kensington)
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2020-01-06 17:33 UTC by Jason Chan
Modified: 2020-01-20 10:24 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (libapparmor-2.13.3_build.log,63.09 KB, text/plain)
2020-01-06 17:39 UTC, Jason Chan
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Chan 2020-01-06 17:33:04 UTC
I've added 3_7 and 3_8 to the ebuild and passed the tests. The problem occurring with the test is that it requires the package to have already been installed; the ebuild environment isn't able to detect the LibAppArmor module otherwise.

libapparmor-2.13.3.ebuild
Proposed ebuild changes: Update EAPI to 7 and add additional license according to https://launchpad.net/apparmor/
---
@@ -1,13 +1,13 @@
 # Copyright 1999-2019 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=6
+EAPI=7
 
 DISTUTILS_OPTIONAL=1
-PYTHON_COMPAT=( python{2_7,3_5,3_6} )
+PYTHON_COMPAT=( python2_7 python3_{5,6,7,8} )
 GENTOO_DEPEND_ON_PERL="no"
 
-inherit autotools distutils-r1 eapi7-ver perl-functions
+inherit autotools distutils-r1 perl-functions
 
 MY_PV="$(ver_cut 1-2)"
 
@@ -15,7 +15,7 @@ DESCRIPTION="Library to support AppArmor
 HOMEPAGE="https://gitlab.com/apparmor/apparmor/wikis/home"
 SRC_URI="https://launchpad.net/apparmor/${MY_PV}/${PV}/+download/apparmor-${PV}.tar.gz"
 
-LICENSE="LGPL-2.1"
+LICENSE="GPL-2 LGPL-2.1"
 SLOT="0"
 KEYWORDS="amd64 ~arm ~arm64 ~x86"
 IUSE="doc +perl +python static-libs"
---

When trying to test without having it already installed, I've tried adding the LibAppArmor.py to path to get the test running but I ran into 'ImportError: attempted relative import with no known parent package' when it tries to import _LibAppArmor.

For reference, the test_python.py that fails is in ${S}/libraries/libapparmor/swig/python/test and the module is in ${S}/libraries/libapparmor/swig/python. Identical LibAppArmor.py files are in ${S}libraries/libapparmor-python{whatever-you-chose}/lib/LibAppArmor.


Reproducible: Always

Steps to Reproduce:
The problem with the test is unrelated to the issue.
Comment 1 Jason Chan 2020-01-06 17:39:11 UTC
Created attachment 602664 [details]
build.log
Comment 2 Ulrich Müller gentoo-dev 2020-01-06 19:24:26 UTC
(In reply to Jason Chan from comment #0)
> -LICENSE="LGPL-2.1"
> +LICENSE="GPL-2 LGPL-2.1"

<licenses team>
Looks good to me. This is what README.md says, and a random sample of files headers confirms it.

Also, this is really GPL version 2 only and LGPL version 2.1 only, without the "or later" clause.
</licenses team>
Comment 3 Larry the Git Cow gentoo-dev 2020-01-20 10:23:50 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3aff69cf5a9cb540cfde8a3617774b93a676d319

commit 3aff69cf5a9cb540cfde8a3617774b93a676d319
Author:     Michael Palimaka <kensington@gentoo.org>
AuthorDate: 2020-01-20 10:18:25 +0000
Commit:     Michael Palimaka <kensington@gentoo.org>
CommitDate: 2020-01-20 10:22:53 +0000

    sys-libs/libapparmor: bump EAPI, python compat, and LICENSE fix
    
    Closes: https://bugs.gentoo.org/704878
    Thanks-to: Jason Chan <graysonchsi@gmail.com>
    Package-Manager: Portage-2.3.84, Repoman-2.3.20
    Signed-off-by: Michael Palimaka <kensington@gentoo.org>

 sys-libs/libapparmor/libapparmor-2.13.3-r1.ebuild | 98 +++++++++++++++++++++++
 1 file changed, 98 insertions(+)
Comment 4 Michael Palimaka (kensington) gentoo-dev 2020-01-20 10:24:18 UTC
Thanks a lot!