Re: [gentoo-portage-dev] [PATCH v2] misc: Distribute a repo.postsync.d hook to run gemato verification

2018-01-17 Thread Michał Górny
W dniu wto, 16.01.2018 o godzinie 11∶32 -0800, użytkownik Zac Medico napisał: > On 01/16/2018 10:39 AM, Michał Górny wrote: > > W dniu wto, 16.01.2018 o godzinie 12∶44 -0500, użytkownik Alec Warner > > napisał: > > > On Tue, Jan 16, 2018 at 11:43 AM, Michał Górny &

Re: [gentoo-portage-dev] [PATCH v2] misc: Distribute a repo.postsync.d hook to run gemato verification

2018-01-16 Thread Michał Górny
gemato. However, gemato doesn't require the hook unconditionally, so we end up with two USE flags that need to be switched together == a mess. -- Best regards, Michał Górny

Re: [gentoo-portage-dev] [PATCH v2] misc: Distribute a repo.postsync.d hook to run gemato verification

2018-01-16 Thread Michał Górny
W dniu wto, 16.01.2018 o godzinie 12∶44 -0500, użytkownik Alec Warner napisał: > On Tue, Jan 16, 2018 at 11:43 AM, Michał Górny <mgo...@gentoo.org> wrote: > > > Include a repo.postsync.d hook to verify the rsync checkout using > > gemato. Given that not all people will

[gentoo-portage-dev] [PATCH v2] misc: Distribute a repo.postsync.d hook to run gemato verification

2018-01-16 Thread Michał Górny
Include a repo.postsync.d hook to verify the rsync checkout using gemato. Given that not all people will want to have it enabled unconditionally, no setup.py rules are included -- instead, the file would be installed conditionally by the ebuild. [v2: included link to the wiki page] ---

[gentoo-portage-dev] [PATCH] misc: Distribute a repo.postsync.d hook to run gemato verification

2018-01-16 Thread Michał Górny
Include a repo.postsync.d hook to verify the rsync checkout using gemato. Given that not all people will want to have it enabled unconditionally, no setup.py rules are included -- instead, the file would be installed conditionally by the ebuild. --- MANIFEST.in | 2 +-

Re: [gentoo-portage-dev] [PATCH] const: Switch default hash set to BLAKE2B+SHA512

2018-01-13 Thread Michał Górny
Dnia 13 stycznia 2018 11:40:09 CET, Zac Medico <zmed...@gentoo.org> napisał(a): >On 01/13/2018 12:50 AM, Michał Górny wrote: >> Switch the Portage defaults to the new Gentoo hash set. We're already >> far past the initial testing and I have been approached by a few >peop

[gentoo-portage-dev] [PATCH] const: Switch default hash set to BLAKE2B+SHA512

2018-01-13 Thread Michał Górny
Switch the Portage defaults to the new Gentoo hash set. We're already far past the initial testing and I have been approached by a few people who were surprised that Portage does not use new hashes for overlays. Switching the defaults will remove the need for custom hashes in layout.conf. ---

Re: [gentoo-portage-dev] [PATCH 2/2] repoman: Enable testing exp profiles by default

2018-01-11 Thread Michał Górny
W dniu śro, 10.01.2018 o godzinie 14∶56 -0800, użytkownik Zac Medico napisał: > On 01/10/2018 02:24 PM, Michał Górny wrote: > > Enable repoman checks on exp profiles by default to improve > > the dependency graph integrity on those profiles and help them on their > > way

Re: [gentoo-portage-dev] [PATCH 2/2] repoman: Enable testing exp profiles by default

2018-01-10 Thread Michał Górny
Dnia 11 stycznia 2018 07:54:40 CET, Mike Gilbert <flop...@gentoo.org> napisał(a): >On Wed, Jan 10, 2018 at 11:10 PM, Michał Górny <mgo...@gentoo.org> >wrote: >> W dniu śro, 10.01.2018 o godzinie 21∶45 -0500, użytkownik Mike >Gilbert >> napisał: >>> O

Re: [gentoo-portage-dev] [PATCH 2/2] repoman: Enable testing exp profiles by default

2018-01-10 Thread Michał Górny
W dniu śro, 10.01.2018 o godzinie 21∶45 -0500, użytkownik Mike Gilbert napisał: > On Wed, Jan 10, 2018 at 5:56 PM, Zac Medico <zmed...@gentoo.org> wrote: > > On 01/10/2018 02:24 PM, Michał Górny wrote: > > > Enable repoman checks on exp profiles by default to improve &g

[gentoo-portage-dev] [PATCH 2/2] repoman: Enable testing exp profiles by default

2018-01-10 Thread Michał Górny
Enable repoman checks on exp profiles by default to improve the dependency graph integrity on those profiles and help them on their way towards stable status. This is possible now that the dependency graph problems are warnings rather than errors. --- repoman/pym/repoman/argparser.py | 2 +- 1

Re: [gentoo-portage-dev] [PATCH v2] install-qa-check: Do not install empty directories

2018-01-10 Thread Michał Górny
W dniu śro, 10.01.2018 o godzinie 15∶39 -0500, użytkownik Michael Orlitzky napisał: > On 01/10/2018 03:13 PM, Michał Górny wrote: > > Remove empty directories in install-qa-check phase in order to prevent > > Portage from installing them, and therefore from developers relying &g

Re: [gentoo-portage-dev] [PATCH] install-qa-check: Do not install empty directories

2018-01-10 Thread Michał Górny
one. > > Also looking at https://devmanual.gentoo.org/eclass-reference/ebuild/ > > It says "keepdir functions the same as dodir" but this has not been true > for a while? No clue where that comes from. I suppose it's some Portage manpage? > > -A > > >

[gentoo-portage-dev] [PATCH v2] install-qa-check: Do not install empty directories

