Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] Fallback PaX spam in portage output
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
Utsuho Reiuji
Apprentice
Apprentice


Joined: 03 Apr 2013
Posts: 153

PostPosted: Sun Sep 28, 2014 1:25 pm    Post subject: [solved] Fallback PaX spam in portage output Reply with quote

Recently, I'm getting console outputs like this:
Code:
>>> Verifying ebuild manifests
>>> Emerging (1 of 1) dev-java/oracle-jdk-bin-1.8.0.20::gentoo
>>> Installing (1 of 1) dev-java/oracle-jdk-bin-1.8.0.20::gentoo
>>> Jobs: 1 of 1 complete                           Load avg: 1.76, 1.44, 1.53

 * Messages for package dev-java/oracle-jdk-bin-1.8.0.20:

 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
 * Fallback PaX marking -m with scanelf
 * Please check that PaX marking worked
>>> Auto-cleaning packages...

>>> No outdated packages were found on your system.


Well, just to get rid of those, I'd gladly check if PaX marking worked, but how?
scanel" seems to be the proper tool, but:
Code:
~ # scanelf -mA
scanelf: Nothing to scan !?


That's like a perfect output to express my confusion about this. Did anyone experience this as well?


Last edited by Utsuho Reiuji on Fri Oct 03, 2014 11:18 am; edited 1 time in total
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Sun Sep 28, 2014 5:21 pm    Post subject: Reply with quote

That's a binpkg, so the scanelf checks usually flag warnings, since the binaries haven't actually been compiled and built by us.

I forget what the FEATURE for this is; if you find it in man emerge, you can disable it on a per-package basis by using /etc/portage/package.env.

As for your command, you need to run scanelf against an actual binary object. For instance, the files from qlist somepkg (qlist is part of portage-utils.)
Back to top
View user's profile Send private message
blueness
Developer
Developer


Joined: 25 Nov 2009
Posts: 32
Location: Buffalo, NY

PostPosted: Sun Sep 28, 2014 8:02 pm    Post subject: Reply with quote

steveL wrote:
That's a binpkg, so the scanelf checks usually flag warnings, since the binaries haven't actually been compiled and built by us.

I forget what the FEATURE for this is; if you find it in man emerge, you can disable it on a per-package basis by using /etc/portage/package.env.

As for your command, you need to run scanelf against an actual binary object. For instance, the files from qlist somepkg (qlist is part of portage-utils.)


Sorry about that. I didn't expect that warning to be triggered repeatedly. Can you test the following patch


Code:
--- pax-utils.eclass.orig   2014-09-28 16:01:40.182884935 -0400
+++ pax-utils.eclass   2014-09-28 16:02:44.482887862 -0400
@@ -71,6 +71,8 @@
    local dodefault=""
    [[ "${flags//[!z]}" ]] && dodefault="yes"
 
+   local warnonce=1
+
    if has PT ${PAX_MARKINGS}; then
       _pax_list_files einfo "$@"
       for f in "$@"; do
@@ -98,8 +100,11 @@
 
          #Finally fall back on scanelf
          if type -p scanelf > /dev/null && [[ ${PAX_MARKINGS} != "none" ]]; then
-            ewarn "Fallback PaX marking -${flags} with scanelf"
-            ewarn "Please check that PaX marking worked"
+            if test $warnonce = 1; then
+               warnonce=0
+               ewarn "Fallback PaX marking -${flags} with scanelf"
+               ewarn "Please check that PaX marking worked"
+            fi
             scanelf -Xxz ${flags} "$f"
          #We failed to set PT_PAX flags
          elif [[ ${PAX_MARKINGS} != "none" ]]; then
Back to top
View user's profile Send private message
blueness
Developer
Developer


Joined: 25 Nov 2009
Posts: 32
Location: Buffalo, NY

PostPosted: Sun Sep 28, 2014 8:11 pm    Post subject: Reply with quote

blueness wrote:


Sorry about that. I didn't expect that warning to be triggered repeatedly. Can you test the following patch


Actually never mind, I just removed the ewarning.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Mon Sep 29, 2014 12:37 am    Post subject: Reply with quote

Cool, cheers blueness.

For future ref it's easier to do:
Code:
local warned=0
..
   if ((! warned)); then
      ewarn ..
      warned=1
   fi
((..)) arithmetic is very quick.

Though in most situations you need a global specific to the function; eg warned vs warnBuild in update. ('warned' is suitable there as it relates to the /etc/warning file.)
Back to top
View user's profile Send private message
Utsuho Reiuji
Apprentice
Apprentice


Joined: 03 Apr 2013
Posts: 153

PostPosted: Fri Oct 03, 2014 11:18 am    Post subject: Reply with quote

hey guys, sorry for my late reply.
Great, thank you for fixing the warning, I'll test it in the next update (this weekend)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum