aboutsummaryrefslogtreecommitdiff
blob: e2ed75404641b838d4e2410643fedd78ca622f2a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
.TH "PORTAGE" "5" "Oct 2011" "Portage VERSION" "Portage"
.SH NAME
portage \- the heart of Gentoo
.SH "DESCRIPTION"
The current portage code uses many different configuration files, most of which 
are unknown to users and normal developers.  Here we will try to collect all 
the odds and ends so as to help users more effectively utilize portage.  This 
is a reference only for files which do not already have a man page.

All files in the make.profile directory may be tweaked via parent profiles 
when using cascading profiles.  For more info, please see 
http://www.gentoo.org/proj/en/releng/docs/cascading-profiles.xml
.IP Note:
If you are looking for information on how to emerge something, please see 
.BR emerge (1).
.SH "SYNOPSIS"
.TP
.BR /etc/
.nf
.BR make.conf (5)
.fi
.TP
\fB/etc/make.profile/\fR or \fB/etc/portage/make.profile/\fR
site\-specific overrides go in \fB/etc/portage/profile/\fR
.nf
deprecated
eapi
make.defaults
packages
packages.build
package.accept_keywords
package.keywords
package.mask
package.provided
package.unmask
package.use
package.use.force
package.use.mask
parent
profile.bashrc
use.force
use.mask
virtuals
.fi
.TP
.BR /etc/portage/
.nf
bashrc
categories
color.map
license_groups
make.conf
mirrors
modules
package.accept_keywords
package.env
package.keywords
package.license
package.mask
package.properties
package.unmask
package.use
repos.conf
.fi
.TP
.BR /etc/portage/env/
package-specific bashrc files
.TP
.BR /etc/portage/profile/
site-specific overrides of \fB/etc/make.profile/\fR
.TP
.BR /usr/portage/metadata/
.nf
layout.conf
.fi
.TP
.BR /usr/portage/profiles/
.nf
arch.list
categories
info_pkgs
info_vars
license_groups
make.defaults
package.mask
package.unmask
package.use
package.use.force
package.use.mask
profiles.desc
repo_name
thirdpartymirrors
use.desc
use.force
use.local.desc
use.mask
.fi
.TP
.BR /usr/share/portage/config/
.nf
make.globals
.fi
.TP
.BR /var/cache/edb/
misc internal cache files
.TP
.BR /var/db/pkg/
database to track installed packages
.TP
.BR /var/lib/portage/
.nf
config
world
world_sets
.fi
.SH "GLOSSARY"
In the following sections, some terminology may be foreign to you or used 
with meaning specific to Portage.  Please see the referenced manpages for 
more detailed explanations.
.RS
.TP
.B DEPEND atom
An atom is either of the form category/package or consists of an operator
followed by category/package followed by a hyphen and a version specification.
An atom might be suffixed by a slot specification.
.br
More reading: 
.BR ebuild (5)

.B Extended Atom Syntax
.br
The following atom syntax extensions are only supported in user
configuration files and command line arguments for programs such as
\fBemerge(1)\fR:
.RS
.TP
.B Repository Constraints
Atoms with repository constraints have a '::' separator appended to the
right side, followed by a repository name. Each repository name should
correspond to the value of a \fBrepo_name\fR entry from one of the
repositories that is configured via the \fBPORTDIR\fR or
\fBPORTDIR_OVERLAY\fR variables (see \fBmake.conf\fR(5)).

.I Examples:
.nf
# match sed from the 'gentoo' repository
sys\-apps/sed::gentoo
# match kdelibs from the 'kde\-testing' repository
kde\-base/kdelibs::kde\-testing
# match empathy from the 'gnome' repository
net\-im/empathy::gnome
.fi
.TP
.B Wildcard Patterns
Atoms containing wildcard patterns are of the form category/package, where
the special '*' wildcard character substitutes for an arbitrary number
of normal characters. More than one '*' character is allowed, but not two
next to each other.

.I Examples:
.nf
# match anything from the 'sys\-apps' category
sys\-apps/*
# match packages named 'zlib' from any category
*/zlib
# match any package from a category that begins with 'net\-'
net\-*/*
# match any package name from any category
*/*
# match any package from the 'gentoo' repository
*/*::gentoo
.fi
.RE
.TP
.B KEYWORD
Each architecture has a unique KEYWORD.
.br
More reading: 
.BR ebuild (5)
.TP
.B virtual
A DEPEND atom that is part of the "virtual" category.  They are used 
when different packages can satisfy a dependency and only one of them is 
needed.
.br
More reading: 
.BR ebuild (5)
.RE
.SH "SPECIFIC FILE DESCRIPTIONS"
.TP
.BR /etc/
.RS
.TP
.BR make.conf
The global custom settings for Portage.  See \fBmake.conf\fR(5).
.RE
.TP
\fB/etc/make.profile/\fR or \fB/etc/portage/make.profile/\fR
This is usually just a symlink to the correct profile in 
\fB/usr/portage/profiles/\fR.  Since it is part of the portage tree, it 
may easily be updated/regenerated by running `emerge \-\-sync`.  It defines 
what a profile is (usually arch specific stuff).  If you need a custom 
profile, then you should make your own \fB/etc/make.profile/\fR 
directory and populate it.  However, if you just wish to override some 
settings, use \fB/etc/portage/profile/\fR (it supports all of the same file
types that \fB/etc/make.profile/\fR does, except parent). Do NOT edit the
settings in \fB/etc/make.profile/\fR because they WILL be lost with the next
`emerge \-\-sync`. If both \fB/etc/make.profile/\fR and
\fB/etc/portage/make.profile/\fR exist, then \fB/etc/make.profile/\fR
will be preferred.

Any file in this directory, directories of other profiles or top-level
"profiles" directory that begins with "package." or "use." can be more than
just a flat file.  If it is a directory, then all the files in that directory
will be sorted in ascending alphabetical order by file name and summed together
as if it were a single file. Note that this behavior is only supported since
portage-2.1.6.7, and it is not included in PMS at this time.

.I Example:
.nf
${PORTDIR}/profiles/package.mask/removals
${PORTDIR}/profiles/package.mask/testing
.fi
.RS
.TP
.BR deprecated
The existence of this file marks a profile as deprecated, meaning it is 
not supported by Gentoo anymore.  The first line must be the profile to which 
users are encouraged to upgrade, optionally followed by some instructions 
explaining how they can upgrade.

.I Example:
.nf
default-linux/x86/2005.0
# emerge -n '>=sys-apps/portage-2.0.51'
# rm -f /etc/make.profile
# ln -s /usr/portage/profiles/default-linux/alpha/2005.0 /etc/make.profile
.fi
.TP
.BR eapi
The first line of this file specifies the \fBEAPI\fR to which files in the
same directory conform. See \fBebuild\fR(5) for information about \fBEAPI\fR
and related features.
.TP
.BR make.defaults
The profile default settings for Portage.  The general format is described 
in \fBmake.conf\fR(5).  The \fImake.defaults\fR for your profile defines a 
few specific variables too:

.PD 0
.RS
.TP
.BR ARCH
Architecture type (x86/ppc/hppa/etc...).
.TP
.B USERLAND = \fI"GNU"\fR
Support BSD/cygwin/etc...
.TP
.B ELIBC = \fI"glibc"\fR
Support uClibc/BSD libc/etc...
.TP
.B PROFILE_ONLY_VARIABLES = \fI"ARCH"\fR
Prevent critical variables from being changed by the user in make.conf 
or the env.
.TP
.BR PROFILE_ARCH
Distinguish machines classes that have the same \fBARCH\fR.  All sparc 
machines have ARCH=sparc but set this to either 'sparc32' or 'sparc64'.
.TP
.BR STAGE1_USE
Special USE flags which may be needed when bootstrapping from stage1 to stage2.
.RE
.PD 1
.TP
.BR packages
Provides the list of packages that compose the special \fIsystem\fR set.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one DEPEND atom per line
\- packages to be added to the system set begin with a *
\- atoms without * only appear for legacy reasons
.fi
.I Note:
In a cascading profile setup, you can remove packages in children 
profiles which were added by parent profiles by prefixing the atom with 
a '\-'.

.I Example:
.nf
# i am a comment !
# pull in a version of glibc less than 2.3
*<sys\-libs/glibc\-2.3
# pull in any version of bash
*app\-shells/bash
# pull in a version of readline earlier than 4.2
*<sys\-libs/readline\-4.2
.fi
.TP
.BR packages.build
A list of packages (one per line) that make up a stage1 tarball.  Really only 
useful for stage builders.
.TP
.BR package.provided
A list of packages (one per line) that portage should assume have been 
provided.  Useful for porting to non-Linux systems. Basically, it's a
list that replaces the \fBemerge \-\-inject\fR syntax.

For example, if you manage your own copy of a 2.6 kernel, then you can 
tell portage that 'sys-kernel/development-sources-2.6.7' is already taken 
care of and it should get off your back about it.

Portage will not attempt to update a package that is listed here unless
another package explicitly requires a version that is newer than what
has been listed. Dependencies that are satisfied by package.provided
entries may cause installed packages satisfying equivalent dependencies
to be removed by \fBemerge\fR(1) \fB\-\-depclean\fR actions (see the
\fBACTIONS\fR section of the \fBemerge\fR(1) man page for more information).

Virtual packages (virtual/*) should not be specified in package.provided.
Depending on the type of virtual, it may be necessary to add an entry to the
virtuals file and/or add a package that satisfies a virtual to
package.provided.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one DEPEND atom per line
\- relational operators are not allowed
\- must include a version
.fi

.I Example:
.nf
# you take care of the kernel
sys-kernel/development-sources-2.6.7

# you installed your own special copy of QT
x11-libs/qt-3.3.0

# you have modular X but packages want monolithic
x11-base/xorg-x11-6.8
.fi
.TP
.BR package.use.force
Per\-package USE flag forcing.

.I Note:
In a cascading profile setup, you can remove USE flags in children 
profiles which were added by parent profiles by prefixing the flag with 
a '\-'.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one DEPEND atom per line with space-delimited USE flags
.fi

.I Example:
.nf
# force docs for GTK 2.x
=x11\-libs/gtk+\-2* doc
# unforce mysql support for QT
x11\-libs/qt \-mysql
.fi
.TP
.BR package.use.mask
Per\-package USE flag masks.

.I Note:
In a cascading profile setup, you can remove USE flags in children 
profiles which were added by parent profiles by prefixing the flag with 
a '\-'.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one DEPEND atom per line with space-delimited USE flags
.fi

.I Example:
.nf
# mask docs for GTK 2.x
=x11\-libs/gtk+\-2* doc
# unmask mysql support for QT
x11\-libs/qt \-mysql
.fi
.TP
.BR parent
This contains a path to the parent profile.  It may be either relative or 
absolute.  The paths will be relative to the location of the profile.  Most 
commonly this file contains '..' to indicate the directory above.  Utilized 
only in cascading profiles.
.TP
.BR profile.bashrc
If needed, this file can be used to set up a special environment for ebuilds,
different from the standard root environment.  The syntax is the same as for
any other bash script.
.TP
.BR use.force
Some USE flags don't make sense to disable under certain conditions.  Here we
list forced flags.

.I Note:
In a cascading profile setup, you can remove USE flags in children 
profiles which were added by parent profiles by prefixing the flag with 
a '\-'.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one USE flag per line
.fi
.TP
.BR use.mask
Some USE flags don't make sense on some archs (for example altivec on 
non\-ppc or mmx on non\-x86), or haven't yet been tested.  Here we list 
the masked ones.

.I Note:
In a cascading profile setup, you can remove USE flags in children 
profiles which were added by parent profiles by prefixing the flag with 
a '\-'.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one USE flag per line
.fi

.I Example:
.nf
# mask doc
doc
# unmask mysql
\-mysql
.fi
.TP
.BR virtuals
This controls what packages will provide a virtual by default.  For example, 
if a package needs to send e\-mail, it will need virtual/mta.  In the absence 
of a package that provides virtual/mta (like qmail, sendmail, postfix, etc...), 
portage will look here to see what package to use.  In this case, Gentoo uses 
net\-mail/ssmtp as the default (as defined in the virtuals file) because it's 
the package that does the very bare minimum to send e\-mail.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one virtual and DEPEND atom base pair per line
.fi

.I Example:
.nf
# use net\-mail/ssmtp as the default mta
virtual/mta           net\-mail/ssmtp
# use app\-dicts/aspell\-en as the default dictionary
virtual/aspell\-dict   app\-dicts/aspell\-en
.fi
.RE
.TP
.BR /etc/portage/
Any file in this directory that begins with "package." can be more than just a 
flat file.  If it is a directory, then all the files in that directory will be 
sorted in ascending alphabetical order by file name and summed together as if
it were a single file.

.I Example:
.nf
/etc/portage/package.accept_keywords/common
/etc/portage/package.accept_keywords/e17
/etc/portage/package.accept_keywords/kde
.fi
.RS
.TP
.BR bashrc
If needed, this file can be used to set up a special environment for ebuilds,
different from the standard root environment.  The syntax is the same as for
any other bash script.

Additional package-specific bashrc files can be created in /etc/portage/env.
.TP
.BR categories
A simple list of valid categories that may be used in /usr/portage, 
PORTDIR_OVERLAY, and PKGDIR (see \fBmake.conf\fR(5)).  This allows for custom 
categories to be created.

.I Format:
.nf
\- one category per line
.fi

.I Example:
.nf
app\-hackers
media\-other
.fi
.TP
.BR color.map
Contains variables customizing colors. See \fBcolor.map\fR(5).
.TP
.BR make.conf
The global custom settings for Portage. See \fBmake.conf\fR(5).
If present, this file will override settings from /etc/make.conf.
.TP
.BR mirrors
Whenever portage encounters a mirror:// style URI it will look up the actual 
hosts here.  If the mirror set is not found here, it will check the global 
mirrors file at /usr/portage/profiles/thirdpartymirrors.  You may also set a 
special mirror type called "local".  This list of mirrors will be checked 
before GENTOO_MIRRORS and will be used even if the package has 
RESTRICT="mirror" or RESTRICT="fetch".

.I Format:
.nf
\- comments begin with # (no inline comments)
\- mirror type followed by a list of hosts
.fi

.I Example:
.nf
# local private mirrors used only by my company
local ftp://192.168.0.3/mirrors/gentoo http://192.168.0.4/distfiles

# people in japan would want to use the japanese mirror first
sourceforge http://keihanna.dl.sourceforge.net/sourceforge

# people in tawain would want to use the local gnu mirror first
gnu ftp://ftp.nctu.edu.tw/UNIX/gnu/
.fi
.TP
.BR modules
This file can be used to override the metadata cache implementation.  In
practice, portdbapi.auxdbmodule is the only variable that the user will want to
override.

.I Example:
.nf
portdbapi.auxdbmodule = portage.cache.sqlite.database
.fi

After changing the portdbapi.auxdbmodule setting, it may be necessary to
transfer or regenerate metadata cache. Users of the rsync tree need to
run `emerge \-\-metadata` if they have enabled FEATURES="metadata-transfer"
in \fBmake.conf\fR(5). In order to regenerate metadata for repositories
listed in \fBPORTDIR_OVERLAY\fR or a cvs tree, run `emerge \-\-regen`
(see \fBemerge\fR(1)). If you use something like the sqlite module and want
to keep all metadata in that format alone (useful for querying), enable
FEATURES="metadata-transfer" in \fBmake.conf\fR(5).
.TP
\fBpackage.accept_keywords\fR and \fBpackage.keywords\fR
Per\-package ACCEPT_KEYWORDS.  Useful for mixing unstable packages in with a normally 
stable system or vice versa.  This will allow ACCEPT_KEYWORDS to be augmented
for a single package. If both \fBpackage.accept_keywords\fR and
\fBpackage.keywords\fR are present, both of them will be used, and values
from \fBpackage.accept_keywords\fR will override values from
\fBpackage.keywords\fR. The \fBpackage.accept_keywords\fR file is
intended to replace the \fBpackage.keywords\fR file, since
profiles support a different form of \fBpackage.keywords\fR which
modifies effective KEYWORDS (rather than ACCEPT_KEYWORDS).

.I Format:
.nf
\- comment lines begin with # (no inline comments)
\- one DEPEND atom per line followed by additional KEYWORDS
\- lines without any KEYWORDS imply unstable host arch

.I Example:
# always use unstable libgd
media\-libs/libgd ~x86
# only use stable mplayer
media\-video/mplayer \-~x86
# always use unstable netcat
net-analyzer/netcat
.fi

.I Note:
.fi
In addition to the normal values from ACCEPT_KEYWORDS package.keywords supports
three special tokens:

.nf
\fB*\fR  package is visible if it is stable on any architecture
\fB~*\fR package is visible if it is in testing on any architecture
\fB**\fR package is always visible (KEYWORDS are ignored completely)
.fi

.I Additional Note:
If you encounter the \fB-*\fR KEYWORD, this indicates that the package is known 
to be broken on all systems which are not otherwise listed in KEYWORDS.  For 
example, a binary only package which is built for x86 will look like:

games-fps/quake3-demo-1.11.ebuild:KEYWORDS="-* x86"

If you wish to accept this package anyways, then use one of the other keywords in your 
package.accept_keywords like this:

games-fps/quake3-demo x86

.TP
.BR package.env
Per\-package environment variable settings. Entries refer to
environment files that are placed in the \fB/etc/portage/env/\fR
directory and have the same format as \fBmake.conf\fR(5).

.I Format:
.nf
\- comment lines begin with # (no inline comments)
\- one DEPEND atom per line followed by name(s) of environment file(s)
.fi

.I Example:
.nf
# use environment variables from /etc/portage/env/glibc.conf for the glibc package
sys\-libs/glibc glibc.conf
.fi

.TP
.BR package.license
This will allow ACCEPT_LICENSE to be augmented for a single package.

.I Format:
.nf
\- comment lines begin with # (no inline comments)
\- one DEPEND atom per line followed by additional licenses or groups
.fi
.TP
.BR package.mask
A list of package atoms to mask.  Useful if specific versions of packages do
not work well for you.  For example, you swear by the Nvidia drivers, but only
versions earlier than 1.0.4496.  No problem!

.I Format:
.nf
\- comment lines begin with # (no inline comments)
\- one DEPEND atom per line
.fi

.I Example:
.nf
# mask out versions 1.0.4496 of the nvidia
# drivers and later
>=media\-video/nvidia\-kernel\-1.0.4496
>=media\-video/nvidia\-glx\-1.0.4496
.fi
.TP
.BR package.properties
This will allow ACCEPT_PROPERTIES to be augmented for a single package.

.I Format:
.nf
\- comment lines begin with # (no inline comments)
\- one DEPEND atom per line followed by additional properties
.fi
.TP
.BR package.unmask
Just like package.mask above, except here you list packages you want to 
unmask.  Useful for overriding the global package.mask file (see 
above).  Note that this does not override packages that are masked via 
KEYWORDS.
.TP
.BR package.use
Per\-package USE flags.  Useful for tracking local USE flags or for 
enabling USE flags for certain packages only.  Perhaps you develop GTK 
and thus you want documentation for it, but you don't want 
documentation for QT.  Easy as pie my friend!

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one DEPEND atom per line with space-delimited USE flags
.fi

.I Example:
.nf
# turn on docs for GTK 2.x
=x11\-libs/gtk+\-2* doc
# disable mysql support for QT
x11\-libs/qt \-mysql
.fi
.TP
.BR repos.conf
Specifies \fIsite\-specific\fR repository configuration information. Note that
configuration settings which are specified here do not apply to tools
such as \fBrepoman\fR(1) and \fBegencache\fR(1), since operations
performed by these tools
are inherently \fBnot\fR \fIsite\-specific\fR. \fBWARNING:\fR Use of
\fBrepos.conf\fR is generally not recommended since resulting changes in
eclass inheritance (especially due to \fBeclass\-overrides\fR) may trigger
performance issues under some circumstances (see \fBbug #124041\fR). When
using \fBeclass\-overrides\fR, due to bug #276264, you must ensure that
your portage tree does not contain a metadata/cache/ directory. If that
directory exists then you should remove it entirely, and set
PORTAGE_RSYNC_EXTRA_OPTS="\-\-exclude=/metadata/cache" in
make.conf in order to exclude the metadata/cache/ directory during
\fBemerge\fR(1) \-\-sync operations.

.I Example:
.nf
[DEFAULT]
# make all repositories inherit eclasses from the java\-overlay and
# java\-experimental repositories, with eclasses from java\-experimental
# taking precedence over those from java\-overlay
eclass\-overrides = java\-overlay java\-experimental

[gentoo]
# disable all eclass overrides for ebuilds from the gentoo repository
eclass\-overrides =
# when processing metadata/layout.conf from other repositories, substitute
# 'gentoo' in place of references to repositories named 'foo' and 'bar',
# and discard the 'baz' alias contained in gentoo's layout.conf
aliases = foo bar -baz

[kde-testing]
# override the metadata/layout.conf masters setting from the kde-testing repo
masters = gentoo kde

[python]
# override the metadata/layout.conf masters setting from the python repo,
# so that settings won't be inherited from those masters, and so that
# those master repos won't be required as dependencies (the user must
# ensure that any required dependencies such as eclasses are satisfied)
masters =
.fi
.RE
.TP
.BR /etc/portage/env/
.RS
In this directory additional package\-specific bashrc files can be created.
Note that if package\-specific environment variable settings are all that's
needed, then \fB/etc/portage/package.env\fR should be used instead of the
bashrc approach that is described here.

set_unless_changed and unset_unless_changed functions can be used to set or
unset given variables only if these variable have not been set to values
different than values set in make.conf. This functionality can be useful for
temporary overriding of these variables during emerge invocation. Variables
set without using set_unless_changed will unconditionally override variables
set during emerge invocation.

.I Syntax:
.nf
set_unless_changed VARIABLE=VALUE
unset_unless_changed VALUE
.fi

Portage will source all of these bashrc files after \fB/etc/portage/bashrc\fR
in the following order:
.nr step 1 1
.IP \n[step]. 3
/etc/portage/env/${CATEGORY}/${PN}
.IP \n+[step].
/etc/portage/env/${CATEGORY}/${PN}:${SLOT}
.IP \n+[step].
/etc/portage/env/${CATEGORY}/${P}
.IP \n+[step].
/etc/portage/env/${CATEGORY}/${PF}
.RE
.TP
.BR /usr/portage/metadata/
.RS
.TP
.BR layout.conf
Specifies information about the repository layout. A
"masters" attribute is supported, which is used to specify names of
repositories which satisfy dependencies on eclasses and/or ebuilds. Each
repository name should correspond the value of a \fBrepo_name\fR entry
from one of the repositories that is configured via the \fBPORTDIR\fR or
\fBPORTDIR_OVERLAY\fR variables (see \fBmake.conf\fR(5)). Repositories listed
toward the right of the \fBmasters\fR list take precedence over those listed
toward the left of the list. An "aliases" attribute is also supported, which
behaves like an "aliases" attribute in \fBrepos.conf\fR. \fISite-specific\fR
overrides to \fBlayout.conf\fR settings may be specified in
\fB/etc/portage/repos.conf\fR. Settings in \fBrepos.conf\fR take
precedence over settings in \fBlayout.conf\fR, except tools such as
\fBrepoman\fR(1) and \fBegencache\fR(1) will entirely ignore
\fBrepos.conf\fR since their operations are inherently \fBnot\fR
\fIsite\-specific\fR.

.I Example:
.nf
# eclasses provided by java-overlay take precedence over identically named
# eclasses that are provided by gentoo
masters = gentoo java-overlay
# indicate that this repo can be used as a substitute for foo-overlay
aliases = foo-overlay
# do not sign manifests in this repo
sign\-manifests = false
# thin\-manifests only contain DIST entries
thin\-manifests = true
# indicate that this repo requires manifests for each package, and is
# considered a failure if a manifest file is missing/incorrect
use\-manifests = strict
# indicate that this repo enables repoman's --echangelog=y option automatically
update\-changelog = true
# indicate that this repo contains both md5-dict and pms cache formats,
# which may be generated by egencache(1)
cache\-formats = md5-dict pms
# indicate that this repo contains profiles that may use directories for
# package.mask, package.provided, package.use, package.use.mask,
# package.use.force, use.mask and use.force.
profile\-formats = portage-1
.fi
.RE
.TP
.BR /usr/portage/profiles/
Global Gentoo settings that are controlled by the developers.  To override 
these settings, you can use the files in \fB/etc/portage/\fR.
.RS
.TP
.BR arch.list
A list of all valid KEYWORDS.  This does not include modifiers.

.I Format:
.nf
\- one KEYWORD per line
.fi

.I Example:
.nf
x86
ppc
sparc
.fi
.TP
.BR categories
A simple list of valid categories that may be used in /usr/portage, 
PORTDIR_OVERLAY, and PKGDIR (see \fBmake.conf\fR(5)).

.I Format:
.nf
\- one category per line
.fi

.I Example:
.nf
app\-admin
dev\-lang
games\-strategy
sys\-kernel
.fi
.TP
.BR info_pkgs
A list of all the packages which will be displayed when you run `emerge info`.
.TP
.BR info_vars
A list of all the variables which will be displayed when you run `emerge info`.
.TP
.BR license_groups
This contains groups of licenses that may be specifed in the
\fBACCEPT_LICENSE\fR variable (see \fBmake.conf\fR(5)). Refer
to GLEP 23 for further information:
\fIhttp://www.gentoo.org/proj/en/glep/glep-0023.html\fR.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one group name, followed by list of licenses and nested groups
\- nested groups are prefixed with the '@' symbol
.fi

.I Example:
.nf
# The FSF-APPROVED group includes the entire GPL-COMPATIBLE group and more.
FSF-APPROVED @GPL-COMPATIBLE Apache-1.1 BSD-4 MPL-1.0 MPL-1.1
# The GPL-COMPATIBLE group includes all licenses compatible with the GNU GPL.
GPL-COMPATIBLE Apache-2.0 BSD BSD-2 GPL-2 GPL-3 LGPL-2.1 LGPL-3 X11 ZLIB
.fi
.TP
.BR package.accept_keywords
Per\-package ACCEPT_KEYWORDS for profiles. This has the same format and
behavior as /etc/portage/package.accept_keywords, including the ability
to list atoms without any keywords in order to accept unstable variants
of all stable keywords listed in ACCEPT_KEYWORDS.
.TP
.BR package.keywords
Per\-profile KEYWORDS. Useful for cases in which the effective KEYWORDS of a
given package should vary depending on which profile the user has selected.

.I Format:
.nf
\- comment lines begin with # (no inline comments)
\- one DEPEND atom per line followed by additional KEYWORDS
.fi

.I Example:
.nf
# add stable keyword to libgd
media\-libs/libgd x86
# remove stable keyword from mplayer and add unstable keyword
media\-video/mplayer \-x86 ~x86
# remove all keywords from netcat
net-analyzer/netcat -*
.fi
.TP
.BR package.mask
This contains a list of DEPEND atoms for packages that should not be installed 
in any profile.  Useful for adding the latest KDE betas and making sure no 
one accidentally upgrades to them.  Also useful for quickly masking specific 
versions due to security issues.  ALWAYS include a comment explaining WHY the 
package has been masked and WHO is doing the masking.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- one DEPEND atom per line
.fi

.I Example:
.nf
# masked for security reasons
<sys\-libs/zlib\-1.1.4
# <caleb@gentoo.org> (10 Sep 2003)
# new kde betas
=kde\-base/kde\-3.2.0_beta1
=kde\-base/kdeaccessibility\-3.2.0_beta1
.fi
.TP
.BR profiles.desc
List all the current stable and development profiles.  If a profile is listed 
here, then it will be checked by repoman.
.I Format:
.nf
\- comments begin with # (no inline comments)
\- one profile list per line in format: arch dir status
\- arch must be listed in arch.list
\- dir is relative to profiles.desc
\- status must be 'stable', 'dev', or 'exp'
.fi

.I Example:
.nf
alpha        default/linux/alpha/10.0    stable
m68k         default/linux/m68k/10.0     dev
x86          default/linux/x86/10.0      stable
x86-linux    prefix/linux/x86            exp
.fi
.TP
.BR repo_name
The first line of the file should define a unique repository name. The name
may contain any of the characters [A\-Za\-z0\-9_\-]. It must not begin with a
hyphen.
.TP
.BR thirdpartymirrors
Controls the mapping of mirror:// style URIs to actual lists of 
mirrors.  Keeps us from overloading a single server.

.I Format:
.nf
\- comments begin with # (no inline comments)
\- mirror type followed by a list of hosts
.fi

.I Example:
.nf
sourceforge http://aleron.dl.sourceforge.net/sourceforge http://unc.dl.sourceforge.net/sourceforge

gentoo http://distro.ibiblio.org/pub/linux/distributions/gentoo/distfiles/ ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo/distfiles

kernel http://www.kernel.org/pub http://www.us.kernel.org/pub
.fi
.TP
.BR use.desc
All global USE flags must be listed here with a description of what they do.  

.I Format:
.nf
\- comments begin with # (no inline comments)
\- use flag \- some description
.fi

.I Example:
.nf
3dfx \- Adds support for 3dfx video cards
acl \- Adds support for Access Control Lists
doc \- Adds extra documentation
.fi
.TP
.BR use.local.desc
All local USE flags are listed here along with the package and a 
description. This file is automatically generated from the
metadata.xml files that are included with each individual package.
Refer to GLEP 56 for further information:
\fIhttp://www.gentoo.org/proj/en/glep/glep-0056.html\fR.

.nf
.I Format:
\- comments begin with # (no inline comments)
\- package:use flag \- description

.I Example:
app\-editors/nano:justify \- Toggles the justify option
dev\-libs/DirectFB:fusion \- Adds Multi Application support
games\-emulation/xmess:net \- Adds network support
.fi
.RE
.TP
.BR /usr/share/portage/config/
.RS
.TP
.BR make.globals
The global default settings for Portage.  This comes from the portage package 
itself.  Settings in \fBmake.conf\fR or \fBpackage.env\fR
override values here. The format 
is described extensivly in \fBmake.conf\fR(5).
.RE
.TP
.BR /var/cache/edb/
.RS
This directory is used to store internal portage cache files.  The names and
purpose of these files are not documented on purpose so as to keep down bitrot
as internals change.  If you aren't working on portage internally, then the
details most likely do not matter to you.

This entire directory can be safely deleted.  It is highly recommended you do
not do this however as it can be a time consuming process to generate them all
again.
.RE
.TP
.BR /var/db/pkg/
.RS
All installed package information is recorded here.  If portage thinks you have
a package installed, it is usually because it is listed here.

The format follows somewhat closely that of the portage tree.  There is a
directory for each category and a package-version subdirectory for each package
you have installed.

Inside each package directory are misc files that describe the installed
contents of the package as well as build time information (so that the package
can be unmerged without needing the portage tree).

The exact file contents and format are not described here again so that things
can be changed quickly.  Generally though there is one file per environment
variable that "matters" (like CFLAGS) with the contents stored inside of it.
Another common file is the CONTENTS file which lists the path and hashes of
all objects that the package installed onto your system.
.RE
.TP
.BR /var/lib/portage/
.RS
.TP
.BR config
Hashes which are used to determine whether files in config protected
directories have been modified since being installed.  Files which have not
been modified will automatically be unmerged.
.TP
.BR world
Every time you emerge a package, the package that you requested is 
recorded here.  Then when you run `emerge world \-up`, the list of 
packages is read from this file.  Note that this does not mean that the 
packages that were installed as dependencies are listed here.  For 
example, if you run `emerge mod_wsgi` and you do not have apache 
already, then "www\-apache/mod_wsgi" is recorded in the world file but 
"www\-servers/apache" is not.  For more information, review \fBemerge\fR(1).

.I Format:
.nf
\- one DEPEND atom base per line
.fi

.I Example:
.nf
games\-misc/fortune\-mod\-gentoo\-dev
dev\-libs/uclibc
app\-cdr/cdemu
.fi
.TP
.BR world_sets
This is like the world file but instead of package atoms it contains
packages sets which always begin with the @ character.

.I Example:
.nf
@kde
.fi
.RE
.SH "REPORTING BUGS"
Please report bugs via http://bugs.gentoo.org/
.SH "AUTHORS"
.nf
Marius Mauch <genone@gentoo.org>
Mike Frysinger <vapier@gentoo.org>
Drake Wyrm <wyrm@haell.com>
Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>
.fi
.SH "SEE ALSO"
.BR emerge (1),
.BR ebuild (1),
.BR ebuild (5),
.BR make.conf (5),
.BR color.map (5)