2018-01-10 Thread Michał Górny
Remove empty directories in install-qa-check phase in order to prevent Portage from installing them, and therefore from developers relying on them being installed. The PMS specifies the behavior upon merging empty directories as undefined, and specifically prohibits ebuilds from attempting to

[gentoo-portage-dev] [PATCH] install-qa-check: Do not install empty directories

2018-01-10 Thread Michał Górny
Remove empty directories in install-qa-check phase in order to prevent Portage from installing them, and therefore from developers relying on them being installed. The PMS specifies the behavior upon merging empty directories as undefined, and specifically prohibits ebuilds from attempting to

Re: [gentoo-portage-dev] [PATCH] Disable dynamic-deps by default

2017-12-19 Thread Michał Górny
W dniu nie, 17.12.2017 o godzinie 13∶03 +0100, użytkownik Michał Górny napisał: > We have prepared for this for quite a while and it's time to pull > the plug. Disable dynamic-deps by default and restore the standard > PMS behavior. This will cause some one-time pain but eventually will

[gentoo-portage-dev] [PATCH v2] [checksum] Disable pygcrypt backend due to breakage

2017-12-05 Thread Michał Górny
Closes: https://bugs.gentoo.org/615620 --- pym/portage/checksum.py | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pym/portage/checksum.py b/pym/portage/checksum.py index 5424ce56b..9e7bffea9 100644 --- a/pym/portage/checksum.py +++ b/pym/portage/checksum.py @@ -150,7

[gentoo-portage-dev] [PATCH] [checksum] Disable pygcrypt backend due to breakage

2017-12-05 Thread Michał Górny
Closes: https://bugs.gentoo.org/615620 --- pym/portage/checksum.py | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pym/portage/checksum.py b/pym/portage/checksum.py index 5424ce56b..0841ab231 100644 --- a/pym/portage/checksum.py +++ b/pym/portage/checksum.py @@ -150,7

[gentoo-portage-dev] [PATCH] portage.manifest: Fix mis-parsing Manifests with numerical checksums

2017-11-19 Thread Michał Górny
Fix the regular expression used to parse Manifests not to fail horribly when one of the checksums accidentally happens to be all-digits. The previously used regular expression used to greedily take everything up to the first number as filename. If one of the checksums happened to be purely

Re: [gentoo-portage-dev] [PATCH] Make manifest-required-hashes configurable

2017-11-07 Thread Michał Górny
W dniu wto, 07.11.2017 o godzinie 11∶21 -0800, użytkownik Zac Medico napisał: > On 11/06/2017 10:23 AM, Michał Górny wrote: > > W dniu pon, 06.11.2017 o godzinie 08∶52 -0800, użytkownik Zac Medico > > napisał: > > > On 11/06/2017 08:47 AM, Michał Górny wrote: > >

Re: [gentoo-portage-dev] [PATCH] Make manifest-required-hashes configurable

2017-11-06 Thread Michał Górny
W dniu pon, 06.11.2017 o godzinie 08∶44 -0800, użytkownik Zac Medico napisał: > On 11/06/2017 07:27 AM, Michał Górny wrote: > > @@ -148,15 +147,21 @@ class Manifest(object): > > self.pkgdir = _unicode_decode(pkgdir).rstrip(os.sep) + os.sep > >

[gentoo-portage-dev] [PATCH] Make manifest-required-hashes configurable

2017-11-06 Thread Michał Górny
The set of required hashes specify which hashes must be present for a distfile not to be refetched. It makes little sense to hardcode this value, and it is mostly useful for transition periods, so make it configurable via layout.conf and default to all hashes in manifest-hashes. ---

[gentoo-portage-dev] [PATCH 1/3] portage.const: Remove obsolete manifest-hashes comment

2017-11-06 Thread Michał Górny
The comment is based upon the wrong assumption that the world is Portage-centric. We are keeping the manifest-hashes in layout.conf indefinitely, and we will most likely take BLAKE2 instead of SHA3. --- pym/portage/const.py | 23 --- 1 file changed, 23 deletions(-) diff --git

[gentoo-portage-dev] [PATCH 3/3] Remove last traces of Manifest1 code

2017-11-06 Thread Michał Górny
--- pym/portage/const.py| 1 - pym/portage/manifest.py | 7 ++- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/pym/portage/const.py b/pym/portage/const.py index 98b7c88c9..0af57d0e2 100644 --- a/pym/portage/const.py +++ b/pym/portage/const.py @@ -205,7 +205,6 @@

[gentoo-portage-dev] [PATCH 2/3] Replace static MANIFEST2_HASH_FUNCTIONS with dynamic list

2017-11-06 Thread Michał Górny
Remove the MANIFEST2_HASH_FUNCTIONS const and replace it with (deduplicated) calls to get_valid_checksum_keys(). We want Portage to always complain whenever one of the hashes is not available even if it is technically supported by the specific Portage version. Closes:

Re: [gentoo-portage-dev] [PATCH] postinst_qa_check: initialize preinst state (bug 635474)

2017-10-26 Thread Michał Górny
same effect could be achieved by adding a small pkg_postinst() to sys-apps/portage. -- Best regards, Michał Górny

[gentoo-portage-dev] [PATCH] portage.checksum: Support pyblake2 fallback for BLAKE2 hashes

2017-10-20 Thread Michał Górny
--- .travis.yml | 2 ++ pym/portage/checksum.py | 15 +-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 20078530e..ebcfbeab9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,6 +12,8 @@ install: # python3.6+ has sha3

[gentoo-portage-dev] [PATCH] postinst-qa-check.d: Skip checks if required tools are missing

