# HOWTO: clean install of X.org and XFree ban

## Wile E. Coyote

forget everything you read about  "emerge -i xfree..." or stupid things like this. I switched from XFree to XOrg quite well some month ago but I had a problem when I wanted to "emerge -u --deep world"

Portage wanted to emerge xfree back. To avoid dependencies involving xfree emerging, just follow these instruction   :Very Happy:  :

1) in /etc/portage/package.keywords add

```
x11-base/xorg-x11 ~x86

x11-terms/xterm ~x86

x11-base/opengl-update ~x86

```

2) Kill the XFree server and go to pure console mode

You can close your X session and usr [Ctrl+Alt+F1] to go to the console and then you can kill gdm/xdm. My method isn't maybe the cleaner way to do it, but it works.

```
ps -aux | grep gdm

kill <gdm's pid>

```

3) Uninstall Xfree

```
emerge unmerge xfree

```

4) in /etc/portage/package.mask add this line

(to mask xfree in the portage tree)

```
x11-base/xfree

```

5) emerge X.Org

Go on this pages to find more information about X.Org and its installation/configuration

http://www.gentoo.org/doc/en/xorg-config.xml

https://forums.gentoo.org/viewtopic.php?t=187389&highlight=xorg+howto

```
emerge xorg-x11

```

You'll need do to some changes to your configuration files

6) in /etc/make.profile/virtuals replace xfree by xorg-x11

(these lines are very important: the dependencies need to be corrected so that X.Org is the X11 server)

```
virtual/xfree    x11-base/xorg-x11

virtual/x11    x11-base/xorg-x11

virtual/opengl    x11-base/xorg-x11

virtual/glu    x11-base/xorg-x11

```

7) enjoy  :Cool: 

With these instruction when you try to update deeply the world (!) you won't have xfree dependencies anymore

Most of ebuilds are using virtual/x11 as dependency. So if you have still one ebuild that requires xfree, just correct it   :Wink: 

[/b]

----------

## codergeek42

If an ebuild still uses x11-base/xfree rather than virtual/x11, it should be noted as a bug, not "just [corrected]".

----------

## JOS654

you missed

 virtual/xft                             x11-base/xorg-x11

 :Wink: 

----------

## Wile E. Coyote

yeah and... to stop the graphic login the simple way is to use

```
/etc/init.d/xdm stop

```

I hope this mini tutorial would avoid pain and hours for everybody who want to switch to X.Org

 :Wink: 

----------

## mikl

Ah, that was helpful! Thanks a billion

----------

## Jamon

You should put/move this to Documentation, Tips & Tricks.  It looks nice though, especially for those who don't already use ~x86.   :Wink: 

	Jamon

----------

## soda_popstar

Sounds good... but it seems that /etc/make.profiles/virtuals gets overwritten every once in a while... I'm not sure if it's on every reboot or just when I emerge sync.  Are there any ways of getting around this?

----------

## Wile E. Coyote

Yes... each emerge sync seems to overwrite /etc/make.profile/virtuals

I think there is a way to define our own virtuals packets, but I still don't know why....  /var/cache/ebd/virtuals contains also virtual definitions... whe should maybe have a look at it.

----------

## cowm00n

In the current Gentoo tree, the package mask file doesn't seem to be in /etc/portage.  Instead:

```
$ locate package.mask

/usr/portage/profiles/package.mask

```

I added

```
x11-base/xfree
```

to this file and performed the other outlined procedures and that seemed to take care of things.

----------

## Malakai

 *cowm00n wrote:*   

