Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
app-portage/gentoolkit/euse envvar PORTDIR is deprecated
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 783
Location: usually offline

PostPosted: Sat Jan 23, 2016 9:30 pm    Post subject: app-portage/gentoolkit/euse envvar PORTDIR is deprecated Reply with quote

i installed (almost) as per the x86 install handbook. as a result of that i have

Code:
 $ cat /etc/portage/make.conf | grep PORTDIR
PORTDIR="/usr/portage"
DISTDIR="${PORTDIR}/distfiles"
PKGDIR="${PORTDIR}/packages"


i installed gentoolkit as was recommended. and Gentoolkit | 3 euse

Code:
$ euse
WARNING: 'portageq envvar PORTDIR' is deprecated. Use any of 'get_repos, get_repo_path, repos_config' instead.
WARNING: 'portageq envvar PORTDIR' is deprecated. Use any of 'get_repos, get_repo_path, repos_config' instead.
WARNING: 'portageq envvar PORTDIR' is deprecated. Use any of 'get_repos, get_repo_path, repos_config' instead.
euse (0.3.0.9-r2)

Syntax: euse <option> [suboptions] [useflaglist]

Options: -h, --help           - show this message
         -V, --version        - show version information
         -i, --info           - show descriptions for the given useflags
         -I, --info-installed - show descriptions for the given useflags and
                                their current impact on the installed system
         -g, --global         - show only global use flags (suboption)
         -l, --local          - show only local use flags (suboption)
         -a, --active         - show currently active useflags and their origin
         -E, --enable         - enable the given useflags
         -D, --disable        - disable the given useflags
         -R, --remove         - remove all references to the given flags from
                                make.conf and package.use to revert to default
                                settings
         -P, --prune          - alias for --remove
         -p, --package        - used with -E, -D, and -R to apply to a
                                specific package only

Notes: euse currently works for global flags defined
       in make.globals, make.defaults, make.conf, use.force, and use.mask
       and local flags defined in package.use and individual package ebuilds.
       It might have issues with cascaded profiles. If multiple options are
       specified only the last one will be used.


tl;dr i don't understand this WARNING: 'portageq envvar PORTDIR' is deprecated. Use any of 'get_repos, get_repo_path, repos_config' instead.


Last edited by josephg on Tue Jan 26, 2016 7:03 pm; edited 1 time in total
Back to top
View user's profile Send private message
ian.au
Guru
Guru


Joined: 07 Apr 2011
Posts: 433
Location: Australia

PostPosted: Sat Jan 23, 2016 10:26 pm    Post subject: Re: app-portage/gentoolkit/euse Reply with quote

josephg wrote:

tl;dr i don't understand this WARNING: 'portageq envvar PORTDIR' is deprecated. Use any of 'get_repos, get_repo_path, repos_config' instead.

josephg,
You are probably missing a directory: /etc/portage/repos.conf in which case you can fix your error by
Code:
# mkdir /etc/portage/repos.conf
Code:
# cp /usr/share/portage/config/repos.conf /etc/portage/repos.conf/gentoo.conf


If you need to change from the default rsync settings, or run overlays you edit the gentoo.conf file, if you need to run an overlay, you add a new definition in repos.conf.

There's further reading here: https://wiki.gentoo.org/wiki/Project:Portage/Sync
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6228
Location: Room 101

PostPosted: Sat Jan 23, 2016 10:31 pm    Post subject: Re: app-portage/gentoolkit/euse Reply with quote

josephg wrote:
tl;dr i don't understand this WARNING: 'portageq envvar PORTDIR' is deprecated. Use any of 'get_repos, get_repo_path, repos_config' instead.

josephg ... don't play the innocent with us ;)

In the get_portdir() function comment the first line and add the second ...

/usr/bin/euse:
  #eval $(portageq envvar -v PORTDIR)
  : ${PORTDIR="$(portageq get_repo_path $(portageq envvar EROOT) gentoo)"}

... yes, that would be a bug, not all packages in the tree get the same level of love.

best ... khay
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 783
Location: usually offline

PostPosted: Sun Jan 24, 2016 12:52 am    Post subject: Re: app-portage/gentoolkit/euse Reply with quote

khayyam wrote:
josephg ... don't play the innocent with us ;)

i wasn't playing with you! i had absolutely no idea..

khayyam wrote:
In the get_portdir() function comment the first line and add the second ...

/usr/bin/euse:
  #eval $(portageq envvar -v PORTDIR)
  : ${PORTDIR="$(portageq get_repo_path $(portageq envvar EROOT) gentoo)"}

... yes, that would be a bug, not all packages in the tree get the same level of love.


what happens at the next sync, if i make such changes to the code? i don't want to be forever patching.. particularly if i end up out of sync with the repos :roll:
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6228
Location: Room 101

PostPosted: Sun Jan 24, 2016 1:16 am    Post subject: Re: app-portage/gentoolkit/euse Reply with quote