2017-10-02 Thread Michał Górny
Closes: https://bugs.gentoo.org/631820 --- bin/postinst-qa-check.d/50gnome2-utils | 2 ++ bin/postinst-qa-check.d/50xdg-utils| 4 2 files changed, 6 insertions(+) diff --git a/bin/postinst-qa-check.d/50gnome2-utils b/bin/postinst-qa-check.d/50gnome2-utils index 569633fe3..7f1b0b847

Re: [gentoo-portage-dev] Portage patch now on gentoo-portage-dev ml

2017-09-12 Thread Michał Górny
e tree > available from git or some url for syncing? > I don't really understand what you're asking for. Is it about the failures with commands in global scope? If it's that, then it's already merged and available via =sys-apps/portage-9999. -- Best regards, Michał Górny

Re: [gentoo-portage-dev] [PATCH] ebuild.sh: Completely ban external commands in global scope

2017-09-08 Thread Michał Górny
W dniu pią, 08.09.2017 o godzinie 14∶48 -0400, użytkownik Alec Warner napisał: > Why PATH=/dev/null vs export PATH="" + # note: we can't use empty because it implies current directory > > On Thu, Sep 7, 2017 at 3:36 AM, Michał Górny <mgo...@gentoo.org> wrote: >

Re: [gentoo-portage-dev] [PATCH] ebuild.sh: Completely ban external commands in global scope

2017-09-07 Thread Michał Górny
Dnia 31 sierpnia 2017 22:45:42 CEST, "Michał Górny" <mgo...@gentoo.org> napisał(a): >Set PATH to /dev/null when sourcing the ebuild for dependency >resolution >in order to prevent shell from finding external commands via PATH >lookup. While this does not prevent exec

[gentoo-portage-dev] [PATCH v2 1/2] repoman: Unify usage of --bug and --closes options

2017-09-02 Thread Michał Górny
Replace the different logic used for --bug and --closes options with a uniform solution. As a result, --closes now interprets numbers as Gentoo bug numbers rather than GitHub pull request numbers. This change is mostly done since the 'Closes' tag now started being used to resolve Gentoo bugs.

Re: [gentoo-portage-dev] [PATCH] repoman: Update --bug/--closes description for bugs.g.o hooks

2017-09-02 Thread Michał Górny
W dniu sob, 02.09.2017 o godzinie 14∶33 -0700, użytkownik Zac Medico napisał: > On 09/02/2017 12:10 PM, Michał Górny wrote: > > Update the description for --bug and --closes to account for the fact > > that the tags are now handled by git hooks on Gentoo Infra, and cause > &

Re: [gentoo-portage-dev] [PATCH] Do not enable optimizations by default to work-around pycparser issue

2017-09-02 Thread Michał Górny
W dniu sob, 02.09.2017 o godzinie 14∶23 -0700, użytkownik Zac Medico napisał: > On 09/02/2017 02:05 PM, Michał Górny wrote: > > W dniu sob, 02.09.2017 o godzinie 12∶19 -0700, użytkownik Zac Medico > > napisał: > > > On 09/02/2017 10:46 AM, Michał Górny wrote: > >

Re: [gentoo-portage-dev] [PATCH] Do not enable optimizations by default to work-around pycparser issue

2017-09-02 Thread Michał Górny
W dniu sob, 02.09.2017 o godzinie 23∶05 +0200, użytkownik Michał Górny napisał: > W dniu sob, 02.09.2017 o godzinie 12∶19 -0700, użytkownik Zac Medico > napisał: > > On 09/02/2017 10:46 AM, Michał Górny wrote: > > > dev-python/pycparser-2.18+ exposes a design f

Re: [gentoo-portage-dev] [PATCH] Do not enable optimizations by default to work-around pycparser issue

2017-09-02 Thread Michał Górny
W dniu sob, 02.09.2017 o godzinie 12∶19 -0700, użytkownik Zac Medico napisał: > On 09/02/2017 10:46 AM, Michał Górny wrote: > > dev-python/pycparser-2.18+ exposes a design flaw in dev-python/ply that > > makes it unable to work with -OO code. Remove the optimizations from >

[gentoo-portage-dev] [PATCH] repoman: Update --bug/--closes description for bugs.g.o hooks

2017-09-02 Thread Michał Górny
Update the description for --bug and --closes to account for the fact that the tags are now handled by git hooks on Gentoo Infra, and cause actions on Gentoo Bugzilla. // NB: It would probably make sense for --closes to default to Gentoo bug numbers now. However, I have doubts that some people

[gentoo-portage-dev] [PATCH] ebuild.sh: Completely ban external commands in global scope

2017-08-31 Thread Michał Górny
Set PATH to /dev/null when sourcing the ebuild for dependency resolution in order to prevent shell from finding external commands via PATH lookup. While this does not prevent executing programs via full path, it should catch the majority of accidental uses. Closes:

Re: [gentoo-portage-dev] [PATCH] ebuild.sh: Fail on command-not-found in global scope

2017-08-31 Thread Michał Górny
W dniu czw, 31.08.2017 o godzinie 10∶42 -0700, użytkownik Zac Medico napisał: > On 08/31/2017 07:56 AM, Michał Górny wrote: > > The PMS specifies that ebuilds must not call external commands in global > > scope. We can not prevent that from happening at the moment since a few > &

[gentoo-portage-dev] [PATCH] ebuild.sh: Fail on command-not-found in global scope

2017-08-31 Thread Michał Górny
The PMS specifies that ebuilds must not call external commands in global scope. We can not prevent that from happening at the moment since a few ebuilds in Gentoo are still doing that. Instead, start increasing strictness by explicitly failing if ebuilds call external commands that are not found.

Re: [gentoo-portage-dev] [PATCH] ebuild.sh: Explicitly ban get_libdir in global scope