> In the current Gentoo tree, the package mask file doesn't seem to be in /etc/portage.  Instead:
> 
> ```
> $ locate package.mask
> 
> ...

 

This is correct, however you should never modify those files.

To unmask something, create a file in /etc/portage/ called package.unmask (filename may be incorrect) with the app-arch/prog_name-version_number setup.

To make programs ~x86 by default, don't mess with any /usr/portage/ stuff either, create /etc/portage/package.keywords and do it from there.

----------

## Mongrol

Any remedy to the virtuals file getting overwritten on each rsync? Its really starting to piss me off now. I'd rather go back to xfree than suffer this.

----------

## gnuageux

 *Quote:*   

> ps -aux | grep gdm 
> 
> kill <gdm's pid>

 

ps -aux | grep gmd | xargs kill -9 ?? All in one line  :Smile:  !

----------

## cerebus_k

 *Mongrol wrote:*   

> Any remedy to the virtuals file getting overwritten on each rsync? Its really starting to piss me off now. I'd rather go back to xfree than suffer this.

 

Try pointing /etc/make.profile to /usr/portage/profiles/default-x86-2004.2 which contains a virtuals file that has the xorg-x11 (and not xfree).

----------

## Rainmaker

 *gnuageux wrote:*   

>  *Quote:*   ps -aux | grep gdm 
> 
> kill <gdm's pid> 
> 
> ps -aux | grep gmd | xargs kill -9 ?? All in one line  !

 

Also one line:

```
gdm-stop
```

 :Smile: 

----------

## Mongrol

 *cerebus_k wrote:*   

>  *Mongrol wrote:*   Any remedy to the virtuals file getting overwritten on each rsync? Its really starting to piss me off now. I'd rather go back to xfree than suffer this. 
> 
> Try pointing /etc/make.profile to /usr/portage/profiles/default-x86-2004.2 which contains a virtuals file that has the xorg-x11 (and not xfree).

 

Has this been tested? If the virtuals gets overwritten every rsync, whats to stop it doing it to the linked files as well?

----------

## Mongrol

aha, it works. I learn something new!

----------

## Jacobs

I don't think the /etc/make.profile symlink gets overwritten during each rsync (correct me if I'm wrong, but it wouldn't make much sense). In this case only the location where it points to is, which doesn't matter much cuz the 2004.2 virtuals don't use xfree by default.

----------

## The_Fang

How do I point /etc/make.profiles to /usr/portage/profiles/default-x86-2004.2?

----------

## The_Fang

How do I point /etc/make.profiles to /usr/portage/profiles/default-x86-2004.2?

----------

## bungernut

 *Quote:*   

>  The_Fang
> 
> Posted: Mon Jul 19, 2004 6:54 am    Post subject:
> 
> How do I point /etc/make.profiles to /usr/portage/profiles/default-x86-2004.2?

 

ln -sf  /usr/portage/profiles/default-x86-2004.2 /etc/make.profiles

man 'ln' to double check.. (thats LN in small letters)

QUESTION:

Do you have to all or any of the above (in the How-To) when you change to xorg if you change your make.profile??

----------

## jbmagic

ln -sf /usr/portage/profiles/default-x86-2004.2 /etc/make.profiles 

it should be profile not profiles at end

correct way is 

ln -s /usr/portage/profiles/default-x86-2004.2 /etc/make.profile

----------

## BennyP

this is a bit OT but i didnt want to make a new thread.

when xorg finished emerging, there was all sorts ofy useful text displayed on the console (green gentoo text) that told me about how to set up glide, cursors, etc. but the emerge continued and i couldn't read it all. How can I call up that text again?

----------

## The_Fang

thanks for the help.

I am sorry for the double post.

----------

## Rainmaker

 *Mongrol wrote:*   

>  *cerebus_k wrote:*    *Mongrol wrote:*   Any remedy to the virtuals file getting overwritten on each rsync? Its really starting to piss me off now. I'd rather go back to xfree than suffer this. 
> 
> Try pointing /etc/make.profile to /usr/portage/profiles/default-x86-2004.2 which contains a virtuals file that has the xorg-x11 (and not xfree). 
> 
> Has this been tested? If the virtuals gets overwritten every rsync, whats to stop it doing it to the linked files as well?

 

read this post if you REALLY want to do this... But read the posts of the devs to!

----------

## alar_k

 *BennyP wrote:*   

> this is a bit OT but i didnt want to make a new thread.
> 
> when xorg finished emerging, there was all sorts ofy useful text displayed on the console (green gentoo text) that told me about how to set up glide, cursors, etc. but the emerge continued and i couldn't read it all. How can I call up that text again?

 

Read the file /usr/portage/x11-base/xorg-x11/xorg-x11-6.7.0-r1.ebuild. There is a section named print_info at the end of the file.

----------

## toddles13

Thanks "Wile E. Coyote", works for me.   :Laughing: 

----------

## KingPunk

ok. im trying to get xft emerged with an install of xorg.. following

the guide given on page 1, i've done the following..

```

cat /etc/make.profile/virtuals

<snip>

virtual/xfree           x11-base/xorg-x11

virtual/x11             x11-base/xorg-x11

virtual/opengl          x11-base/xorg-x11

virtual/glu             x11-base/xorg-x11

virtual/xft             x11-base/xorg-x11

```

and..

```

cat /etc/portage/package.mask

..

x11-base/xfree

```

and..

```

cat /etc/portage/package.keywords

..

x11-base/xorg-x11 ~x86

x11-terms/xterm ~x86

x11-base/opengl-update ~x86

```

yet..

```

# emerge -p xft

These are the packages that I would merge, in order:

Calculating dependencies \

!!! all ebuilds that could satisfy "x11-base/xfree" have been masked.

!!! possible candidates are:

- x11-base/xfree-4.3.0-r5 (masked by: package.mask)

- x11-base/xfree-4.3.0-r6 (masked by: package.mask)

- x11-base/xfree-4.3.0-r7 (masked by: package.mask, ~keyword)

!!!    (dependency required by "x11-libs/xft-2.0.1-r2" [ebuild])

!!! Error calculating dependencies. Please correct.

```

And i've added xft to the virtuals file.. and it doesn't seem to solve the

issue. what gives? Thank you in advance!

  ~KingPunk

----------

## KingPunk

...i still await a resolve for this issue  :Sad: 

*BUMP*

----------

## toddles13

cat /etc/make.profile/virtuals

Shouldn't show xfree anywhere. Just replace all instances of xfree with xorg-x11 and see what that does.

Worth a shot.

----------

## KingPunk

the virtual in that file.. is to redirect stuff, that needs xfree, 

as a dependacy, to the xorg package instead.

so im one slightly confused dog. lol. *bark*

----------

## bungernut

TO: KingPunk, have you tried changing your make.profile??

----------

## KingPunk

 *bungernut wrote:*   

> TO: KingPunk, have you tried changing your make.profile??

 

and what should i change it to, i don't think i fully understand the question.

:/

----------

## cold_flame

 *Rainmaker wrote:*   

>  *gnuageux wrote:*    *Quote:*   ps -aux | grep gdm 
> 
> kill <gdm's pid> 
> 
> ps -aux | grep gmd | xargs kill -9 ?? All in one line  ! 
> ...

 

pkill {kdm,gdm,xdm}

pkill is your friend.  :Smile: 

----------

## ian!

Moved from 'Desktop Environments' to 'Documentation, Tips & Tricks'.

----------