josephg wrote:
khayyam wrote:
josephg ... don't play the innocent with us ;)

i wasn't playing with you! i had absolutely no idea.

josephg ... yes, I know, I was being ironic.

josephg wrote:
khayyam wrote:
In the get_portdir() function comment the first line and add the second ...

/usr/bin/euse:
  #eval $(portageq envvar -v PORTDIR)
  : ${PORTDIR="$(portageq get_repo_path $(portageq envvar EROOT) gentoo)"}

... yes, that would be a bug, not all packages in the tree get the same level of love.

what happens at the next sync, if i make such changes to the code? i don't want to be forever patching.. particularly if i end up out of sync with the repos :roll:

It won't be effected by sync, only if you happen to re-merge the package. I wouldn't worry about it, by the time the package is updated the above fix should be taken care of. So, its temporary, but you shouldn't need to repeat.

best ... khay
Back to top
View user's profile Send private message
bandreabis
Advocate
Advocate


Joined: 18 Feb 2005
Posts: 2413
Location: イタリアのロディで

PostPosted: Tue Jan 26, 2016 1:20 pm    Post subject: Reply with quote

It's not so... temporary. :lol:
_________________
Il numero di post non fa di me un esperto! Anzi!
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6228
Location: Room 101

PostPosted: Tue Jan 26, 2016 1:31 pm    Post subject: Reply with quote

bandreabis wrote:
It's not so... temporary. :lol:

bandreabis ... why is that?

best ... khay
Back to top
View user's profile Send private message
bandreabis
Advocate
Advocate


Joined: 18 Feb 2005
Posts: 2413
Location: イタリアのロディで

PostPosted: Tue Jan 26, 2016 1:34 pm    Post subject: Reply with quote

This warning is not new as I can recall.
But it's a warning, only that.

:)
_________________
Il numero di post non fa di me un esperto! Anzi!
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6228
Location: Room 101

PostPosted: Tue Jan 26, 2016 2:37 pm    Post subject: Reply with quote

bandreabis wrote:
This warning is not new as I can recall. But it's a warning, only that.

bandreabis ... yes, but editing the script in none the less "temporary", and I wouldn't consider it a warning, it's not caused by the user but by the script using "depreciated" parameters, the user is bound to think they have done something to cause the error, and that *they* should "use any of". That is bad QA ... and the fact its labled "WARNING" is further bad QA.

best ... khay
Back to top
View user's profile Send private message
bandreabis
Advocate
Advocate


Joined: 18 Feb 2005
Posts: 2413
Location: イタリアのロディで

PostPosted: Tue Jan 26, 2016 3:25 pm    Post subject: Reply with quote

You're right.
Once you know it's not an user error, you can care none about.
It's annoying, by the way.
_________________
Il numero di post non fa di me un esperto! Anzi!
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 783
Location: usually offline

PostPosted: Tue Jan 26, 2016 7:00 pm    Post subject: Reply with quote

khayyam wrote:
I wouldn't consider it a warning, it's not caused by the user but by the script using "deprecated" parameters, the user is bound to think they have done something to cause the error, and that *they* should "use any of"

that's exactly what i was thinking!
.. and wondering if i should perhaps be removing PORTDIR from /etc/portage/make.conf
Back to top
View user's profile Send private message
mv
Watchman
Watchman


Joined: 20 Apr 2005
Posts: 6281

PostPosted: Tue Jan 26, 2016 9:15 pm    Post subject: Reply with quote

josephg wrote:
.. and wondering if i should perhaps be removing PORTDIR from /etc/portage/make.conf

Independent of the original discussion, the answer to this is: yes, you should. AFAIK, it is already ignored by portage anyway (for sure, if you have already configured repos.conf), so it is just a cause of confusion to yourself.
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 783
Location: usually offline

PostPosted: Tue Jan 26, 2016 9:50 pm    Post subject: Reply with quote

mv wrote:
josephg wrote:
.. and wondering if i should perhaps be removing PORTDIR from /etc/portage/make.conf

Independent of the original discussion, the answer to this is: yes, you should. AFAIK, it is already ignored by portage anyway (for sure, if you have already configured repos.conf), so it is just a cause of confusion to yourself.


if i remove PORTDIR, then these other *DIRs become invalid

josephg wrote:
i installed (almost) as per the x86 install handbook. as a result of that i have

Code:
 $ cat /etc/portage/make.conf | grep PORTDIR
PORTDIR="/usr/portage"
DISTDIR="${PORTDIR}/distfiles"
PKGDIR="${PORTDIR}/packages"
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 5761

PostPosted: Mon Feb 01, 2016 5:44 pm    Post subject: Reply with quote

IMO putting such frequently-written directories in /usr/ is a terrible default anyway; one of the first things I do on any system is change PORTDIR to /var/db/portage and DISTDIR to /var/cache/distfiles.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo 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