2017-08-31 Thread Michał Górny
W dniu śro, 30.08.2017 o godzinie 23∶36 -0700, użytkownik Zac Medico napisał: > On 08/30/2017 01:45 PM, Michał Górny wrote: > > W dniu śro, 30.08.2017 o godzinie 13∶35 -0700, użytkownik Zac Medico > > napisał: > > > On 08/30/2017 01:31 PM, Michał Górny wrote: > >

Re: [gentoo-portage-dev] [PATCH] ebuild.sh: Explicitly ban get_libdir in global scope

2017-08-30 Thread Michał Górny
W dniu śro, 30.08.2017 o godzinie 10∶48 -0700, użytkownik Zac Medico napisał: > On 08/30/2017 02:06 AM, Michał Górny wrote: > > The value of get_libdir depends on the profile, and so it is not useful > > for dependency calculations. Furthermore, it seems that Portage does > >

[gentoo-portage-dev] [PATCH] ebuild.sh: Explicitly ban get_libdir in global scope

2017-08-30 Thread Michał Górny
The value of get_libdir depends on the profile, and so it is not useful for dependency calculations. Furthermore, it seems that Portage does not handle defining it in global scope well due to EAPI checking magic. Ban it completely where it is defined as EAPI function to let developers catch their

[gentoo-portage-dev] [PATCH] gnome2-utils postinst: Restrict file types to fix false positives

2017-08-29 Thread Michał Górny
Restrict the file types checked by the gtk-icon-cache-update check to match the one used inside the tool. This ensures that we do not report any false positives for files that are intentionally skipped. Bug: https://bugs.gentoo.org/629148 --- bin/postinst-qa-check.d/50gnome2-utils | 7 ++- 1

Re: [gentoo-portage-dev] [PATCH] Rewrite doins in python (bug 624526)

