Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 629516 - app-portage/gs-pypi-0.2.1-r1:files installed outside the prefix
Summary: app-portage/gs-pypi-0.2.1-r1:files installed outside the prefix
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard: Pending removal: 2018-12-11
Keywords: PMASKED
Depends on:
Blocks:
 
Reported: 2017-09-01 02:54 UTC by tastu teche
Modified: 2018-12-11 13:35 UTC (History)
1 user (show)

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


Attachments
0.2.1-data_files.patch (0.2.1-data_files.patch,945 bytes, patch)
2017-09-01 02:55 UTC, tastu teche
Details | Diff
gs-pypi-0.2.1-r1.ebuild with 0.2.1-data_files.patch added (gs-pypi-0.2.1-r1.ebuild,745 bytes, text/plain)
2017-09-01 02:57 UTC, tastu teche
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tastu teche 2017-09-01 02:54:20 UTC
* QA Notice: the following files are outside of the prefix:
 * /etc
 * /etc/layman
 * /etc/layman/overlays
 * /etc/layman/overlays/gs-pypi-overlays.xml
 * /etc/g-sorcery
 * /etc/g-sorcery/gs-pypi.json
 * ERROR: app-portage/gs-pypi-0.2.1-r1::gentoo failed:
 *   Aborting due to QA concerns: there are files installed outside the prefix
 * 
 * Call stack:
 *   misc-functions.sh, line 603:  Called install_qa_check
 *   misc-functions.sh, line 217:  Called source 'install_symlink_html_docs'
 *            05prefix, line 114:  Called install_qa_check_prefix
 *            05prefix, line  27:  Called die
 * The specific snippet of code:
 *   			die "Aborting due to QA concerns: there are files installed outside the prefix"

my fix:
(1) 0.2.1-data_files.patch
--- a/setup.py
+++ b/setup.py
@@ -21,7 +21,7 @@
       packages      = ['gs_pypi'],
       package_data  = {'gs_pypi': ['data/*']},
       scripts       = ['bin/gs-pypi-generate-db', 'bin/gs-pypi'],
-      data_files    = [('/etc/g-sorcery/', ['gs-pypi.json']),
-                       ('/etc/layman/overlays/', ['gs-pypi-overlays.xml'])],
+      data_files    = [('@GENTOO_PORTAGE_EPREFIX@/etc/g-sorcery/', ['gs-pypi.json']),
+                       ('@GENTOO_PORTAGE_EPREFIX@/etc/layman/overlays/', ['gs-pypi-overlays.xml'])],
       license       = 'GPL-2',
       )

--- a/gs_pypi/gs_pypi_generate_db.py
+++ b/gs_pypi/gs_pypi_generate_db.py
@@ -43,7 +43,7 @@
 
     logger = Logger()
     cfg_path = None
-    for path in '.', '~', '/etc/g-sorcery':
+    for path in '.', '~', '@GENTOO_PORTAGE_EPREFIX@/etc/g-sorcery':
         current = os.path.join(path, "gs-pypi.json")
         if (os.path.isfile(current)):
             cfg_path = path
(2)gs-pypi-0.2.1-r1.ebuild
--- /r/a/p/usr/portage/app-portage/gs-pypi/gs-pypi-0.2.1-r1.ebuild
+++ /r/a/p/usr/local/portage/app-portage/gs-pypi/gs-pypi-0.2.1-r1.ebuild
@@ -1,11 +1,11 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
 
 PYTHON_COMPAT=(python{2_7,3_4,3_5})
 
-inherit distutils-r1
+inherit distutils-r1 prefix
 
 DESCRIPTION="g-sorcery backend for pypi packages"
 HOMEPAGE="https://github.com/jauhien/gs-pypi"
@@ -19,6 +19,13 @@
 	dev-python/beautifulsoup:4[$(python_gen_usedep 'python*')]"
 RDEPEND="${DEPEND}"
 
+
+
+src_prepare() {
+	eapply "$(prefixify_ro ${FILESDIR}/${PV}-data_files.patch)"
+	eapply_user
+}
+
 python_install_all() {
 	distutils-r1_python_install_all
 	doman docs/*.8
Comment 1 tastu teche 2017-09-01 02:55:18 UTC
Created attachment 491306 [details, diff]
0.2.1-data_files.patch
Comment 2 tastu teche 2017-09-01 02:57:08 UTC
Created attachment 491308 [details]
gs-pypi-0.2.1-r1.ebuild with 0.2.1-data_files.patch added
Comment 3 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2018-12-11 13:35:52 UTC
Removing wrt #659414.