Fork of Original Code Base: anongit.freedesktop.org/systemd

This is the initial fork of the code base from freedsktop.org.
The code is provided here as a reference of the initial starting
point and for possible future checkouts after a large portion
of this code is removed.

Merge git://anongit.freedesktop.org/systemd/systemd
This commit is contained in:
Anthony G. Basile 2012-11-15 10:10:41 -05:00
commit 2944f347d0
967 changed files with 376354 additions and 0 deletions

7
.dir-locals.el Normal file
View File

@ -0,0 +1,7 @@
; Sets emacs variables based on mode.
; A list of (major-mode . ((var1 . value1) (var2 . value2)))
; Mode can be nil, which gives default values.
((nil . ((indent-tabs-mode . nil)
(tab-width . 8)))
)

144
.gitignore vendored Normal file
View File

@ -0,0 +1,144 @@
/test-replace-var
/test-journal-enum
/test-sleep
/localectl
/hostnamectl
/timedatectl
/test-date
/install-tree
/systemd-journal-gatewayd
/test-mmap-cache
/test-unit-file
/test-log
/test-journal-verify
/test-journal-match
/test-journal-stream
/test-unit-name
/systemd-system-update-generator
/systemd-fstab-generator
/systemd-delta
/systemd-sleep
/systemd-inhibit
/systemd-remount-fs
/build-aux
/test-watchdog
/test-journal-send
/test-journal-syslog
/systemd-multi-seat-x
/systemd-cgtop
/systemd-coredump
/systemd-cat
/systemd-rc-local-generator
/journalctl
/systemd-journald
/test-id128
/test-journal
/test-install
/test-inhibit
/org.freedesktop.hostname1.xml
/org.freedesktop.locale1.xml
/test-login
/loginctl
/systemd-localed
/systemd-timedated
/org.freedesktop.timedate1.xml
/systemd-logind
/systemd-uaccess
/systemd-hostnamed
/systemd-binfmt
/systemd-getty-generator
/systemd-nspawn
/systemd-stdio-bridge
/systemd-machine-id-setup
/systemd-detect-virt
/systemd-sysctl
/test-strv
/systemd-ac-power
/systemd-timestamp
/systemd-coredumpctl
/systemd-cryptsetup
/systemd-cryptsetup-generator
/systemd-tty-ask-password-agent
/systemd-fsck
/systemd-quotacheck
/systemd-user-sessions
/systemd-shutdown
/systemd-tmpfiles
/systemd-readahead
/systemd-reply-password
/systemd-gnome-ask-password-agent
/systemd-ask-password
/systemd-kmsg-syslogd
/systemd-remount-api-vfs
/test-hostname
/systemd-modules-load
/systemd-vconsole-setup
/systemd-shutdownd
/systemd-random-seed
/systemd-update-utmp
/test-env-replace
/systemd-cgls
/test-cgroup
.libs/
/systemd-notify
/test-daemon
/org.freedesktop.systemd1.*.xml
/test-ns
/test-loopback
/systemd-cgroups-agent
/systemd-initctl
/systemd
/test-engine
/test-job-type
/systemctl
/systemadm
.dirstamp
*.1
*.3
*.5
*.7
*.8
*.html
*~
*.o
*.lo
*.a
*.la
.deps/
Makefile.in
aclocal.m4
*.cache
compile
config.guess
config.h
config.h.in
config.log
config.status
config.sub
configure
depcomp
install-sh
missing
stamp-*
*.stamp
/Makefile
/ltmain.sh
/*.tar.xz
/*.tar.gz
/*.tar.bz2
/libtool
/accelerometer
/ata_id
/cdrom_id
/collect
/gtk-doc.make
/keymap
/mtd_probe
/scsi_id
/udevadm
/systemd-udevd
/v4l_id
/test-libudev
/test-udev
/TAGS
/tags

45
.mailmap Normal file
View File

@ -0,0 +1,45 @@
Kay Sievers <kay@vrfy.org>
Kay Sievers <kay@vrfy.org> <kay.sievers@vrfy.org>
Kay Sievers <kay@vrfy.org> <kay.sievers@suse.de>
Kay Sievers <kay@vrfy.org> <kay@pim.off.vrfy.org>
Kay Sievers <kay@vrfy.org> <kay@pim>
Greg KH <greg@kroah.com>
Greg KH <greg@kroah.com> <greg@kroah.com>
Greg KH <greg@kroah.com> <greg@press.(none)>
Greg KH <greg@kroah.com> <gregkh@suse.de>
Harald Hoyer <harald@redhat.com>
David Zeuthen <david@fubar.dk>
David Zeuthen <david@fubar.dk> <davidz@redhat.com>
David Zeuthen <david@fubar.dk> <zeuthen@gmail.com>
Hannes Reinecke <hare@suse.de>
Scott James Remnant <scott@netsplit.com>
Scott James Remnant <scott@netsplit.com> <scott@ubuntu.com>
Alan Jenkins <alan.christopher.jenkins@googlemail.com>
Alan Jenkins <alan.christopher.jenkins@googlemail.com> <alan-jenkins@tuffmail.co.uk>
Marco d'Itri <md@linux.it> <md@Linux.IT>
Robert Gerus <ar@bash.org.pl> Robert "arachnist" Gerus <ar@bash.org.pl>
Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> Zbyszek Szmek <zbyszek@in.waw.pl>
Fabiano Fidêncio <fabianofidencio@gmail.com> Fabiano Fidencio <fidencio@profusion.mobi>
Martin Pitt <martinpitt@gnome.org>
Martin Pitt <martinpitt@gnome.org> <martin.pitt@ubuntu.com>
Daniel J Walsh <dwalsh@redhat.com>
Dave Reisner <dreisner@archlinux.org> <d@falconindy.com>
Diego Elio Pettenò <flameeyes@gmail.com>
Daniel Elstner <daniel.kitta@gmail.com> <danielk@openismus.com>
Frederic Crozat <fcrozat@suse.com> <fcrozat@mandriva.com>
Ian Campbell <ijc@hellion.org.uk> <Ian.Campbell@citrix.com>
Jerone Young <jyoung@redhat.com> <jerone.young@canonical.com>
Luis Felipe Strano Moraes <luis.strano@gmail.com> <lfelipe@profusion.mobi>
Mario Limonciello <mario_limonciello@dell.com> <Mario_Limonciello@dell.com>
Matthias Clasen <mclasen@redhat.com> <matthias.clasen@gmail.com>
Michal Soltys <soltys@ziu.info> <nozo@ziu.info>
Piter PUNK <piterpunk@slackware.com> <piterpk@terra.com.br>
Richard Hughes <richard@hughsie.com> <hughsient@gmail.com>
Robby Workman <rw@rlworkman.net> <rworkman@slackware.com>
Shawn Landden <shawnlandden@gmail.com>
Simon Peeters <peeters.simon@gmail.com>
Tobias Klauser <tklauser@distanz.ch> <tklauser@nuerscht.ch>
Miklos Vajna <vmiklos@frugalware.org> <vmiklos@gmail.com>
William Jon McCann <jmccann@redhat.com> <william.jon.mccann@gmail.com>
Yin Kangkai <kangkai.yin@intel.com> <kangkai.yin@linux.intel.com>
Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>

4
.vimrc Normal file
View File

@ -0,0 +1,4 @@
" 'set exrc' in ~/.vimrc will read .vimrc from the current directory
set tabstop=8
set shiftwidth=8
set expandtab

27
CODING_STYLE Normal file
View File

@ -0,0 +1,27 @@
- 8ch indent, no tabs
- structs in MixedCase, variables, functions in lower_case
- the destructors always unregister the object from the next bigger
object, not the other way around
- to minimize strict aliasing violations we prefer unions over casting
- for robustness reasons destructors should be able to destruct
half-initialized objects, too
- error codes are returned as negative Exxx. i.e. return -EINVAL. There
are some exceptions: for constructors its is OK to return NULL on
OOM. For lookup functions NULL is fine too for "not found"
- Do not issue NSS requests (that includes user name and host name
lookups) from the main daemon as this might trigger deadlocks when
we those lookups involve synchronously talking to services that we
would need to start up
- Do not access any directories outside of /etc, /dev, /lib from the
init daemon to avoid deadlocks with the automounter
- Don't synchronously talk to any other service, due to risk of
deadlocks

58
DISTRO_PORTING Normal file
View File

@ -0,0 +1,58 @@
Porting systemd To New Distributions
HOWTO:
You need to make the follow changes to adapt systemd to your
distribution:
0) Make your distribution recognized via the autoconf checks
in configure.ac. Grep for the word "fedora" (case
insensitively) and you should be able to find the places where
you need to add/change things.
1) Patch src/hostname-setup.c so that systemd knows where to
read your host name from. You might also want to update
status_welcome() in util.c.
2) Check the unit files in units/ if they match your
distribution. Most likely you will have to make additions to
units/*.m4 and create a copy of units/fedora/ with changes for
your distribution.
3) Adjust Makefile.am to register the unit files you added in
step 2. Also you might need to update the m4 invocation in
Makefile.am. Grep for the word "fedora" (case insensitively)
and you should be able to find the places where you need to
add/change things.
4) Try it out. Play around with 'systemd --test --system' for
a test run of systemd without booting. This will read the unit
files and print the initial transaction it would execute
during boot-up. This will also inform you about ordering loops
and suchlike.
CONTRIBUTING UPSTREAM:
We are interested in merging your changes upstream, if they
are for a big, and well-known distribution. Unfortunately we
don't have the time and resources to maintain
distribution-specific patches for all distributions on the
planet, hence please do not send us patches that add systemd
support for non-mainstream or niche distributions.
Thank you for understanding.
BE CONSIDERATE:
We'd like to keep differences between the distributions
minimal. This both simplifies our maintenance work, as well
as it helps administrators to move from one distribution to
another.
Hence we'd like to ask you to keep your changes minimal, and
not rename any units without a very good reason (if you need a
particular name for compatibility reasons, consider using
alias names via symlinks). Before you make changes that change
semantics from upstream, please talk to us!
In SysV almost every distribution uses a different
nomenclature and different locations for the boot-up
scripts. We'd like to avoid chaos like that with systemd right
from the beginning. So please, be considerate!

339
LICENSE.GPL2 Normal file
View File

@ -0,0 +1,339 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Lesser General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License.

508
LICENSE.LGPL2.1 Normal file
View File

@ -0,0 +1,508 @@
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations
below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
^L
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it
becomes a de-facto standard. To achieve this, non-free programs must
be allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
^L
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control
compilation and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
^L
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
^L
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at least
three years, to give the same user the materials specified in
Subsection 6a, above, for a charge no more than the cost of
performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
^L
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
^L
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply, and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License
may add an explicit geographical distribution limitation excluding those
countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
^L
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
^L
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms
of the ordinary General Public License).
To apply these terms, attach the following notices to the library.
It is safest to attach them to the start of each source file to most
effectively convey the exclusion of warranty; and each file should
have at least the "copyright" line and a pointer to where the full
notice is found.
<one line to give the library's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or
your school, if any, to sign a "copyright disclaimer" for the library,
if necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James
Random Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!

19
LICENSE.MIT Normal file
View File

@ -0,0 +1,19 @@
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation files
(the "Software"), to deal in the Software without restriction,
including without limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of the Software,
and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

4045
Makefile.am Normal file

File diff suppressed because it is too large Load Diff

1149
NEWS Normal file

File diff suppressed because it is too large Load Diff

609
TODO Normal file
View File

@ -0,0 +1,609 @@
Bugfixes:
* check systemd-tmpfiles for selinux context hookup for mknod(), symlink() and similar
* swap units that are activated by one name but shown in the kernel under another are semi-broken
* make anaconda write timeout=0 for encrypted devices
* Dangling symlinks of .automount unit files in .wants/ directories, set up
automount points even when the original .automount file did not exist
anymore. Only the .mount unit was still around.
* make polkit checks async
* properly handle .mount unit state tracking when two mount points are stacked one on top of another on the exact same mount point.
F18:
* Retest multi-seat
* add rpm macros for %rulesdir, %hwdbdir, update rules/hwdb call
Features:
* add API to close/reopen/get fd for journal client fd in libsystemd-journal.
* maybe add API to send pairs of iovecs via sd_journal_send
* fallback to /dev/log based logging in libsystemd-journal, if we can't log natively?
* declare the local journal protocol stable in the wiki interface chart
* introduce ntp.service (or suchlike) as symlink that is used to arbitrate between various
NTP implementations
* sd-journal: don't return fields > a threshold by default
* journal: reuse XZ context
* sd-journal: speed up sd_journal_get_data() with transparent hash table in bg
* introduce ntp.service (or suchlike) as symlink that is used to arbitrate between various NTP implementations
* timer units should get the ability to trigger when:
- CLOCK_REALTIME makes jumps (TFD_TIMER_CANCEL_ON_SET)
- DST changes
* update the kernel's TZ (sys_tz) when DST changes
* sync down the system time to the RTC when:
- CLOCK_REALTIME makes jumps (the user explicitely requested a time set)
- DST/timezone changes && ntp is active && RTC-in-localtime (never do it without ntp)
This takes care of syncing ntpdate updates to the RTC, and DST updates for localtime
mode, it will never touch the RTC if the no reliable time source is active or the
user did not request anything like it.
* When we begin with system shutdown all kind of suspend/hibernation should be prohibited until shutdown/reboot
* When we update the kernel all kind of hibernation should be prohibited until shutdown/reboot
* hwdb:
- implement conditional properties (dmi matches)
- hwdb --filter=ID_DRIVE_*
- find out what to do for blockdevs and skipping scsi modaliases
- move writing code to src/libudev/libudev-hwdb-private.c
* if booted in "quiet" mode, and an error happens, turn on status output again, so that the emergency mode isn't totally surprising
* localectl: add listing support for X11 keymaps, by parsing /usr/share/X11/xkb/rules/xorg.lst
* libunwind support for coredump pattern hook, and includes this in
the message for coredumps. After all, libunwind is now capable to
unwind coredumps since a few weeks ago. This probably requires that
we have nice support for multi-line messages on display in logs-show.c.
* figure out relation of --all and --full in the various tools
* journal: when writing journal auto-rotate if time jumps backwards
* introduce new "journal" group in place of adm? introduce groups for the various mini daemons?
* journal: add a setgid "adm" utility to invoke from libsystemd-journal, which passes fds via STDOUT and does PK access
* link up selected blog stories from man pages?
* journactl: support negative filtering, i.e. FOOBAR!="waldo",
and !FOOBAR for events without FOOBAR.
* print nice message from systemctl --failed if there are no entries shown, and hook that into ExecStartPre of rescue.service/emergency.service
* add libsystemd-password or so to query passwords during boot using the password agent logic
* journal: when rotating, copy over old acls/access mode
* journal: document why we do not give ownership to journal files to the user that created them but use FS ACLs for that
* journal: send out marker messages every now and then, and immediately sync with fdatasync() afterwards, in order to have hourly guaranteed syncs.
* journal: when we haven't written anything in a while, sync to disk and mark file as offline, in order to be more often than not in a clean state
* journal-send.c, log.c: when the log socket is clogged, and we drop, count this and write a message about this when it gets unclogged again.
* If we show an error about a unit (such as not showing up) and it has no Description string, then show a description string generated form the reverse of unit_name_mangle().
* fedup: add --unit to systemctl switch-root somehow
* fedup: don't delete initrd on switch-root
* fedup: generator
* journal: find a way to allow dropping history early, based on priority, other rules
* journal: When used on NFS, check payload hashes
* journal: When used on NFS make sure wake up sd_journal_wait() every 2s, to handle missing inotify
* document that people can use file system ACLs to manage access to journal files, with example
* don't show cgroup in "systemctl status" if empty/non-existent, especially for foreign .mount units
* timedated: export boolean that clarifies whether NTP is even available
* timedated: refuse time changes when NTP is on
* clean up date formatting and parsing so that all absolute/relative timestamps we format can also be parsed
* document unit_name_mangle()
* add new command to systemctl: "systemctl system-reexec" which reexecs as many daemons as virtually possible
* introduce generic AUGMENT_PID=, AUGMENT_DEVICE= fields
* deal with sendmail/postfix exclusivity
* systemctl enable: improve the success messages (i.e. more human readable, less shell-like)
* systemctl enable: fail if target to alias into doesn't exist? maybe show how many units are enabled afterwards?
* on shutdown: move utmp, wall, audit logic all into PID 1 itself, get rid of systemd-update-utmp-runlevel
* add "provisioning" instructions to setup an empty /etc + /var
- used to setup a new container from a shared /usr
- superset of tmpfiles model
- instructions shipped by packages and stored in /usr/lib/
- compose /etc/passwd and /etc/group, copy files
- able to create uid + gid used by packages, for file ownership
* make repeated alt-ctrl-del presses printing a dump, or even force a reboot without
waiting for the timeout
* high level net_prio setting in execution context
* Introduce journalctl -b <nr> to show journal messages of a previous boot
* hostnamed: before returning information from /etc/machine-info.conf check the modification data and reread. Similar for localed, ...
* currently x-systemd.timeout is lost in the initrd, since crypttab is copied into dracut, but fstab isn't
* WorkingDirectory: support env var replacements like in ExecStart= so that people can use $HOME
* refuse boot if /etc/machine-id is not useful
* nspawn: consider changing users for -u with su, so that NSS resolving works correctly
* nspawn: implement personality changes a la linux32(8)
* nspawn: reset all aux groups
* cryptsetup-generator: warn if the password files are world-readable
* cryptsetup-generator: add RequiresMountsFor= to cryptseup service files referencing a file, similar for devices
* cryptsetup-generator: allow specification of passwords in crypttab itself
* document that deps in [Unit] sections ignore Alias= fileds in
[Install] units of other units, unless those units are disabled
* need to update LGPL2.1 text to newest version (with updated FSF address)
* systemctl: when powering down/suspending check for inhibitors, and warn.
* instantiated [Install] for target units
https://bugs.freedesktop.org/show_bug.cgi?id=54377
* move debug shell to tty6 and make sure this doesn't break the gettys on tty6
* move cryptsetup key caching into kernel keyctl?
https://bugs.freedesktop.org/show_bug.cgi?id=54982
* make nspawn work without terminal
* hw watchdog: optionally try to use the preset watchdog timeout instead of always overriding it
https://bugs.freedesktop.org/show_bug.cgi?id=54712
* after deserializing sockets in socket.c we should reapply sockopts and things
* make timer units go away after they elapsed
* http://lists.freedesktop.org/archives/systemd-devel/2012-September/006502.html
* come up with a nice way to write queue/read_ahead_kb for a block device without interfering with readahead
* journald: add kernel cmdline option to disable ratelimiting for debug purposes
* move PID 1 segfaults to /var/lib/systemd/coredump?
* Document word splitting syntax for ExecStart= and friends
* create /sbin/init symlinks from the build system
* Query Paul Moore about relabelling socket fds while they are open
* move keymaps to /usr/lib/... rather than /usr/lib/udev/...
* journald: check whether it is OK if the client can still modify delivered journal entries
* journal live copy, based on libneon (client) and libmicrohttpd
* system-wide seccomp filter
* ability to pass fds into systemd
* system.conf should have controls for cgroups
* bind mount read-only the cgroup tree higher than nspawn
* allow writing multiple conditions in unit files on one line
* explore multiple service instances per listening socket idea
* testing tool for socket activation: some binary that listens on a socket and passes it on using the usual socket activation protocol to some server.
* shutdown: don't read-only mount anything when running in container
* nspawn: --read-only is not applied recursively to submounts
* MountFlags=shared acts as MountFlags=slave right now.
* ReadOnlyDirectories= is not applied recursively to submounts
* drop PID 1 reloading, only do reexecing (difficult: Reload()
currently is properly synchronous, Reexec() is weird, because we
can't delay the response properly until we are back, so instead of
being properly synchronous we just keep open the fd and close it
when done. That means clients don't get a successful method reply,
but much rather a disconnect on success.
* document that service reload may be implemented as service reexec
* remember which condition failed for services, not just the fact that something failed
* use opterr = 0 for all getopt tools
* properly handle loop back mounts via fstab, especially regards to fsck/passno
* allow services with no ExecStart= but with an ExecStop=
* add proper journal support to "systemctl --user status ..."
* add _SYSTEMD_USER_UNIT= field to journal entries
* dracut-shutdown needs to be ordered before unmounting /boot
* initialize the hostname from the fs label of /, if /etc/hostname does not exist?
* rename "userspace" to "core-os"
* systemctl: "Journal has been rotated since unit was started." message is misleading
* syscall filter: add knowledge about compat syscalls
* syscall filter: don't enforce no new privs?
* syscall filter: option to return EPERM rather than SIGSYS?
* syscall filter: port to libseccomp
* logind: wakelock/opportunistic suspend support
* systemd-analyze post-boot is broken for initrd
* man: clarify that time-sync.target is not only sysv compat but also useful otherwise. Same for similar targets
* .device aliases need to be implemented with the "following" logic, probably.
* refuse taking lower-case variable names in sd_journal_send() and friends.
* load-fragment: when loading a unit file via a chain of symlinks
verify that it isn't masked via any of the names traversed.
* journald: we currently rotate only after MaxUse+MaxFilesize has been reached.
* Document:
- PID 1 D-Bus API
* introduce Type=pid-file
* maybe allow services with ExecStop= set, but no ExecStart=?
* efi: implement /forcefsck as uefi variables thus not requiring file system altering to trigger a file system check
* efi: honor language efi variables for default language selection
* efi: honor timezone efi variables for default timezone selection
* efi: automatically mount EFI partition to /boot if no such entry exists in /etc/fstab and /boot is empty
gummiboot exports the EFI system partion (ESP) device:
/sys/firmware/efi/vars/LoaderDeviceIdentifier-4a67b082-0a4c-41cf-b6c7-440b29bb8c4f/data
Acpi(PNP0A03,0)/Pci(1F|2)/?/HD(Part1,Sig1FCBC57F-4BFC-4C2B-91A3-9C84FBCD9AF1)
'/' is the separator for the device path list
HD(Part1,Sig1FCBC57F-4BFC-4C2B-91A3-9C84FBCD9AF1) contains the GPT UUID of the ESP
* read the bootloader performance data (raw TSC) in systemd-analyze
/sys/firmware/efi/vars/LoaderTicksExec-4a67b082-0a4c-41cf-b6c7-440b29bb8c4f/data
19066159288
/sys/firmware/efi/vars/LoaderTicksInit-4a67b082-0a4c-41cf-b6c7-440b29bb8c4f/data
17442940316
/sys/firmware/efi/vars/LoaderTicksStartMenu-4a67b082-0a4c-41cf-b6c7-440b29bb8c4f/data
(only set if the menu was active)
* change Requires=basic.target to RequisiteOverride=basic.target
* support rd.luks.allow-discards= kernel cmdline params in cryptsetup generator
* nspawn: make use of device cgroup contrller by default
* drop accountsservice's StandardOutput=syslog and Type=dbus fields
* when breaking cycles drop sysv services first, then services from /run, then from /etc, then from /usr
* readahead: when bumping /sys readahead variable save mtime and compare later to detect changes
* (attempt to) make Debianites happy:
- implement .d/ auto includes for unit files
- add syntax to reset ExecStart= lists (and similar)
* move passno parsing to fstab generator
* improve !/proc/*/loginuid situation: make /proc/*/loginuid less dependent on CONFIG_AUDIT,
or use the users cgroup information when /proc/*/loginuid is not available.
* pam_systemd: try to get old session id from cgroup, if audit sessionid cannot be determined
* pam: when leaving a session explicitly exclude the ReleaseSession() caller process from the killing spree
* maybe introduce ~/.config/locale.conf and apply it within PAM
* readahead: make use of EXT4_IOC_MOVE_EXT, as used by http://e4rat.sourceforge.net/
* automount: implement expire
* logind: auto-suspend, auto-shutdown:
IdleAction=(none|suspend|opportunistic|hibernate|poweroff)
IdleActionDelay=...
SessionIdleMode=(explicit|ignore|login)
ForceShutdown=(yes|no)
* services which create their own subcgroups break cgroup-empty notification (needs to be fixed in the kernel)
* don't delete /tmp/systemd-namespace-* before a process is gone down
* vconsole: implement setterm -store -foreground xxx --background zzz
* ExecOnFailure=/usr/bin/foo
* fedora: make sshd and pam_loginuid work in nspawn containers
* fix utmp for console logins in containers
* Add pretty name for seats in logind
* ConditionSecurity= should learn about IMA
* Auke: merge Auke's bootchart
* udev: move to LGPL
* udev systemd unify:
- strpcpy(), strpcpyl(), strscpy(), strscpyl()
- utf8 validator code
* udev: scsi_id -> sg3_utils -> kill scsi_id
* udev: add trigger --subsystem-match=usb/usb_device device
* allow configuration of console width/height in vconsole.conf
* cleanup syslog 'priority' vs. 'level' wording
* dbus upstream still refers to dbus.target and shouldn't
* when a service has the same env var set twice we actually store it twice and return that in systemctl show -p... We should only show the last setting
* support container_ttys=
* introduce mix of BindTo and Requisite
* journalctl: show multiline log messages sanely, expand tabs, and show all valid utf8 messages
* add DeleteSocketsOnStop=yes|no option to socket units
* journal: store euid in journal if it differs from uid
* There's currently no way to cancel fsck (used to be possible via C-c or c on the console)
* journal: sanely deal with entries which are larger than the individual file size, but where the components would fit
* add command to systemctl to plot dependency graph as tree (see rhbz 795365)
* add option to sockets to avoid activation. Instead just drop packets/connections, see http://cyberelk.net/tim/2012/02/15/portreserve-systemd-solution/
* default unix qlen is too small (10). bump sysctl? add sockopt?
* figure out whether we should leave dbus around during shutdown
* dbus: in fedora, make the machine a symlink to /etc/machine-id
* dbus: move dbus to early boot
* logind: add equivalent to sd_pid_get_owner_uid() to the D-Bus API
* journal: deal nicely with byte-by-byte copied files, especially regards header
* journal: local deserializer of export mode, http server
* journal: message catalog
* document the exit codes when services fail before they are exec()ed
* save coredump in Windows/Mozilla minidump format
* support crash reporting operation modes (https://live.gnome.org/GnomeOS/Design/Whiteboards/ProblemReporting)
* clean up session cgroups that remain after logout (think sshd), but eventually run empty
* support "systemctl stop foobar@.service" to stop all units matching a certain template
* logind: allow showing logout dialog from system
* document that %% can be used to write % in a string that is specifier extended
* when an instanced service exits, remove its parent cgroup too if possible.
* default to actual 32bit PIDs, via /proc/sys/kernel/pid_max
* be able to specify a forced restart of service A where service B depends on, in case B
needs to be auto-respawned?
* Something is wrong with symlink handling of "autovt@.service" in "systemctl list-unit-files"
* when a bus name of a service disappears from the bus make sure to queue further activation requests
* something like ConditionExec= or ExecStartPre= without failure state
* tmpfiles: apply "x" on "D" too (see patch from William Douglas)
* don't set $HOME in services unless requested
* hide PAM/TCPWrap options in fragment parser when compile time disabled
* when we automatically restart a service, ensure we restart its rdeps, too.
* allow Type=simple with PIDFile=
https://bugzilla.redhat.com/show_bug.cgi?id=723942
* move PAM code into its own binary
* logind: spawn user@..service on login
* logind: non-local X11 server handling
* implement Register= switch in .socket units to enable registration
in Avahi, RPC and other socket registration services.
* make sure systemd-ask-password-wall does not shutdown systemd-ask-password-console too early
* readahead: use BTRFS_IOC_DEFRAG_RANGE instead of BTRFS_IOC_DEFRAG ioctl, with START_IO
* readahead: check whether a btrfs volume includes ssd by checking mount flag "ssd"
* support sd_notify() style notification when reload begins (RELOADING=1), reload is finished (READY=1), and add ReloadSignal= then to use in combination
* support sd_notify() style notification when shutting down, to make auto-exit bus services work (STOPPING=1)
* verify that the AF_UNIX sockets of a service in the fs still exist
when we start a service in order to avoid confusion when a user
assumes starting a service is enough to make it accessible
* Make it possible to set the keymap independently from the font on
the kernel cmdline. Right now setting one resets also the other.
* move nss-myhostname into systemd
* and a dbus call to generate target from current state
* drop /.readahead on bigger upgrades with yum
* add support for /bin/mount -s
* GC unreferenced jobs (such as .device jobs)
* write blog stories about:
- hwdb: what belongs into it, lsusb
- enabling dbus services
- status update
- how to make changes to sysctl and sysfs attributes
- remote access
- how to pass throw-away units to systemd, or dynamically change properties of existing units
- how to integrate cgconfig and suchlike with systemd
- testing with Harald's awesome test kit
- auto-restart
- how to develop against journal browsing APIs
- the journal HTTP iface
- non-cgroup resource management
* allow port=0 in .socket units
* move readahead files into /var (look for them with .path units?)
* teach dbus to activate all services it finds in /etc/systemd/services/org-*.service
* support systemd.mask= on the kernel command line.
* when key file cannot be found, read it from kbd in cryptsetup
* reuse mkdtemp namespace dirs in /tmp?
* recreate systemd's D-Bus private socket file on SIGUSR2
* Support --test based on current system state
* investigate whether the gnome pty helper should be moved into systemd, to provide cgroup support.
* maybe introduce ExecRestartPre=
* configurable jitter for timer events
* timer events with system resume
* dot output for --test showing the 'initial transaction'
* calendar time support in timer:
https://docs.google.com/document/pub?id=1bAMyFAjWLpzR3GTDYdgj5FWRMxoZiWw5zmUHEtvdHKA
* writable cgroups dbus properties for live changes
* port over to LISTEN_FDS/LISTEN_PID:
- rpcbind (/var/run/rpcbind.sock!) HAVEPATCH
- cups HAVEPATCH
- postfix, saslauthd
- apache/samba
- libvirtd (/var/run/libvirt/libvirt-sock-ro)
- bluetoothd (/var/run/sdp! @/org/bluez/audio!)
- distccd
* fingerprint.target, wireless.target, gps.target, netdevice.target
* io priority during initialization
* systemctl list-jobs - show dependencies
* add systemctl switch to dump transaction without executing it
* drop cap bounding set in readahead and other services
External:
* dbus:
- dbus --user
- natively watch for dbus-*.service symlinks (PENDING)
- allow specification of socket mode/umask when allocating DBusServer
- allow disabling of fd passing when connecting a AF_UNIX connection
- allow disabling of UID passing for AUTH EXTERNAL
- always pass cred data along each message
* fix alsa mixer restore to not print error when no config is stored
* gnome-shell python script/glxinfo/is-accelerated must die
* make cryptsetup lower --iter-time
* patch kernel for xattr support in /dev, /proc/, /sys and /sys/fs/cgroup?
* NTP: the kernel's 11-minutes-mode syncs the system time to the RTC, but only
in an ~30 minutes window. It does not adjust larger differences. Find a way
to tell the kernel, to always do a full time sync when the RTC is in UTC and
we are in 11-minutes-mode. When we trust the system time to NTP we also want
the RTC to sync up.
* kernel: add device_type = "fb", "fbcon" to class "graphics"
Regularly:
* look for close() vs. close_nointr() vs. close_nointr_nofail()
* check for strerror(r) instead of strerror(-r)
* Use PR_SET_PROCTITLE_AREA if it becomes available in the kernel
* %m in printf() instead of strerror(errno);
* pahole
* set_put(), hashmap_put() return values check. i.e. == 0 doesn't free()!
* use secure_getenv() instead of getenv() where appropriate
Scheduled for removal or fixing:
* xxxOverridable dependencies (probably: fix)
* support for early-boot SysV services (definitely: remove)
* insserv support (definitely: remove)

67
autogen.sh Executable file
View File

@ -0,0 +1,67 @@
#!/bin/sh
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# systemd is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with systemd; If not, see <http://www.gnu.org/licenses/>.
set -e
if [ -f .git/hooks/pre-commit.sample ] && [ ! -f .git/hooks/pre-commit ]; then
# This part is allowed to fail
cp -p .git/hooks/pre-commit.sample .git/hooks/pre-commit && \
chmod +x .git/hooks/pre-commit && \
echo "Activated pre-commit hook." || :
fi
if which gtkdocize >/dev/null 2>/dev/null; then
gtkdocize --docdir docs/
gtkdocargs=--enable-gtk-doc
else
echo "You don't have gtk-doc installed, and thus won't be able to generate the documentation."
rm -f docs/gtk-doc.make
echo 'EXTRA_DIST =' > docs/gtk-doc.make
fi
intltoolize --force --automake
autoreconf --force --install --symlink
libdir() {
echo $(cd "$1/$(gcc -print-multi-os-directory)"; pwd)
}
args="\
--sysconfdir=/etc \
--localstatedir=/var \
--libdir=$(libdir /usr/lib) \
$gtkdocargs"
if [ ! -L /bin ]; then
args="$args \
--with-rootprefix= \
--with-rootlibdir=$(libdir /lib) \
"
fi
if [ "x$1" = "xc" ]; then
./configure CFLAGS='-g -O0 -Wp,-U_FORTIFY_SOURCE' $args
make clean
else
echo
echo "----------------------------------------------------------------"
echo "Initialized build system. For a common configuration please run:"
echo "----------------------------------------------------------------"
echo
echo "./configure CFLAGS='-g -O0 -Wp,-U_FORTIFY_SOURCE' $args"
echo
fi

881
configure.ac Normal file
View File

@ -0,0 +1,881 @@
#
# This file is part of systemd.
#
# Copyright 2010-2012 Lennart Poettering
# Copyright 2010-2012 Kay Sievers
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# systemd is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with systemd; If not, see <http://www.gnu.org/licenses/>.
AC_PREREQ([2.64])
AC_INIT([systemd],
[195],
[http://bugs.freedesktop.org/enter_bug.cgi?product=systemd],
[systemd],
[http://www.freedesktop.org/wiki/Software/systemd])
AC_CONFIG_SRCDIR([src/core/main.c])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_AUX_DIR([build-aux])
AC_USE_SYSTEM_EXTENSIONS
AC_SYS_LARGEFILE
AC_PREFIX_DEFAULT([/usr])
AM_INIT_AUTOMAKE([foreign 1.11 -Wall -Wno-portability silent-rules tar-pax no-dist-gzip dist-xz subdir-objects check-news])
AM_SILENT_RULES([yes])
AC_CANONICAL_HOST
AC_DEFINE_UNQUOTED([CANONICAL_HOST], "$host", [Canonical host string.])
AS_IF([test "x$host_cpu" = "xmips" || test "x$host_cpu" = "xmipsel" ||
test "x$host_cpu" = "xmips64" || test "x$host_cpu" = "xmips64el"],
[AC_DEFINE(ARCH_MIPS, [], [Whether on mips arch])])
LT_PREREQ(2.2)
LT_INIT
# i18n stuff for the PolicyKit policy files
IT_PROG_INTLTOOL([0.40.0])
GETTEXT_PACKAGE=systemd
AC_SUBST(GETTEXT_PACKAGE)
AC_PROG_MKDIR_P
AC_PROG_LN_S
AC_PROG_SED
AC_PROG_GREP
AC_PROG_AWK
AC_PROG_CC
AC_PROG_CC_C99
AM_PROG_CC_C_O
AC_PROG_GCC_TRADITIONAL
AC_PATH_PROG([M4], [m4])
AC_PATH_PROG([XSLTPROC], [xsltproc])
AC_PATH_PROG([QUOTAON], [quotaon], [/usr/sbin/quotaon])
AC_PATH_PROG([QUOTACHECK], [quotacheck], [/usr/sbin/quotacheck])
AC_PATH_PROG([SETCAP], [setcap], [/usr/sbin/setcap])
AC_PATH_PROG([KILL], [kill], [/usr/bin/kill])
# gtkdocize greps for '^GTK_DOC_CHECK', so it needs to be on its own line
m4_ifdef([GTK_DOC_CHECK], [
GTK_DOC_CHECK([1.18],[--flavour no-tmpl])
], [AM_CONDITIONAL([ENABLE_GTK_DOC], [false])])
AS_IF([test "x$enable_gtk_doc" = "xyes" -a "x$XSLTPROC" = x], [
AC_MSG_ERROR([*** GTK doc requested but xsltproc not found])
])
m4_ifdef([GOBJECT_INTROSPECTION_CHECK], [
GOBJECT_INTROSPECTION_CHECK([1.31.1])
], [AM_CONDITIONAL([HAVE_INTROSPECTION], [false])])
AC_PATH_TOOL(OBJCOPY, objcopy)
AC_PATH_TOOL(STRINGS, strings)
AC_PATH_TOOL(GPERF, gperf)
if test -z "$GPERF" ; then
AC_MSG_ERROR([*** gperf not found])
fi
# we use python to build the man page index, and for systemd-python
have_python=no
have_python_devel=no
AC_ARG_WITH([python],
[AS_HELP_STRING([--without-python], [Disable building the man page index and systemd-python (default: test)])])
AS_IF([test "x$with_python" != "xno"], [
AM_PATH_PYTHON(,, [:])
AS_IF([test "$PYTHON" != :], [have_python=yes])
])
AM_CONDITIONAL([HAVE_PYTHON], [test "$have_python" = "yes"])
AS_IF([test "x$with_python" != "xno"], [
AC_PATH_PROG(PYTHON_CONFIG, python${PYTHON_VERSION}-config)
AS_IF([test -n "$PYTHON_CONFIG"], [
have_python_devel=yes
PYTHON_CFLAGS="`$PYTHON_CONFIG --cflags`"
PYTHON_LIBS="`$PYTHON_CONFIG --ldflags`"
AC_SUBST(PYTHON_CFLAGS)
AC_SUBST(PYTHON_LIBS)
])
])
AM_CONDITIONAL([HAVE_PYTHON_DEVEL], [test "$have_python_devel" = "yes"])
CC_CHECK_FLAGS_APPEND([with_cflags], [CFLAGS], [\
-pipe \
-Wall \
-Wextra \
-Wno-inline \
-Wundef \
-Wformat=2 \
-Wlogical-op \
-Wsign-compare \
-Wformat-security \
-Wmissing-include-dirs \
-Wformat-nonliteral \
-Wold-style-definition \
-Wpointer-arith \
-Winit-self \
-Wdeclaration-after-statement \
-Wfloat-equal \
-Wmissing-prototypes \
-Wstrict-prototypes \
-Wredundant-decls \
-Wmissing-declarations \
-Wmissing-noreturn \
-Wshadow \
-Wendif-labels \
-Wcast-align \
-Wstrict-aliasing=2 \
-Wwrite-strings \
-Wno-long-long \
-Wno-overlength-strings \
-Wno-unused-parameter \
-Wno-missing-field-initializers \
-Wno-unused-result \
-Werror=overflow \
-ffast-math \
-fno-common \
-fdiagnostics-show-option \
-fno-strict-aliasing \
-fvisibility=hidden \
-ffunction-sections \
-fdata-sections \
-fstack-protector \
--param=ssp-buffer-size=4])
AC_SUBST([OUR_CFLAGS], $with_cflags)
CC_CHECK_FLAGS_APPEND([with_cppflags], [CPPFLAGS], [\
-Wp,-D_FORTIFY_SOURCE=2])
AC_SUBST([OUR_CPPFLAGS], $with_cppflags)
CC_CHECK_FLAGS_APPEND([with_ldflags], [LDFLAGS], [\
-Wl,--as-needed \
-Wl,--gc-sections \
-Wl,-z,relro \
-Wl,-z,now])
AC_SUBST([OUR_LDFLAGS], $with_ldflags)
AC_SEARCH_LIBS([mq_open], [rt], [], [AC_MSG_ERROR([*** POSIX RT library not found])])
AC_SEARCH_LIBS([dlsym], [dl], [], [AC_MSG_ERROR([*** Dynamic linking loader library not found])])
save_LIBS="$LIBS"
LIBS=
AC_SEARCH_LIBS([cap_init], [cap], [], [AC_MSG_ERROR([*** POSIX caps library not found])])
AC_CHECK_HEADERS([sys/capability.h], [], [AC_MSG_ERROR([*** POSIX caps headers not found])])
CAP_LIBS="$LIBS"
LIBS="$save_LIBS"
AC_SUBST(CAP_LIBS)
AC_CHECK_FUNCS([fanotify_init fanotify_mark])
AC_CHECK_FUNCS([__secure_getenv secure_getenv])
AC_CHECK_DECLS([gettid, pivot_root, name_to_handle_at], [], [], [[#include <sys/types.h>
#include <unistd.h>
#include <sys/mount.h>
#include <fcntl.h>]])
# This makes sure pkg.m4 is available.
m4_pattern_forbid([^_?PKG_[A-Z_]+$],[*** pkg.m4 missing, please install pkg-config])
PKG_CHECK_MODULES(DBUS, [dbus-1 >= 1.3.2])
PKG_CHECK_MODULES(KMOD, [libkmod >= 5])
PKG_CHECK_MODULES(BLKID,[blkid >= 2.20])
# ------------------------------------------------------------------------------
have_ima=yes
AC_ARG_ENABLE([ima], AS_HELP_STRING([--disable-ima],[Disable optional IMA support]),
[case "${enableval}" in
yes) have_ima=yes ;;
no) have_ima=no ;;
*) AC_MSG_ERROR(bad value ${enableval} for --disable-ima) ;;
esac],
[have_ima=yes])
if test "x${have_ima}" != xno ; then
AC_DEFINE(HAVE_IMA, 1, [Define if IMA is available])
fi
# ------------------------------------------------------------------------------
have_selinux=no
AC_ARG_ENABLE(selinux, AS_HELP_STRING([--disable-selinux], [Disable optional SELINUX support]))
if test "x$enable_selinux" != "xno"; then
PKG_CHECK_MODULES([SELINUX], [libselinux >= 2.1.9],
[AC_DEFINE(HAVE_SELINUX, 1, [Define if SELinux is available]) have_selinux=yes], have_selinux=no)
if test "x$have_selinux" = xno -a "x$enable_selinux" = xyes; then
AC_MSG_ERROR([*** SELinux support requested but libraries not found])
fi
fi
AM_CONDITIONAL(HAVE_SELINUX, [test "$have_selinux" = "yes"])
if test "x${have_selinux}" != xno ; then
sushell=/sbin/sushell
else
sushell=/bin/bash
fi
AC_SUBST(sushell)
# ------------------------------------------------------------------------------
have_xz=no
AC_ARG_ENABLE(xz, AS_HELP_STRING([--disable-xz], [Disable optional XZ support]))
if test "x$enable_xz" != "xno"; then
PKG_CHECK_MODULES(XZ, [ liblzma ],
[AC_DEFINE(HAVE_XZ, 1, [Define if XZ is available]) have_xz=yes], have_xz=no)
if test "x$have_xz" = xno -a "x$enable_xz" = xyes; then
AC_MSG_ERROR([*** Xz support requested but libraries not found])
fi
fi
AM_CONDITIONAL(HAVE_XZ, [test "$have_xz" = "yes"])
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([tcpwrap],
AS_HELP_STRING([--disable-tcpwrap],[Disable optional TCP wrappers support]),
[case "${enableval}" in
yes) have_tcpwrap=yes ;;
no) have_tcpwrap=no ;;
*) AC_MSG_ERROR(bad value ${enableval} for --disable-tcpwrap) ;;
esac],
[have_tcpwrap=auto])
if test "x${have_tcpwrap}" != xno ; then
ACX_LIBWRAP
if test "x${LIBWRAP_LIBS}" = x ; then
if test "x$have_tcpwrap" = xyes ; then
AC_MSG_ERROR([*** TCP wrappers support not found.])
fi
have_tcpwrap=no
else
have_tcpwrap=yes
fi
else
LIBWRAP_LIBS=
fi
AC_SUBST(LIBWRAP_LIBS)
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([pam],
AS_HELP_STRING([--disable-pam],[Disable optional PAM support]),
[case "${enableval}" in
yes) have_pam=yes ;;
no) have_pam=no ;;
*) AC_MSG_ERROR(bad value ${enableval} for --disable-pam) ;;
esac],
[have_pam=auto])
if test "x${have_pam}" != xno ; then
AC_CHECK_HEADERS(
[security/pam_modules.h security/pam_modutil.h security/pam_ext.h],
[have_pam=yes],
[if test "x$have_pam" = xyes ; then
AC_MSG_ERROR([*** PAM headers not found.])
fi])
AC_CHECK_LIB(
[pam],
[pam_syslog],
[have_pam=yes],
[if test "x$have_pam" = xyes ; then
AC_MSG_ERROR([*** libpam not found.])
fi])
if test "x$have_pam" = xyes ; then
PAM_LIBS="-lpam -lpam_misc"
AC_DEFINE(HAVE_PAM, 1, [PAM available])
else
have_pam=no
fi
else
PAM_LIBS=
fi
AC_SUBST(PAM_LIBS)
AM_CONDITIONAL([HAVE_PAM], [test "x$have_pam" != xno])
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([acl],
AS_HELP_STRING([--disable-acl],[Disable optional ACL support]),
[case "${enableval}" in
yes) have_acl=yes ;;
no) have_acl=no ;;
*) AC_MSG_ERROR(bad value ${enableval} for --disable-acl) ;;
esac],
[have_acl=auto])
if test "x${have_acl}" != xno ; then
AC_CHECK_HEADERS(
[sys/acl.h acl/libacl.h],
[have_acl=yes],
[if test "x$have_acl" = xyes ; then
AC_MSG_ERROR([*** ACL headers not found.])
fi])
AC_CHECK_LIB(
[acl],
[acl_get_file],
[have_acl=yes],
[if test "x$have_acl" = xyes ; then
AC_MSG_ERROR([*** libacl not found.])
fi])
if test "x$have_acl" = xyes ; then
ACL_LIBS="-lacl"
AC_DEFINE(HAVE_ACL, 1, [ACL available])
else
have_acl=no
fi
else
ACL_LIBS=
fi
AC_SUBST(ACL_LIBS)
AM_CONDITIONAL([HAVE_ACL], [test "x$have_acl" != xno])
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([xattr],
AS_HELP_STRING([--disable-xattr],[Disable optional XATTR support]),
[case "${enableval}" in
yes) have_xattr=yes ;;
no) have_xattr=no ;;
*) AC_MSG_ERROR(bad value ${enableval} for --disable-xattr) ;;
esac],
[have_xattr=auto])
if test "x${have_xattr}" != xno ; then
AC_CHECK_HEADERS(
[attr/xattr.h],
[have_xattr=yes],
[if test "x$have_xattr" = xyes ; then
AC_MSG_ERROR([*** XATTR headers not found.])
fi])
AC_CHECK_LIB(
[attr],
[fsetxattr],
[have_xattr=yes],
[if test "x$have_xattr" = xyes ; then
AC_MSG_ERROR([*** libattr not found.])
fi])
if test "x$have_xattr" = xyes ; then
XATTR_LIBS="-lattr"
AC_DEFINE(HAVE_XATTR, 1, [XATTR available])
else
have_xattr=no
fi
else
XATTR_LIBS=
fi
AC_SUBST(XATTR_LIBS)
AM_CONDITIONAL([HAVE_XATTR], [test "x$have_xattr" != xno])
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([gcrypt],
AS_HELP_STRING([--disable-gcrypt],[Disable optional GCRYPT support]),
[case "${enableval}" in
yes) have_gcrypt=yes ;;
no) have_gcrypt=no ;;
*) AC_MSG_ERROR(bad value ${enableval} for --disable-gcrypt) ;;
esac],
[have_gcrypt=auto])
if test "x${have_gcrypt}" != xno ; then
AM_PATH_LIBGCRYPT(
[1.4.5],
[have_gcrypt=yes],
[if test "x$have_gcrypt" = xyes ; then
AC_MSG_ERROR([*** GCRYPT headers not found.])
fi])
if test "x$have_gcrypt" = xyes ; then
GCRYPT_LIBS="$LIBGCRYPT_LIBS"
GCRYPT_CFLAGS="$LIBGCRYPT_CFLAGS"
AC_DEFINE(HAVE_GCRYPT, 1, [GCRYPT available])
else
have_gcrypt=no
fi
else
GCRYPT_LIBS=
GCRYPT_CFLAGS=
fi
AC_SUBST(GCRYPT_LIBS)
AC_SUBST(GCRYPT_CFLAGS)
AM_CONDITIONAL([HAVE_GCRYPT], [test "x$have_gcrypt" != xno])
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([audit],
AS_HELP_STRING([--disable-audit],[Disable optional AUDIT support]),
[case "${enableval}" in
yes) have_audit=yes ;;
no) have_audit=no ;;
*) AC_MSG_ERROR(bad value ${enableval} for --disable-audit) ;;
esac],
[have_audit=auto])
if test "x${have_audit}" != xno ; then
AC_CHECK_HEADERS(
[libaudit.h],
[have_audit=yes],
[if test "x$have_audit" = xyes ; then
AC_MSG_ERROR([*** AUDIT headers not found.])
fi])
AC_CHECK_LIB(
[audit],
[audit_open],
[have_audit=yes],
[if test "x$have_audit" = xyes ; then
AC_MSG_ERROR([*** libaudit not found.])
fi])
if test "x$have_audit" = xyes ; then
AUDIT_LIBS="-laudit"
AC_DEFINE(HAVE_AUDIT, 1, [AUDIT available])
else
have_audit=no
fi
else
AUDIT_LIBS=
fi
AC_SUBST(AUDIT_LIBS)
# ------------------------------------------------------------------------------
have_libcryptsetup=no
AC_ARG_ENABLE(libcryptsetup, AS_HELP_STRING([--disable-libcryptsetup], [disable libcryptsetup tools]))
if test "x$enable_libcryptsetup" != "xno"; then
PKG_CHECK_MODULES(LIBCRYPTSETUP, [ libcryptsetup >= 1.4.2 ],
[AC_DEFINE(HAVE_LIBCRYPTSETUP, 1, [Define if libcryptsetup is available]) have_libcryptsetup=yes], have_libcryptsetup=no)
if test "x$have_libcryptsetup" = xno -a "x$enable_libcryptsetup" = xyes; then
AC_MSG_ERROR([*** libcryptsetup support requested but libraries not found])
fi
fi
AM_CONDITIONAL(HAVE_LIBCRYPTSETUP, [test "$have_libcryptsetup" = "yes"])
# ------------------------------------------------------------------------------
have_qrencode=no
AC_ARG_ENABLE(qrencode, AS_HELP_STRING([--disable-qrencode], [disable qrencode support]))
if test "x$enable_qrencode" != "xno"; then
PKG_CHECK_MODULES(QRENCODE, [ libqrencode ],
[AC_DEFINE(HAVE_QRENCODE, 1, [Define if qrencode is available]) have_qrencode=yes], have_qrencode=no)
if test "x$have_qrencode" = xno -a "x$enable_qrencode" = xyes; then
AC_MSG_ERROR([*** qrencode support requested but libraries not found])
fi
fi
AM_CONDITIONAL(HAVE_QRENCODE, [test "$have_qrencode" = "yes"])
# ------------------------------------------------------------------------------
have_microhttpd=no
AC_ARG_ENABLE(microhttpd, AS_HELP_STRING([--disable-microhttpd], [disable microhttpd support]))
if test "x$enable_microhttpd" != "xno"; then
PKG_CHECK_MODULES(MICROHTTPD, [libmicrohttpd >= 0.9.5],
[AC_DEFINE(HAVE_MICROHTTPD, 1, [Define if microhttpd is available]) have_microhttpd=yes], have_microhttpd=no)
if test "x$have_microhttpd" = xno -a "x$enable_microhttpd" = xyes; then
AC_MSG_ERROR([*** microhttpd support requested but libraries not found])
fi
fi
AM_CONDITIONAL(HAVE_MICROHTTPD, [test "$have_microhttpd" = "yes"])
# ------------------------------------------------------------------------------
have_binfmt=no
AC_ARG_ENABLE(binfmt, AS_HELP_STRING([--disable-binfmt], [disable binfmt tool]))
if test "x$enable_binfmt" != "xno"; then
have_binfmt=yes
fi
AM_CONDITIONAL(ENABLE_BINFMT, [test "$have_binfmt" = "yes"])
# ------------------------------------------------------------------------------
have_vconsole=no
AC_ARG_ENABLE(vconsole, AS_HELP_STRING([--disable-vconsole], [disable vconsole tool]))
if test "x$enable_vconsole" != "xno"; then
have_vconsole=yes
fi
AM_CONDITIONAL(ENABLE_VCONSOLE, [test "$have_vconsole" = "yes"])
# ------------------------------------------------------------------------------
have_readahead=no
AC_ARG_ENABLE(readahead, AS_HELP_STRING([--disable-readahead], [disable readahead tools]))
if test "x$enable_readahead" != "xno"; then
have_readahead=yes
fi
AM_CONDITIONAL(ENABLE_READAHEAD, [test "$have_readahead" = "yes"])
# ------------------------------------------------------------------------------
have_quotacheck=no
AC_ARG_ENABLE(quotacheck, AS_HELP_STRING([--disable-quotacheck], [disable quotacheck tools]))
if test "x$enable_quotacheck" != "xno"; then
have_quotacheck=yes
fi
AM_CONDITIONAL(ENABLE_QUOTACHECK, [test "$have_quotacheck" = "yes"])
# ------------------------------------------------------------------------------
have_randomseed=no
AC_ARG_ENABLE(randomseed, AS_HELP_STRING([--disable-randomseed], [disable randomseed tools]))
if test "x$enable_randomseed" != "xno"; then
have_randomseed=yes
fi
AM_CONDITIONAL(ENABLE_RANDOMSEED, [test "$have_randomseed" = "yes"])
# ------------------------------------------------------------------------------
have_logind=no
AC_ARG_ENABLE(logind, AS_HELP_STRING([--disable-logind], [disable login daemon]))
if test "x$enable_logind" != "xno"; then
have_logind=yes
fi
AM_CONDITIONAL(ENABLE_LOGIND, [test "$have_logind" = "yes"])
AS_IF([test "$have_logind" = "yes"], [ AC_DEFINE(HAVE_LOGIND, [1], [Logind support available]) ])
# ------------------------------------------------------------------------------
have_hostnamed=no
AC_ARG_ENABLE(hostnamed, AS_HELP_STRING([--disable-hostnamed], [disable hostname daemon]))
if test "x$enable_hostnamed" != "xno"; then
have_hostnamed=yes
fi
AM_CONDITIONAL(ENABLE_HOSTNAMED, [test "$have_hostnamed" = "yes"])
# ------------------------------------------------------------------------------
have_timedated=no
AC_ARG_ENABLE(timedated, AS_HELP_STRING([--disable-timedated], [disable timedate daemon]))
if test "x$enable_timedated" != "xno"; then
have_timedated=yes
fi
AM_CONDITIONAL(ENABLE_TIMEDATED, [test "$have_timedated" = "yes"])
# ------------------------------------------------------------------------------
have_localed=no
AC_ARG_ENABLE(localed, AS_HELP_STRING([--disable-localed], [disable locale daemon]))
if test "x$enable_localed" != "xno"; then
have_localed=yes
fi
AM_CONDITIONAL(ENABLE_LOCALED, [test "$have_localed" = "yes"])
# ------------------------------------------------------------------------------
have_coredump=no
AC_ARG_ENABLE(coredump, AS_HELP_STRING([--disable-coredump], [disable coredump hook]))
if test "x$enable_coredump" != "xno"; then
have_coredump=yes
fi
AM_CONDITIONAL(ENABLE_COREDUMP, [test "$have_coredump" = "yes"])
# ------------------------------------------------------------------------------
AC_ARG_WITH(firmware-path,
AS_HELP_STRING([--with-firmware-path=DIR[[[:DIR[...]]]]],
[Firmware search path (default=ROOTPREFIX/lib/firmware/updates:ROOTPREFIX/lib/firmware)]),
[], [with_firmware_path="$rootprefix/lib/firmware/updates:$rootprefix/lib/firmware"])
OLD_IFS=$IFS
IFS=:
for i in $with_firmware_path; do
if test "x${FIRMWARE_PATH}" = "x"; then
FIRMWARE_PATH="\\\"${i}/\\\""
else
FIRMWARE_PATH="${FIRMWARE_PATH}, \\\"${i}/\\\""
fi
done
IFS=$OLD_IFS
AC_SUBST([FIRMWARE_PATH], [$FIRMWARE_PATH])
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([gudev],
AS_HELP_STRING([--disable-gudev], [disable Gobject libudev support @<:@default=enabled@:>@]),
[], [enable_gudev=yes])
AS_IF([test "x$enable_gudev" = "xyes"], [ PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.22.0 gobject-2.0 >= 2.22.0]) ])
AM_CONDITIONAL([ENABLE_GUDEV], [test "x$enable_gudev" = "xyes"])
# ------------------------------------------------------------------------------
AC_ARG_ENABLE([keymap],
AS_HELP_STRING([--disable-keymap], [disable keymap fixup support @<:@default=enabled@:>@]),
[], [enable_keymap=yes])
AS_IF([test "x$enable_keymap" = "xyes"], [
AC_PATH_PROG([GPERF], [gperf])
if test -z "$GPERF"; then
AC_MSG_ERROR([gperf is needed])
fi
AC_CHECK_HEADER([linux/input.h], [:], AC_MSG_ERROR([kernel headers not found]))
AC_SUBST([INCLUDE_PREFIX], [$(echo '#include <linux/input.h>' | eval $ac_cpp -E - | sed -n '/linux\/input.h/ {s:.*"\(.*\)/linux/input.h".*:\1:; p; q}')])
])
AM_CONDITIONAL([ENABLE_KEYMAP], [test "x$enable_keymap" = "xyes"])
# ------------------------------------------------------------------------------
have_manpages=no
AC_ARG_ENABLE(manpages, AS_HELP_STRING([--disable-manpages], [disable manpages]))
AS_IF([test "x$enable_manpages" != xno], [
AS_IF([test "x$enable_manpages" = xyes -a "x$XSLTPROC" = x], [
AC_MSG_ERROR([*** Manpages requested but xsltproc not found])
])
AS_IF([test "x$XSLTPROC" != x], [have_manpages=yes])
])
AM_CONDITIONAL(ENABLE_MANPAGES, [test "x$have_manpages" = "xyes"])
# ------------------------------------------------------------------------------
AC_ARG_WITH(distro, AS_HELP_STRING([--with-distro=DISTRO],[Specify the distribution to target: One of fedora, suse, debian, ubuntu, arch, gentoo, slackware, altlinux, mandriva, mageia, angstrom or other]))
if test "z$with_distro" = "z"; then
if test "$cross_compiling" = yes; then
AC_MSG_WARN([Target distribution cannot be reliably detected when cross-compiling. You should specify it with --with-distro (see $0 --help for recognized distros)])
else
with_distro=$($GREP '^ID=' /etc/os-release 2>/dev/null | $SED 's/ID=//');
fi
if test "z$with_distro" = "z"; then
with_distro=other
fi
fi
with_distro=`echo ${with_distro} | tr '[[:upper:]]' '[[:lower:]]' `
AC_DEFINE_UNQUOTED(DISTRIBUTION, ["${with_distro}"], [Target Distribution])
# Location of the init scripts as mandated by LSB
SYSTEM_SYSVINIT_PATH=/etc/init.d
SYSTEM_SYSVRCND_PATH=/etc/rc.d
M4_DEFINES=
case $with_distro in
fedora)
SYSTEM_SYSVINIT_PATH=/etc/rc.d/init.d
AC_DEFINE(TARGET_FEDORA, [], [Target is Fedora/RHEL])
M4_DEFINES=-DTARGET_FEDORA=1
;;
opensuse|suse)
SYSTEM_SYSVRCND_PATH=/etc/init.d
AC_DEFINE(TARGET_SUSE, [], [Target is openSUSE/SLE])
M4_DEFINES=-DTARGET_SUSE=1
;;
debian)
SYSTEM_SYSVRCND_PATH=/etc
AC_DEFINE(TARGET_DEBIAN, [], [Target is Debian])
M4_DEFINES=-DTARGET_DEBIAN=1
;;
ubuntu)
SYSTEM_SYSVRCND_PATH=/etc
AC_DEFINE(TARGET_UBUNTU, [], [Target is Ubuntu])
M4_DEFINES=-DTARGET_UBUNTU=1
;;
arch)
SYSTEM_SYSVINIT_PATH=
SYSTEM_SYSVRCND_PATH=
AC_DEFINE(TARGET_ARCH, [], [Target is ArchLinux])
M4_DEFINES=-DTARGET_ARCH=1
;;
gentoo)
SYSTEM_SYSVINIT_PATH=
SYSTEM_SYSVRCND_PATH=
AC_DEFINE(TARGET_GENTOO, [], [Target is Gentoo])
M4_DEFINES=-DTARGET_GENTOO=1
;;
slackware)
SYSTEM_SYSVINIT_PATH=/etc/rc.d/init.d
AC_DEFINE(TARGET_SLACKWARE, [], [Target is Slackware])
M4_DEFINES=-DTARGET_SLACKWARE=1
;;
frugalware)
SYSTEM_SYSVINIT_PATH=/etc/rc.d
AC_DEFINE(TARGET_FRUGALWARE, [], [Target is Frugalware])
M4_DEFINES=-DTARGET_FRUGALWARE=1
;;
altlinux)
SYSTEM_SYSVINIT_PATH=/etc/rc.d/init.d
AC_DEFINE(TARGET_ALTLINUX, [], [Target is ALTLinux])
M4_DEFINES=-DTARGET_ALTLINUX=1
;;
mandriva)
SYSTEM_SYSVINIT_PATH=/etc/rc.d/init.d
AC_DEFINE(TARGET_MANDRIVA, [], [Target is Mandriva])
M4_DEFINES=-DTARGET_MANDRIVA=1
;;
angstrom)
SYSTEM_SYSVRCND_PATH=/etc
AC_DEFINE(TARGET_ANGSTROM, [], [Target is Ångström])
M4_DEFINES=-DTARGET_ANGSTROM=1
;;
mageia)
SYSTEM_SYSVINIT_PATH=/etc/rc.d/init.d
AC_DEFINE(TARGET_MAGEIA, [], [Target is Mageia])
M4_DEFINES=-DTARGET_MAGEIA=1
;;
other)
;;
*)
AC_MSG_ERROR([Your distribution (${with_distro}) is not yet supported, SysV init scripts could not be found! (patches welcome); you can specify --with-distro=other to skip this check])
;;
esac
AC_ARG_WITH([sysvinit-path],
[AS_HELP_STRING([--with-sysvinit-path=PATH],
[Specify the path to where the SysV init scripts are located @<:@default=based on distro@:>@])],
[SYSTEM_SYSVINIT_PATH="$withval"],
[])
AC_ARG_WITH([sysvrcd-path],
[AS_HELP_STRING([--with-sysvrcd-path=PATH],
[Specify the path to the base directory for the SysV rcN.d directories @<:@default=based on distro@:>@])],
[SYSTEM_SYSVRCND_PATH="$withval"],
[])
AC_SUBST(SYSTEM_SYSVINIT_PATH)
AC_SUBST(SYSTEM_SYSVRCND_PATH)
AC_SUBST(M4_DEFINES)
if test "x${SYSTEM_SYSVINIT_PATH}" != "x" -a "x${SYSTEM_SYSVRCND_PATH}" != "x"; then
AC_DEFINE(HAVE_SYSV_COMPAT, [], [SysV init scripts and rcN.d links are supported.])
SYSTEM_SYSV_COMPAT="yes"
M4_DEFINES="$M4_DEFINES -DHAVE_SYSV_COMPAT"
elif test "x${SYSTEM_SYSVINIT_PATH}" != "x" -o "x${SYSTEM_SYSVRCND_PATH}" != "x"; then
AC_MSG_ERROR([*** You need both --with-sysvinit-path=PATH and --with-sysvrcd-path=PATH to enable SysV compatibility support, or both empty to disable it.])
else
SYSTEM_SYSV_COMPAT="no"
fi
AC_ARG_WITH([tty-gid],
[AS_HELP_STRING([--with-tty-gid=GID],
[Specify the numeric GID of the 'tty' group])],
[AC_DEFINE_UNQUOTED(TTY_GID, [$withval], [GID of the 'tty' group])],
[])
AM_CONDITIONAL(TARGET_FEDORA, test x"$with_distro" = xfedora)
AM_CONDITIONAL(TARGET_SUSE, test x"$with_distro" = xsuse)
AM_CONDITIONAL(TARGET_DEBIAN, test x"$with_distro" = xdebian)
AM_CONDITIONAL(TARGET_UBUNTU, test x"$with_distro" = xubuntu)
AM_CONDITIONAL(TARGET_DEBIAN_OR_UBUNTU, test x"$with_distro" = xdebian -o x"$with_distro" = xubuntu)
AM_CONDITIONAL(TARGET_ARCH, test x"$with_distro" = xarch)
AM_CONDITIONAL(TARGET_GENTOO, test x"$with_distro" = xgentoo)
AM_CONDITIONAL(TARGET_SLACKWARE, test x"$with_distro" = xslackware)
AM_CONDITIONAL(TARGET_FRUGALWARE, test x"$with_distro" = xfrugalware)
AM_CONDITIONAL(TARGET_ALTLINUX, test x"$with_distro" = xaltlinux)
AM_CONDITIONAL(TARGET_MANDRIVA, test x"$with_distro" = xmandriva)
AM_CONDITIONAL(TARGET_ANGSTROM, test x"$with_distro" = xangstrom)
AM_CONDITIONAL(TARGET_MAGEIA, test x"$with_distro" = xmageia)
AM_CONDITIONAL(HAVE_SYSV_COMPAT, test "$SYSTEM_SYSV_COMPAT" = "yes")
AC_ARG_WITH([dbuspolicydir],
AS_HELP_STRING([--with-dbuspolicydir=DIR], [D-Bus policy directory]),
[],
[with_dbuspolicydir=`pkg-config --variable=sysconfdir dbus-1`/dbus-1/system.d])
AC_ARG_WITH([dbussessionservicedir],
AS_HELP_STRING([--with-dbussessionservicedir=DIR], [D-Bus session service directory]),
[],
[with_dbussessionservicedir=`pkg-config --variable=session_bus_services_dir dbus-1`])
AC_ARG_WITH([dbussystemservicedir],
AS_HELP_STRING([--with-dbussystemservicedir=DIR], [D-Bus system service directory]),
[],
[with_dbussystemservicedir=`pkg-config --variable=session_bus_services_dir dbus-1`/../system-services])
AC_ARG_WITH([dbusinterfacedir],
AS_HELP_STRING([--with-dbusinterfacedir=DIR], [D-Bus interface directory]),
[],
[with_dbusinterfacedir=`pkg-config --variable=session_bus_services_dir dbus-1`/../interfaces])
AC_ARG_WITH([rootprefix],
AS_HELP_STRING([--with-rootprefix=DIR], [rootfs directory prefix for config files and kernel modules]),
[], [with_rootprefix=${ac_default_prefix}])
AC_ARG_WITH([rootlibdir],
AS_HELP_STRING([--with-rootlibdir=DIR], [Root directory for libraries necessary for boot]),
[],
[with_rootlibdir=${libdir}])
AC_ARG_WITH([pamlibdir],
AS_HELP_STRING([--with-pamlibdir=DIR], [Directory for PAM modules]),
[],
[with_pamlibdir=${with_rootlibdir}/security])
AC_ARG_ENABLE([split-usr],
AS_HELP_STRING([--enable-split-usr], [Assume that /bin, /sbin aren\'t symlinks into /usr]),
[],
[AS_IF([test "x${ac_default_prefix}" != "x${with_rootprefix}"], [
enable_split_usr=yes
], [
enable_split_usr=no
])])
AS_IF([test "x${enable_split_usr}" = "xyes"], [
AC_DEFINE(HAVE_SPLIT_USR, 1, [Define if /bin, /sbin aren't symlinks into /usr])
])
AC_SUBST([dbuspolicydir], [$with_dbuspolicydir])
AC_SUBST([dbussessionservicedir], [$with_dbussessionservicedir])
AC_SUBST([dbussystemservicedir], [$with_dbussystemservicedir])
AC_SUBST([dbusinterfacedir], [$with_dbusinterfacedir])
AC_SUBST([pamlibdir], [$with_pamlibdir])
AC_SUBST([rootprefix], [$with_rootprefix])
AC_SUBST([rootlibdir], [$with_rootlibdir])
AC_CONFIG_FILES([
Makefile po/Makefile.in
docs/libudev/Makefile
docs/libudev/version.xml
docs/gudev/Makefile
docs/gudev/version.xml
])
AC_OUTPUT
AC_MSG_RESULT([
$PACKAGE_NAME $VERSION
Distribution: ${with_distro}
SysV compatibility: ${SYSTEM_SYSV_COMPAT}
SysV init scripts: ${SYSTEM_SYSVINIT_PATH}
SysV rc?.d directories: ${SYSTEM_SYSVRCND_PATH}
libcryptsetup: ${have_libcryptsetup}
tcpwrap: ${have_tcpwrap}
PAM: ${have_pam}
AUDIT: ${have_audit}
IMA: ${have_ima}
SELinux: ${have_selinux}
XZ: ${have_xz}
ACL: ${have_acl}
XATTR: ${have_xattr}
GCRYPT: ${have_gcrypt}
QRENCODE: ${have_qrencode}
MICROHTTPD: ${have_microhttpd}
binfmt: ${have_binfmt}
vconsole: ${have_vconsole}
readahead: ${have_readahead}
quotacheck: ${have_quotacheck}
randomseed: ${have_randomseed}
logind: ${have_logind}
hostnamed: ${have_hostnamed}
timedated: ${have_timedated}
localed: ${have_localed}
coredump: ${have_coredump}
firmware path: ${FIRMWARE_PATH}
gudev: ${enable_gudev}
gintrospection: ${enable_introspection}
keymap: ${enable_keymap}
Python: ${have_python}
Python Headers: ${have_python_devel}
prefix: ${prefix}
rootprefix: ${with_rootprefix}
sysconf dir: ${sysconfdir}
datarootdir: ${datarootdir}
includedir: ${includedir}
include_prefix: ${INCLUDE_PREFIX}
lib dir: ${libdir}
rootlib dir: ${with_rootlibdir}
PAM modules dir: ${with_pamlibdir}
D-Bus policy dir: ${with_dbuspolicydir}
D-Bus session dir: ${with_dbussessionservicedir}
D-Bus system dir: ${with_dbussystemservicedir}
D-Bus interfaces dir: ${with_dbusinterfacedir}
Split /usr: ${enable_split_usr}
man pages: ${have_manpages}
gtk-doc: ${enable_gtk_doc}
CFLAGS: ${OUR_CFLAGS} ${CFLAGS}
CPPLAGS: ${OUR_CPPFLAGS} ${CPPFLAGS}
LDFLAGS: ${OUR_LDFLAGS} ${LDFLAGS}
PYTHON_CFLAGS: ${PYTHON_CFLAGS}
PYTHON_LIBS: ${PYTHON_LIBS}
])

1
docs/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
/gtk-doc.make

1
docs/Makefile Symbolic link
View File

@ -0,0 +1 @@
../src/Makefile

19
docs/gudev/.gitignore vendored Normal file
View File

@ -0,0 +1,19 @@
/*.bak
/gtk-doc.make
/version.xml
/Makefile
/gudev-overrides.txt
/gudev-decl-list.txt
/gudev-decl.txt
/gudev-undeclared.txt
/gudev-undocumented.txt
/gudev-unused.txt
/gudev.args
/gudev.hierarchy
/gudev.interfaces
/gudev.prerequisites
/gudev.signals
/html/
/xml/
/*.stamp
/tmpl/

113
docs/gudev/Makefile.am Normal file
View File

@ -0,0 +1,113 @@
## Process this file with automake to produce Makefile.in
# We require automake 1.10 at least.
AUTOMAKE_OPTIONS = 1.10
# This is a blank Makefile.am for using gtk-doc.
# Copy this to your project's API docs directory and modify the variables to
# suit your project. See the GTK+ Makefiles in gtk+/docs/reference for examples
# of using the various options.
# The name of the module, e.g. 'glib'.
DOC_MODULE=gudev
# Uncomment for versioned docs and specify the version of the module, e.g. '2'.
#DOC_MODULE_VERSION=2
# The top-level SGML file. You can change this if you want to.
DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
# The directory containing the source code. Relative to $(srcdir).
# gtk-doc will search all .c & .h files beneath here for inline comments
# documenting the functions and macros.
# e.g. DOC_SOURCE_DIR=../../../gtk
DOC_SOURCE_DIR=$(top_srcdir)/src/gudev $(top_builddir)/src/gudev
# Extra options to pass to gtkdoc-scangobj. Not normally needed.
SCANGOBJ_OPTIONS=
# Extra options to supply to gtkdoc-scan.
# e.g. SCAN_OPTIONS=--deprecated-guards="GTK_DISABLE_DEPRECATED"
SCAN_OPTIONS=
# Extra options to supply to gtkdoc-mkdb.
# e.g. MKDB_OPTIONS=--sgml-mode --output-format=xml
MKDB_OPTIONS=--xml-mode --output-format=xml --name-space=g_udev
# Extra options to supply to gtkdoc-mktmpl
# e.g. MKTMPL_OPTIONS=--only-section-tmpl
MKTMPL_OPTIONS=
# Extra options to supply to gtkdoc-mkhtml
MKHTML_OPTIONS=--path=$(abs_srcdir) --path=$(abs_builddir)
# Extra options to supply to gtkdoc-fixref. Not normally needed.
# e.g. FIXXREF_OPTIONS=--extra-dir=../gdk-pixbuf/html --extra-dir=../gdk/html
FIXXREF_OPTIONS=>/dev/null 2>&1
# Used for dependencies. The docs will be rebuilt if any of these change.
# e.g. HFILE_GLOB=$(top_srcdir)/gtk/*.h
# e.g. CFILE_GLOB=$(top_srcdir)/gtk/*.c
HFILE_GLOB=$(top_srcdir)/src/gudev/*.h
CFILE_GLOB=$(top_srcdir)/src/gudev/*.c
# Extra header to include when scanning, which are not under DOC_SOURCE_DIR
# e.g. EXTRA_HFILES=$(top_srcdir}/contrib/extra.h
EXTRA_HFILES=
# Header files to ignore when scanning. Use base file name, no paths
# e.g. IGNORE_HFILES=gtkdebug.h gtkintl.h
IGNORE_HFILES=gudevenumtypes.h gudevmarshal.h
# Images to copy into HTML directory.
# e.g. HTML_IMAGES=$(top_srcdir)/gtk/stock-icons/stock_about_24.png
HTML_IMAGES=
# Extra SGML files that are included by $(DOC_MAIN_SGML_FILE).
# e.g. content_files=running.sgml building.sgml changes-2.0.sgml
content_files = version.xml
# SGML files where gtk-doc abbrevations (#GtkWidget) are expanded
# These files must be listed here *and* in content_files
# e.g. expand_content_files=running.sgml
expand_content_files=
# Hack, hack. You silly gtk-doc, you must not add CFLAGS multiple
# times when calling gcc; it surely can not work with options that must
# be listed only once.
# Kill CFLAGS here because gtk-doc thinks adding CFLAGS to CC _and_ also
# adding CFLAGS itself again would work.
override CFLAGS=
override LDFLAGS=
# CFLAGS and LDFLAGS for compiling gtkdoc-scangobj with your library.
# Only needed if you are using gtkdoc-scangobj to dynamically query widget
# signals and properties.
# e.g. GTKDOC_CFLAGS=-I$(top_srcdir) -I$(top_builddir) $(GTK_DEBUG_FLAGS)
# e.g. GTKDOC_LIBS=$(top_builddir)/gtk/$(gtktargetlib)
GTKDOC_CFLAGS = \
$(GLIB_CFLAGS) \
-I$(top_srcdir)/src/gudev \
-I$(top_builddir)/src/gudev
GTKDOC_LIBS = \
$(GLIB_LIBS) \
$(top_builddir)/libgudev-1.0.la
# This includes the standard gtk-doc make rules, copied by gtkdocize.
include $(top_srcdir)/docs/gtk-doc.make
# Other files to distribute
# e.g. EXTRA_DIST += version.xml.in
EXTRA_DIST += version.xml.in
# Files not to distribute
# for --rebuild-types in $(SCAN_OPTIONS), e.g. $(DOC_MODULE).types
# for --rebuild-sections in $(SCAN_OPTIONS) e.g. $(DOC_MODULE)-sections.txt
#DISTCLEANFILES +=
# Comment this out if you want your docs-status tested during 'make check'
if ENABLE_GTK_DOC
TESTS_ENVIRONMENT = cd $(top_srcdir)
TESTS = $(GTKDOC_CHECK)
endif

52
docs/gudev/gudev-docs.xml Normal file
View File

@ -0,0 +1,52 @@
<?xml version="1.0"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
[
<!ENTITY version SYSTEM "version.xml">
]>
<book id="index" xmlns:xi="http://www.w3.org/2003/XInclude">
<bookinfo>
<title>GUdev Reference Manual</title>
<releaseinfo>
For version &version; — the latest version of this
documentation can be found at
<ulink role="online-location" url="http://www.freedesktop.org/software/systemd/gudev/">
http://www.freedesktop.org/software/systemd/gudev/
</ulink>.
</releaseinfo>
<copyright>
<year>2009-2012</year>
<holder>David Zeuthen &lt;davidz@redhat.com&gt;</holder>
<holder>Bastien Nocera &lt;hadess@hadess.net&gt;</holder>
</copyright>
</bookinfo>
<chapter id="ref-API">
<title>API Reference</title>
<xi:include href="xml/gudevclient.xml"/>
<xi:include href="xml/gudevdevice.xml"/>
<xi:include href="xml/gudevenumerator.xml"/>
</chapter>
<chapter id="gudev-hierarchy">
<title>Object Hierarchy</title>
<xi:include href="xml/tree_index.sgml"/>
</chapter>
<index id="api-index-full">
<title>API Index</title>
<xi:include href="xml/api-index-full.xml"><xi:fallback /></xi:include>
</index>
<index role="165">
<title>Index of new symbols in 165</title>
<xi:include href="xml/api-index-165.xml"><xi:fallback /></xi:include>
</index>
<index id="api-index-deprecated" role="deprecated">
<title>Index of deprecated API</title>
<xi:include href="xml/api-index-deprecated.xml"><xi:fallback /></xi:include>
</index>
<xi:include href="xml/annotation-glossary.xml"><xi:fallback /></xi:include>
</book>

View File

@ -0,0 +1,100 @@
<SECTION>
<FILE>gudevclient</FILE>
<TITLE>GUdevClient</TITLE>
GUdevClient
GUdevClientClass
GUdevDeviceType
GUdevDeviceNumber
g_udev_client_new
g_udev_client_query_by_subsystem
g_udev_client_query_by_device_number
g_udev_client_query_by_device_file
g_udev_client_query_by_sysfs_path
g_udev_client_query_by_subsystem_and_name
<SUBSECTION Standard>
G_UDEV_CLIENT
G_UDEV_IS_CLIENT
G_UDEV_TYPE_CLIENT
g_udev_client_get_type
G_UDEV_CLIENT_CLASS
G_UDEV_IS_CLIENT_CLASS
G_UDEV_CLIENT_GET_CLASS
<SUBSECTION Private>
GUdevClientPrivate
</SECTION>
<SECTION>
<FILE>gudevdevice</FILE>
<TITLE>GUdevDevice</TITLE>
GUdevDevice
GUdevDeviceClass
g_udev_device_get_subsystem
g_udev_device_get_devtype
g_udev_device_get_name
g_udev_device_get_number
g_udev_device_get_sysfs_path
g_udev_device_get_driver
g_udev_device_get_action
g_udev_device_get_seqnum
g_udev_device_get_device_type
g_udev_device_get_device_number
g_udev_device_get_device_file
g_udev_device_get_device_file_symlinks
g_udev_device_get_parent
g_udev_device_get_parent_with_subsystem
g_udev_device_get_tags
g_udev_device_get_is_initialized
g_udev_device_get_usec_since_initialized
g_udev_device_get_property_keys
g_udev_device_has_property
g_udev_device_get_property
g_udev_device_get_property_as_int
g_udev_device_get_property_as_uint64
g_udev_device_get_property_as_double
g_udev_device_get_property_as_boolean
g_udev_device_get_property_as_strv
g_udev_device_get_sysfs_attr
g_udev_device_get_sysfs_attr_as_int
g_udev_device_get_sysfs_attr_as_uint64
g_udev_device_get_sysfs_attr_as_double
g_udev_device_get_sysfs_attr_as_boolean
g_udev_device_get_sysfs_attr_as_strv
<SUBSECTION Standard>
G_UDEV_DEVICE
G_UDEV_IS_DEVICE
G_UDEV_TYPE_DEVICE
g_udev_device_get_type
G_UDEV_DEVICE_CLASS
G_UDEV_IS_DEVICE_CLASS
G_UDEV_DEVICE_GET_CLASS
<SUBSECTION Private>
GUdevDevicePrivate
</SECTION>
<SECTION>
<FILE>gudevenumerator</FILE>
<TITLE>GUdevEnumerator</TITLE>
GUdevEnumerator
GUdevEnumeratorClass
g_udev_enumerator_new
g_udev_enumerator_add_match_subsystem
g_udev_enumerator_add_nomatch_subsystem
g_udev_enumerator_add_match_sysfs_attr
g_udev_enumerator_add_nomatch_sysfs_attr
g_udev_enumerator_add_match_property
g_udev_enumerator_add_match_name
g_udev_enumerator_add_match_tag
g_udev_enumerator_add_match_is_initialized
g_udev_enumerator_add_sysfs_path
g_udev_enumerator_execute
<SUBSECTION Standard>
G_UDEV_ENUMERATOR
G_UDEV_IS_ENUMERATOR
G_UDEV_TYPE_ENUMERATOR
g_udev_enumerator_get_type
G_UDEV_ENUMERATOR_CLASS
G_UDEV_IS_ENUMERATOR_CLASS
G_UDEV_ENUMERATOR_GET_CLASS
<SUBSECTION Private>
GUdevEnumeratorPrivate
</SECTION>

4
docs/gudev/gudev.types Normal file
View File

@ -0,0 +1,4 @@
g_udev_device_type_get_type
g_udev_device_get_type
g_udev_client_get_type
g_udev_enumerator_get_type

View File

@ -0,0 +1 @@
@VERSION@

19
docs/libudev/.gitignore vendored Normal file
View File

@ -0,0 +1,19 @@
/gtk-doc.make
/version.xml
/Makefile
/libudev-overrides.txt
/libudev-decl-list.txt
/libudev-decl.txt
/libudev-undeclared.txt
/libudev-undocumented.txt
/libudev-unused.txt
/libudev.args
/libudev.hierarchy
/libudev.interfaces
/libudev.prerequisites
/libudev.signals
/html/
/xml/
/*.stamp
/*.bak
/tmpl/

107
docs/libudev/Makefile.am Normal file
View File

@ -0,0 +1,107 @@
## Process this file with automake to produce Makefile.in
# We require automake 1.10 at least.
AUTOMAKE_OPTIONS = 1.10
# This is a blank Makefile.am for using gtk-doc.
# Copy this to your project's API docs directory and modify the variables to
# suit your project. See the GTK+ Makefiles in gtk+/docs/reference for examples
# of using the various options.
# The name of the module, e.g. 'glib'.
DOC_MODULE=libudev
# Uncomment for versioned docs and specify the version of the module, e.g. '2'.
#DOC_MODULE_VERSION=2
# The top-level SGML file. You can change this if you want to.
DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
# The directory containing the source code. Relative to $(srcdir).
# gtk-doc will search all .c & .h files beneath here for inline comments
# documenting the functions and macros.
# e.g. DOC_SOURCE_DIR=../../../gtk
DOC_SOURCE_DIR=$(top_srcdir)/src/libudev
# Extra options to pass to gtkdoc-scangobj. Not normally needed.
SCANGOBJ_OPTIONS=
# Extra options to supply to gtkdoc-scan.
# e.g. SCAN_OPTIONS=--deprecated-guards="GTK_DISABLE_DEPRECATED"
SCAN_OPTIONS=
# Extra options to supply to gtkdoc-mkdb.
# e.g. MKDB_OPTIONS=--sgml-mode --output-format=xml
MKDB_OPTIONS=--xml-mode --output-format=xml --name-space=udev
# Extra options to supply to gtkdoc-mktmpl
# e.g. MKTMPL_OPTIONS=--only-section-tmpl
MKTMPL_OPTIONS=
# Extra options to supply to gtkdoc-mkhtml
MKHTML_OPTIONS=--path=$(abs_srcdir) --path=$(abs_builddir)
# Extra options to supply to gtkdoc-fixref. Not normally needed.
# e.g. FIXXREF_OPTIONS=--extra-dir=../gdk-pixbuf/html --extra-dir=../gdk/html
FIXXREF_OPTIONS=>/dev/null 2>&1
# Used for dependencies. The docs will be rebuilt if any of these change.
# e.g. HFILE_GLOB=$(top_srcdir)/gtk/*.h
# e.g. CFILE_GLOB=$(top_srcdir)/gtk/*.c
HFILE_GLOB=$(top_srcdir)/src/libudev/libudev*.h
CFILE_GLOB=$(top_srcdir)/src/libudev/libudev*.c
# Extra header to include when scanning, which are not under DOC_SOURCE_DIR
# e.g. EXTRA_HFILES=$(top_srcdir}/contrib/extra.h
EXTRA_HFILES=
# Header files to ignore when scanning. Use base file name, no paths
# e.g. IGNORE_HFILES=gtkdebug.h gtkintl.h
IGNORE_HFILES = libudev-private.h libudev-hwdb-def.h
# Images to copy into HTML directory.
# e.g. HTML_IMAGES=$(top_srcdir)/gtk/stock-icons/stock_about_24.png
HTML_IMAGES=
# Extra SGML files that are included by $(DOC_MAIN_SGML_FILE).
# e.g. content_files=running.sgml building.sgml changes-2.0.sgml
content_files = version.xml
# SGML files where gtk-doc abbrevations (#GtkWidget) are expanded
# These files must be listed here *and* in content_files
# e.g. expand_content_files=running.sgml
expand_content_files=
# Hack, hack. You silly gtk-doc, you must not add CFLAGS multiple
# times when calling gcc; it surely can not work with options that must
# be listed only once.
# Kill CFLAGS here because gtk-doc thinks adding CFLAGS to CC _and_ also
# adding CFLAGS itself again would work.
override CFLAGS=
override LDFLAGS=
# CFLAGS and LDFLAGS for compiling gtkdoc-scangobj with your library.
# Only needed if you are using gtkdoc-scangobj to dynamically query widget
# signals and properties.
# e.g. GTKDOC_CFLAGS=-I$(top_srcdir) -I$(top_builddir) $(GTK_DEBUG_FLAGS)
# e.g. GTKDOC_LIBS=$(top_builddir)/gtk/$(gtktargetlib)
GTKDOC_CFLAGS=
GTKDOC_LIBS=
# This includes the standard gtk-doc make rules, copied by gtkdocize.
include $(top_srcdir)/docs/gtk-doc.make
# Other files to distribute
# e.g. EXTRA_DIST += version.xml.in
EXTRA_DIST += version.xml.in
# Files not to distribute
# for --rebuild-types in $(SCAN_OPTIONS), e.g. $(DOC_MODULE).types
# for --rebuild-sections in $(SCAN_OPTIONS) e.g. $(DOC_MODULE)-sections.txt
#DISTCLEANFILES +=
# Comment this out if you want your docs-status tested during 'make check'
if ENABLE_GTK_DOC
TESTS_ENVIRONMENT = cd $(top_srcdir)
TESTS = $(GTKDOC_CHECK)
endif

View File

@ -0,0 +1,40 @@
<?xml version="1.0"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
[
<!ENTITY version SYSTEM "version.xml">
]>
<book id="index" xmlns:xi="http://www.w3.org/2003/XInclude">
<bookinfo>
<title>libudev Reference Manual</title>
<releaseinfo>
For version &version; — the latest version of this
documentation can be found at
<ulink role="online-location" url="http://www.freedesktop.org/software/systemd/libudev/">
http://www.freedesktop.org/software/systemd/libudev/
</ulink>.
</releaseinfo>
<copyright>
<year>2009-2012</year>
<holder>Kay Sievers &lt;kay@vrfy.org&gt;</holder>
</copyright>
</bookinfo>
<chapter>
<title>API Reference</title>
<xi:include href="xml/libudev.xml"/>
<xi:include href="xml/libudev-list.xml"/>
<xi:include href="xml/libudev-device.xml"/>
<xi:include href="xml/libudev-monitor.xml"/>
<xi:include href="xml/libudev-enumerate.xml"/>
<xi:include href="xml/libudev-queue.xml"/>
<xi:include href="xml/libudev-hwdb.xml"/>
<xi:include href="xml/libudev-util.xml"/>
<xi:include href="xml/api-index-deprecated.xml"/>
</chapter>
<index id="api-index-full">
<title>Index</title>
<xi:include href="xml/api-index-full.xml"/>
</index>
</book>

View File

@ -0,0 +1,134 @@
<SECTION>
<FILE>libudev</FILE>
<TITLE>udev</TITLE>
udev
udev_ref
udev_unref
udev_new
udev_set_log_fn
udev_get_log_priority
udev_set_log_priority
udev_get_userdata
udev_set_userdata
</SECTION>
<SECTION>
<FILE>libudev-list</FILE>
<TITLE>udev_list</TITLE>
udev_list_entry
udev_list_entry_get_next
udev_list_entry_get_by_name
udev_list_entry_get_name
udev_list_entry_get_value
udev_list_entry_foreach
</SECTION>
<SECTION>
<FILE>libudev-device</FILE>
<TITLE>udev_device</TITLE>
udev_device
udev_device_ref
udev_device_unref
udev_device_get_udev
udev_device_new_from_syspath
udev_device_new_from_devnum
udev_device_new_from_subsystem_sysname
udev_device_new_from_device_id
udev_device_new_from_environment
udev_device_get_parent
udev_device_get_parent_with_subsystem_devtype
udev_device_get_devpath
udev_device_get_subsystem
udev_device_get_devtype
udev_device_get_syspath
udev_device_get_sysname
udev_device_get_sysnum
udev_device_get_devnode
udev_device_get_is_initialized
udev_device_get_devlinks_list_entry
udev_device_get_properties_list_entry
udev_device_get_tags_list_entry
udev_device_get_property_value
udev_device_get_driver
udev_device_get_devnum
udev_device_get_action
udev_device_get_sysattr_value
udev_device_get_sysattr_list_entry
udev_device_get_seqnum
udev_device_get_usec_since_initialized
udev_device_has_tag
</SECTION>
<SECTION>
<FILE>libudev-monitor</FILE>
<TITLE>udev_monitor</TITLE>
udev_monitor
udev_monitor_ref
udev_monitor_unref
udev_monitor_get_udev
udev_monitor_new_from_netlink
udev_monitor_enable_receiving
udev_monitor_set_receive_buffer_size
udev_monitor_get_fd
udev_monitor_receive_device
udev_monitor_filter_add_match_subsystem_devtype
udev_monitor_filter_add_match_tag
udev_monitor_filter_update
udev_monitor_filter_remove
</SECTION>
<SECTION>
<FILE>libudev-enumerate</FILE>
<TITLE>udev_enumerate</TITLE>
udev_enumerate
udev_enumerate_ref
udev_enumerate_unref
udev_enumerate_get_udev
udev_enumerate_new
udev_enumerate_add_match_subsystem
udev_enumerate_add_nomatch_subsystem
udev_enumerate_add_match_sysattr
udev_enumerate_add_nomatch_sysattr
udev_enumerate_add_match_property
udev_enumerate_add_match_tag
udev_enumerate_add_match_parent
udev_enumerate_add_match_is_initialized
udev_enumerate_add_match_sysname
udev_enumerate_add_syspath
udev_enumerate_scan_devices
udev_enumerate_scan_subsystems
udev_enumerate_get_list_entry
</SECTION>
<SECTION>
<FILE>libudev-queue</FILE>
<TITLE>udev_queue</TITLE>
udev_queue
udev_queue_ref
udev_queue_unref
udev_queue_get_udev
udev_queue_new
udev_queue_get_udev_is_active
udev_queue_get_queue_is_empty
udev_queue_get_seqnum_is_finished
udev_queue_get_seqnum_sequence_is_finished
udev_queue_get_queued_list_entry
udev_queue_get_kernel_seqnum
udev_queue_get_udev_seqnum
</SECTION>
<SECTION>
<FILE>libudev-hwdb</FILE>
<TITLE>udev_hwdb</TITLE>
udev_hwdb
udev_hwdb_ref
udev_hwdb_unref
udev_hwdb_new
udev_hwdb_get_properties_list_entry
</SECTION>
<SECTION>
<FILE>libudev-util</FILE>
<TITLE>udev_util</TITLE>
udev_util_encode_string
</SECTION>

View File

View File

@ -0,0 +1 @@
@VERSION@

1
docs/sysvinit/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
/README

1
docs/sysvinit/Makefile Symbolic link
View File

@ -0,0 +1 @@
../../src/Makefile

27
docs/sysvinit/README.in Normal file
View File

@ -0,0 +1,27 @@
You are looking for the traditional init scripts in @SYSTEM_SYSVINIT_PATH@,
and they are gone?
Here's an explanation on what's going on:
You are running a systemd-based OS where traditional init scripts have
been replaced by native systemd services files. Service files provide
very similar functionality to init scripts. To make use of service
files simply invoke "systemctl", which will output a list of all
currently running services (and other units). Use "systemctl
list-unit-files" to get a listing of all known unit files, including
stopped, disabled and masked ones. Use "systemctl start
foobar.service" and "systemctl stop foobar.service" to start or stop a
service, respectively. For further details, please refer to
systemctl(1).
Note that traditional init scripts continue to function on a systemd
system. An init script @SYSTEM_SYSVINIT_PATH@/foobar is implicitly mapped
into a service unit foobar.service during system initialization.
Thank you!
Further reading:
man:systemctl(1)
man:systemd(1)
http://0pointer.de/blog/projects/systemd-for-admins-3.html
http://www.freedesktop.org/wiki/Software/systemd/Incompatibilities

1
docs/var-log/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
/README

1
docs/var-log/Makefile Symbolic link
View File

@ -0,0 +1 @@
../../src/Makefile

26
docs/var-log/README.in Normal file
View File

@ -0,0 +1,26 @@
You are looking for the traditional text log files in @VARLOGDIR@, and
they are gone?
Here's an explanation on what's going on:
You are running a systemd-based OS where traditional syslog has been
replaced with the Journal. The journal stores the same (and more)
information as classic syslog. To make use of the journal and access
the collected log data simply invoke "journalctl", which will output
the logs in the identical text-based format the syslog files in
@VARLOGDIR@ used to be. For further details, please refer to
journalctl(1).
Alternatively, consider installing one of the traditional syslog
implementations available for your distribution, which will generate
the classic log files for you. Syslog implementations such as
syslog-ng or rsyslog may be installed side-by-side with the journal
and will continue to function the way they always did.
Thank you!
Further reading:
man:journalctl(1)
man:systemd-journald.service(8)
man:journald.conf(5)
http://0pointer.de/blog/projects/the-journal.html

3
hwdb/.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
/pci.ids
/usb.ids
/oui.txt

51108
hwdb/20-OUI.hwdb Normal file

File diff suppressed because it is too large Load Diff

6050
hwdb/20-acpi-vendor.hwdb Normal file

File diff suppressed because it is too large Load Diff

531
hwdb/20-pci-classes.hwdb Normal file
View File

@ -0,0 +1,531 @@
# This file is part of systemd.
#
# Data imported and updated from: http://pci-ids.ucw.cz/v2.2/pci.ids
pci:v*d*sv*sd*bc00*
ID_PCI_CLASS_FROM_DATABASE=Unclassified device
pci:v*d*sv*sd*bc00sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Non-VGA unclassified device
pci:v*d*sv*sd*bc00sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=VGA compatible unclassified device
pci:v*d*sv*sd*bc01*
ID_PCI_CLASS_FROM_DATABASE=Mass storage controller
pci:v*d*sv*sd*bc01sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=SCSI storage controller
pci:v*d*sv*sd*bc01sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=IDE interface
pci:v*d*sv*sd*bc01sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=Floppy disk controller
pci:v*d*sv*sd*bc01sc03*
ID_PCI_SUBCLASS_FROM_DATABASE=IPI bus controller
pci:v*d*sv*sd*bc01sc04*
ID_PCI_SUBCLASS_FROM_DATABASE=RAID bus controller
pci:v*d*sv*sd*bc01sc05*
ID_PCI_SUBCLASS_FROM_DATABASE=ATA controller
pci:v*d*sv*sd*bc01sc05i20*
ID_PCI_INTERFACE_FROM_DATABASE=ADMA single stepping
pci:v*d*sv*sd*bc01sc05i30*
ID_PCI_INTERFACE_FROM_DATABASE=ADMA continuous operation
pci:v*d*sv*sd*bc01sc06*
ID_PCI_SUBCLASS_FROM_DATABASE=SATA controller
pci:v*d*sv*sd*bc01sc06i00*
ID_PCI_INTERFACE_FROM_DATABASE=Vendor specific
pci:v*d*sv*sd*bc01sc06i01*
ID_PCI_INTERFACE_FROM_DATABASE=AHCI 1.0
pci:v*d*sv*sd*bc01sc07*
ID_PCI_SUBCLASS_FROM_DATABASE=Serial Attached SCSI controller
pci:v*d*sv*sd*bc01sc08*
ID_PCI_SUBCLASS_FROM_DATABASE=Non-Volatile memory controller
pci:v*d*sv*sd*bc01sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Mass storage controller
pci:v*d*sv*sd*bc02*
ID_PCI_CLASS_FROM_DATABASE=Network controller
pci:v*d*sv*sd*bc02sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Ethernet controller
pci:v*d*sv*sd*bc02sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=Token ring network controller
pci:v*d*sv*sd*bc02sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=FDDI network controller
pci:v*d*sv*sd*bc02sc03*
ID_PCI_SUBCLASS_FROM_DATABASE=ATM network controller
pci:v*d*sv*sd*bc02sc04*
ID_PCI_SUBCLASS_FROM_DATABASE=ISDN controller
pci:v*d*sv*sd*bc02sc05*
ID_PCI_SUBCLASS_FROM_DATABASE=WorldFip controller
pci:v*d*sv*sd*bc02sc06*
ID_PCI_SUBCLASS_FROM_DATABASE=PICMG controller
pci:v*d*sv*sd*bc02sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Network controller
pci:v*d*sv*sd*bc03*
ID_PCI_CLASS_FROM_DATABASE=Display controller
pci:v*d*sv*sd*bc03sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=VGA compatible controller
pci:v*d*sv*sd*bc03sc00i00*
ID_PCI_INTERFACE_FROM_DATABASE=VGA controller
pci:v*d*sv*sd*bc03sc00i01*
ID_PCI_INTERFACE_FROM_DATABASE=8514 controller
pci:v*d*sv*sd*bc03sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=XGA compatible controller
pci:v*d*sv*sd*bc03sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=3D controller
pci:v*d*sv*sd*bc03sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Display controller
pci:v*d*sv*sd*bc04*
ID_PCI_CLASS_FROM_DATABASE=Multimedia controller
pci:v*d*sv*sd*bc04sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Multimedia video controller
pci:v*d*sv*sd*bc04sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=Multimedia audio controller
pci:v*d*sv*sd*bc04sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=Computer telephony device
pci:v*d*sv*sd*bc04sc03*
ID_PCI_SUBCLASS_FROM_DATABASE=Audio device
pci:v*d*sv*sd*bc04sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Multimedia controller
pci:v*d*sv*sd*bc05*
ID_PCI_CLASS_FROM_DATABASE=Memory controller
pci:v*d*sv*sd*bc05sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=RAM memory
pci:v*d*sv*sd*bc05sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=FLASH memory
pci:v*d*sv*sd*bc05sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Memory controller
pci:v*d*sv*sd*bc06*
ID_PCI_CLASS_FROM_DATABASE=Bridge
pci:v*d*sv*sd*bc06sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Host bridge
pci:v*d*sv*sd*bc06sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=ISA bridge
pci:v*d*sv*sd*bc06sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=EISA bridge
pci:v*d*sv*sd*bc06sc03*
ID_PCI_SUBCLASS_FROM_DATABASE=MicroChannel bridge
pci:v*d*sv*sd*bc06sc04*
ID_PCI_SUBCLASS_FROM_DATABASE=PCI bridge
pci:v*d*sv*sd*bc06sc04i00*
ID_PCI_INTERFACE_FROM_DATABASE=Normal decode
pci:v*d*sv*sd*bc06sc04i01*
ID_PCI_INTERFACE_FROM_DATABASE=Subtractive decode
pci:v*d*sv*sd*bc06sc05*
ID_PCI_SUBCLASS_FROM_DATABASE=PCMCIA bridge
pci:v*d*sv*sd*bc06sc06*
ID_PCI_SUBCLASS_FROM_DATABASE=NuBus bridge
pci:v*d*sv*sd*bc06sc07*
ID_PCI_SUBCLASS_FROM_DATABASE=CardBus bridge
pci:v*d*sv*sd*bc06sc08*
ID_PCI_SUBCLASS_FROM_DATABASE=RACEway bridge
pci:v*d*sv*sd*bc06sc08i00*
ID_PCI_INTERFACE_FROM_DATABASE=Transparent mode
pci:v*d*sv*sd*bc06sc08i01*
ID_PCI_INTERFACE_FROM_DATABASE=Endpoint mode
pci:v*d*sv*sd*bc06sc09*
ID_PCI_SUBCLASS_FROM_DATABASE=Semi-transparent PCI-to-PCI bridge
pci:v*d*sv*sd*bc06sc09i40*
ID_PCI_INTERFACE_FROM_DATABASE=Primary bus towards host CPU
pci:v*d*sv*sd*bc06sc09i80*
ID_PCI_INTERFACE_FROM_DATABASE=Secondary bus towards host CPU
pci:v*d*sv*sd*bc06sc0A*
ID_PCI_SUBCLASS_FROM_DATABASE=InfiniBand to PCI host bridge
pci:v*d*sv*sd*bc06sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Bridge
pci:v*d*sv*sd*bc07*
ID_PCI_CLASS_FROM_DATABASE=Communication controller
pci:v*d*sv*sd*bc07sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Serial controller
pci:v*d*sv*sd*bc07sc00i00*
ID_PCI_INTERFACE_FROM_DATABASE=8250
pci:v*d*sv*sd*bc07sc00i01*
ID_PCI_INTERFACE_FROM_DATABASE=16450
pci:v*d*sv*sd*bc07sc00i02*
ID_PCI_INTERFACE_FROM_DATABASE=16550
pci:v*d*sv*sd*bc07sc00i03*
ID_PCI_INTERFACE_FROM_DATABASE=16650
pci:v*d*sv*sd*bc07sc00i04*
ID_PCI_INTERFACE_FROM_DATABASE=16750
pci:v*d*sv*sd*bc07sc00i05*
ID_PCI_INTERFACE_FROM_DATABASE=16850
pci:v*d*sv*sd*bc07sc00i06*
ID_PCI_INTERFACE_FROM_DATABASE=16950
pci:v*d*sv*sd*bc07sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=Parallel controller
pci:v*d*sv*sd*bc07sc01i00*
ID_PCI_INTERFACE_FROM_DATABASE=SPP
pci:v*d*sv*sd*bc07sc01i01*
ID_PCI_INTERFACE_FROM_DATABASE=BiDir
pci:v*d*sv*sd*bc07sc01i02*
ID_PCI_INTERFACE_FROM_DATABASE=ECP
pci:v*d*sv*sd*bc07sc01i03*
ID_PCI_INTERFACE_FROM_DATABASE=IEEE1284
pci:v*d*sv*sd*bc07sc01iFE*
ID_PCI_INTERFACE_FROM_DATABASE=IEEE1284 Target
pci:v*d*sv*sd*bc07sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=Multiport serial controller
pci:v*d*sv*sd*bc07sc03*
ID_PCI_SUBCLASS_FROM_DATABASE=Modem
pci:v*d*sv*sd*bc07sc03i00*
ID_PCI_INTERFACE_FROM_DATABASE=Generic
pci:v*d*sv*sd*bc07sc03i01*
ID_PCI_INTERFACE_FROM_DATABASE=Hayes/16450
pci:v*d*sv*sd*bc07sc03i02*
ID_PCI_INTERFACE_FROM_DATABASE=Hayes/16550
pci:v*d*sv*sd*bc07sc03i03*
ID_PCI_INTERFACE_FROM_DATABASE=Hayes/16650
pci:v*d*sv*sd*bc07sc03i04*
ID_PCI_INTERFACE_FROM_DATABASE=Hayes/16750
pci:v*d*sv*sd*bc07sc04*
ID_PCI_SUBCLASS_FROM_DATABASE=GPIB controller
pci:v*d*sv*sd*bc07sc05*
ID_PCI_SUBCLASS_FROM_DATABASE=Smard Card controller
pci:v*d*sv*sd*bc07sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Communication controller
pci:v*d*sv*sd*bc08*
ID_PCI_CLASS_FROM_DATABASE=Generic system peripheral
pci:v*d*sv*sd*bc08sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=PIC
pci:v*d*sv*sd*bc08sc00i00*
ID_PCI_INTERFACE_FROM_DATABASE=8259
pci:v*d*sv*sd*bc08sc00i01*
ID_PCI_INTERFACE_FROM_DATABASE=ISA PIC
pci:v*d*sv*sd*bc08sc00i02*
ID_PCI_INTERFACE_FROM_DATABASE=EISA PIC
pci:v*d*sv*sd*bc08sc00i10*
ID_PCI_INTERFACE_FROM_DATABASE=IO-APIC
pci:v*d*sv*sd*bc08sc00i20*
ID_PCI_INTERFACE_FROM_DATABASE=IO(X)-APIC
pci:v*d*sv*sd*bc08sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=DMA controller
pci:v*d*sv*sd*bc08sc01i00*
ID_PCI_INTERFACE_FROM_DATABASE=8237
pci:v*d*sv*sd*bc08sc01i01*
ID_PCI_INTERFACE_FROM_DATABASE=ISA DMA
pci:v*d*sv*sd*bc08sc01i02*
ID_PCI_INTERFACE_FROM_DATABASE=EISA DMA
pci:v*d*sv*sd*bc08sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=Timer
pci:v*d*sv*sd*bc08sc02i00*
ID_PCI_INTERFACE_FROM_DATABASE=8254
pci:v*d*sv*sd*bc08sc02i01*
ID_PCI_INTERFACE_FROM_DATABASE=ISA Timer
pci:v*d*sv*sd*bc08sc02i02*
ID_PCI_INTERFACE_FROM_DATABASE=EISA Timers
pci:v*d*sv*sd*bc08sc03*
ID_PCI_SUBCLASS_FROM_DATABASE=RTC
pci:v*d*sv*sd*bc08sc03i00*
ID_PCI_INTERFACE_FROM_DATABASE=Generic
pci:v*d*sv*sd*bc08sc03i01*
ID_PCI_INTERFACE_FROM_DATABASE=ISA RTC
pci:v*d*sv*sd*bc08sc04*
ID_PCI_SUBCLASS_FROM_DATABASE=PCI Hot-plug controller
pci:v*d*sv*sd*bc08sc05*
ID_PCI_SUBCLASS_FROM_DATABASE=SD Host controller
pci:v*d*sv*sd*bc08sc06*
ID_PCI_SUBCLASS_FROM_DATABASE=IOMMU
pci:v*d*sv*sd*bc08sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=System peripheral
pci:v*d*sv*sd*bc09*
ID_PCI_CLASS_FROM_DATABASE=Input device controller
pci:v*d*sv*sd*bc09sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Keyboard controller
pci:v*d*sv*sd*bc09sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=Digitizer Pen
pci:v*d*sv*sd*bc09sc02*
ID_PCI_SUBCLASS_FROM_DATABASE=Mouse controller
pci:v*d*sv*sd*bc09sc03*
ID_PCI_SUBCLASS_FROM_DATABASE=Scanner controller
pci:v*d*sv*sd*bc09sc04*
ID_PCI_SUBCLASS_FROM_DATABASE=Gameport controller
pci:v*d*sv*sd*bc09sc04i00*
ID_PCI_INTERFACE_FROM_DATABASE=Generic
pci:v*d*sv*sd*bc09sc04i10*
ID_PCI_INTERFACE_FROM_DATABASE=Extended
pci:v*d*sv*sd*bc09sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Input device controller
pci:v*d*sv*sd*bc0A*
ID_PCI_CLASS_FROM_DATABASE=Docking station
pci:v*d*sv*sd*bc0Asc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Generic Docking Station
pci:v*d*sv*sd*bc0Asc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Docking Station
pci:v*d*sv*sd*bc0B*
ID_PCI_CLASS_FROM_DATABASE=Processor
pci:v*d*sv*sd*bc0Bsc00*
ID_PCI_SUBCLASS_FROM_DATABASE=386
pci:v*d*sv*sd*bc0Bsc01*
ID_PCI_SUBCLASS_FROM_DATABASE=486
pci:v*d*sv*sd*bc0Bsc02*
ID_PCI_SUBCLASS_FROM_DATABASE=Pentium
pci:v*d*sv*sd*bc0Bsc10*
ID_PCI_SUBCLASS_FROM_DATABASE=Alpha
pci:v*d*sv*sd*bc0Bsc20*
ID_PCI_SUBCLASS_FROM_DATABASE=Power PC
pci:v*d*sv*sd*bc0Bsc30*
ID_PCI_SUBCLASS_FROM_DATABASE=MIPS
pci:v*d*sv*sd*bc0Bsc40*
ID_PCI_SUBCLASS_FROM_DATABASE=Co-processor
pci:v*d*sv*sd*bc0C*
ID_PCI_CLASS_FROM_DATABASE=Serial bus controller
pci:v*d*sv*sd*bc0Csc00*
ID_PCI_SUBCLASS_FROM_DATABASE=FireWire (IEEE 1394)
pci:v*d*sv*sd*bc0Csc00i00*
ID_PCI_INTERFACE_FROM_DATABASE=Generic
pci:v*d*sv*sd*bc0Csc00i10*
ID_PCI_INTERFACE_FROM_DATABASE=OHCI
pci:v*d*sv*sd*bc0Csc01*
ID_PCI_SUBCLASS_FROM_DATABASE=ACCESS Bus
pci:v*d*sv*sd*bc0Csc02*
ID_PCI_SUBCLASS_FROM_DATABASE=SSA
pci:v*d*sv*sd*bc0Csc03*
ID_PCI_SUBCLASS_FROM_DATABASE=USB controller
pci:v*d*sv*sd*bc0Csc03i00*
ID_PCI_INTERFACE_FROM_DATABASE=UHCI
pci:v*d*sv*sd*bc0Csc03i10*
ID_PCI_INTERFACE_FROM_DATABASE=OHCI
pci:v*d*sv*sd*bc0Csc03i20*
ID_PCI_INTERFACE_FROM_DATABASE=EHCI
pci:v*d*sv*sd*bc0Csc03i30*
ID_PCI_INTERFACE_FROM_DATABASE=XHCI
pci:v*d*sv*sd*bc0Csc03i80*
ID_PCI_INTERFACE_FROM_DATABASE=Unspecified
pci:v*d*sv*sd*bc0Csc03iFE*
ID_PCI_INTERFACE_FROM_DATABASE=USB Device
pci:v*d*sv*sd*bc0Csc04*
ID_PCI_SUBCLASS_FROM_DATABASE=Fibre Channel
pci:v*d*sv*sd*bc0Csc05*
ID_PCI_SUBCLASS_FROM_DATABASE=SMBus
pci:v*d*sv*sd*bc0Csc06*
ID_PCI_SUBCLASS_FROM_DATABASE=InfiniBand
pci:v*d*sv*sd*bc0Csc07*
ID_PCI_SUBCLASS_FROM_DATABASE=IPMI SMIC interface
pci:v*d*sv*sd*bc0Csc08*
ID_PCI_SUBCLASS_FROM_DATABASE=SERCOS interface
pci:v*d*sv*sd*bc0Csc09*
ID_PCI_SUBCLASS_FROM_DATABASE=CANBUS
pci:v*d*sv*sd*bc0D*
ID_PCI_CLASS_FROM_DATABASE=Wireless controller
pci:v*d*sv*sd*bc0Dsc00*
ID_PCI_SUBCLASS_FROM_DATABASE=IRDA controller
pci:v*d*sv*sd*bc0Dsc01*
ID_PCI_SUBCLASS_FROM_DATABASE=Consumer IR controller
pci:v*d*sv*sd*bc0Dsc10*
ID_PCI_SUBCLASS_FROM_DATABASE=RF controller
pci:v*d*sv*sd*bc0Dsc11*
ID_PCI_SUBCLASS_FROM_DATABASE=Bluetooth
pci:v*d*sv*sd*bc0Dsc12*
ID_PCI_SUBCLASS_FROM_DATABASE=Broadband
pci:v*d*sv*sd*bc0Dsc20*
ID_PCI_SUBCLASS_FROM_DATABASE=802.1a controller
pci:v*d*sv*sd*bc0Dsc21*
ID_PCI_SUBCLASS_FROM_DATABASE=802.1b controller
pci:v*d*sv*sd*bc0Dsc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Wireless controller
pci:v*d*sv*sd*bc0E*
ID_PCI_CLASS_FROM_DATABASE=Intelligent controller
pci:v*d*sv*sd*bc0Esc00*
ID_PCI_SUBCLASS_FROM_DATABASE=I2O
pci:v*d*sv*sd*bc0F*
ID_PCI_CLASS_FROM_DATABASE=Satellite communications controller
pci:v*d*sv*sd*bc0Fsc01*
ID_PCI_SUBCLASS_FROM_DATABASE=Satellite TV controller
pci:v*d*sv*sd*bc0Fsc02*
ID_PCI_SUBCLASS_FROM_DATABASE=Satellite audio communication controller
pci:v*d*sv*sd*bc0Fsc03*
ID_PCI_SUBCLASS_FROM_DATABASE=Satellite voice communication controller
pci:v*d*sv*sd*bc0Fsc04*
ID_PCI_SUBCLASS_FROM_DATABASE=Satellite data communication controller
pci:v*d*sv*sd*bc10*
ID_PCI_CLASS_FROM_DATABASE=Encryption controller
pci:v*d*sv*sd*bc10sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=Network and computing encryption device
pci:v*d*sv*sd*bc10sc10*
ID_PCI_SUBCLASS_FROM_DATABASE=Entertainment encryption device
pci:v*d*sv*sd*bc10sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Encryption controller
pci:v*d*sv*sd*bc11*
ID_PCI_CLASS_FROM_DATABASE=Signal processing controller
pci:v*d*sv*sd*bc11sc00*
ID_PCI_SUBCLASS_FROM_DATABASE=DPIO module
pci:v*d*sv*sd*bc11sc01*
ID_PCI_SUBCLASS_FROM_DATABASE=Performance counters
pci:v*d*sv*sd*bc11sc10*
ID_PCI_SUBCLASS_FROM_DATABASE=Communication synchronizer
pci:v*d*sv*sd*bc11sc20*
ID_PCI_SUBCLASS_FROM_DATABASE=Signal processing management
pci:v*d*sv*sd*bc11sc80*
ID_PCI_SUBCLASS_FROM_DATABASE=Signal processing controller
pci:v*d*sv*sd*bcFF*
ID_PCI_CLASS_FROM_DATABASE=Unassigned class

File diff suppressed because it is too large Load Diff

339
hwdb/20-usb-classes.hwdb Normal file
View File

@ -0,0 +1,339 @@
# This file is part of systemd.
#
# Data imported and updated from: http://www.linux-usb.org/usb.ids
usb:v*p*d*dc01*
ID_USB_CLASS_FROM_DATABASE=Audio
usb:v*p*d*dc01dsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Control Device
usb:v*p*d*dc01dsc02*
ID_USB_SUBCLASS_FROM_DATABASE=Streaming
usb:v*p*d*dc01dsc03*
ID_USB_SUBCLASS_FROM_DATABASE=MIDI Streaming
usb:v*p*d*dc02*
ID_USB_CLASS_FROM_DATABASE=Communications
usb:v*p*d*dc02dsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Direct Line
usb:v*p*d*dc02dsc02*
ID_USB_SUBCLASS_FROM_DATABASE=Abstract (modem)
usb:v*p*d*dc02dsc02dp01*
ID_USB_PROTOCOL_FROM_DATABASE=AT-commands (v.25ter)
usb:v*p*d*dc02dsc02dp02*
ID_USB_PROTOCOL_FROM_DATABASE=AT-commands (PCCA101)
usb:v*p*d*dc02dsc02dp03*
ID_USB_PROTOCOL_FROM_DATABASE=AT-commands (PCCA101 + wakeup)
usb:v*p*d*dc02dsc02dp04*
ID_USB_PROTOCOL_FROM_DATABASE=AT-commands (GSM)
usb:v*p*d*dc02dsc02dp05*
ID_USB_PROTOCOL_FROM_DATABASE=AT-commands (3G)
usb:v*p*d*dc02dsc02dp06*
ID_USB_PROTOCOL_FROM_DATABASE=AT-commands (CDMA)
usb:v*p*d*dc02dsc02dpFE*
ID_USB_PROTOCOL_FROM_DATABASE=Defined by command set descriptor
usb:v*p*d*dc02dsc02dpFF*
ID_USB_PROTOCOL_FROM_DATABASE=Vendor Specific (MSFT RNDIS?)
usb:v*p*d*dc02dsc03*
ID_USB_SUBCLASS_FROM_DATABASE=Telephone
usb:v*p*d*dc02dsc04*
ID_USB_SUBCLASS_FROM_DATABASE=Multi-Channel
usb:v*p*d*dc02dsc05*
ID_USB_SUBCLASS_FROM_DATABASE=CAPI Control
usb:v*p*d*dc02dsc06*
ID_USB_SUBCLASS_FROM_DATABASE=Ethernet Networking
usb:v*p*d*dc02dsc07*
ID_USB_SUBCLASS_FROM_DATABASE=ATM Networking
usb:v*p*d*dc02dsc08*
ID_USB_SUBCLASS_FROM_DATABASE=Wireless Handset Control
usb:v*p*d*dc02dsc09*
ID_USB_SUBCLASS_FROM_DATABASE=Device Management
usb:v*p*d*dc02dsc0A*
ID_USB_SUBCLASS_FROM_DATABASE=Mobile Direct Line
usb:v*p*d*dc02dsc0B*
ID_USB_SUBCLASS_FROM_DATABASE=OBEX
usb:v*p*d*dc02dsc0C*
ID_USB_SUBCLASS_FROM_DATABASE=Ethernet Emulation
usb:v*p*d*dc02dsc0Cdp07*
ID_USB_PROTOCOL_FROM_DATABASE=Ethernet Emulation (EEM)
usb:v*p*d*dc03*
ID_USB_CLASS_FROM_DATABASE=Human Interface Device
usb:v*p*d*dc03dsc00dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Keyboard
usb:v*p*d*dc03dsc00dp02*
ID_USB_PROTOCOL_FROM_DATABASE=Mouse
usb:v*p*d*dc03dsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Boot Interface Subclass
usb:v*p*d*dc03dsc01dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Keyboard
usb:v*p*d*dc03dsc01dp02*
ID_USB_PROTOCOL_FROM_DATABASE=Mouse
usb:v*p*d*dc05*
ID_USB_CLASS_FROM_DATABASE=Physical Interface Device
usb:v*p*d*dc06*
ID_USB_CLASS_FROM_DATABASE=Imaging
usb:v*p*d*dc06dsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Still Image Capture
usb:v*p*d*dc06dsc01dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Picture Transfer Protocol (PIMA 15470)
usb:v*p*d*dc07*
ID_USB_CLASS_FROM_DATABASE=Printer
usb:v*p*d*dc07dsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Printer
usb:v*p*d*dc07dsc01dp00*
ID_USB_PROTOCOL_FROM_DATABASE=Reserved/Undefined
usb:v*p*d*dc07dsc01dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Unidirectional
usb:v*p*d*dc07dsc01dp02*
ID_USB_PROTOCOL_FROM_DATABASE=Bidirectional
usb:v*p*d*dc07dsc01dp03*
ID_USB_PROTOCOL_FROM_DATABASE=IEEE 1284.4 compatible bidirectional
usb:v*p*d*dc07dsc01dpFF*
ID_USB_PROTOCOL_FROM_DATABASE=Vendor Specific
usb:v*p*d*dc08*
ID_USB_CLASS_FROM_DATABASE=Mass Storage
usb:v*p*d*dc08dsc01*
ID_USB_SUBCLASS_FROM_DATABASE=RBC (typically Flash)
usb:v*p*d*dc08dsc01dp00*
ID_USB_PROTOCOL_FROM_DATABASE=Control/Bulk/Interrupt
usb:v*p*d*dc08dsc01dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Control/Bulk
usb:v*p*d*dc08dsc01dp50*
ID_USB_PROTOCOL_FROM_DATABASE=Bulk-Only
usb:v*p*d*dc08dsc02*
ID_USB_SUBCLASS_FROM_DATABASE=SFF-8020i, MMC-2 (ATAPI)
usb:v*p*d*dc08dsc03*
ID_USB_SUBCLASS_FROM_DATABASE=QIC-157
usb:v*p*d*dc08dsc04*
ID_USB_SUBCLASS_FROM_DATABASE=Floppy (UFI)
usb:v*p*d*dc08dsc04dp00*
ID_USB_PROTOCOL_FROM_DATABASE=Control/Bulk/Interrupt
usb:v*p*d*dc08dsc04dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Control/Bulk
usb:v*p*d*dc08dsc04dp50*
ID_USB_PROTOCOL_FROM_DATABASE=Bulk-Only
usb:v*p*d*dc08dsc05*
ID_USB_SUBCLASS_FROM_DATABASE=SFF-8070i
usb:v*p*d*dc08dsc06*
ID_USB_SUBCLASS_FROM_DATABASE=SCSI
usb:v*p*d*dc08dsc06dp00*
ID_USB_PROTOCOL_FROM_DATABASE=Control/Bulk/Interrupt
usb:v*p*d*dc08dsc06dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Control/Bulk
usb:v*p*d*dc08dsc06dp50*
ID_USB_PROTOCOL_FROM_DATABASE=Bulk-Only
usb:v*p*d*dc09*
ID_USB_CLASS_FROM_DATABASE=Hub
usb:v*p*d*dc09dsc00dp00*
ID_USB_PROTOCOL_FROM_DATABASE=Full speed (or root) hub
usb:v*p*d*dc09dsc00dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Single TT
usb:v*p*d*dc09dsc00dp02*
ID_USB_PROTOCOL_FROM_DATABASE=TT per port
usb:v*p*d*dc0A*
ID_USB_CLASS_FROM_DATABASE=CDC Data
usb:v*p*d*dc0Adsc00dp30*
ID_USB_PROTOCOL_FROM_DATABASE=I.430 ISDN BRI
usb:v*p*d*dc0Adsc00dp31*
ID_USB_PROTOCOL_FROM_DATABASE=HDLC
usb:v*p*d*dc0Adsc00dp32*
ID_USB_PROTOCOL_FROM_DATABASE=Transparent
usb:v*p*d*dc0Adsc00dp50*
ID_USB_PROTOCOL_FROM_DATABASE=Q.921M
usb:v*p*d*dc0Adsc00dp51*
ID_USB_PROTOCOL_FROM_DATABASE=Q.921
usb:v*p*d*dc0Adsc00dp52*
ID_USB_PROTOCOL_FROM_DATABASE=Q.921TM
usb:v*p*d*dc0Adsc00dp90*
ID_USB_PROTOCOL_FROM_DATABASE=V.42bis
usb:v*p*d*dc0Adsc00dp91*
ID_USB_PROTOCOL_FROM_DATABASE=Q.932 EuroISDN
usb:v*p*d*dc0Adsc00dp92*
ID_USB_PROTOCOL_FROM_DATABASE=V.120 V.24 rate ISDN
usb:v*p*d*dc0Adsc00dp93*
ID_USB_PROTOCOL_FROM_DATABASE=CAPI 2.0
usb:v*p*d*dc0Adsc00dpFD*
ID_USB_PROTOCOL_FROM_DATABASE=Host Based Driver
usb:v*p*d*dc0Adsc00dpFE*
ID_USB_PROTOCOL_FROM_DATABASE=CDC PUF
usb:v*p*d*dc0Adsc00dpFF*
ID_USB_PROTOCOL_FROM_DATABASE=Vendor specific
usb:v*p*d*dc0B*
ID_USB_CLASS_FROM_DATABASE=Chip/SmartCard
usb:v*p*d*dc0D*
ID_USB_CLASS_FROM_DATABASE=Content Security
usb:v*p*d*dc0E*
ID_USB_CLASS_FROM_DATABASE=Video
usb:v*p*d*dc0Edsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Video Control
usb:v*p*d*dc0Edsc02*
ID_USB_SUBCLASS_FROM_DATABASE=Video Streaming
usb:v*p*d*dc0Edsc03*
ID_USB_SUBCLASS_FROM_DATABASE=Video Interface Collection
usb:v*p*d*dc58*
ID_USB_CLASS_FROM_DATABASE=Xbox
usb:v*p*d*dc58dsc42*
ID_USB_SUBCLASS_FROM_DATABASE=Controller
usb:v*p*d*dcDC*
ID_USB_CLASS_FROM_DATABASE=Diagnostic
usb:v*p*d*dcDCdsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Reprogrammable Diagnostics
usb:v*p*d*dcDCdsc01dp01*
ID_USB_PROTOCOL_FROM_DATABASE=USB2 Compliance
usb:v*p*d*dcE0*
ID_USB_CLASS_FROM_DATABASE=Wireless
usb:v*p*d*dcE0dsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Radio Frequency
usb:v*p*d*dcE0dsc01dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Bluetooth
usb:v*p*d*dcE0dsc01dp02*
ID_USB_PROTOCOL_FROM_DATABASE=Ultra WideBand Radio Control
usb:v*p*d*dcE0dsc01dp03*
ID_USB_PROTOCOL_FROM_DATABASE=RNDIS
usb:v*p*d*dcE0dsc02*
ID_USB_SUBCLASS_FROM_DATABASE=Wireless USB Wire Adapter
usb:v*p*d*dcE0dsc02dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Host Wire Adapter Control/Data Streaming
usb:v*p*d*dcE0dsc02dp02*
ID_USB_PROTOCOL_FROM_DATABASE=Device Wire Adapter Control/Data Streaming
usb:v*p*d*dcE0dsc02dp03*
ID_USB_PROTOCOL_FROM_DATABASE=Device Wire Adapter Isochronous Streaming
usb:v*p*d*dcEF*
ID_USB_CLASS_FROM_DATABASE=Miscellaneous Device
usb:v*p*d*dcEFdsc01dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Microsoft ActiveSync
usb:v*p*d*dcEFdsc01dp02*
ID_USB_PROTOCOL_FROM_DATABASE=Palm Sync
usb:v*p*d*dcEFdsc02dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Interface Association
usb:v*p*d*dcEFdsc02dp02*
ID_USB_PROTOCOL_FROM_DATABASE=Wire Adapter Multifunction Peripheral
usb:v*p*d*dcEFdsc03dp01*
ID_USB_PROTOCOL_FROM_DATABASE=Cable Based Association
usb:v*p*d*dcFE*
ID_USB_CLASS_FROM_DATABASE=Application Specific Interface
usb:v*p*d*dcFEdsc01*
ID_USB_SUBCLASS_FROM_DATABASE=Device Firmware Update
usb:v*p*d*dcFEdsc02*
ID_USB_SUBCLASS_FROM_DATABASE=IRDA Bridge
usb:v*p*d*dcFEdsc03*
ID_USB_SUBCLASS_FROM_DATABASE=Test and Measurement
usb:v*p*d*dcFEdsc03dp01*
ID_USB_PROTOCOL_FROM_DATABASE=TMC
usb:v*p*d*dcFEdsc03dp02*
ID_USB_PROTOCOL_FROM_DATABASE=USB488
usb:v*p*d*dcFF*
ID_USB_CLASS_FROM_DATABASE=Vendor Specific Class
usb:v*p*d*dcFFdscFF*
ID_USB_SUBCLASS_FROM_DATABASE=Vendor Specific Subclass
usb:v*p*d*dcFFdscFFdpFF*
ID_USB_PROTOCOL_FROM_DATABASE=Vendor Specific Protocol

File diff suppressed because it is too large Load Diff

239
hwdb/ids-update.pl Executable file
View File

@ -0,0 +1,239 @@
#!/usr/bin/perl
use strict;
use warnings;
sub usb_vendor {
my $vendor;
open(IN, "<", "usb.ids");
open(OUT, ">", "20-usb-vendor-product.hwdb");
print(OUT "# This file is part of systemd.\n" .
"#\n" .
"# Data imported and updated from: http://www.linux-usb.org/usb.ids\n");
while (my $line = <IN>) {
$line =~ s/\s+$//;
$line =~ m/^([0-9a-f]{4})\s*(.*)$/;
if (defined $1) {
$vendor = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "usb:v" . $vendor . "*\n");
print(OUT " ID_VENDOR_FROM_DATABASE=" . $text . "\n");
next;
}
$line =~ m/^\t([0-9a-f]{4})\s*(.*)$/;
if (defined $1) {
my $product = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "usb:v" . $vendor . "p" . $product . "*\n");
print(OUT " ID_PRODUCT_FROM_DATABASE=" . $text . "\n");
}
}
close(INP);
close(OUTP);
}
sub usb_classes {
my $class;
my $subclass;
my $protocol;
open(IN, "<", "usb.ids");
open(OUT, ">", "20-usb-classes.hwdb");
print(OUT "# This file is part of systemd.\n" .
"#\n" .
"# Data imported and updated from: http://www.linux-usb.org/usb.ids\n");
while (my $line = <IN>) {
$line =~ s/\s+$//;
$line =~ m/^C\ ([0-9a-f]{2})\s*(.*)$/;
if (defined $1) {
$class = uc $1;
if ($class =~ m/^00$/) {
next;
}
my $text = $2;
print(OUT "\n");
print(OUT "usb:v*p*d*dc" . $class . "*\n");
print(OUT " ID_USB_CLASS_FROM_DATABASE=" . $text . "\n");
next;
}
if (not defined $class) {
next;
} elsif ($line =~ m/^$/) {
last;
}
$line =~ m/^\t([0-9a-f]{2})\s*(.*)$/;
if (defined $1) {
$subclass = uc $1;
if ($subclass =~ m/^00$/) {
next;
}
my $text = $2;
if ($text =~ m/^(\?|None|Unused)$/) {
next;
}
print(OUT "\n");
print(OUT "usb:v*p*d*dc" . $class . "dsc" . $subclass . "*\n");
print(OUT " ID_USB_SUBCLASS_FROM_DATABASE=" . $text . "\n");
next;
}
$line =~ m/^\t\t([0-9a-f]{2})\s*(.*)$/;
if (defined $1) {
$protocol = uc $1;
my $text = $2;
if ($text =~ m/^(\?|None|Unused)$/) {
next;
}
print(OUT "\n");
print(OUT "usb:v*p*d*dc" . $class . "dsc" . $subclass . "dp" . $protocol . "*\n");
print(OUT " ID_USB_PROTOCOL_FROM_DATABASE=" . $text . "\n");
}
}
close(INP);
close(OUTP);
}
sub pci_vendor {
my $vendor;
my $device;
open(IN, "<", "usb.ids");
open(IN, "<", "pci.ids");
open(OUT, ">", "20-pci-vendor-product.hwdb");
print(OUT "# This file is part of systemd.\n" .
"#\n" .
"# Data imported and updated from: http://pci-ids.ucw.cz/v2.2/pci.ids\n");
while (my $line = <IN>) {
$line =~ s/\s+$//;
$line =~ m/^([0-9a-f]{4})\s*(.*)$/;
if (defined $1) {
$vendor = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "pci:v0000" . $vendor . "*\n");
print(OUT " ID_VENDOR_FROM_DATABASE=" . $text . "\n");
next;
}
$line =~ m/^\t([0-9a-f]{4})\s*(.*)$/;
if (defined $1) {
$device = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "pci:v0000" . $vendor . "d0000" . $device . "*\n");
print(OUT " ID_PRODUCT_FROM_DATABASE=" . $text . "\n");
next;
}
$line =~ m/^\t\t([0-9a-f]{4})\s*([0-9a-f]{4})\s*(.*)$/;
if (defined $1) {
my $sub_vendor = uc $1;
my $sub_device = uc $2;
my $text = $3;
print(OUT "\n");
print(OUT "pci:v0000" . $vendor . "d0000" . $device . "sv0000" . $sub_vendor . "sd0000" . $sub_device . "*\n");
print(OUT " ID_PRODUCT_FROM_DATABASE=" . $text . "\n");
}
}
close(INP);
close(OUTP);
}
sub pci_classes {
my $class;
my $subclass;
my $interface;
open(IN, "<", "pci.ids");
open(OUT, ">", "20-pci-classes.hwdb");
print(OUT "# This file is part of systemd.\n" .
"#\n" .
"# Data imported and updated from: http://pci-ids.ucw.cz/v2.2/pci.ids\n");
while (my $line = <IN>) {
$line =~ s/\s+$//;
$line =~ m/^C\ ([0-9a-f]{2})\s*(.*)$/;
if (defined $1) {
$class = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "pci:v*d*sv*sd*bc" . $class . "*\n");
print(OUT " ID_PCI_CLASS_FROM_DATABASE=" . $text . "\n");
next;
}
if (not defined $class) {
next;
} elsif ($line =~ m/^$/) {
last;
}
$line =~ m/^\t([0-9a-f]{2})\s*(.*)$/;
if (defined $1) {
$subclass = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "pci:v*d*sv*sd*bc" . $class . "sc" . $subclass . "*\n");
print(OUT " ID_PCI_SUBCLASS_FROM_DATABASE=" . $text . "\n");
next;
}
$line =~ m/^\t\t([0-9a-f]{2})\s*(.*)$/;
if (defined $1) {
$interface = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "pci:v*d*sv*sd*bc" . $class . "sc" . $subclass . "i" . $interface . "*\n");
print(OUT " ID_PCI_INTERFACE_FROM_DATABASE=" . $text . "\n");
}
}
close(INP);
close(OUTP);
}
sub oui {
open(IN, "<", "oui.txt");
open(OUT, ">", "20-OUI.hwdb");
print(OUT "# This file is part of systemd.\n" .
"#\n" .
"# Data imported and updated from: http://standards.ieee.org/develop/regauth/oui/oui.txt\n");
while (my $line = <IN>) {
$line =~ s/\s+$//;
$line =~ m/^([0-9A-F]{6})\s*\(base 16\)\s*(.*)$/;
if (defined $1) {
my $vendor = uc $1;
my $text = $2;
print(OUT "\n");
print(OUT "OUI:" . $vendor . "\n");
print(OUT " ID_OUI_FROM_DATABASE=" . $text . "\n");
}
}
close(INP);
close(OUTP);
}
usb_vendor();
usb_classes();
pci_vendor();
pci_classes();
oui();

13
introspect.awk Normal file
View File

@ -0,0 +1,13 @@
BEGIN {
print "<!DOCTYPE node PUBLIC DBUS_INTROSPECT_1_0_XML_PUBLIC_IDENTIFIER"
print "DBUS_INTROSPECT_1_0_XML_SYSTEM_IDENTIFIER>"
print "<node>"
}
// {
print
}
END {
print "</node>"
}

View File

@ -0,0 +1,3 @@
0xa0 #mute
0xae #volume down
0xb0 #volume up

View File

@ -0,0 +1 @@
0x9E

View File

@ -0,0 +1 @@
0x8C

View File

@ -0,0 +1,3 @@
# list of scancodes (hex or decimal), optional comment
0xd8 # Touchpad off
0xd9 # Touchpad on

View File

@ -0,0 +1,6 @@
# list of scancodes (hex or decimal), optional comment
0xCE # Fn+F8 keyboard backlit up
0x8D # Fn+F7 keyboard backlit down
0x97 # Fn+F12 wifi on/off
0x96 # Fn+F1 performance mode (?)
0xD5 # Fn+F6 battery life extender

View File

@ -0,0 +1,10 @@
# list of scancodes (hex or decimal), optional comment
0x82 # Fn+F4 CRT/LCD
0x83 # Fn+F2 battery
0x84 # Fn+F5 backlight on/off
0x86 # Fn+F9 WLAN
0x88 # Fn-Up brightness up
0x89 # Fn-Down brightness down
0xB3 # Fn+F8 switch power mode (battery/dynamic/performance)
0xF7 # Fn+F10 Touchpad on
0xF9 # Fn+F10 Touchpad off

22
keymaps/acer Normal file
View File

@ -0,0 +1,22 @@
0xA5 help # Fn+F1
0xA6 setup # Fn+F2 Acer eSettings
0xA7 battery # Fn+F3 Power Management
0xA9 switchvideomode # Fn+F5
0xB3 euro
0xB4 dollar
0xCE brightnessup # Fn+Right
0xD4 bluetooth # (toggle) off-to-on
0xD5 wlan # (toggle) on-to-off
0xD6 wlan # (toggle) off-to-on
0xD7 bluetooth # (toggle) on-to-off
0xD8 bluetooth # (toggle) off-to-on
0xD9 brightnessup # Fn+Right
0xEE brightnessup # Fn+Right
0xEF brightnessdown # Fn+Left
0xF1 f22 # Fn+F7 Touchpad toggle (off-to-on)
0xF2 f23 # Fn+F7 Touchpad toggle (on-to-off)
0xF3 prog2 # "P2" programmable button
0xF4 prog1 # "P1" programmable button
0xF5 presentation
0xF8 fn
0xF9 f23 # Launch NTI shadow

5
keymaps/acer-aspire_5720 Normal file
View File

@ -0,0 +1,5 @@
0x84 bluetooth # sent when bluetooth module missing, and key pressed
0x92 media # acer arcade
0xD4 bluetooth # bluetooth on
0xD9 bluetooth # bluetooth off
0xF4 prog3 # e-key

View File

@ -0,0 +1,5 @@
0x8A media
0x92 media
0xA6 setup
0xB2 www
0xD9 bluetooth # (toggle) on-to-off

5
keymaps/acer-aspire_6920 Normal file
View File

@ -0,0 +1,5 @@
0xD9 bluetooth # (toggle) on-to-off
0x92 media
0x9E back
0x83 rewind
0x89 fastforward

5
keymaps/acer-aspire_8930 Normal file
View File

@ -0,0 +1,5 @@
0xCA prog3 # key 'HOLD' on cine dash media console
0x83 rewind
0x89 fastforward
0x92 media # key 'ARCADE' on cine dash media console
0x9E back

View File

@ -0,0 +1,5 @@
0x67 f24 # FIXME: rotate screen
0x68 up
0x69 down
0x6B fn
0x6C screenlock # FIXME: lock tablet device/buttons

3
keymaps/asus Normal file
View File

@ -0,0 +1,3 @@
0xED volumeup
0xEE volumedown
0xEF mute

4
keymaps/compaq-e_evo Normal file
View File

@ -0,0 +1,4 @@
0xA3 www # I key
0x9A search
0x9E email
0x9F homepage

29
keymaps/dell Normal file
View File

@ -0,0 +1,29 @@
0x81 playpause # Play/Pause
0x82 stopcd # Stop
0x83 previoussong # Previous song
0x84 nextsong # Next song
0x85 brightnessdown # Fn+Down arrow Brightness Down
0x86 brightnessup # Fn+Up arrow Brightness Up
0x87 battery # Fn+F3 battery icon
0x88 unknown # Fn+F2 Turn On/Off Wireless - handled in hardware
0x89 ejectclosecd # Fn+F10 Eject CD
0x8A suspend # Fn+F1 hibernate
0x8B switchvideomode # Fn+F8 CRT/LCD (high keycode: "displaytoggle")
0x8C f23 # Fn+Right arrow Auto Brightness
0x8F switchvideomode # Fn+F7 aspect ratio
0x90 previoussong # Front panel previous song
0x91 prog1 # Wifi Catcher (DELL Specific)
0x92 media # MediaDirect button (house icon)
0x93 f23 # FIXME Fn+Left arrow Auto Brightness
0x95 camera # Shutter button Takes a picture if optional camera available
0x97 email # Tablet email button
0x98 f21 # FIXME: Tablet screen rotatation
0x99 nextsong # Front panel next song
0x9A setup # Tablet tools button
0x9B switchvideomode # Display Toggle button
0x9E f21 #touchpad toggle
0xA2 playpause # Front panel play/pause
0xA4 stopcd # Front panel stop
0xED media # MediaDirect button
0xD8 screenlock # FIXME: Tablet lock button
0xD9 f21 # touchpad toggle

View File

@ -0,0 +1,4 @@
0x9B up # tablet rocker up
0x9E enter # tablet rocker press
0x9F back # tablet back
0xA3 down # tablet rocker down

7
keymaps/everex-xt5000 Normal file
View File

@ -0,0 +1,7 @@
0x5C media
0x65 f21 # Fn+F5 Touchpad toggle
0x67 prog3 # Fan Speed Control button
0x6F brightnessup
0x7F brightnessdown
0xB2 www
0xEC mail

View File

@ -0,0 +1,3 @@
0xD9 brightnessdown # Fn+F8 brightness down
0xEF brightnessup # Fn+F9 brightness up
0xA9 switchvideomode # Fn+F10 Cycle between available video outputs

View File

@ -0,0 +1,3 @@
0xE0 volumedown
0xE1 volumeup
0xE5 prog1

View File

@ -0,0 +1,4 @@
0xA5 help # Fn-F1
0xA9 switchvideomode # Fn-F3
0xD9 brightnessdown # Fn-F8
0xE0 brightnessup # Fn-F9

View File

@ -0,0 +1,2 @@
0xF4 f21 # FIXME: silent-mode decrease CPU/GPU clock
0xF7 switchvideomode # Fn+F3

View File

@ -0,0 +1,6 @@
0xE1 wlan
0xF3 wlan
0xEE brightnessdown
0xE0 brightnessup
0xE2 bluetooth
0xF7 video

View File

@ -0,0 +1,4 @@
0xA9 switchvideomode
0xD9 brightnessdown
0xDF sleep
0xEF brightnessup

View File

@ -0,0 +1,2 @@
0xCE brightnessup
0xEF brightnessdown

View File

@ -0,0 +1,35 @@
# Genius SlimStar 320
#
# Only buttons which are not properly mapped yet are configured below
# "Scroll wheel", a circular up/down/left/right button. Aimed for scolling,
# but since there are no scrollleft/scrollright, let's map to back/forward.
0x900f0 scrollup
0x900f1 scrolldown
0x900f3 back
0x900f2 forward
# Multimedia buttons, left side (from left to right)
# [W]
0x900f5 wordprocessor
# [Ex]
0x900f6 spreadsheet
# [P]
0x900f4 presentation
# Other five (calculator, playpause, stop, mute and eject) are OK
# Right side, from left to right
# [e]
0xc0223 www
# "man"
0x900f7 chat
# "Y"
0x900fb prog1
# [X]
0x900f8 close
# "picture"
0x900f9 graphicseditor
# "two windows"
0x900fd scale
# "lock"
0x900fc screenlock

12
keymaps/hewlett-packard Normal file
View File

@ -0,0 +1,12 @@
0x81 fn_esc
0x89 battery # FnF8
0x8A screenlock # FnF6
0x8B camera
0x8C media # music
0x8E dvd
0xB1 help
0xB3 f23 # FIXME: Auto brightness
0xD7 wlan
0x92 brightnessdown # FnF7 (FnF9 on 6730b)
0x97 brightnessup # FnF8 (FnF10 on 6730b)
0xEE switchvideomode # FnF4

View File

@ -0,0 +1,2 @@
0xD8 f23 # touchpad off
0xD9 f22 # touchpad on

View File

@ -0,0 +1,2 @@
0x88 presentation
0xD9 help # I key (high keycode: "info")

View File

@ -0,0 +1,3 @@
0x88 media # FIXME: quick play
0xD8 f23 # touchpad off
0xD9 f22 # touchpad on

View File

@ -0,0 +1,3 @@
0xF0 help
0xF1 screenlock
0xF3 search

View File

@ -0,0 +1,6 @@
0x82 prog2 # Funny Key
0x83 prog1 # Q
0x84 tab
0x85 esc
0x86 pageup
0x87 pagedown

View File

@ -0,0 +1,3 @@
0xC2 media
0xD8 f23 # Toggle touchpad button on tx2 (OFF)
0xD9 f22 # Toggle touchpad button on tx2 (ON)

View File

@ -0,0 +1,5 @@
0x88 www
0xA0 mute
0xAE volumedown
0xB0 volumeup
0xEC mail

View File

@ -0,0 +1,7 @@
0x900f0 screenlock
0x900f1 wlan
0x900f2 switchvideomode
0x900f3 suspend
0x900f4 brightnessup
0x900f5 brightnessdown
0x900f8 zoom

View File

@ -0,0 +1,2 @@
0xF3 prog2
0xF4 prog1

5
keymaps/lenovo-3000 Normal file
View File

@ -0,0 +1,5 @@
0x8B switchvideomode # Fn+F7 video
0x96 wlan # Fn+F5 wireless
0x97 sleep # Fn+F4 suspend
0x98 suspend # Fn+F12 hibernate
0xB4 prog1 # Lenovo Care

8
keymaps/lenovo-ideapad Normal file
View File

@ -0,0 +1,8 @@
# Key codes observed on S10-3, assumed valid on other IdeaPad models
0x81 rfkill # does nothing in BIOS
0x83 display_off # BIOS toggles screen state
0xB9 brightnessup # does nothing in BIOS
0xBA brightnessdown # does nothing in BIOS
0xF1 camera # BIOS toggles camera power
0xf2 f21 # touchpad toggle (key alternately emits f2 and f3)
0xf3 f21

View File

@ -0,0 +1,13 @@
0x90012 screenlock # Fn+F2
0x90013 battery # Fn+F3
0x90014 wlan # Fn+F5
0x90016 switchvideomode # Fn+F7
0x90017 f21 # Fn+F8 touchpadtoggle
0x90019 suspend # Fn+F12
0x9001A brightnessup # Fn+Home
0x9001B brightnessdown # Fn+End
0x9001D zoom # Fn+Space
0x90011 prog1 # Thinkvantage button
0x90015 camera # Fn+F6 headset/camera VoIP key ??
0x90010 micmute # Microphone mute button

View File

@ -0,0 +1,6 @@
0x5D menu
0x63 fn
0x66 screenlock
0x67 cyclewindows # bezel circular arrow
0x68 setup # bezel setup / menu
0x6c direction # rotate screen

View File

@ -0,0 +1,8 @@
0x6C f21 # rotate
0x68 screenlock # screenlock
0x6B esc # escape
0x6D right # right on d-pad
0x6E left # left on d-pad
0x71 up # up on d-pad
0x6F down # down on d-pad
0x69 enter # enter on d-pad

12
keymaps/lg-x110 Normal file
View File

@ -0,0 +1,12 @@
0xA0 mute # Fn-F9
0xAE volumedown # Fn-Left
0xAF search # Fn-F3
0xB0 volumeup # Fn-Right
0xB1 battery # Fn-F10 Info
0xB3 suspend # Fn-F12
0xDF sleep # Fn-F4
# 0xE2 bluetooth # satellite dish2
0xE4 f21 # Fn-F5 Touchpad disable
0xF6 wlan # Fn-F6
0xF7 reserved # brightnessdown # Fn-Down
0xF8 reserved # brightnessup # Fn-Up

16
keymaps/logitech-wave Normal file
View File

@ -0,0 +1,16 @@
0x9001C scale #expo
0x9001F zoomout #zoom out
0x90020 zoomin #zoom in
0x9003D prog1 #gadget
0x90005 camera #camera
0x90018 media #media center
0x90041 wordprocessor #fn+f1 (word)
0x90042 spreadsheet #fn+f2 (excel)
0x90043 calendar #fn+f3 (calendar)
0x90044 prog2 #fn+f4 (program a)
0x90045 prog3 #fn+f5 (program b)
0x90046 prog4 #fn+f6 (program c)
0x90048 messenger #fn+f8 (msn messenger)
0x9002D find #fn+f10 (search www)
0x9004B search #fn+f11 (search pc)
0x9004C ejectclosecd #fn+f12 (eject)

View File

@ -0,0 +1,15 @@
0xD4 zoomin
0xCC zoomout
0xC0183 media
0xC1005 camera
0xC101F zoomout
0xC1020 zoomin
0xC1041 wordprocessor
0xC1042 spreadsheet
0xC1043 calendar
0xC1044 prog2 #fn+f4 (program a)
0xC1045 prog3 #fn+f5 (program b)
0xC1046 prog4 #fn+f6 (program c)
0xC1048 messenger
0xC104A find #fn+f10 (search www)
0xC104C ejectclosecd

View File

@ -0,0 +1,12 @@
0xC01B6 camera
0xC0183 media
0xC0184 wordprocessor
0xC0186 spreadsheet
0xC018E calendar
0xC0223 homepage
0xC01BC messenger
0xC018A mail
0xC0221 search
0xC00B8 ejectcd
0xC022D zoomin
0xC022E zoomout

9
keymaps/maxdata-pro_7000 Normal file
View File

@ -0,0 +1,9 @@
0x97 prog2
0x9F prog1
0xA0 mute # Fn-F5
0x82 www
0xEC email
0xAE volumedown # Fn-Down
0xB0 volumeup # Fn-Up
0xDF suspend # Fn+F2
0xF5 help

2
keymaps/medion-fid2060 Normal file
View File

@ -0,0 +1,2 @@
0x6B channeldown # Thottle Down
0x6D channelup # Thottle Up

4
keymaps/medionnb-a555 Normal file
View File

@ -0,0 +1,4 @@
0x63 www # N button
0x66 prog1 # link 1 button
0x67 email # envelope button
0x69 prog2 # link 2 button

13
keymaps/micro-star Normal file
View File

@ -0,0 +1,13 @@
0xA0 mute # Fn-F9
0xAE volumedown # Fn-F7
0xB0 volumeup # Fn-F8
0xB2 www # e button
0xDF sleep # Fn-F12
0xE2 bluetooth # satellite dish2
0xE4 f21 # Fn-F3 Touchpad disable
0xEC email # envelope button
0xEE camera # Fn-F6 camera disable
0xF6 wlan # satellite dish1
0xF7 brightnessdown # Fn-F4
0xF8 brightnessup # Fn-F5
0xF9 search

11
keymaps/module-asus-w3j Normal file
View File

@ -0,0 +1,11 @@
0x41 nextsong
0x45 playpause
0x43 stopcd
0x40 previoussong
0x4C ejectclosecd
0x32 mute
0x31 volumedown
0x30 volumeup
0x5D wlan
0x7E bluetooth
0x8A media # high keycode: "tv"

16
keymaps/module-ibm Normal file
View File

@ -0,0 +1,16 @@
0x01 battery # Fn+F2
0x02 screenlock # Fn+F3
0x03 sleep # Fn+F4
0x04 wlan # Fn+F5
0x06 switchvideomode # Fn+F7
0x07 zoom # Fn+F8 screen expand
0x08 f24 # Fn+F9 undock
0x0B suspend # Fn+F12
0x0F brightnessup # Fn+Home
0x10 brightnessdown # Fn+End
0x11 kbdillumtoggle # Fn+PgUp - ThinkLight
0x13 zoom # Fn+Space
0x14 volumeup
0x15 volumedown
0x16 mute
0x17 prog1 # ThinkPad/ThinkVantage button (high keycode: "vendor")

17
keymaps/module-lenovo Normal file
View File

@ -0,0 +1,17 @@
0x1 screenlock # Fn+F2
0x2 battery # Fn+F3
0x3 sleep # Fn+F4
0x4 wlan # Fn+F5
0x6 switchvideomode # Fn+F7
0x7 f21 # Fn+F8 touchpadtoggle
0x8 f24 # Fn+F9 undock
0xB suspend # Fn+F12
0xF brightnessup # Fn+Home
0x10 brightnessdown # Fn+End
0x11 kbdillumtoggle # Fn+PgUp - ThinkLight
0x13 zoom # Fn+Space
0x14 volumeup
0x15 volumedown
0x16 mute
0x17 prog1 # ThinkPad/ThinkVantage button (high keycode: "vendor")
0x1A micmute # Microphone mute

8
keymaps/module-sony Normal file
View File

@ -0,0 +1,8 @@
0x06 mute # Fn+F2
0x07 volumedown # Fn+F3
0x08 volumeup # Fn+F4
0x09 brightnessdown # Fn+F5
0x0A brightnessup # Fn+F6
0x0B switchvideomode # Fn+F7
0x0E zoom # Fn+F10
0x10 suspend # Fn+F12

2
keymaps/module-sony-old Normal file
View File

@ -0,0 +1,2 @@
0x06 battery
0x07 mute

8
keymaps/module-sony-vgn Normal file
View File

@ -0,0 +1,8 @@
0x00 brightnessdown # Fn+F5
0x10 brightnessup # Fn+F6
0x11 switchvideomode # Fn+F7
0x12 zoomout
0x14 zoomin
0x15 suspend # Fn+F12
0x17 prog1
0x20 media

4
keymaps/module-sony-vpc Normal file
View File

@ -0,0 +1,4 @@
# 0x05 touchpad_toggle # fn_f1 -> KEY_TOUCHPAD_TOGGLE
0x05 f21 # fn_f1 -> KEY_F21 (The actual touchpad toggle)
0x0d zoomout # fn_f9
0x0e zoomin # fn_f10

74
keymaps/olpc-xo Normal file
View File

@ -0,0 +1,74 @@
0x59 fn
0x81 fn_esc
0xF9 camera
0xF8 sound # Fn-CAMERA = Mic
# Function key mappings, as per
# http://dev.laptop.org/ticket/10213#comment:20
#
# Unmodified F1-F8 produce F1-F8, so no remap necessary.
# Unmodified F9-F12 control brightness and volume.
0x43 brightnessdown
0x44 brightnessup
0x57 volumedown
0x58 volumeup
# fn-modified fkeys all produce the unmodified version of the key.
0xBB f1
0xBC f2
0xBD f3
0xBE f4
0xBF f5
0xC0 f6
0xC1 f7
0xC2 f8
0xC3 f9
0xC4 f10
0xD7 f11
0xD8 f12
# Using F13-F21 for the .5 F keys right now.
0xF7 f13
0xF6 f14
0xF5 f15
0xF4 f16
0xF3 f17
0xF2 f18
0xF1 f19
0xF0 f20
0xEF f21
0xEE chat
0xE4 chat # Just mapping Fn-Chat to Chat for now
0xDD menu # Frame
0xDA prog1 # Fn-Frame
# The FN of some keys is other keys
0xD3 delete
0xD2 insert
0xC9 pageup
0xD1 pagedown
0xC7 home
0xCF end
# Language key - don't ask what they are doing as KEY_HP
0x73 hp
0x7E hp
0xDB leftmeta # left grab
0xDC rightmeta # right grab
0x85 rightmeta # Right grab releases on a different scancode
0xD6 kbdillumtoggle # Fn-space
0x69 switchvideomode # Brightness key
# Game keys
0x65 kp8 # up
0x66 kp2 # down
0x67 kp4 # left
0x68 kp6 # right
0xE5 kp9 # pgup
0xE6 kp3 # pgdn
0xE7 kp7 # home
0xE8 kp1 # end

14
keymaps/onkyo Normal file
View File

@ -0,0 +1,14 @@
0xA0 mute # Fn+D
0xAE volumedown # Fn+F
0xB0 volumeup # Fn+G
0xDF sleep # Fn+W
0xE0 bluetooth # Fn+H
0xE2 cyclewindows # Fn+Esc
0xEE battery # Fn+Q
0xF0 media # Fn+R
0xF5 switchvideomode # Fn+E
0xF6 camera # Fn+T
0xF7 f21 # Fn+Y (touchpad toggle)
0xF8 brightnessup # Fn+S
0xF9 brightnessdown # Fn+A
0xFB wlan # Fn+J

Some files were not shown because too many files have changed in this diff Show More