2017-08-23 Thread Michał Górny
> - pushd "$PWD" >/dev/null > - else > - pushd "${x%/*}" >/dev/null > - fi > - x=${x##*/} > - x_orig=$x > - # Follow any symlinks recursively until we've got > - # a normal directory for 'find' to traverse. The > - # name of the symlink will be used for the name > - # of the installed directory, as discussed in > - # bug #239529. > - while [ -L "$x" ] ; do > - pushd "$(readlink "$x")" >/dev/null > - x=${PWD##*/} > - pushd "${PWD%/*}" >/dev/null > - done > - if [[ $x != $x_orig ]] ; then > - mv "$x" "$TMP/1/$x_orig" > - pushd "$TMP/1" >/dev/null > - fi > - find "$x_orig" -type d -exec dodir "${INSDESTTREE}/{}" \; > - find "$x_orig" \( -type f -or -type l \) -print0 | _xdoins > - if [[ ${PIPESTATUS[1]} -eq 0 ]] ; then > - # NOTE: Even if only an empty directory is installed > here, it > - # still counts as success, since an empty directory > given as > - # an argument to doins -r should not trigger failure. > - ((success|=1)) > - else > - ((failed|=1)) > - fi > - if [[ $x != $x_orig ]] ; then > - popd >/dev/null > - mv "$TMP/1/$x_orig" "$x" > - fi > - while popd >/dev/null 2>&1 ; do true ; done > - else > - _doins "${x}" > - if [[ $? -eq 0 ]] ; then > - ((success|=1)) > - else > - ((failed|=1)) > - fi > - fi > -done > -rm -rf "$TMP" > -[[ $failed -ne 0 || $success -eq 0 ]] && { __helpers_die "${helper} failed"; > exit 1; } || exit 0 > +"${PORTAGE_PYTHON:-/usr/bin/python}" \ > + "${PORTAGE_BIN_PATH:-/usr/lib/portage/bin}"/doins.py \ > + ${RECURSIVE_OPTION} ${SYMLINK_OPTION} \ > + --helper "${helper}" --dest "${ED}${INSDESTTREE}" "$@" || \ > +{ __helpers_die "${helper} failed"; exit 1; } To be honest, I don't like the idea of using more Python inside ebuild helpers. But if you're sure this is safe and not going to collide with ebuilds doing random stuff with Python, feel free to proceed with it. -- Best regards, Michał Górny

Re: [gentoo-portage-dev] [PATCH] elog mod_echo: Print log path if PORT_LOGDIR is used

2017-08-17 Thread Michał Górny
W dniu śro, 16.08.2017 o godzinie 09∶12 -0700, użytkownik Brian Dolbec napisał: > On Wed, 16 Aug 2017 12:10:52 +0200 > Michał Górny <mgo...@gentoo.org> wrote: > > > Include the path to the log file if PORT_LOGDIR is being used > > (and therefore the log is going to

[gentoo-portage-dev] [PATCH v2 2/4] Add post-postinst checks for a few missed cache updates

2017-08-16 Thread Michał Górny
Add postinst-qa-check.d checks for missed desktop, mime-info and GTK+ icon cache updates. In all of the cases the checks simply look for any installed files that are newer than the cache. This check has some limitations: it assumes that mtime is not preserved when copying files to D, it can't

[gentoo-portage-dev] [PATCH v2 4/4] Update caches after reporting missing cache updates

2017-08-16 Thread Michał Górny
Call the appropriate updater to update caches after reporting a missing cache update, in order to stop repeating the same issue on subsequent packages that did not install any relevant files. --- bin/postinst-qa-check.d/50gnome2-utils | 9 + bin/postinst-qa-check.d/50xdg-utils| 18

[gentoo-portage-dev] [PATCH v2 3/4] Use ctime in cache post-postinst checks

2017-08-16 Thread Michał Górny
Use ctime rather than mtime in cache post-postinst checks since mtime may be preserved from the original tarball, and therefore be 'long time ago'. ctime is more reliable in this regard. --- bin/postinst-qa-check.d/50gnome2-utils | 2 +- bin/postinst-qa-check.d/50xdg-utils| 4 ++-- 2 files

[gentoo-portage-dev] [PATCH v2 1/4] Support post-postinst QA checks

2017-08-16 Thread Michał Górny
Extend the QA check mechanics in Portage to support post-postinst QA checks. They are like post-install QA checks, except they are run after pkg_postinst(), and so they can be used to verify that necessary postinst actions were performed (e.g. regenerating caches). --- bin/misc-functions.sh

Re: [gentoo-portage-dev] [PATCH 3/2] Update caches after reporting missing cache updates

2017-08-16 Thread Michał Górny
W dniu śro, 16.08.2017 o godzinie 16∶22 +0200, użytkownik Michał Górny napisał: > Call the appropriate updater to update caches after reporting a missing > cache update, in order to stop repeating the same issue on subsequent > packages that did not install any relevant files. >

[gentoo-portage-dev] [PATCH 3/2] Update caches after reporting missing cache updates

2017-08-16 Thread Michał Górny
Call the appropriate updater to update caches after reporting a missing cache update, in order to stop repeating the same issue on subsequent packages that did not install any relevant files. --- bin/postinst-qa-check.d/50gnome2-utils | 8 bin/postinst-qa-check.d/50xdg-utils| 16

[gentoo-portage-dev] [PATCH] elog mod_echo: Print log path if PORT_LOGDIR is used

2017-08-16 Thread Michał Górny
Include the path to the log file if PORT_LOGDIR is being used (and therefore the log is going to be preserved past the build). This is useful when elog messages contain QA warnings or other errors that require reporting a bug. In such case, having a path to the log is handy. After this commit,

[gentoo-portage-dev] [PATCH 2/2] Add post-postinst checks for a few missed cache updates

2017-08-15 Thread Michał Górny
Add postinst-qa-check.d checks for missed desktop, mime-info and GTK+ icon cache updates. In all of the cases the checks simply look for any installed files that are newer than the cache. This check has some limitations: it assumes that mtime is not preserved when copying files to D, it can't

[gentoo-portage-dev] [PATCH 1/2] Support post-postinst QA checks

2017-08-15 Thread Michał Górny
Extend the QA check mechanics in Portage to support post-postinst QA checks. They are like post-install QA checks, except they are run after pkg_postinst(), and so they can be used to verify that necessary postinst actions were performed (e.g. regenerating caches). --- bin/misc-functions.sh

Re: [gentoo-portage-dev] [PATCH v4] repoman commit: Support --bug (-b) and --closes (-c) for git footer

2017-08-06 Thread Michał Górny
On nie, 2017-08-06 at 00:18 -0700, Zac Medico wrote: > On Sat, Aug 5, 2017 at 11:53 PM, Michał Górny <mgo...@gentoo.org> wrote: > > Support two new options: --bug (-b) and --closes (-c) to add a plain > > 'Bug' reference and a 'Closes' footer for a GitHub pull request.

Re: [gentoo-portage-dev] [PATCH] repoman commit: Merge code generating common part of the footer (DCO)

2017-08-06 Thread Michał Górny
On sob, 2017-08-05 at 22:50 -0700, Zac Medico wrote: > On Thu, Aug 3, 2017 at 6:55 AM, Michał Górny <mgo...@gentoo.org> wrote: > > The DCO Signed-off-by footer looks the same on the git branch, and on > > the branch for other VCS-es. Therefore, move the code generating i

[gentoo-portage-dev] [PATCH v4] repoman commit: Support --bug (-b) and --closes (-c) for git footer

2017-08-06 Thread Michał Górny
Support two new options: --bug (-b) and --closes (-c) to add a plain 'Bug' reference and a 'Closes' footer for a GitHub pull request. Both options can be specified multiple times, resulting in multiple footer tags being written. The --bug option accepts either a Gentoo Bugzilla bug number or an

[gentoo-portage-dev] [PATCH v3] repoman commit: Support --bug (-b) and --closes (-c) for git footer

2017-08-05 Thread Michał Górny
Support two new options: --bug (-b) and --closes (-c) to add a plain 'Bug' reference and a 'Closes' footer for a GitHub pull request. Both options can be specified multiple times, resulting in multiple footer tags being written. The --bug option accepts either a Gentoo Bugzilla bug number or an

Re: [gentoo-portage-dev] [PATCH v2] repoman commit: Support --bug (-b) and --closes (-c) for git footer

2017-08-05 Thread Michał Górny
On sob, 2017-08-05 at 17:11 -0400, Alec Warner wrote: > On Fri, Aug 4, 2017 at 6:37 PM, Michał Górny <mgo...@gentoo.org> wrote: > > > Support two new options: --bug (-b) and --closes (-c) to add a plain > > 'Bug' reference and a 'Closes' footer for a GitHub pull reque

[gentoo-portage-dev] [PATCH v2] repoman commit: Support --bug (-b) and --closes (-c) for git footer

2017-08-04 Thread Michał Górny
Support two new options: --bug (-b) and --closes (-c) to add a plain 'Bug' reference and a 'Closes' footer for a GitHub pull request. Both options can be specified multiple times, resulting in multiple footer tags being written. The --bug option accepts either a Gentoo Bugzilla bug number or an

Re: [gentoo-portage-dev] [PATCH] repoman commit: Support --bug (-b) and --closes (-c) for git footer

2017-08-03 Thread Michał Górny
On czw, 2017-08-03 at 11:18 -0400, Alec Warner wrote: > On Thu, Aug 3, 2017 at 10:18 AM, Michał Górny <mgo...@gentoo.org> wrote: > > > Support two new options: --bug (-b) and --closes (-c) to add a plain > > 'Bug' reference and a 'Closes' footer for a GitHub pull reque

[gentoo-portage-dev] [PATCH] repoman commit: Support --bug (-b) and --closes (-c) for git footer

2017-08-03 Thread Michał Górny
Support two new options: --bug (-b) and --closes (-c) to add a plain 'Bug' reference and a 'Closes' footer for a GitHub pull request. Both options can be specified multiple times, resulting in multiple footer tags being written. The --bug option accepts either a Gentoo Bugzilla bug number or an

[gentoo-portage-dev] [PATCH] repoman commit: Merge code generating common part of the footer (DCO)

2017-08-03 Thread Michał Górny
The DCO Signed-off-by footer looks the same on the git branch, and on the branch for other VCS-es. Therefore, move the code generating it above the split branches. This also prepares the code for further footer elements being added. --- repoman/pym/repoman/actions.py | 13 +++-- 1 file

Re: [gentoo-portage-dev] [PATCH] make.globals: Enable FEATURES=multilib-strict by default

2017-08-02 Thread Michał Górny
On śro, 2017-08-02 at 00:30 -0700, Zac Medico wrote: > On Wed, Jul 26, 2017 at 12:20 AM, Michał Górny <mgo...@gentoo.org> wrote: > > Enable the multilib-strict feature necessary for Portage to detect > > ebuilds not respecting libdir for libraries. Since those issues were &g

Re: [gentoo-portage-dev] [PATCH] make.globals: Enable FEATURES=multilib-strict by default

2017-07-31 Thread Michał Górny
Dnia 31 lipca 2017 10:17:56 CEST, Zac Medico <zmed...@gentoo.org> napisał(a): >On Wed, Jul 26, 2017 at 1:44 PM, Michał Górny <mgo...@gentoo.org> >wrote: >> On śro, 2017-07-26 at 11:29 -0700, Zac Medico wrote: >>> You might think that, but I just check

Re: [gentoo-portage-dev] [PATCH v2] Support different compressors for binary packages

2017-07-29 Thread Michał Górny
we have already: PORTAGE_COMPRESS PORTAGE_COMPRESS_FLAGS ^^ and you've added: BINPKG_COMPRESSION ^^^ BINPKG_COMPRESSION_ARGS Wouldn't it be better to at least try having consistent variable naming? -- Best regards, Michał Górny signature.

Re: [gentoo-portage-dev] [PATCH] make.globals: Enable FEATURES=multilib-strict by default

2017-07-26 Thread Michał Górny
On śro, 2017-07-26 at 11:29 -0700, Zac Medico wrote: > On Wed, Jul 26, 2017 at 10:11 AM, Michał Górny <mgo...@gentoo.org> wrote: > > On śro, 2017-07-26 at 09:58 -0700, Zac Medico wrote: > > > On Wed, Jul 26, 2017 at 12:20 AM, Michał Górny <mgo...@gentoo.org> wrot

Re: [gentoo-portage-dev] [PATCH] make.globals: Enable FEATURES=multilib-strict by default

2017-07-26 Thread Michał Górny
On śro, 2017-07-26 at 09:58 -0700, Zac Medico wrote: > On Wed, Jul 26, 2017 at 12:20 AM, Michał Górny <mgo...@gentoo.org> wrote: > > Enable the multilib-strict feature necessary for Portage to detect > > ebuilds not respecting libdir for libraries. Since those issues were &g

[gentoo-portage-dev] [PATCH] make.globals: Enable FEATURES=multilib-strict by default

2017-07-26 Thread Michał Górny
Enable the multilib-strict feature necessary for Portage to detect ebuilds not respecting libdir for libraries. Since those issues were reliably fixed over the years and we're nearing the removal of 'lib' symlink, I think we can safely enable it by default for our users without risking many

Re: [gentoo-portage-dev] [PATCH] doman: QA-complain on compressed files

2017-07-09 Thread Michał Górny
On nie, 2017-07-02 at 11:57 -0700, Brian Dolbec wrote: > On Sun, 2 Jul 2017 19:57:57 +0200 > Michał Górny <mgo...@gentoo.org> wrote: > > > Passing compressed files to doman is not permitted by the PMS. > > However, Portage permitting it results in many develope

Re: [gentoo-portage-dev] Leader election

2017-07-09 Thread Michał Górny
der > > > > > > > > > > > > > I've picked Sunday, July 2 at 4:00 PM UTC > > > > > > > We've decided (the members in attendance), to do the lead election via > > > email. > > > So, nominations are open from now to July 5, 2017. > > > Voting will be closed July 10, 2017, results posted here again. > > > - -- > > > Brian Dolbec > > > > > > I nominate Zac > > Thank you, I accept. > > I also nominate Brian Dolbec and Alexander Berntsen. My vote goes for Zac as well. -- Best regards, Michał Górny signature.asc Description: This is a digitally signed message part

Re: [gentoo-portage-dev] [PATCH] Support different (de)compressors for binary packages

2017-07-05 Thread Michał Górny
t to something a standard install doesn't include. > > Assume all binpkgs are set to be compressed with zstd, the patch makes > sure an app-arch/zstd binpkg will still be compressed with bzip2. And app-arch/bzip2 binpackage? In other words, that's the wrong approach. If I set binpackages to use X, I want them to use X, not 'use X if someone thought it correct to use X'. Just do what the user says to do. If you try to outsmart him, you're building another Windows. -- Best regards, Michał Górny signature.asc Description: This is a digitally signed message part

[gentoo-portage-dev] [PATCH v2] checks: Add more deprecated eclasses

2017-06-19 Thread Michał Górny
Changes in v2: * multilib-minimal is suggested replacement of autotools-multilib. --- repoman/pym/repoman/modules/scan/ebuild/checks.py | 5 + 1 file changed, 5 insertions(+) diff --git a/repoman/pym/repoman/modules/scan/ebuild/checks.py b/repoman/pym/repoman/modules/scan/ebuild/checks.py

[gentoo-portage-dev] [PATCH] checks: Add more deprecated eclasses

2017-06-19 Thread Michał Górny
--- repoman/pym/repoman/modules/scan/ebuild/checks.py | 5 + 1 file changed, 5 insertions(+) diff --git a/repoman/pym/repoman/modules/scan/ebuild/checks.py b/repoman/pym/repoman/modules/scan/ebuild/checks.py index e6e5d78ba..a1fa066be 100644 ---

Re: [gentoo-portage-dev] [PATCH] const: Change the MANIFEST2_REQUIRED_HASH to SHA512

2017-06-15 Thread Michał Górny
On czw, 2017-06-15 at 09:49 -0700, Zac Medico wrote: > On Thu, Jun 15, 2017 at 12:42 AM, Michał Górny <mgo...@gentoo.org> wrote: > > > > Following the plan established in GLEP 59, we're long overdue > > deprecating SHA256. Since we have finally got rid of the last

Re: [gentoo-portage-dev] [PATCH] const: Remove unused MANIFEST1_REQUIRED_HASH

2017-06-15 Thread Michał Górny
On czw, 2017-06-15 at 09:08 -0700, Zac Medico wrote: > On Thu, Jun 15, 2017 at 12:27 AM, Michał Górny <mgo...@gentoo.org> wrote: > > > The MANIFEST1_REQUIRED_HASH constant is not used anywhere, so it should > > be possible to remove it safely. > > --- > > py

[gentoo-portage-dev] [PATCH] const: Change the MANIFEST2_REQUIRED_HASH to SHA512

2017-06-15 Thread Michał Górny
Following the plan established in GLEP 59, we're long overdue deprecating SHA256. Since we have finally got rid of the last packages lacking SHA512 checksums, we can proceed with that. In order to prepare for it, however, we need to change the required hash to SHA512 and make sure developers

[gentoo-portage-dev] [PATCH] const: Remove unused MANIFEST1_REQUIRED_HASH

2017-06-15 Thread Michał Górny
The MANIFEST1_REQUIRED_HASH constant is not used anywhere, so it should be possible to remove it safely. --- pym/portage/const.py | 1 - 1 file changed, 1 deletion(-) diff --git a/pym/portage/const.py b/pym/portage/const.py index 7e415ba9c..052d4ca2f 100644 --- a/pym/portage/const.py +++

[gentoo-portage-dev] [PATCH v3] dosym: protect Prefix hack from double EPREFIX

2017-04-20 Thread Michał Górny
Add an additional conditional to the dosym Prefix hack to ensure that the symlink is not using double Prefix when the ebuild uses ${EPREFIX} explicitly. This ensures that Portage on Prefix systems is both compatible with the ebuilds relying on the hack, and using dosym in the PMS-defined manner.

Re: [gentoo-portage-dev] [PATCH] dosym: protect Prefix hack from double EPREFIX

2017-04-19 Thread Michał Górny
On śro, 2017-04-19 at 18:06 +0200, Ulrich Mueller wrote: > > > > > > On Wed, 19 Apr 2017, Michał Górny wrote: > > Add an additional conditional to the dosym Prefix hack to ensure that > > the symlink is not using double Prefix when the ebuild uses ${EPREFIX

[gentoo-portage-dev] [PATCH] dosym: protect Prefix hack from double EPREFIX

2017-04-19 Thread Michał Górny
Add an additional conditional to the dosym Prefix hack to ensure that the symlink is not using double Prefix when the ebuild uses ${EPREFIX} explicitly. This ensures that Portage on Prefix systems is both compatible with the ebuilds relying on the hack, and using dosym in the PMS-defined manner.

Re: [gentoo-portage-dev] [PATCH] repoman: Add a check for relative dosym candidates

2017-04-15 Thread Michał Górny
On sob, 2017-04-15 at 10:11 -0700, Zac Medico wrote: > On Sat, Apr 15, 2017 at 4:04 AM, Michał Górny <mgo...@gentoo.org> wrote: > > diff --git a/repoman/pym/repoman/modules/scan/ebuild/checks.py > > b/repoman/pym/repoman/modules/scan/ebuild/checks.py > > index

[gentoo-portage-dev] [PATCH] repoman: Add a check for relative dosym candidates

2017-04-15 Thread Michał Górny
Add a check for dosym with target path matching absolute paths controlled by the package manager, e.g. /bin, /etc... Example output: ebuild.absdosym 5 app-editors/nano/nano-2.5.3.ebuild: dosym '/bin/nano'... could use relative path on line: 81 --- repoman/man/repoman.1

[gentoo-portage-dev] [RFC] eslurp helper

2017-03-26 Thread Michał Górny
listed packages in PKGDIR (respecting subdirectories, updating index). If neither of the options were specified, it would guess the directory type by the filename suffix. What do you think? -- Best regards, Michał Górny signature.asc Description: This is a digitally signed message part

Re: [gentoo-portage-dev] [PATCH] phase-functions: Fix cleaning fake FILESDIR, reported by Arfrever

2017-03-26 Thread Michał Górny
On nie, 2017-03-26 at 00:38 -0700, Zac Medico wrote: > On Sun, Mar 26, 2017 at 12:30 AM, Michał Górny <mgo...@gentoo.org> wrote: > > --- > > bin/phase-functions.sh | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/bin/phase-functions.sh b/bin

[gentoo-portage-dev] [PATCH] phase-functions: Fix cleaning fake FILESDIR, reported by Arfrever

2017-03-26 Thread Michał Górny
--- bin/phase-functions.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/phase-functions.sh b/bin/phase-functions.sh index 50f0fdb9b..dfd8733c8 100644 --- a/bin/phase-functions.sh +++ b/bin/phase-functions.sh @@ -283,6 +283,7 @@ __dyn_clean() { rm -rf

Re: [gentoo-portage-dev] [PATCH] portage.package.ebuild: Use a fake FILESDIR to catch invalid accesses

2017-03-24 Thread Michał Górny
On czw, 2017-03-16 at 20:56 +0100, Michał Górny wrote: > Use a model of fake FILESDIR path to ensure that invalid accesses to > FILESDIR will result in failures rather than being silently allowed by > Portage. This mostly involves accesses in the global scope and pkg_* > phas

[gentoo-portage-dev] [PATCH v3] portage.package.ebuild: Use a fake FILESDIR to catch invalid accesses

2017-03-21 Thread Michał Górny
Use a model of fake FILESDIR path to ensure that invalid accesses to FILESDIR will result in failures rather than being silently allowed by Portage. This mostly involves accesses in the global scope and pkg_* phases, although the current model does not cover the latter completely (i.e. does not

Re: [gentoo-portage-dev] [PATCH 3/4] portage.package.ebuild.doebuild: Override DISTDIR unconditionally, #612972

2017-03-18 Thread Michał Górny
On sob, 2017-03-18 at 13:45 -0700, Zac Medico wrote: > On Sat, Mar 18, 2017 at 1:12 PM, Zac Medico <zmed...@gentoo.org> wrote: > > On Sat, Mar 18, 2017 at 12:57 PM, Zac Medico <zmed...@gentoo.org> wrote: > > > On Sat, Mar 18, 2017 at 12:04 PM, Michał Górny <mgo...@

[gentoo-portage-dev] [PATCH 1/4] portage.package.ebuild: Move _prepare_fake_distdir to .prepare_build_dirs

2017-03-18 Thread Michał Górny
--- pym/_emerge/EbuildExecuter.py| 2 +- pym/portage/package/ebuild/doebuild.py | 32 +--- pym/portage/package/ebuild/prepare_build_dirs.py | 31 +++ 3 files changed, 33 insertions(+), 32 deletions(-) diff --git

[gentoo-portage-dev] [PATCH 2/4] portage.package.ebuild.fetch: Use PORTAGE_ACTUAL_DISTDIR for fetching

2017-03-18 Thread Michał Górny
--- pym/portage/package/ebuild/fetch.py | 45 - 1 file changed, 25 insertions(+), 20 deletions(-) diff --git a/pym/portage/package/ebuild/fetch.py b/pym/portage/package/ebuild/fetch.py index 0431e11ea..90b6f2e54 100644 ---

[gentoo-portage-dev] [PATCH 4/4] _emerge.Ebuild*: delay creating DISTDIR shadow until src_unpack

2017-03-18 Thread Michał Górny
--- pym/_emerge/EbuildExecuter.py | 4 pym/_emerge/EbuildPhase.py| 4 +++- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/pym/_emerge/EbuildExecuter.py b/pym/_emerge/EbuildExecuter.py index 7a454c3e6..81257aa9e 100644 --- a/pym/_emerge/EbuildExecuter.py +++

[gentoo-portage-dev] [PATCH 3/4] portage.package.ebuild.doebuild: Override DISTDIR unconditionally, #612972

2017-03-18 Thread Michał Górny
Ensure that DISTDIR is always defined to the path to the shadow directory. This ensures that PMS rules for consistent value are followed, and that no global scope calls should be able to access the distfile directory. This also ensures that global-scope assignments (e.g. in PATCHES) do not work

[gentoo-portage-dev] [PATCHES] Restrict DISTDIR to src_unpack and further

2017-03-18 Thread Michał Górny
directory. The directory itself is not created until src_unpack, so mistaken accesses in earlier phases are caught early. The accesses in pkg_pre/post phases are not caught yet. As usual, this patch can be applied after reasonable set of blockers in ::gentoo is resolved. -- Best regards, Michał Górny

[gentoo-portage-dev] [PATCH v2] portage.package.ebuild: Use a fake FILESDIR to catch invalid accesses

2017-03-18 Thread Michał Górny
Use a model of fake FILESDIR path to ensure that invalid accesses to FILESDIR will result in failures rather than being silently allowed by Portage. This mostly involves accesses in the global scope and pkg_* phases, although the current model does not cover the latter completely (i.e. does not

Re: [gentoo-portage-dev] [PATCH] portage.package.ebuild: Use a fake FILESDIR to catch invalid accesses

2017-03-16 Thread Michał Górny
On czw, 2017-03-16 at 21:29 +0100, Ulrich Mueller wrote: > > > > > > On Thu, 16 Mar 2017, Michał Górny wrote: > > + mysettings["FILESDIR"] = os.path.join(settings["PORTAGE_BUILDDIR"], > > "files") > > I believe that this

[gentoo-portage-dev] [PATCH] portage.package.ebuild: Use a fake FILESDIR to catch invalid accesses

2017-03-16 Thread Michał Górny
Use a model of fake FILESDIR path to ensure that invalid accesses to FILESDIR will result in failures rather than being silently allowed by Portage. This mostly involves accesses in the global scope and pkg_* phases, although the current model does not cover the latter completely (i.e. does not

Re: [gentoo-portage-dev] [PATCHES] portage.checksum hacking, pt. 4

2017-03-13 Thread Michał Górny
W dniu 12.03.2017, nie o godzinie 21∶31 -0700, użytkownik Zac Medico napisał: > On Sun, Mar 12, 2017 at 11:59 AM, Michał Górny <mgo...@gentoo.org> wrote: > > Hi, > > > > Here's a huge batch of patches for portage.checksum and relevant stuff. > > It's not a comp

[gentoo-portage-dev] [PATCH] portage.checksum: Store supported hash types in a frozenset

2017-03-13 Thread Michał Górny
Copy the list of supported hash types (hashfunc_map dict) into a frozenset to support efficient access in the public API. --- pym/portage/checksum.py | 25 ++--- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/pym/portage/checksum.py b/pym/portage/checksum.py

<    1   2   3   4   5   6   7   8   9   >