Gentoo - Replacing base files with custom built alternatives

This is a discussion on Gentoo - Replacing base files with custom built alternatives within the Linux General forums, part of the Linux Forums category; I am using Gentoo. I would like to replace some of my core files with custom built alternatives. For example, ...


Go Back   Usenet Forums > Linux Forums > Linux General

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 05-09-2008
Mark Hobley
 
Posts: n/a
Default Gentoo - Replacing base files with custom built alternatives

I am using Gentoo. I would like to replace some of my core files with
custom built alternatives. For example, I would like to replace
/bin/echo, /bin/ls, and lots of other base binaries.

Is there a way to lock these files out of the portage database,
preventing them from ever being overridden by portage.

Also, I would like to replace /etc/passwd, /etc/group, etc/shadow,
/etc/gshadow, and other key configuration files.

Is there a way to prevent these from being updated by portage?

Thanks in advance to anyone who can help.

Mark.

--
Mark Hobley,
393 Quinton Road West,
Quinton, BIRMINGHAM.
B32 1QE.
Reply With Quote
  #2 (permalink)  
Old 05-09-2008
AZ Nomad
 
Posts: n/a
Default Re: Gentoo - Replacing base files with custom built alternatives

On Fri, 09 May 2008 21:08:15 GMT, Mark Hobley <markhobley@hotpop.donottypethisbit.com> wrote:
>I am using Gentoo. I would like to replace some of my core files with
>custom built alternatives. For example, I would like to replace
>/bin/echo, /bin/ls, and lots of other base binaries.


>Is there a way to lock these files out of the portage database,
>preventing them from ever being overridden by portage.


>Also, I would like to replace /etc/passwd, /etc/group, etc/shadow,
>/etc/gshadow, and other key configuration files.


>Is there a way to prevent these from being updated by portage?


equery belongs <file> to find what package has them
then put the package in /etc/portage/profile/package.provided


>Thanks in advance to anyone who can help.


>Mark.


Reply With Quote
  #3 (permalink)  
Old 05-10-2008
Aragorn
 
Posts: n/a
Default Re: Gentoo - Replacing base files with custom built alternatives

Mark Hobley wrote:

> I am using Gentoo. I would like to replace some of my core files with
> custom built alternatives. For example, I would like to replace
> /bin/echo, /bin/ls, and lots of other base binaries. [...]


Just for the record, */bin/echo,* */bin/ls* and siblings are normally never
used if you're running GNU Bash as your command shell, because Bash has
those commands built-in.

These commands only exist as independent binaries for when you're running a
shell that doesn't have those commands built-in, like the very
minimal /ash/ shell, once popular on small-memory systems.

Just a FYI... ;-)

--
*Aragorn*
(registered GNU/Linux user #223157)
Reply With Quote
  #4 (permalink)  
Old 05-10-2008
Mark Hobley
 
Posts: n/a
Default /etc/portage or /etc/portage/profile

In alt.os.linux.gentoo AZ Nomad <aznomad.3@premoveobthisox.com> wrote:

> put the package in /etc/portage/profile/package.provided


Looking at my /etc directory, I notice that my package.* files are
located in /etc/portage as follows:

/etc/portage/package.keywords
/etc/portage/package.mask
/etc/portage/package.use

There is no subdirectory /etc/portage/profile/

Googling around, I find references to both /etc/portage and
/etc/portage/profile.

These files appear in different locations, depending on which
documentation I read. Hence I am confused.

Is it necessary to create a subdirectory "profile"?

Should I relocate my existing files /etc/portage files to a newly
created profile subdirectory, or is /etc/portage ok?

Do I have to modify or update scripts to reflect a change of location?

Please advise.

Mark.

--
Mark Hobley,
393 Quinton Road West,
Quinton, BIRMINGHAM.
B32 1QE.
Reply With Quote
  #5 (permalink)  
Old 05-11-2008
AZ Nomad
 
Posts: n/a
Default Re: /etc/portage or /etc/portage/profile

On Sat, 10 May 2008 18:08:05 GMT, Mark Hobley <markhobley@hotpop.donottypethisbit.com> wrote:
>In alt.os.linux.gentoo AZ Nomad <aznomad.3@premoveobthisox.com> wrote:


>> put the package in /etc/portage/profile/package.provided


>Looking at my /etc directory, I notice that my package.* files are
>located in /etc/portage as follows:


>/etc/portage/package.keywords
>/etc/portage/package.mask
>/etc/portage/package.use


>There is no subdirectory /etc/portage/profile/


>Googling around, I find references to both /etc/portage and
>/etc/portage/profile.


>These files appear in different locations, depending on which
>documentation I read. Hence I am confused.


>Is it necessary to create a subdirectory "profile"?


>Should I relocate my existing files /etc/portage files to a newly
>created profile subdirectory, or is /etc/portage ok?


>Do I have to modify or update scripts to reflect a change of location?



Create a file called /etc/portage/profile/package.provided. Create the profile
directory if needed.

In the file put the package category/name-version

For example, I have a /etc/portage/profile/package.provided with
the lines:
media-libs/libdvdread-0.9.7
media-video/transcode-1.0.6_rc2


It causes gentoo to think those packages are installed even though portage
didn't do it. If at some later date a newer package is required as a dependancy
such as a transcode-1.1.0, then portage will bitch and I'll have to manually
install a newer version (probably already done) and update the package.provided
file.



Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 09:56 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0