Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Q&A

I deselected a package and changed my mind. How to select it without re-emerging?

+2
−0

I executed

emerge --deselect xournalpp

, which means "I don't need the xournalpp package anymore", so it can be removed by a future --depclean action in case Portage figures xournalpp is not a dependency of any other installed package.

Hence the aforementioned command does not uninstall Xournalpp. It only removes it from the world file.

Now, suppose I realize that was a mistake* and want to keep Xournalpp. It seems only natural to use --select:

--select [ y | n ], -w
       Add specified packages to the world set (inverse of --oneshot).

However, Portage wants to re-emerge the package!

# emerge --ask --select xournalpp
These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R    ] app-text/xournalpp-1.0.20

Would you like to merge these packages? [Yes/No]

Although answering Yes would solve the problem, it entails essentially reinstalling the package (extracting the compressed file, re-compiling the package, ...), which is a waste of time — that may take from seconds to hours — and CPU cycles.

How do I add xournalpp back to the world file without emerging the already installed package?

*Actually my motivation to run that command was to find out the installed dependencies of Xournalpp that were not dependencies to any other package. I realize now there are better ways to do that, but the question stands.

History
Why does this post require moderator attention?
You might want to add some details to your flag.
Why should this post be closed?

0 comment threads

1 answer

+1
−0

From Selected-packages set (Portage) — Adding an atom without recompilation (yes, embarrassingly the very link in the question, the word "atom" put me off...),

emerge --noreplace xournalpp
--noreplace, -n
       Skips the packages specified on the command-line that have
       already been installed.  Without this option, any package atoms
       or package sets you specify on the command-line will cause
       Portage to remerge the package, even if it is already installed.
       Note that Portage will not remerge dependencies by default. This
       option can be used to update the world file without rebuilding
       the packages.

Used with --ask, the prompt will change accordingly to

* app-text/xournalpp

Would you like to add these packages to your world favorites? [Yes/No]
History
Why does this post require moderator attention?
You might want to add some details to your flag.

0 comment threads

Sign up to answer this question »