Difference between pages "Xfce" and "Funtoo 1.0 Profile"

(Difference between pages)
(About Xfce)
 
(Remove redundant subtopic...)
 
Line 1: Line 1:
== About Xfce ==
+
== What is a profile? ==
  
Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.
+
In Gentoo and Funtoo Linux, profiles are used to define base system settings, and have historically had a lot of untapped potential. In Funtoo Linux, I wanted to take advantage of some of this potential to allow Funtoo Linux users to easily tailor their system for various types of roles. Enter the new Funtoo profile system.
  
Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.
+
== What It Is ==
  
Another priority of Xfce is adhereance to standards, specifically those defined at [http://freedesktop.org/ freedesktop.org]. [http://www.xfce.org/about/ About XFCE]
+
Historically, users have had to add a ton of settings to <tt>/etc/make.conf</tt> to customize their Gentoo or Funtoo Linux system, which made setup of the operating system more difficult than it should be.
  
== Installation ==
+
In Gentoo Linux, it is possible to only define one ''system profile''. Think of a system profile as the default settings that Portage uses for building everything on your system.
  
Before emerging Xfce you need to:
+
In Funtoo Linux, multiple profiles can be enabled at the same time. These include:
  
* Check that you have enabled the USE flags necessary for a XFCE desktop environment. [[Funtoo_Linux_First_Steps#Changing_profile|Set your profile to "xfce" via mix-ins]], as follows:
+
* '''arch''' - one arch profile is enabled, at build time, and is not changed. This defines CPU architecture-specific settings.
 +
* '''build''' - one build profile is enabled, at build time, and is generally not changed. It defines the type of build, such as 'current' or 'stable', and associated settings.
 +
* '''flavor''' - one flavor is enabled per system, and can be changed by the user. This defines the general use of the system, such as 'minimal', 'core', 'workstation' or 'desktop'
 +
* '''mix-in''' - zero or more mix-ins can be enabled that enable settings specific to a particular subset of features, such as 'gnome', 'kde', 'media', 'mate', 'X', 'hardened'
  
<console>
+
{{Fancynote|1=
# ##i## eselect profile add funtoo/1.0/linux-gnu/mix-ins/xfce
+
See [[Flavors and Mix-ins]] for a complete list of all flavors and mix-ins available in Funtoo Linux, along with descriptions of what each one does.}}
</console>
+
  
* Verify that you have [[Funtoo_Linux_First_Steps#X.Org|X.Org Server]] configured properly.
+
=== Origins and Benefits ===
  
We are now ready to install Xfce. Install the meta-package, which pulls in all of the components you need for a minimal Xfce installation:
+
This new system is really a completion of the original cascading profile design that was designed by Daniel Robbins and implemented by Seemant Kulleen as part of Portage. Funtoo Profiles designed to leverage the existing cascading profile system and provide something much more useable and maintainable for users and developers alike. Here are some of its benefits:
  
<console>
+
* Fewer settings in /etc/make.conf. <tt>CHOST</tt> and <tt>ARCH</tt> no longer set in <tt>/etc/make.conf</tt>.
# ##i##emerge xfce4-meta
+
* Separation of concerns -- arch, build, and flavor-related settings are organized together.
</console>
+
* User flexibility - any number of mix-ins can be enabled to tweak masks or USE settings as needed.
  
== Running Xfce ==
+
{{fancynote|See [[Custom Profiles]] for information on how to extend the profile system.}}
  
There are several different ways to start Xfce:
+
== Switch to the Funtoo 1.0 Profile ==
  
* Editing the <tt>.xinitrc</tt> file in your user's home directory and using <tt>startx</tt> from a text console.
+
=== Using eselect ===
* Using a display manager (e.g. SLiM, GDM, and KDM).
+
The preferred method of adding and removing profiles is to use [[eselect|eselect profile]]. This will ensure that profiles are added correctly and in the proper order. The order is imperative for things to work right.
* Configuring your shell profile to automatically start Xfce upon a successful login.
+
  
=== .xinitrc ===
+
Type the following to view a list of available options for '''eselect profile''':
 +
<console>
 +
###i## eselect profile help
 +
</console>
  
The most common way to start the environment is to configure <tt>~/.xinitrc</tt> to launch an Xfce session. The proper way to launch Xfce from the terminal is by using <tt>startxfce4</tt> combined with <tt>ck-launch-session</tt>.
 
  
 +
For a start, let's see what the default configuration has to offer. Get an overview using the '''list''' command:
 
<console>
 
<console>
$ ##i##echo "exec startxfce4 --with-ck-launch" > ~/.xinitrc
+
###i## eselect profile list
 +
##b####g##Currently available arch profiles:
 +
  ##b##[1]  funtoo/1.0/linux-gnu/arch/x86-64bit##!b## *
 +
  ##b##[2]##!b##  funtoo/1.0/linux-gnu/arch/pure64
 +
##b####g##Currently available build profiles:
 +
  ##b##[3]##!b##  funtoo/1.0/linux-gnu/build/stable
 +
  ##b##[4]  funtoo/1.0/linux-gnu/build/current##!b## *
 +
  ##b##[5]##!b##  funtoo/1.0/linux-gnu/build/experimental
 +
##b####g##Currently available flavor profiles:
 +
  ##b##[6]##!b##  funtoo/1.0/linux-gnu/flavor/minimal
 +
  ##b##[7]  funtoo/1.0/linux-gnu/flavor/core##!b## *
 +
  ##b##[8]##!b##  funtoo/1.0/linux-gnu/flavor/desktop
 +
  ##b##[9]##!b##  funtoo/1.0/linux-gnu/flavor/workstation
 +
  ##b##[10]##!b##  funtoo/1.0/linux-gnu/flavor/hardened
 +
##b####g##Currently available mix-ins profiles:
 +
  ##b##[11]##!b##  funtoo/1.0/linux-gnu/mix-ins/audio
 +
  ##b##[12]##!b##  funtoo/1.0/linux-gnu/mix-ins/cinnamon
 +
  ##b##[13]##!b##  funtoo/1.0/linux-gnu/mix-ins/console-extras
 +
  ##b##[14]##!b##  funtoo/1.0/linux-gnu/mix-ins/dvd
 +
  ##b##[15]##!b##  funtoo/1.0/linux-gnu/mix-ins/gnome
 +
  ##b##[16]##!b##  funtoo/1.0/linux-gnu/mix-ins/kde
 +
  ##b##[17]##!b##  funtoo/1.0/linux-gnu/mix-ins/mate
 +
  ##b##[18]##!b##  funtoo/1.0/linux-gnu/mix-ins/media
 +
  ##b##[19]##!b##  funtoo/1.0/linux-gnu/mix-ins/print
 +
  ##b##[20]##!b##  funtoo/1.0/linux-gnu/mix-ins/python3-only
 +
  ##b##[21]##!b##  funtoo/1.0/linux-gnu/mix-ins/rhel5-compat
 +
  ##b##[22]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-db
 +
  ##b##[23]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-mail
 +
  ##b##[24]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-web
 +
  ##b##[25]##!b##  funtoo/1.0/linux-gnu/mix-ins/X
 +
  ##b##[26]##!b##  funtoo/1.0/linux-gnu/mix-ins/xfce
 +
  ##b##[27]##!b##  funtoo/1.0/linux-gnu/mix-ins/vmware-guest
 +
  ##b##[28]##!b##  funtoo/1.0/linux-gnu/mix-ins/hardened
 
</console>
 
</console>
  
Note that <tt>--with-ck-launch</tt> (from ConsoleKit) is required by Xfce for important tasks such as shutting down, suspending, and automatically mounting removable storage media. Some applications will not work properly without it. Therefore we need to add ConsoleKit to the <tt>default</tt> runlevel, executing the following command as root:
+
As in several other Funtoo utilities, a star ('''*''') on the right indicates an active item (your case may differ from the example above).
 +
In most cases you will want to set your "flavor" first. Remember that you can only set ''one'' flavor at time.
  
<console>
+
To choose your favorite flavor use the '''set-flavor''' command including your selection. In this example, we will set the '''desktop''' flavor:
# ##i##rc-update add consolekit default
+
{{Fancynote| You ''must'' use numbers to reference to the profiles you want.}}
 +
<console>###i## eselect profile set-flavor 8</console>
 +
View the result:
 +
<console>###i## eselect profile list
 +
##b####g##Currently available arch profiles:
 +
  ##b##[1]  funtoo/1.0/linux-gnu/arch/x86-64bit##!b## *
 +
  ##b##[2]##!b##  funtoo/1.0/linux-gnu/arch/pure64
 +
##b####g##Currently available build profiles:
 +
  ##b##[3]##!b##  funtoo/1.0/linux-gnu/build/stable
 +
  ##b##[4]  funtoo/1.0/linux-gnu/build/current##!b## *
 +
  ##b##[5]##!b##  funtoo/1.0/linux-gnu/build/experimental
 +
##b####g##Currently available flavor profiles:
 +
  ##b##[6]##!b##  funtoo/1.0/linux-gnu/flavor/minimal
 +
  ##b##[7]##!b##  funtoo/1.0/linux-gnu/flavor/core
 +
  ##b##[8]  funtoo/1.0/linux-gnu/flavor/desktop##!b## *
 +
  ##b##[9]##!b##  funtoo/1.0/linux-gnu/flavor/workstation
 +
  ##b##[10]##!b##  funtoo/1.0/linux-gnu/flavor/hardened
 +
##b####g##Currently available mix-ins profiles:
 +
  ##b##[11]  funtoo/1.0/linux-gnu/mix-ins/audio (auto)
 +
  ##b##[12]##!b##  funtoo/1.0/linux-gnu/mix-ins/cinnamon
 +
  ##b##[13]  funtoo/1.0/linux-gnu/mix-ins/console-extras (auto)
 +
  ##b##[14]  funtoo/1.0/linux-gnu/mix-ins/dvd (auto)
 +
  ##b##[15]##!b##  funtoo/1.0/linux-gnu/mix-ins/gnome
 +
  ##b##[16]##!b##  funtoo/1.0/linux-gnu/mix-ins/kde
 +
  ##b##[17]##!b##  funtoo/1.0/linux-gnu/mix-ins/mate
 +
  ##b##[18]  funtoo/1.0/linux-gnu/mix-ins/media (auto)
 +
  ##b##[19]  funtoo/1.0/linux-gnu/mix-ins/print (auto)
 +
  ##b##[20]##!b##  funtoo/1.0/linux-gnu/mix-ins/python3-only
 +
  ##b##[21]##!b##  funtoo/1.0/linux-gnu/mix-ins/rhel5-compat
 +
  ##b##[22]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-db
 +
  ##b##[23]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-mail
 +
  ##b##[24]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-web
 +
  ##b##[25]  funtoo/1.0/linux-gnu/mix-ins/X (auto)
 +
  ##b##[26]##!b##  funtoo/1.0/linux-gnu/mix-ins/xfce
 +
  ##b##[27]##!b##  funtoo/1.0/linux-gnu/mix-ins/vmware-guest
 +
  ##b##[28]##!b##  funtoo/1.0/linux-gnu/mix-ins/hardened
 
</console>
 
</console>
 +
As you see by the '''(auto)''' entries, the <code>desktop</code> flavor already pre-set some mix-ins for you.
 +
 +
Now, let's head over and add some mix-ins. To add, say, the mix-ins '''gnome''' and '''kde''' we'd have to enter:
  
Finally, to start the graphical environment, run <tt>startx</tt> from a login shell:
 
 
<console>
 
<console>
$ ##i##startx
+
###i## eselect profile add 15
 +
###i## eselect profile add 16
 
</console>
 
</console>
  
== Display Manager ==
+
Or, in a one-shot:
 
+
A display manager is a program that manages sessions and acts as a login screen. Here's a short list of a few of the display managers available in Funtoo:
+
 
+
* XDM (<tt>x11-apps/xdm</tt>): X.Org's standard display manager.
+
 
+
* LightDM (<tt>x11-misc/lightdm</tt>): A lightweight, but highly configurable display manager.
+
 
+
* SLiM (<tt>x11-misc/slim</tt>): Simple Login Manager -- a lightweight display manager. Not very configurable.
+
 
+
Any of these would make a fine choice. After you've chosen which display manager to use, install it:
+
  
 
<console>
 
<console>
# ##i##emerge lightdm
+
###i## eselect profile add 15 16
 
</console>
 
</console>
  
All that's left to do now is to add the name of the display manager to <tt>/etc/conf.d/xdm</tt>, add the <tt>xdm</tt> service to the <tt>default</tt> runlevel, and start the service:
+
If we want to remove a mix-in, for example '''gnome''', simply enter:
 
+
<pre>
+
DISPLAYMANAGER="lightdm"
+
</pre>
+
  
 
<console>
 
<console>
# ##i##rc-update add xdm default
+
###i## eselect profile remove 15
# ##i##/etc/init.d/xdm start
+
 
</console>
 
</console>
  
==Power Group==
+
Verification:
  
If you wish to be able to shutdown/reboot/suspend/hibernate using xfce4-logout-session then you will need to add yourself or the user to the power group by:
+
<console>###i## eselect profile list
 
+
##b####g##Currently available arch profiles:
<console>
+
  ##b##[1]  funtoo/1.0/linux-gnu/arch/x86-64bit##!b## *
# ##i##gpasswd -a <username> power
+
  ##b##[2]##!b##  funtoo/1.0/linux-gnu/arch/pure64
 +
##b####g##Currently available build profiles:
 +
  ##b##[3]##!b##  funtoo/1.0/linux-gnu/build/stable
 +
  ##b##[4]  funtoo/1.0/linux-gnu/build/current##!b## *
 +
  ##b##[5]##!b##  funtoo/1.0/linux-gnu/build/experimental
 +
##b####g##Currently available flavor profiles:
 +
  ##b##[6]##!b##  funtoo/1.0/linux-gnu/flavor/minimal
 +
  ##b##[7]##!b##  funtoo/1.0/linux-gnu/flavor/core
 +
  ##b##[8]  funtoo/1.0/linux-gnu/flavor/desktop##!b## *
 +
  ##b##[9]##!b##  funtoo/1.0/linux-gnu/flavor/workstation
 +
  ##b##[10]##!b##  funtoo/1.0/linux-gnu/flavor/hardened
 +
##b####g##Currently available mix-ins profiles:
 +
  ##b##[11]  funtoo/1.0/linux-gnu/mix-ins/audio (auto)
 +
  ##b##[12]##!b##  funtoo/1.0/linux-gnu/mix-ins/cinnamon
 +
  ##b##[13]  funtoo/1.0/linux-gnu/mix-ins/console-extras (auto)
 +
  ##b##[14] funtoo/1.0/linux-gnu/mix-ins/dvd (auto)
 +
  ##b##[15]##!b##  funtoo/1.0/linux-gnu/mix-ins/gnome
 +
  ##b##[16]  funtoo/1.0/linux-gnu/mix-ins/kde *
 +
  ##b##[17]##!b##  funtoo/1.0/linux-gnu/mix-ins/mate
 +
  ##b##[18]  funtoo/1.0/linux-gnu/mix-ins/media (auto)
 +
  ##b##[19]  funtoo/1.0/linux-gnu/mix-ins/print (auto)
 +
  ##b##[20]##!b##  funtoo/1.0/linux-gnu/mix-ins/python3-only
 +
  ##b##[21]##!b##  funtoo/1.0/linux-gnu/mix-ins/rhel5-compat
 +
  ##b##[22]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-db
 +
  ##b##[23]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-mail
 +
  ##b##[24]##!b##  funtoo/1.0/linux-gnu/mix-ins/server-web
 +
  ##b##[25]  funtoo/1.0/linux-gnu/mix-ins/X (auto)
 +
  ##b##[26]##!b##  funtoo/1.0/linux-gnu/mix-ins/xfce
 +
  ##b##[27]##!b##  funtoo/1.0/linux-gnu/mix-ins/vmware-guest
 +
  ##b##[28]##!b##  funtoo/1.0/linux-gnu/mix-ins/hardened
 
</console>
 
</console>
  
If the group does not exist then execute the following and try again:
 
  
 +
No magic here, whatever you add gets put into the <code>/etc/portage/make.profile/parent</code> file by portage.
 +
 +
In our case, this file contains:
 
<console>
 
<console>
# ##i##groupadd power
+
###i## cat /etc/portage/make.profile/parent
 +
gentoo:funtoo/1.0/linux-gnu/arch/x86-64bit
 +
gentoo:funtoo/1.0/linux-gnu/build/current
 +
gentoo:funtoo/1.0/linux-gnu/flavor/desktop
 +
gentoo:funtoo/1.0/linux-gnu/mix-ins/kde
 
</console>
 
</console>
 +
{{fancywarning|Please, do not add anything manually into <tt>parent</tt> file. This may result in profile breakage.}}
  
Now you need to add the following to /usr/share/polkit-1/actions/org.freedesktop.upower.policy:
+
== For Developers ==
  
{{file|lang=xml|name=/usr/share/polkit-1/actions/org.freedesktop.upower.policy|desc=|body=
+
=== Define the profile sub-sets you will use ===
<?xml version="1.0" encoding="UTF-8"?>
+
<!DOCTYPE policyconfig PUBLIC
+
"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
+
"http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
+
<policyconfig>
+
  <vendor>The UPower Project</vendor>
+
  <vendor_url>http://upower.freedesktop.org/</vendor_url>
+
  <icon_name>system-suspend</icon_name>
+
  
  <action id="org.freedesktop.upower.suspend">
+
So far in Funtoo we have used the exact same profiles as Gentoo thus Funtoo/2008.0 was strictly the same thing as Gentoo/2008.0 or the barely the same 10.0. This (monolithic) profile was set though a symbolic link named '''/etc/make.profile''' pointing on a complex directory architecture located somewhere under '''/usr/portage/profiles'''. This is no longer valid with the Funtoo 1.0 profiles as they are split in several smaller bricks which are then glued together via the '''/etc/portage/make.profile/parent''' file (You do not need to include everything, just use the "bricks" you need). Those bricks belongs to several categories:
    <description>Suspend the system</description>
+
    <description xml:lang="fr">Mettre le système en veille</description>
+
    <description xml:lang="it">Sospende il sistema</description>
+
    <description xml:lang="pl">Wstrzymanie systemu</description>
+
    <description xml:lang="sv">Försätt systemet i vänteläge</description>
+
    <message>Authentication is required to suspend the system</message>
+
    <message xml:lang="fr">Vous devez vous identifier pour mettre le système en veille</message>
+
    <message xml:lang="it">È richiesto autenticarsi per sospendere il sistema</message>
+
    <message xml:lang="pl">Wymagane jest uwierzytelnienie, aby wstrzymać system</message>
+
    <message xml:lang="sv">Autentisering krävs för att försätta systemet i vänteläge</message>
+
    <defaults>
+
      <allow_any>yes</allow_any>
+
      <allow_inactive>no</allow_inactive>
+
      <allow_active>yes</allow_active>
+
    </defaults>
+
  </action>
+
  
  <action id="org.freedesktop.upower.hibernate">
+
1. MANDATORY -- An "arch" profile which defines settings for a particular architecture. You'll want to set this to whatever arch your system is and leave it alone. '''Setting it to a different arch than your system could severely break it.'''
    <description>Hibernate the system</description>
+
    <description xml:lang="fr">Mettre le système en hibernation</description>
+
    <description xml:lang="it">Iberna il sistema</description>
+
    <description xml:lang="pl">Hibernacja systemu</description>
+
    <description xml:lang="sv">Försätt systemet i viloläge</description>
+
    <message>Authentication is required to hibernate the system</message>
+
    <message xml:lang="fr">Vous devez vous identifier pour mettre le système en hibernation</message>
+
    <message xml:lang="it">È richiesto autenticarsi per ibernare il sistema</message>
+
    <message xml:lang="pl">Wymagane jest uwierzytelnienie, aby zahibernować system</message>
+
    <message xml:lang="sv">Autentisering krävs för att försätta systemet i viloläge</message>
+
    <defaults>
+
      <allow_any>yes</allow_any>
+
      <allow_inactive>no</allow_inactive>
+
      <allow_active>yes</allow_active>
+
    </defaults>
+
  </action>
+
  
</policyconfig>
+
2. MANDATORY -- A "build" profile which should match the tree you wish to use. '''Stable''', '''Current''' (~arch), or '''Experimental''' (use it if you are brave enough and find '''current''' too stable).
}}
+
  
and also add the following to /usr/share/polkit-1/actions/org.freedesktop.consolekit.policy:
+
3. MANDATORY -- A "flavor" profile (what was previously known as ''profiles'' is still known as such in Gentoo) which describes the kind of system you want.
 +
* minimal - Be warned, minimal is exactly what it says, the minimal profile stuff you need for a usable system, nothing else. This is really for people who know what they're doing.
 +
* core - This is the core profile. This is for stuff that affects both desktops and servers.
 +
* desktop - Exactly what it says. If you're using a desktop, you should set this as your flavor.
 +
* server - If you're running a server, you should set this as your flavor.
  
{{file|lang=xml|name=/usr/share/polkit-1/actions/org.freedesktop.consolekit.policy|desc= |body=
+
4. OPTIONAL -- One or more "mix-ins" profiles which describe optional add-ons. 'mix-ins' are the heart of the Funtoo 1.0 profiles. Unlike the monolithic profiles which sets a massive amount of use flags and options for you, we've split them into logical add-on profiles. For instance if you want support for gnome, you would add the gnome mix-in to your current profiles. That mix-in sets all the proper use flags and such for gnome. Same with others. Want dvd support? Add that one in. Using a rhel5 kernel which requires special versions of packages such as udev? There's a mix-in for that too. Run a mail server? web server? There's mix-ins for those also. Expect this category to grow in the future as new mix-ins are created.
<?xml version="1.0" encoding="UTF-8"?>
+
<!DOCTYPE policyconfig PUBLIC
+
"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
+
"http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
+
  
<!--
+
The contents of '''/etc/portage/make.profile/parent''' for a basic setup might look like this:
Policy definitions for ConsoleKit
+
-->
+
  
<policyconfig>
+
<pre>
 +
gentoo:funtoo/1.0/linux-gnu/arch/x86-64bit
 +
gentoo:funtoo/1.0/linux-gnu/build/current
 +
gentoo:funtoo/1.0/linux-gnu/flavor/core
 +
</pre>
  
  <action id="org.freedesktop.consolekit.system.stop">
+
A more rounded setup for a desktop might look like this:
    <description>Stop the system</description>
+
    <message>System policy prevents stopping the system</message>
+
    <defaults>
+
      <allow_any>yes</allow_any>
+
      <allow_inactive>no</allow_inactive>
+
      <allow_active>yes</allow_active>
+
    </defaults>
+
  </action>
+
  
  <action id="org.freedesktop.consolekit.system.stop-multiple-users">
+
<pre>
    <description>Stop the system when multiple users are logged in</description>
+
gentoo:funtoo/1.0/linux-gnu/arch/x86-64bit
    <message>System policy prevents stopping the system when other users are logged in</message>
+
gentoo:funtoo/1.0/linux-gnu/build/current
    <defaults>
+
gentoo:funtoo/1.0/linux-gnu/flavor/desktop
      <allow_any>yes</allow_any>
+
gentoo:funtoo/1.0/linux-gnu/mix-ins/dvd
      <allow_inactive>no</allow_inactive>
+
gentoo:funtoo/1.0/linux-gnu/mix-ins/media
      <allow_active>yes</allow_active>
+
</pre>
    </defaults>
+
  </action>
+
 
+
  <action id="org.freedesktop.consolekit.system.restart">
+
    <description>Restart the system</description>
+
    <message>System policy prevents restarting the system</message>
+
    <defaults>
+
      <allow_any>yes</allow_any>
+
      <allow_inactive>no</allow_inactive>
+
      <allow_active>yes</allow_active>
+
    </defaults>
+
  </action>
+
 
+
  <action id="org.freedesktop.consolekit.system.restart-multiple-users">
+
    <description>Restart the system when multiple users are logged in</description>
+
    <message>System policy prevents restarting the system when other users are logged in</message>
+
    <defaults>
+
      <allow_any>yes</allow_any>
+
      <allow_inactive>no</allow_inactive>
+
      <allow_active>yes</allow_active>
+
    </defaults>
+
  </action>
+
  
</policyconfig>
+
== Related ==
}}
+
* [[Flavors and Mix-ins]]
  
[[Category:Desktop]]
+
[[Category:Funtoo features]]
[[Category:First Steps]]
+
[[Category:Portage]]
 +
[[Category:Labs]]
 +
[[Category:HOWTO]]
 
[[Category:Official Documentation]]
 
[[Category:Official Documentation]]

Revision as of 23:33, 18 September 2014

What is a profile?

In Gentoo and Funtoo Linux, profiles are used to define base system settings, and have historically had a lot of untapped potential. In Funtoo Linux, I wanted to take advantage of some of this potential to allow Funtoo Linux users to easily tailor their system for various types of roles. Enter the new Funtoo profile system.

What It Is

Historically, users have had to add a ton of settings to /etc/make.conf to customize their Gentoo or Funtoo Linux system, which made setup of the operating system more difficult than it should be.

In Gentoo Linux, it is possible to only define one system profile. Think of a system profile as the default settings that Portage uses for building everything on your system.

In Funtoo Linux, multiple profiles can be enabled at the same time. These include:

  • arch - one arch profile is enabled, at build time, and is not changed. This defines CPU architecture-specific settings.
  • build - one build profile is enabled, at build time, and is generally not changed. It defines the type of build, such as 'current' or 'stable', and associated settings.
  • flavor - one flavor is enabled per system, and can be changed by the user. This defines the general use of the system, such as 'minimal', 'core', 'workstation' or 'desktop'
  • mix-in - zero or more mix-ins can be enabled that enable settings specific to a particular subset of features, such as 'gnome', 'kde', 'media', 'mate', 'X', 'hardened'

Note

See Flavors and Mix-ins for a complete list of all flavors and mix-ins available in Funtoo Linux, along with descriptions of what each one does.

Origins and Benefits

This new system is really a completion of the original cascading profile design that was designed by Daniel Robbins and implemented by Seemant Kulleen as part of Portage. Funtoo Profiles designed to leverage the existing cascading profile system and provide something much more useable and maintainable for users and developers alike. Here are some of its benefits:

  • Fewer settings in /etc/make.conf. CHOST and ARCH no longer set in /etc/make.conf.
  • Separation of concerns -- arch, build, and flavor-related settings are organized together.
  • User flexibility - any number of mix-ins can be enabled to tweak masks or USE settings as needed.

Note

See Custom Profiles for information on how to extend the profile system.

Switch to the Funtoo 1.0 Profile

Using eselect

The preferred method of adding and removing profiles is to use eselect profile. This will ensure that profiles are added correctly and in the proper order. The order is imperative for things to work right.

Type the following to view a list of available options for eselect profile:

# eselect profile help


For a start, let's see what the default configuration has to offer. Get an overview using the list command:

# eselect profile list
Currently available arch profiles:
  [1]   funtoo/1.0/linux-gnu/arch/x86-64bit * 
  [2]   funtoo/1.0/linux-gnu/arch/pure64
Currently available build profiles:
  [3]   funtoo/1.0/linux-gnu/build/stable
  [4]  funtoo/1.0/linux-gnu/build/current * 
  [5]   funtoo/1.0/linux-gnu/build/experimental
Currently available flavor profiles:
  [6]   funtoo/1.0/linux-gnu/flavor/minimal
  [7]   funtoo/1.0/linux-gnu/flavor/core *
  [8]   funtoo/1.0/linux-gnu/flavor/desktop
  [9]   funtoo/1.0/linux-gnu/flavor/workstation
  [10]  funtoo/1.0/linux-gnu/flavor/hardened
Currently available mix-ins profiles:
  [11]  funtoo/1.0/linux-gnu/mix-ins/audio
  [12]  funtoo/1.0/linux-gnu/mix-ins/cinnamon
  [13]  funtoo/1.0/linux-gnu/mix-ins/console-extras
  [14]  funtoo/1.0/linux-gnu/mix-ins/dvd
  [15]  funtoo/1.0/linux-gnu/mix-ins/gnome
  [16]  funtoo/1.0/linux-gnu/mix-ins/kde
  [17]  funtoo/1.0/linux-gnu/mix-ins/mate
  [18]  funtoo/1.0/linux-gnu/mix-ins/media
  [19]  funtoo/1.0/linux-gnu/mix-ins/print
  [20]  funtoo/1.0/linux-gnu/mix-ins/python3-only
  [21]  funtoo/1.0/linux-gnu/mix-ins/rhel5-compat
  [22]  funtoo/1.0/linux-gnu/mix-ins/server-db
  [23]  funtoo/1.0/linux-gnu/mix-ins/server-mail
  [24]  funtoo/1.0/linux-gnu/mix-ins/server-web
  [25]  funtoo/1.0/linux-gnu/mix-ins/X
  [26]  funtoo/1.0/linux-gnu/mix-ins/xfce
  [27]  funtoo/1.0/linux-gnu/mix-ins/vmware-guest
  [28]  funtoo/1.0/linux-gnu/mix-ins/hardened

As in several other Funtoo utilities, a star (*) on the right indicates an active item (your case may differ from the example above). In most cases you will want to set your "flavor" first. Remember that you can only set one flavor at time.

To choose your favorite flavor use the set-flavor command including your selection. In this example, we will set the desktop flavor:

Note

You must use numbers to reference to the profiles you want.
# eselect profile set-flavor 8

View the result:

# eselect profile list
Currently available arch profiles:
  [1]   funtoo/1.0/linux-gnu/arch/x86-64bit * 
  [2]   funtoo/1.0/linux-gnu/arch/pure64
Currently available build profiles:
  [3]   funtoo/1.0/linux-gnu/build/stable
  [4]  funtoo/1.0/linux-gnu/build/current * 
  [5]   funtoo/1.0/linux-gnu/build/experimental
Currently available flavor profiles:
  [6]   funtoo/1.0/linux-gnu/flavor/minimal
  [7]   funtoo/1.0/linux-gnu/flavor/core
  [8]   funtoo/1.0/linux-gnu/flavor/desktop *
  [9]   funtoo/1.0/linux-gnu/flavor/workstation
  [10]  funtoo/1.0/linux-gnu/flavor/hardened
Currently available mix-ins profiles:
  [11]  funtoo/1.0/linux-gnu/mix-ins/audio (auto)
  [12]  funtoo/1.0/linux-gnu/mix-ins/cinnamon
  [13]  funtoo/1.0/linux-gnu/mix-ins/console-extras (auto)
  [14]  funtoo/1.0/linux-gnu/mix-ins/dvd (auto)
  [15]  funtoo/1.0/linux-gnu/mix-ins/gnome
  [16]  funtoo/1.0/linux-gnu/mix-ins/kde
  [17]  funtoo/1.0/linux-gnu/mix-ins/mate
  [18]  funtoo/1.0/linux-gnu/mix-ins/media (auto)
  [19]  funtoo/1.0/linux-gnu/mix-ins/print (auto)
  [20]  funtoo/1.0/linux-gnu/mix-ins/python3-only
  [21]  funtoo/1.0/linux-gnu/mix-ins/rhel5-compat
  [22]  funtoo/1.0/linux-gnu/mix-ins/server-db
  [23]  funtoo/1.0/linux-gnu/mix-ins/server-mail
  [24]  funtoo/1.0/linux-gnu/mix-ins/server-web
  [25]  funtoo/1.0/linux-gnu/mix-ins/X (auto)
  [26]  funtoo/1.0/linux-gnu/mix-ins/xfce
  [27]  funtoo/1.0/linux-gnu/mix-ins/vmware-guest
  [28]  funtoo/1.0/linux-gnu/mix-ins/hardened

As you see by the (auto) entries, the desktop flavor already pre-set some mix-ins for you.

Now, let's head over and add some mix-ins. To add, say, the mix-ins gnome and kde we'd have to enter:

# eselect profile add 15
# eselect profile add 16

Or, in a one-shot:

# eselect profile add 15 16

If we want to remove a mix-in, for example gnome, simply enter:

# eselect profile remove 15

Verification:

# eselect profile list
Currently available arch profiles:
  [1]   funtoo/1.0/linux-gnu/arch/x86-64bit * 
  [2]   funtoo/1.0/linux-gnu/arch/pure64
Currently available build profiles:
  [3]   funtoo/1.0/linux-gnu/build/stable
  [4]  funtoo/1.0/linux-gnu/build/current * 
  [5]   funtoo/1.0/linux-gnu/build/experimental
Currently available flavor profiles:
  [6]   funtoo/1.0/linux-gnu/flavor/minimal
  [7]   funtoo/1.0/linux-gnu/flavor/core
  [8]   funtoo/1.0/linux-gnu/flavor/desktop *
  [9]   funtoo/1.0/linux-gnu/flavor/workstation
  [10]  funtoo/1.0/linux-gnu/flavor/hardened
Currently available mix-ins profiles:
  [11]  funtoo/1.0/linux-gnu/mix-ins/audio (auto)
  [12]  funtoo/1.0/linux-gnu/mix-ins/cinnamon
  [13]  funtoo/1.0/linux-gnu/mix-ins/console-extras (auto)
  [14] funtoo/1.0/linux-gnu/mix-ins/dvd (auto)
  [15]  funtoo/1.0/linux-gnu/mix-ins/gnome
  [16]  funtoo/1.0/linux-gnu/mix-ins/kde *
  [17]  funtoo/1.0/linux-gnu/mix-ins/mate
  [18]  funtoo/1.0/linux-gnu/mix-ins/media (auto)
  [19]  funtoo/1.0/linux-gnu/mix-ins/print (auto)
  [20]  funtoo/1.0/linux-gnu/mix-ins/python3-only
  [21]  funtoo/1.0/linux-gnu/mix-ins/rhel5-compat
  [22]  funtoo/1.0/linux-gnu/mix-ins/server-db
  [23]  funtoo/1.0/linux-gnu/mix-ins/server-mail
  [24]  funtoo/1.0/linux-gnu/mix-ins/server-web
  [25]  funtoo/1.0/linux-gnu/mix-ins/X (auto)
  [26]  funtoo/1.0/linux-gnu/mix-ins/xfce
  [27]  funtoo/1.0/linux-gnu/mix-ins/vmware-guest
  [28]  funtoo/1.0/linux-gnu/mix-ins/hardened


No magic here, whatever you add gets put into the /etc/portage/make.profile/parent file by portage.

In our case, this file contains:

# cat /etc/portage/make.profile/parent
gentoo:funtoo/1.0/linux-gnu/arch/x86-64bit
gentoo:funtoo/1.0/linux-gnu/build/current
gentoo:funtoo/1.0/linux-gnu/flavor/desktop
gentoo:funtoo/1.0/linux-gnu/mix-ins/kde

Warning

Please, do not add anything manually into parent file. This may result in profile breakage.

For Developers

Define the profile sub-sets you will use

So far in Funtoo we have used the exact same profiles as Gentoo thus Funtoo/2008.0 was strictly the same thing as Gentoo/2008.0 or the barely the same 10.0. This (monolithic) profile was set though a symbolic link named /etc/make.profile pointing on a complex directory architecture located somewhere under /usr/portage/profiles. This is no longer valid with the Funtoo 1.0 profiles as they are split in several smaller bricks which are then glued together via the /etc/portage/make.profile/parent file (You do not need to include everything, just use the "bricks" you need). Those bricks belongs to several categories:

1. MANDATORY -- An "arch" profile which defines settings for a particular architecture. You'll want to set this to whatever arch your system is and leave it alone. Setting it to a different arch than your system could severely break it.

2. MANDATORY -- A "build" profile which should match the tree you wish to use. Stable, Current (~arch), or Experimental (use it if you are brave enough and find current too stable).

3. MANDATORY -- A "flavor" profile (what was previously known as profiles is still known as such in Gentoo) which describes the kind of system you want.

  • minimal - Be warned, minimal is exactly what it says, the minimal profile stuff you need for a usable system, nothing else. This is really for people who know what they're doing.
  • core - This is the core profile. This is for stuff that affects both desktops and servers.
  • desktop - Exactly what it says. If you're using a desktop, you should set this as your flavor.
  • server - If you're running a server, you should set this as your flavor.

4. OPTIONAL -- One or more "mix-ins" profiles which describe optional add-ons. 'mix-ins' are the heart of the Funtoo 1.0 profiles. Unlike the monolithic profiles which sets a massive amount of use flags and options for you, we've split them into logical add-on profiles. For instance if you want support for gnome, you would add the gnome mix-in to your current profiles. That mix-in sets all the proper use flags and such for gnome. Same with others. Want dvd support? Add that one in. Using a rhel5 kernel which requires special versions of packages such as udev? There's a mix-in for that too. Run a mail server? web server? There's mix-ins for those also. Expect this category to grow in the future as new mix-ins are created.

The contents of /etc/portage/make.profile/parent for a basic setup might look like this:

gentoo:funtoo/1.0/linux-gnu/arch/x86-64bit
gentoo:funtoo/1.0/linux-gnu/build/current
gentoo:funtoo/1.0/linux-gnu/flavor/core

A more rounded setup for a desktop might look like this:

gentoo:funtoo/1.0/linux-gnu/arch/x86-64bit
gentoo:funtoo/1.0/linux-gnu/build/current
gentoo:funtoo/1.0/linux-gnu/flavor/desktop
gentoo:funtoo/1.0/linux-gnu/mix-ins/dvd
gentoo:funtoo/1.0/linux-gnu/mix-ins/media

Related