Compare commits
No commits in common. "master" and "v3.0.0-rc2" have entirely different histories.
master
...
v3.0.0-rc2
945 changed files with 57194 additions and 261132 deletions
24
.cvsignore
Normal file
24
.cvsignore
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
Makefile
|
||||||
|
Makefile.in
|
||||||
|
mkinstalldirs
|
||||||
|
aclocal.m4
|
||||||
|
autom4te.cache
|
||||||
|
config.guess
|
||||||
|
config.h
|
||||||
|
config.h.in
|
||||||
|
config.log
|
||||||
|
config.status
|
||||||
|
config.rpath
|
||||||
|
config.sub
|
||||||
|
configure
|
||||||
|
depcomp
|
||||||
|
install-sh
|
||||||
|
libtool
|
||||||
|
ltmain.sh
|
||||||
|
missing
|
||||||
|
stamp-h1
|
||||||
|
|
||||||
|
root
|
||||||
|
tags
|
||||||
|
cscope.out
|
||||||
|
pacman-*.tar.gz
|
|
@ -1,24 +0,0 @@
|
||||||
# EditorConfig configuration for pacman
|
|
||||||
# https://editorconfig.org
|
|
||||||
|
|
||||||
# Top-most EditorConfig file
|
|
||||||
root = true
|
|
||||||
|
|
||||||
# Unix-style newlines without trailing whitespaces, but with a newline
|
|
||||||
# ending every file, utf-8 charset, set indent to tabs
|
|
||||||
[*]
|
|
||||||
end_of_line = lf
|
|
||||||
insert_final_newline = true
|
|
||||||
trim_trailing_whitespace = true
|
|
||||||
charset = utf-8
|
|
||||||
indent_style = tab
|
|
||||||
|
|
||||||
[{NEWS,HACKING}]
|
|
||||||
indent_style = space
|
|
||||||
|
|
||||||
[meson.build]
|
|
||||||
indent_style = space
|
|
||||||
indent_size = 2
|
|
||||||
|
|
||||||
[*.py]
|
|
||||||
indent_style = space
|
|
1
.gitattributes
vendored
1
.gitattributes
vendored
|
@ -1 +0,0 @@
|
||||||
*.py diff=python
|
|
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -1,3 +0,0 @@
|
||||||
*~
|
|
||||||
*.o
|
|
||||||
pacman-*.tar.gz
|
|
132
.gitlab-ci.yml
132
.gitlab-ci.yml
|
@ -1,132 +0,0 @@
|
||||||
variables:
|
|
||||||
MAKEFLAGS: "-j10"
|
|
||||||
VERBOSE: 1
|
|
||||||
|
|
||||||
default:
|
|
||||||
after_script:
|
|
||||||
- build-aux/print-failed-test-output build/meson-logs/testlog.json
|
|
||||||
|
|
||||||
.arch-test:
|
|
||||||
image: archlinux:base-devel
|
|
||||||
before_script:
|
|
||||||
- >
|
|
||||||
pacman -Syu --needed --noconfirm
|
|
||||||
git
|
|
||||||
gpgme libarchive curl
|
|
||||||
python
|
|
||||||
fakeroot fakechroot
|
|
||||||
meson
|
|
||||||
artifacts:
|
|
||||||
when: always
|
|
||||||
paths:
|
|
||||||
- build/meson-logs/meson-log.txt
|
|
||||||
|
|
||||||
arch:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- meson setup build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
arch-debug:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- meson setup --buildtype=debug --werror build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
arch-docs:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- pacman -Syu --needed --noconfirm asciidoc
|
|
||||||
- meson setup -Ddoc=enabled build
|
|
||||||
- ninja -C build
|
|
||||||
|
|
||||||
arch-clang:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- pacman -Syu --needed --noconfirm clang
|
|
||||||
- CC=clang meson setup build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
#arch-valgrind:
|
|
||||||
# extends: .arch-test
|
|
||||||
# script:
|
|
||||||
# - pacman -Syu --needed --noconfirm valgrind
|
|
||||||
# - pacman -U --noconfirm https://geo.mirror.pkgbuild.com/core-debug/os/x86_64/glibc-debug-$(pacman -S --print-format %v glibc)-x86_64.pkg.tar.zst
|
|
||||||
# - meson setup build
|
|
||||||
# - ninja -C build
|
|
||||||
# - PACTEST_VALGRIND=1 fakechroot meson test -C build
|
|
||||||
|
|
||||||
arch-nettle:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- meson setup -Dcrypto=nettle --buildtype=debug build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
arch-no-gpg:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- meson setup -Dgpgme=disabled --buildtype=debug build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
arch-no-curl:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- meson setup -Dcurl=disabled --buildtype=debug build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
arch-no-nls:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- meson setup -Di18n=false --buildtype=debug build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
debian:
|
|
||||||
image: debian:bookworm
|
|
||||||
before_script:
|
|
||||||
- apt update
|
|
||||||
- >
|
|
||||||
apt -y install --no-install-recommends
|
|
||||||
git pkg-config meson gcc libtool
|
|
||||||
libgpgme-dev libarchive-dev libcurl4-openssl-dev libssl-dev curl
|
|
||||||
gettext python3 python3-setuptools dash gawk ca-certificates
|
|
||||||
fakeroot fakechroot
|
|
||||||
script:
|
|
||||||
- meson setup --buildtype=debug build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
fedora:
|
|
||||||
image: fedora
|
|
||||||
before_script:
|
|
||||||
- >
|
|
||||||
dnf -y install
|
|
||||||
git findutils patch sed
|
|
||||||
meson gcc libtool bsdtar
|
|
||||||
gpgme-devel libarchive-devel libcurl-devel openssl-devel gettext-devel
|
|
||||||
asciidoc python3 dash gawk
|
|
||||||
fakeroot fakechroot
|
|
||||||
perl-Module-Load-Conditional
|
|
||||||
script:
|
|
||||||
- meson setup --buildtype=debug build
|
|
||||||
- ninja -C build
|
|
||||||
- fakechroot meson test -C build
|
|
||||||
|
|
||||||
pages:
|
|
||||||
extends: .arch-test
|
|
||||||
script:
|
|
||||||
- pacman -Syu --needed --noconfirm asciidoc
|
|
||||||
- meson setup -Ddoc=enabled build
|
|
||||||
- ninja -C build html
|
|
||||||
artifacts:
|
|
||||||
paths:
|
|
||||||
- build/doc
|
|
||||||
publish: build/doc
|
|
||||||
rules:
|
|
||||||
- if: $CI_COMMIT_BRANCH == "release/6.1.x"
|
|
35
.mailmap
35
.mailmap
|
@ -1,35 +0,0 @@
|
||||||
Aaron Griffin <aaron@archlinux.org> <aaronmgriffin@gmail.com>
|
|
||||||
Allan McRae <allan@archlinux.org> <mcrae_allan@hotmail.com>
|
|
||||||
Allan McRae <allan@archlinux.org> <mcrae_allan at hotmail.com>
|
|
||||||
Allan McRae <allan@archlinux.org> <allan.mcrae@qimr.edu.au>
|
|
||||||
Andres P <aepd87@gmail.com> <stderr@mail.com>
|
|
||||||
Andrew Gregory <andrew.gregory.8@gmail.com>
|
|
||||||
Barbu Paul - Gheorghe <barbu.paul.gheorghe@gmail.com>
|
|
||||||
Bryan Ischo <bryan@ischo.com> <bji-keyword-pacman.3644cb@www.ischo.com>
|
|
||||||
Christos Nouskas <nous@archlinux.us> <nouskas@gmail.com>
|
|
||||||
Daenyth Blank <daenyth+arch@gmail.com> <Daenyth+Arch@gmail.com>
|
|
||||||
Daenyth Blank <Daenyth+arch@gmail.com> <Daenyth+git@gmail.com>
|
|
||||||
Dave Reisner <dreisner@archlinux.org> <d@falconindy.com>
|
|
||||||
甘露(Gan Lu) <rhythm.gan@gmail.com>
|
|
||||||
Giovanni Scafora <giovanni@archlinux.org> <linuxmania@gmail.com>
|
|
||||||
Jan Alexander Steffens (heftig) <heftig@archlinux.org> <jan.steffens@gmail.com>
|
|
||||||
Jaroslaw Swierczynski <swiergot@gmail.com> <swiergot@juvepoland.com>
|
|
||||||
Jonathan Conder <j@skurvy.no-ip.org> <jonno.conder@gmail.com>
|
|
||||||
Juan Pablo González Tognarelli <lord_jotape@yahoo.com.ar>
|
|
||||||
Juan Pablo González Tognarelli <lord_jotape@yahoo.com.ar> <jotapesan@gmail.com>
|
|
||||||
Manuel Tortosa <manutortosa@chakra-project.org> <manutortosa@gmail.com>
|
|
||||||
Marc - A. Dahlhaus <mad@wol.de>
|
|
||||||
Matthias Gorissen <matthias@archlinux.de> <siquame@web.de>
|
|
||||||
morganamilo <morganamilo@archlinux.org> <morganamilo@gmail.com>
|
|
||||||
Laszlo Papp <djszapi@archlinux.us> <djszapi2@gmail.com>
|
|
||||||
Nagy Gabor <ngaba@bibl.u-szeged.hu> <ngaba@petra.hos.u-szeged.hu>
|
|
||||||
Nagy Gabor <ngaba@bibl.u-szeged.hu> <ngaba at bibl.u-szeged.hu>
|
|
||||||
Nezmer <git@nezmer.info> <Nezmer@allurelinux.org>
|
|
||||||
Roman Kyrylych <roman@archlinux.org> <roman.kyrylych@gmail.com>
|
|
||||||
Sebastian Nowicki <sebnow@gmail.com> <xilonmu@gmail.com>
|
|
||||||
Vojtěch Gondžala <vojtech.gondzala@gmail.com> <vogo@seznam.cz>
|
|
||||||
Vojtěch Gondžala <vojtech.gondzala@gmail.com> Vojtech Gondzala <vojtech.gondzala@gmail.com>
|
|
||||||
William Giokas <1007380@gmail.com>
|
|
||||||
Xavier Chantry <shiningxc@gmail.com>
|
|
||||||
Xavier Chantry <shiningxc@gmail.com> <chantry.xavier@gmail.com>
|
|
||||||
Xavier Chantry <shiningxc@gmail.com> <xav@chantry.homelinux.org>
|
|
18
.tx/config
18
.tx/config
|
@ -1,18 +0,0 @@
|
||||||
[main]
|
|
||||||
host = https://www.transifex.com
|
|
||||||
|
|
||||||
[o:toofishes:p:archlinux-pacman:r:libalpm-pot]
|
|
||||||
file_filter = lib/libalpm/po/<lang>.po
|
|
||||||
source_file = lib/libalpm/po/libalpm.pot
|
|
||||||
source_lang = en
|
|
||||||
|
|
||||||
[o:toofishes:p:archlinux-pacman:r:pacman-pot]
|
|
||||||
file_filter = src/pacman/po/<lang>.po
|
|
||||||
source_file = src/pacman/po/pacman.pot
|
|
||||||
source_lang = en
|
|
||||||
|
|
||||||
[o:toofishes:p:archlinux-pacman:r:pacman-scripts-pot]
|
|
||||||
file_filter = scripts/po/<lang>.po
|
|
||||||
source_file = scripts/po/pacman-scripts.pot
|
|
||||||
source_lang = en
|
|
||||||
|
|
14
AUTHORS
14
AUTHORS
|
@ -1 +1,13 @@
|
||||||
Use `git shortlog -s` for a list of contributors.
|
Judd Vinet <jvinet@zeroflux.org>
|
||||||
|
Aurelien Foret <aurelien@archlinux.org>
|
||||||
|
Aaron Griffin <aaron@archlinux.org>
|
||||||
|
Dan McGee <dan@archlinux.org>
|
||||||
|
|
||||||
|
Miklós Vajna <vmiklos@frugalware.org>
|
||||||
|
Christian Hamar <krics@linuxforum.hu>
|
||||||
|
|
||||||
|
Josh Wheeler <deltalima@gmail.com>
|
||||||
|
David Kimpe <DNAku@frugalware.org>
|
||||||
|
|
||||||
|
James Rosten <seinfeld90@gmail.com>
|
||||||
|
Roman Kyrylych <Roman.Kyrylych@gmail.com>
|
||||||
|
|
31
COPYING
31
COPYING
|
@ -1,8 +1,9 @@
|
||||||
GNU GENERAL PUBLIC LICENSE
|
GNU GENERAL PUBLIC LICENSE
|
||||||
Version 2, June 1991
|
Version 2, June 1991
|
||||||
|
|
||||||
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
|
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
|
||||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
Everyone is permitted to copy and distribute verbatim copies
|
Everyone is permitted to copy and distribute verbatim copies
|
||||||
of this license document, but changing it is not allowed.
|
of this license document, but changing it is not allowed.
|
||||||
|
|
||||||
|
@ -15,7 +16,7 @@ software--to make sure the software is free for all its users. This
|
||||||
General Public License applies to most of the Free Software
|
General Public License applies to most of the Free Software
|
||||||
Foundation's software and to any other program whose authors commit to
|
Foundation's software and to any other program whose authors commit to
|
||||||
using it. (Some other Free Software Foundation software is covered by
|
using it. (Some other Free Software Foundation software is covered by
|
||||||
the GNU Lesser General Public License instead.) You can apply it to
|
the GNU Library General Public License instead.) You can apply it to
|
||||||
your programs, too.
|
your programs, too.
|
||||||
|
|
||||||
When we speak of free software, we are referring to freedom, not
|
When we speak of free software, we are referring to freedom, not
|
||||||
|
@ -55,7 +56,7 @@ patent must be licensed for everyone's free use or not licensed at all.
|
||||||
|
|
||||||
The precise terms and conditions for copying, distribution and
|
The precise terms and conditions for copying, distribution and
|
||||||
modification follow.
|
modification follow.
|
||||||
|
|
||||||
GNU GENERAL PUBLIC LICENSE
|
GNU GENERAL PUBLIC LICENSE
|
||||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||||
|
|
||||||
|
@ -110,7 +111,7 @@ above, provided that you also meet all of these conditions:
|
||||||
License. (Exception: if the Program itself is interactive but
|
License. (Exception: if the Program itself is interactive but
|
||||||
does not normally print such an announcement, your work based on
|
does not normally print such an announcement, your work based on
|
||||||
the Program is not required to print an announcement.)
|
the Program is not required to print an announcement.)
|
||||||
|
|
||||||
These requirements apply to the modified work as a whole. If
|
These requirements apply to the modified work as a whole. If
|
||||||
identifiable sections of that work are not derived from the Program,
|
identifiable sections of that work are not derived from the Program,
|
||||||
and can be reasonably considered independent and separate works in
|
and can be reasonably considered independent and separate works in
|
||||||
|
@ -168,7 +169,7 @@ access to copy from a designated place, then offering equivalent
|
||||||
access to copy the source code from the same place counts as
|
access to copy the source code from the same place counts as
|
||||||
distribution of the source code, even though third parties are not
|
distribution of the source code, even though third parties are not
|
||||||
compelled to copy the source along with the object code.
|
compelled to copy the source along with the object code.
|
||||||
|
|
||||||
4. You may not copy, modify, sublicense, or distribute the Program
|
4. You may not copy, modify, sublicense, or distribute the Program
|
||||||
except as expressly provided under this License. Any attempt
|
except as expressly provided under this License. Any attempt
|
||||||
otherwise to copy, modify, sublicense or distribute the Program is
|
otherwise to copy, modify, sublicense or distribute the Program is
|
||||||
|
@ -225,7 +226,7 @@ impose that choice.
|
||||||
|
|
||||||
This section is intended to make thoroughly clear what is believed to
|
This section is intended to make thoroughly clear what is believed to
|
||||||
be a consequence of the rest of this License.
|
be a consequence of the rest of this License.
|
||||||
|
|
||||||
8. If the distribution and/or use of the Program is restricted in
|
8. If the distribution and/or use of the Program is restricted in
|
||||||
certain countries either by patents or by copyrighted interfaces, the
|
certain countries either by patents or by copyrighted interfaces, the
|
||||||
original copyright holder who places the Program under this License
|
original copyright holder who places the Program under this License
|
||||||
|
@ -278,8 +279,8 @@ PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
|
||||||
POSSIBILITY OF SUCH DAMAGES.
|
POSSIBILITY OF SUCH DAMAGES.
|
||||||
|
|
||||||
END OF TERMS AND CONDITIONS
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
How to Apply These Terms to Your New Programs
|
Appendix: How to Apply These Terms to Your New Programs
|
||||||
|
|
||||||
If you develop a new program, and you want it to be of the greatest
|
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
|
possible use to the public, the best way to achieve this is to make it
|
||||||
|
@ -291,7 +292,7 @@ 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.
|
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.>
|
<one line to give the program's name and a brief idea of what it does.>
|
||||||
Copyright (C) <year> <name of author>
|
Copyright (C) 19yy <name of author>
|
||||||
|
|
||||||
This program is free software; you can redistribute it and/or modify
|
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
|
it under the terms of the GNU General Public License as published by
|
||||||
|
@ -303,16 +304,16 @@ the "copyright" line and a pointer to where the full notice is found.
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
GNU General Public License for more details.
|
GNU General Public License for more details.
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License along
|
You should have received a copy of the GNU General Public License
|
||||||
with this program; if not, write to the Free Software Foundation, Inc.,
|
along with this program; if not, write to the Free Software
|
||||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
|
|
||||||
Also add information on how to contact you by electronic and paper mail.
|
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
|
If the program is interactive, make it output a short notice like this
|
||||||
when it starts in an interactive mode:
|
when it starts in an interactive mode:
|
||||||
|
|
||||||
Gnomovision version 69, Copyright (C) year name of author
|
Gnomovision version 69, Copyright (C) 19yy name of author
|
||||||
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||||
This is free software, and you are welcome to redistribute it
|
This is free software, and you are welcome to redistribute it
|
||||||
under certain conditions; type `show c' for details.
|
under certain conditions; type `show c' for details.
|
||||||
|
@ -335,5 +336,5 @@ necessary. Here is a sample; alter the names:
|
||||||
This General Public License does not permit incorporating your program into
|
This General Public License does not permit incorporating your program into
|
||||||
proprietary programs. If your program is a subroutine library, you may
|
proprietary programs. If your program is a subroutine library, you may
|
||||||
consider it more useful to permit linking proprietary applications with the
|
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
|
library. If this is what you want to do, use the GNU Library General
|
||||||
Public License instead of this License.
|
Public License instead of this License.
|
||||||
|
|
169
HACKING
169
HACKING
|
@ -1,178 +1,95 @@
|
||||||
Pacman - Contributing
|
Contributing to pacman
|
||||||
=====================
|
======================
|
||||||
|
|
||||||
This file is meant to give you a brief overview of coding style and other
|
Please read 'submitting-patches' and 'translation-help' in the same directory
|
||||||
concerns when hacking on pacman. If you are interested in contributing, please
|
as this file.
|
||||||
read link:submitting-patches.html[submitting-patches] and
|
|
||||||
link:translation-help.html[translation-help] as well.
|
|
||||||
|
|
||||||
Coding Style
|
Coding style
|
||||||
------------
|
------------
|
||||||
|
|
||||||
1. All code should be indented with tabs. (Ignore the use of only spaces in
|
1. All code should be indented with tabs. (Ignore the use of only spaces in
|
||||||
this file.) A tab size of two spaces is used when calculating line widths,
|
this file) By default, source files contain the following VIM modeline:
|
||||||
which should be a maximum of 80 characters. An EditorConfig file is used
|
/* vim: set ts=2 sw=2 noet: */
|
||||||
to set this project-wide default.
|
|
||||||
|
|
||||||
2. When opening new blocks such as 'while', 'if', or 'for', leave the opening
|
2. When opening new blocks such as 'while', 'if', or 'for', leave the opening
|
||||||
brace on the same line as the beginning of the codeblock. The closing brace
|
brace on the same line as the beginning of the codeblock. The closing brace
|
||||||
gets its own line (the only exception being 'else'). Do not use extra
|
gets its own line (the only exception being 'else'). Do not use extra
|
||||||
spaces around the parentheses of the block. ALWAYS use opening and closing
|
spaces around the parentheses of the block. ALWAYS use opening/closing
|
||||||
braces, even if it's just a one-line block. This reduces future error when
|
braces, even if it's just a one-line block.
|
||||||
blocks are expanded beyond one line.
|
|
||||||
+
|
|
||||||
[source,C]
|
|
||||||
-------------------------------------------
|
|
||||||
for(lp = list; lp; lp = lp->next) {
|
|
||||||
newlist = _alpm_list_add(newlist, strdup(lp->data));
|
|
||||||
}
|
|
||||||
|
|
||||||
while(it) {
|
for(lp = list; lp; lp = lp->next) {
|
||||||
ptr = it->next;
|
newlist = _alpm_list_add(newlist, strdup(lp->data));
|
||||||
if(fn) {
|
}
|
||||||
fn(it->data);
|
|
||||||
} else {
|
while(it) {
|
||||||
return 1;
|
ptr = it->next;
|
||||||
}
|
if(fn) {
|
||||||
free(it);
|
fn(it->data);
|
||||||
it = ptr;
|
} else {
|
||||||
}
|
return(1);
|
||||||
-------------------------------------------
|
}
|
||||||
|
free(it);
|
||||||
|
it = ptr;
|
||||||
|
}
|
||||||
|
|
||||||
3. When declaring a new function, put the opening and closing braces on their
|
3. When declaring a new function, put the opening and closing braces on their
|
||||||
own line. Also, when declaring a pointer, do not put a space between the
|
own line. Also, when declaring a pointer, do not put a space between the
|
||||||
asterisk and the variable name.
|
asterisk and the variable name.
|
||||||
+
|
|
||||||
[source,C]
|
|
||||||
-------------------------------------------
|
|
||||||
alpm_list_t *alpm_list_add(alpm_list_t *list, void *data)
|
|
||||||
{
|
|
||||||
alpm_list_t *ptr, *lp;
|
|
||||||
|
|
||||||
ptr = list;
|
pmlist_t *_alpm_list_add(pmlist_t *list, void *data)
|
||||||
if(ptr == NULL) {
|
{
|
||||||
...
|
pmlist_t *ptr, *lp;
|
||||||
}
|
|
||||||
...
|
|
||||||
}
|
|
||||||
-------------------------------------------
|
|
||||||
|
|
||||||
4. Comments should be ANSI-C89 compliant. That means no `// Comment` style;
|
ptr = list;
|
||||||
use only `/* Comment */` style.
|
if(ptr == NULL) {
|
||||||
|
...
|
||||||
|
}
|
||||||
|
|
||||||
/* This is a comment */
|
4. Comments should be ANSI-C89 compliant. That means no "// Comment" style;
|
||||||
NOT
|
use only "/* Comment */" style.
|
||||||
// This is a comment
|
|
||||||
|
|
||||||
5. Return statements should *not* be written like function calls.
|
5. Return statements should be written like a function call.
|
||||||
|
|
||||||
return 0;
|
|
||||||
NOT
|
|
||||||
return(0);
|
return(0);
|
||||||
|
|
||||||
6. When using strcmp() (or any function that returns 0 on success) in a
|
|
||||||
conditional statement, use != 0 or == 0 and not the negation (!) operator.
|
|
||||||
It reads much cleaner for humans (using a negative to check for success is
|
|
||||||
confusing) and the compiler will treat it correctly anyway.
|
|
||||||
|
|
||||||
if(strcmp(a, b) == 0)
|
|
||||||
NOT
|
NOT
|
||||||
if(!strcmp(a, b))
|
return 0;
|
||||||
|
|
||||||
7. Use spaces around almost all arithmetic, comparison and assignment
|
6. The sizeof() operator should accept a type, not a value. (TODO: in certain
|
||||||
operators and after all ',;:' separators.
|
cases, it may be better- should this be a set guideline? Read "The Practice
|
||||||
|
of Programming")
|
||||||
foobar[2 * size + 1] = function(a, 6);
|
|
||||||
NOT
|
|
||||||
foobar[2*size+1]=function(a,6);
|
|
||||||
|
|
||||||
for(a = 0; a < n && n > 0; a++, n--) {}
|
|
||||||
NOT
|
|
||||||
for(a=0;a<n&&n>0;a++,n--) {}
|
|
||||||
|
|
||||||
8. Declare all variables at the start of the block.
|
|
||||||
[source,C]
|
|
||||||
-------------------------------------------
|
|
||||||
int SYMEXPORT alpm_db_remove_server(alpm_db_t *db, const char *url)
|
|
||||||
{
|
|
||||||
char *newurl, *vdata = NULL;
|
|
||||||
|
|
||||||
newurl = url;
|
|
||||||
if(!newurl) {
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
...
|
|
||||||
|
|
||||||
if(vdata) {
|
|
||||||
...
|
|
||||||
}
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
-------------------------------------------
|
|
||||||
|
|
||||||
NOT
|
|
||||||
|
|
||||||
[source,C]
|
|
||||||
-------------------------------------------
|
|
||||||
int SYMEXPORT alpm_db_remove_server(alpm_db_t *db, const char *url)
|
|
||||||
{
|
|
||||||
char *newurl = url;
|
|
||||||
|
|
||||||
if(!newurl) {
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
char *vdata = NULL;
|
|
||||||
|
|
||||||
if(vdata) {
|
|
||||||
...
|
|
||||||
}
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
-------------------------------------------
|
|
||||||
|
|
||||||
|
sizeof(alpm_list_t);
|
||||||
|
NOT
|
||||||
|
sizeof(*mylist);
|
||||||
|
|
||||||
Other Concerns
|
Other Concerns
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
Header Includes
|
|
||||||
~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
Currently our #include usage is in messy shape, but this is no reason to
|
Currently our #include usage is in messy shape, but this is no reason to
|
||||||
continue down this messy path. When adding an include to a file, follow this
|
continue down this messy path. When adding an include to a file, follow this
|
||||||
general pattern, including blank lines:
|
general pattern, including blank lines:
|
||||||
|
|
||||||
[source,C]
|
#include "config.h"
|
||||||
-------------------------------------------
|
|
||||||
#include <standardheader.h>
|
#include <standardheader.h>
|
||||||
#include <another.h>
|
#include <another.h>
|
||||||
#include <...>
|
#include <...>
|
||||||
-------------------------------------------
|
|
||||||
|
|
||||||
Follow this with some more headers, depending on whether the file is in libalpm
|
Follow this with some more headers, depending on whether the file is in libalpm
|
||||||
or pacman proper. For libalpm:
|
or pacman proper. For libalpm:
|
||||||
|
|
||||||
[source,C]
|
|
||||||
-------------------------------------------
|
|
||||||
/* libalpm */
|
/* libalpm */
|
||||||
#include "yourfile.h"
|
#include "yourfile.h"
|
||||||
#include "alpm_list.h"
|
#include "alpm_list.h"
|
||||||
#include "anythingelse.h"
|
#include "anythingelse.h"
|
||||||
-------------------------------------------
|
|
||||||
|
|
||||||
For pacman:
|
For pacman:
|
||||||
|
|
||||||
[source,C]
|
|
||||||
-------------------------------------------
|
|
||||||
#include <alpm.h>
|
#include <alpm.h>
|
||||||
#include <alpm_list.h>
|
#include <alpm_list.h>
|
||||||
|
|
||||||
/* pacman */
|
/* pacman */
|
||||||
#include "yourfile.h"
|
#include "yourfile.h"
|
||||||
#include "anythingelse.h"
|
#include "anythingelse.h"
|
||||||
-------------------------------------------
|
|
||||||
|
|
||||||
Never directly include config.h. This will always be added via Makefiles.
|
vim: set ts=2 sw=2 et:
|
||||||
|
|
234
INSTALL
Normal file
234
INSTALL
Normal file
|
@ -0,0 +1,234 @@
|
||||||
|
Installation Instructions
|
||||||
|
*************************
|
||||||
|
|
||||||
|
Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
|
||||||
|
2006 Free Software Foundation, Inc.
|
||||||
|
|
||||||
|
This file is free documentation; the Free Software Foundation gives
|
||||||
|
unlimited permission to copy, distribute and modify it.
|
||||||
|
|
||||||
|
Basic Installation
|
||||||
|
==================
|
||||||
|
|
||||||
|
Briefly, the shell commands `./configure; make; make install' should
|
||||||
|
configure, build, and install this package. The following
|
||||||
|
more-detailed instructions are generic; see the `README' file for
|
||||||
|
instructions specific to this package.
|
||||||
|
|
||||||
|
The `configure' shell script attempts to guess correct values for
|
||||||
|
various system-dependent variables used during compilation. It uses
|
||||||
|
those values to create a `Makefile' in each directory of the package.
|
||||||
|
It may also create one or more `.h' files containing system-dependent
|
||||||
|
definitions. Finally, it creates a shell script `config.status' that
|
||||||
|
you can run in the future to recreate the current configuration, and a
|
||||||
|
file `config.log' containing compiler output (useful mainly for
|
||||||
|
debugging `configure').
|
||||||
|
|
||||||
|
It can also use an optional file (typically called `config.cache'
|
||||||
|
and enabled with `--cache-file=config.cache' or simply `-C') that saves
|
||||||
|
the results of its tests to speed up reconfiguring. Caching is
|
||||||
|
disabled by default to prevent problems with accidental use of stale
|
||||||
|
cache files.
|
||||||
|
|
||||||
|
If you need to do unusual things to compile the package, please try
|
||||||
|
to figure out how `configure' could check whether to do them, and mail
|
||||||
|
diffs or instructions to the address given in the `README' so they can
|
||||||
|
be considered for the next release. If you are using the cache, and at
|
||||||
|
some point `config.cache' contains results you don't want to keep, you
|
||||||
|
may remove or edit it.
|
||||||
|
|
||||||
|
The file `configure.ac' (or `configure.in') is used to create
|
||||||
|
`configure' by a program called `autoconf'. You need `configure.ac' if
|
||||||
|
you want to change it or regenerate `configure' using a newer version
|
||||||
|
of `autoconf'.
|
||||||
|
|
||||||
|
The simplest way to compile this package is:
|
||||||
|
|
||||||
|
1. `cd' to the directory containing the package's source code and type
|
||||||
|
`./configure' to configure the package for your system.
|
||||||
|
|
||||||
|
Running `configure' might take a while. While running, it prints
|
||||||
|
some messages telling which features it is checking for.
|
||||||
|
|
||||||
|
2. Type `make' to compile the package.
|
||||||
|
|
||||||
|
3. Optionally, type `make check' to run any self-tests that come with
|
||||||
|
the package.
|
||||||
|
|
||||||
|
4. Type `make install' to install the programs and any data files and
|
||||||
|
documentation.
|
||||||
|
|
||||||
|
5. You can remove the program binaries and object files from the
|
||||||
|
source code directory by typing `make clean'. To also remove the
|
||||||
|
files that `configure' created (so you can compile the package for
|
||||||
|
a different kind of computer), type `make distclean'. There is
|
||||||
|
also a `make maintainer-clean' target, but that is intended mainly
|
||||||
|
for the package's developers. If you use it, you may have to get
|
||||||
|
all sorts of other programs in order to regenerate files that came
|
||||||
|
with the distribution.
|
||||||
|
|
||||||
|
Compilers and Options
|
||||||
|
=====================
|
||||||
|
|
||||||
|
Some systems require unusual options for compilation or linking that the
|
||||||
|
`configure' script does not know about. Run `./configure --help' for
|
||||||
|
details on some of the pertinent environment variables.
|
||||||
|
|
||||||
|
You can give `configure' initial values for configuration parameters
|
||||||
|
by setting variables in the command line or in the environment. Here
|
||||||
|
is an example:
|
||||||
|
|
||||||
|
./configure CC=c99 CFLAGS=-g LIBS=-lposix
|
||||||
|
|
||||||
|
*Note Defining Variables::, for more details.
|
||||||
|
|
||||||
|
Compiling For Multiple Architectures
|
||||||
|
====================================
|
||||||
|
|
||||||
|
You can compile the package for more than one kind of computer at the
|
||||||
|
same time, by placing the object files for each architecture in their
|
||||||
|
own directory. To do this, you can use GNU `make'. `cd' to the
|
||||||
|
directory where you want the object files and executables to go and run
|
||||||
|
the `configure' script. `configure' automatically checks for the
|
||||||
|
source code in the directory that `configure' is in and in `..'.
|
||||||
|
|
||||||
|
With a non-GNU `make', it is safer to compile the package for one
|
||||||
|
architecture at a time in the source code directory. After you have
|
||||||
|
installed the package for one architecture, use `make distclean' before
|
||||||
|
reconfiguring for another architecture.
|
||||||
|
|
||||||
|
Installation Names
|
||||||
|
==================
|
||||||
|
|
||||||
|
By default, `make install' installs the package's commands under
|
||||||
|
`/usr/local/bin', include files under `/usr/local/include', etc. You
|
||||||
|
can specify an installation prefix other than `/usr/local' by giving
|
||||||
|
`configure' the option `--prefix=PREFIX'.
|
||||||
|
|
||||||
|
You can specify separate installation prefixes for
|
||||||
|
architecture-specific files and architecture-independent files. If you
|
||||||
|
pass the option `--exec-prefix=PREFIX' to `configure', the package uses
|
||||||
|
PREFIX as the prefix for installing programs and libraries.
|
||||||
|
Documentation and other data files still use the regular prefix.
|
||||||
|
|
||||||
|
In addition, if you use an unusual directory layout you can give
|
||||||
|
options like `--bindir=DIR' to specify different values for particular
|
||||||
|
kinds of files. Run `configure --help' for a list of the directories
|
||||||
|
you can set and what kinds of files go in them.
|
||||||
|
|
||||||
|
If the package supports it, you can cause programs to be installed
|
||||||
|
with an extra prefix or suffix on their names by giving `configure' the
|
||||||
|
option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
|
||||||
|
|
||||||
|
Optional Features
|
||||||
|
=================
|
||||||
|
|
||||||
|
Some packages pay attention to `--enable-FEATURE' options to
|
||||||
|
`configure', where FEATURE indicates an optional part of the package.
|
||||||
|
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
|
||||||
|
is something like `gnu-as' or `x' (for the X Window System). The
|
||||||
|
`README' should mention any `--enable-' and `--with-' options that the
|
||||||
|
package recognizes.
|
||||||
|
|
||||||
|
For packages that use the X Window System, `configure' can usually
|
||||||
|
find the X include and library files automatically, but if it doesn't,
|
||||||
|
you can use the `configure' options `--x-includes=DIR' and
|
||||||
|
`--x-libraries=DIR' to specify their locations.
|
||||||
|
|
||||||
|
Specifying the System Type
|
||||||
|
==========================
|
||||||
|
|
||||||
|
There may be some features `configure' cannot figure out automatically,
|
||||||
|
but needs to determine by the type of machine the package will run on.
|
||||||
|
Usually, assuming the package is built to be run on the _same_
|
||||||
|
architectures, `configure' can figure that out, but if it prints a
|
||||||
|
message saying it cannot guess the machine type, give it the
|
||||||
|
`--build=TYPE' option. TYPE can either be a short name for the system
|
||||||
|
type, such as `sun4', or a canonical name which has the form:
|
||||||
|
|
||||||
|
CPU-COMPANY-SYSTEM
|
||||||
|
|
||||||
|
where SYSTEM can have one of these forms:
|
||||||
|
|
||||||
|
OS KERNEL-OS
|
||||||
|
|
||||||
|
See the file `config.sub' for the possible values of each field. If
|
||||||
|
`config.sub' isn't included in this package, then this package doesn't
|
||||||
|
need to know the machine type.
|
||||||
|
|
||||||
|
If you are _building_ compiler tools for cross-compiling, you should
|
||||||
|
use the option `--target=TYPE' to select the type of system they will
|
||||||
|
produce code for.
|
||||||
|
|
||||||
|
If you want to _use_ a cross compiler, that generates code for a
|
||||||
|
platform different from the build platform, you should specify the
|
||||||
|
"host" platform (i.e., that on which the generated programs will
|
||||||
|
eventually be run) with `--host=TYPE'.
|
||||||
|
|
||||||
|
Sharing Defaults
|
||||||
|
================
|
||||||
|
|
||||||
|
If you want to set default values for `configure' scripts to share, you
|
||||||
|
can create a site shell script called `config.site' that gives default
|
||||||
|
values for variables like `CC', `cache_file', and `prefix'.
|
||||||
|
`configure' looks for `PREFIX/share/config.site' if it exists, then
|
||||||
|
`PREFIX/etc/config.site' if it exists. Or, you can set the
|
||||||
|
`CONFIG_SITE' environment variable to the location of the site script.
|
||||||
|
A warning: not all `configure' scripts look for a site script.
|
||||||
|
|
||||||
|
Defining Variables
|
||||||
|
==================
|
||||||
|
|
||||||
|
Variables not defined in a site shell script can be set in the
|
||||||
|
environment passed to `configure'. However, some packages may run
|
||||||
|
configure again during the build, and the customized values of these
|
||||||
|
variables may be lost. In order to avoid this problem, you should set
|
||||||
|
them in the `configure' command line, using `VAR=value'. For example:
|
||||||
|
|
||||||
|
./configure CC=/usr/local2/bin/gcc
|
||||||
|
|
||||||
|
causes the specified `gcc' to be used as the C compiler (unless it is
|
||||||
|
overridden in the site shell script).
|
||||||
|
|
||||||
|
Unfortunately, this technique does not work for `CONFIG_SHELL' due to
|
||||||
|
an Autoconf bug. Until the bug is fixed you can use this workaround:
|
||||||
|
|
||||||
|
CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
|
||||||
|
|
||||||
|
`configure' Invocation
|
||||||
|
======================
|
||||||
|
|
||||||
|
`configure' recognizes the following options to control how it operates.
|
||||||
|
|
||||||
|
`--help'
|
||||||
|
`-h'
|
||||||
|
Print a summary of the options to `configure', and exit.
|
||||||
|
|
||||||
|
`--version'
|
||||||
|
`-V'
|
||||||
|
Print the version of Autoconf used to generate the `configure'
|
||||||
|
script, and exit.
|
||||||
|
|
||||||
|
`--cache-file=FILE'
|
||||||
|
Enable the cache: use and save the results of the tests in FILE,
|
||||||
|
traditionally `config.cache'. FILE defaults to `/dev/null' to
|
||||||
|
disable caching.
|
||||||
|
|
||||||
|
`--config-cache'
|
||||||
|
`-C'
|
||||||
|
Alias for `--cache-file=config.cache'.
|
||||||
|
|
||||||
|
`--quiet'
|
||||||
|
`--silent'
|
||||||
|
`-q'
|
||||||
|
Do not print messages saying which checks are being made. To
|
||||||
|
suppress all normal output, redirect it to `/dev/null' (any error
|
||||||
|
messages will still be shown).
|
||||||
|
|
||||||
|
`--srcdir=DIR'
|
||||||
|
Look for the package's source code in directory DIR. Usually
|
||||||
|
`configure' can determine that directory automatically.
|
||||||
|
|
||||||
|
`configure' also accepts some other, not widely useful, options. Run
|
||||||
|
`configure --help' for more details.
|
||||||
|
|
12
Makefile.am
Normal file
12
Makefile.am
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
SUBDIRS = lib/libalpm src/util src/pacman scripts doc etc pactest contrib
|
||||||
|
|
||||||
|
#DISTCHECK_CONFIGURE_FLAGS = --disable-fakeroot
|
||||||
|
|
||||||
|
# Some files automatically included, so they aren't specified below:
|
||||||
|
# AUTHORS, COPYING, NEWS, README
|
||||||
|
EXTRA_DIST = HACKING
|
||||||
|
|
||||||
|
check-local: src/pacman
|
||||||
|
python $(top_srcdir)/pactest/pactest.py --test $(top_srcdir)/pactest/tests/*.py -p $(top_builddir)/src/pacman/pacman
|
||||||
|
rm -rf $(top_builddir)/root
|
||||||
|
|
684
README
684
README
|
@ -2,19 +2,20 @@ ALPM library overview & internals
|
||||||
=================================
|
=================================
|
||||||
|
|
||||||
Here is a list of the main objects and files from the ALPM (i.e. Arch Linux
|
Here is a list of the main objects and files from the ALPM (i.e. Arch Linux
|
||||||
Package Management) library. This document, while not exhaustive, also
|
Package Management) library. This document, whilst not exhaustive, also
|
||||||
indicates some limitations (on purpose, or sometimes due to its poor design) of
|
indicates some limitations (on purpose, or sometimes due to its poor design) of
|
||||||
the library at the present time.
|
the library at the present time.
|
||||||
|
|
||||||
There is one special file, "alpm.h", which is the public interface that
|
There is one special file,"alpm.h", which is the public interface that
|
||||||
should be distributed and installed on systems with the library. Only
|
should be distributed and installed on systems with the library. Only
|
||||||
structures, data and functions declared within this file are made available to
|
structures, data and functions declared within this file are made available to
|
||||||
the frontend. Lots of structures are of an opaque type and their fields are
|
the frontend. Lots of structures are of an opaque type and their fields are
|
||||||
only accessible in read-only mode, through some clearly defined functions.
|
only accessible in read-only mode, through some clearly defined functions.
|
||||||
|
|
||||||
In addition to "alpm.h", the interfaces of "alpm_list.h" have also been made
|
In addition to "alpm.h", the interfaces of "alpm_list.h" have also been made
|
||||||
available to the frontend, for allowing it to manipulate the lists returned by
|
available to the frontend. It is not a requirement for the frontend to use
|
||||||
the backend.
|
these list functions; however, it prevents frontends from having to reimplement
|
||||||
|
a list data structure.
|
||||||
|
|
||||||
Several structures and functions have been renamed compared to pacman 2.9 code.
|
Several structures and functions have been renamed compared to pacman 2.9 code.
|
||||||
This was done at first for the sake of naming scheme consistency, and then
|
This was done at first for the sake of naming scheme consistency, and then
|
||||||
|
@ -24,7 +25,7 @@ same name declared in both spaces. To avoid such conflicts, internal function
|
||||||
names have been prepended with "_alpm_".
|
names have been prepended with "_alpm_".
|
||||||
|
|
||||||
In a general manner, public library functions are named "alpm_<type>_<action>"
|
In a general manner, public library functions are named "alpm_<type>_<action>"
|
||||||
(examples: alpm_trans_commit(), alpm_release(), alpm_pkg_get_name(), ...).
|
(examples: alpm_trans_commit(), alpm_release(), alpm_pkg_getinfo(), ...).
|
||||||
Internal (and thus private) functions should be named "_alpm_XXX" for instance
|
Internal (and thus private) functions should be named "_alpm_XXX" for instance
|
||||||
(examples: _alpm_needbackup(), _alpm_runscriplet(), ...). Functions defined and
|
(examples: _alpm_needbackup(), _alpm_runscriplet(), ...). Functions defined and
|
||||||
used inside a single file should be defined as "static".
|
used inside a single file should be defined as "static".
|
||||||
|
@ -32,62 +33,60 @@ used inside a single file should be defined as "static".
|
||||||
|
|
||||||
[Initialization]
|
[Initialization]
|
||||||
|
|
||||||
alpm_initialize() is used to initialize library internals and to create
|
alpm_init() is used to initialize library internals and to create
|
||||||
a transparent handle object. Before its call, the library can't be used.
|
a transparent handle object. Before its call, the library can't be used.
|
||||||
|
|
||||||
alpm_release() just does the opposite (memory used by the library, and the
|
alpm_lib_release() just does the opposite (memory used by the library, and the
|
||||||
handle is freed). After its call, the library is no longer available.
|
handle is freed). After its call, the library is no longer available.
|
||||||
|
|
||||||
|
|
||||||
[Options]
|
[Options]
|
||||||
|
|
||||||
The library does not use any configuration file. It is up to the front end to
|
In the future, the library will not use any configuration file. It will be up
|
||||||
configure the library as needed; the handle holds a number of configuration
|
to the front end to The handle holds a
|
||||||
options instead.
|
number of configuration options instead (IGNOREPKG, SYSLOG usage,
|
||||||
|
log file name, registered databases, ...).
|
||||||
|
|
||||||
All of the following options have a alpm_option_get_* and alpm_option_set_*
|
All of the following options have a alpm_option_get_* and alpm_option_set_*
|
||||||
function for getting and setting the value. They cannot be set before the
|
function for getting and setting the value. The cannot be set before the
|
||||||
library is initialized.
|
library is initialized.
|
||||||
|
|
||||||
* logcb: The callback function for "log" operations.
|
* logcb: The callback function for "log" operations.
|
||||||
* dlcb: The callback function for download progress of each package.
|
* dlcb: The callback function for download progress.
|
||||||
* fetchcb: Callback for custom download function.
|
* logmask: The logging mask for which level of output is sent to the logcb.
|
||||||
* eventcb: Callback for transaction messages.
|
* root: The root directory on which pacman operates (Default: /)
|
||||||
* questioncb: Callback for selecting amongst choices.
|
* dbpath: The base path to pacman's databases (Default: var/lib/pacman)
|
||||||
* progresscb: Callback to handle display of transaction progress.
|
* cachedir: The base path to pacman's download cache (Default: var/cache/pacman)
|
||||||
* gpgdir: Directory where GnuPG files are stored.
|
* logfile: The base path to pacman's log file (Default: var/log/pacman.log)
|
||||||
* arch: Allowed package architecture.
|
|
||||||
* checkspace: Check disk space before installing.
|
|
||||||
* default_siglevel: Default signature verification level.
|
|
||||||
* local_file_siglevel: Signature verification level for local file upgrades.
|
|
||||||
* remote_file_siglevel: Signature verification level for remote file upgrades.
|
|
||||||
* logfile: The base path to pacman's log file (Default: /var/log/pacman.log)
|
|
||||||
* usesyslog: Log to syslog instead of `logfile` for file-base logging.
|
* usesyslog: Log to syslog instead of `logfile` for file-base logging.
|
||||||
|
* upgradedelay: The time span to wait before listing a package as an upgrade (Default: 0)
|
||||||
|
* xfercommand: The command to use for downloading instead of pacman's internal
|
||||||
|
downloading functionality.
|
||||||
|
* nopassiveftp: Do not use passive FTP commands for ftp connections.
|
||||||
|
* chomp: No way, easter eggs are secret!
|
||||||
|
* usecolor: Unimplemented, but for the future. You can assume what it means.
|
||||||
|
|
||||||
The following options also have `alpm_option_{add,remove}_*` functions, as the
|
The following options also have a `alpm_option_add_*` function, as the values
|
||||||
values are list structures.
|
are list structures (NOTE: The add functions are NOT plural, as they're in
|
||||||
NOTE: The add and remove functions are NOT plural, as they are in English:
|
english: alpm_option_get_noupgrades -> alpm_option_add_noupgrade).
|
||||||
alpm_option_{get,set}_noupgrades -> alpm_option_{add,remove}_noupgrade.
|
|
||||||
|
|
||||||
* cachedirs: Paths to pacman's download caches (Default: /var/cache/pacman/pkg)
|
|
||||||
* noupgrades: Files which will never be touched by pacman (extracted as .pacnew)
|
* noupgrades: Files which will never be touched by pacman (extracted as .pacnew)
|
||||||
* noextracts: Files which will never be extracted at all (no .pacnew file)
|
* noextracts: Files which will never be extracted at all (no .pacnew file)
|
||||||
* ignorepkgs: Packages to ignore when upgrading.
|
* ignorepkgs: Packages to ignore when upgrading.
|
||||||
* ignoregrps: Groups to ignore when upgrading.
|
* holdpkgs: Packages which must be upgraded before continuing.
|
||||||
|
|
||||||
The following options are read-only, having ONLY alpm_option_get_* functions:
|
The following options are read-only, having ONLY alpm_option_get_* functions:
|
||||||
|
|
||||||
* root: The root directory for pacman to install to
|
* localdb: A pmdb_t structure for the local (installed) database
|
||||||
* dbpath: The toplevel database directory
|
* syncdbs: A list of pmdb_t structures to which pacman can sync from.
|
||||||
* lockfile: The file used for locking the database (Default: <dbpath>/db.lck)
|
|
||||||
|
|
||||||
|
|
||||||
[Transactions]
|
[Transactions]
|
||||||
|
|
||||||
The transaction structure permits easy manipulations of several packages
|
The transaction sturcture permits easy manipulations of several packages
|
||||||
at a time (i.e. adding, upgrade and removal operations).
|
at a time (i.e. adding, upgrade and removal operations).
|
||||||
|
|
||||||
A transaction can be initiated with a type (SYNC, UPGRADE or REMOVE),
|
A transaction can be initiated with a type (ADD, UPGRADE or REMOVE),
|
||||||
and some flags (NODEPS, FORCE, CASCADE, ...).
|
and some flags (NODEPS, FORCE, CASCADE, ...).
|
||||||
|
|
||||||
Note: there can only be one type at a time: a transaction is either
|
Note: there can only be one type at a time: a transaction is either
|
||||||
|
@ -107,7 +106,7 @@ These targets represent the list of packages to be handled.
|
||||||
|
|
||||||
Then, a transaction needs to be prepared (alpm_trans_prepare()). It
|
Then, a transaction needs to be prepared (alpm_trans_prepare()). It
|
||||||
means that the various targets added, will be inspected and challenged
|
means that the various targets added, will be inspected and challenged
|
||||||
against the set of already installed packages (dependency checking, etc...)
|
against the set of already installed packages (dependency checkings,
|
||||||
|
|
||||||
Last, a callback is associated with each transaction. During the
|
Last, a callback is associated with each transaction. During the
|
||||||
transaction resolution, each time a new step is started or done (i.e
|
transaction resolution, each time a new step is started or done (i.e
|
||||||
|
@ -118,27 +117,27 @@ the resolution. Can be useful to implement a progress bar.
|
||||||
|
|
||||||
[Package Cache]
|
[Package Cache]
|
||||||
|
|
||||||
libalpm maintains two caches for each DB. One is a general package cache, the
|
libalpm maintains two caches for each DB. One is a general package cache, the
|
||||||
other is a group cache (for package groups). These caches are loaded on demand,
|
other is a group cache (for package groups). These caches are loaded on demand,
|
||||||
and freed when the library is.
|
and freed when the libary is.
|
||||||
|
It is important to note tha, as a general rule, package structures should NOT be
|
||||||
It is important to note that, as a general rule, package structures should NOT
|
freed manually, as they SHOULD be part of the cache.
|
||||||
be freed manually, as they SHOULD be part of the cache. The cache of a
|
The cache of a database is always updated by the library after
|
||||||
database is always updated by the library after an operation changing the
|
an operation changing the database content (adding and/or removal of
|
||||||
database content (adding and/or removal of packages). Beware frontends ;)
|
packages). Beware frontends ;)
|
||||||
|
|
||||||
|
|
||||||
[Package]
|
[Package]
|
||||||
|
|
||||||
The package structure maintains all information for a package. In general,
|
The package structure maintains all information for a package. In general,
|
||||||
packages should never be freed from front-ends, as they should always be part
|
packages should never be freed from front-ends, as they should always be part of
|
||||||
of the package cache.
|
the package cache.
|
||||||
|
|
||||||
The 'origin' data member indicates whether the package is from a file (i.e. -U
|
The 'origin' data member indicates whether the package is from a file
|
||||||
operations) or from the package cache. In the case of a file, all data members
|
(i.e. -U operations) or from the package cache. In the case of a file, all data
|
||||||
available are present in the structure. Packages indicated as being from the
|
members available are present in the structure. Packages indicated as being
|
||||||
cache have data members filled on demand. For this reason, the alpm_pkg_get_*
|
from the cache have data members filled on demand. For this reason, the
|
||||||
functions will load the data from the DB as needed.
|
alpm_pkg_get_* functions will load the data from the DB as needed.
|
||||||
|
|
||||||
|
|
||||||
[Errors]
|
[Errors]
|
||||||
|
@ -151,15 +150,13 @@ indicating success, -1 indicating a failure.
|
||||||
If -1 is returned, the variable pm_errno is set to a meaningful value
|
If -1 is returned, the variable pm_errno is set to a meaningful value
|
||||||
Wise frontends should always care for these returned values.
|
Wise frontends should always care for these returned values.
|
||||||
|
|
||||||
Note: the helper function alpm_strerror() can also be used to translate one
|
Note: the helper function alpm_strerror() can also be used to translate
|
||||||
specified error code into a more friendly sentence, and alpm_strerrorlast()
|
the error code into a more friendly sentence.
|
||||||
does the same for the last error encountered (represented by pm_errno).
|
|
||||||
|
|
||||||
|
|
||||||
[List - alpm_list_t]
|
[List - alpm_list_t]
|
||||||
|
|
||||||
The alpm_list_t structure is a doubly-linked list for use with the libalpm
|
The alpm_list_t structure is a doubly-linked list for use with the libalpm
|
||||||
routines. This type is provided publicly so that frontends are free to use it
|
routines. This type is provided publicly so that frontends are free to use it
|
||||||
if they have no native list type (C++, glib, python, etc all have list types).
|
if they have no native list type (C++, glib, python, etc all have list types).
|
||||||
See the proper man pages for alpm_list_t references.
|
See the proper man pages for alpm_list_t references.
|
||||||
|
|
||||||
|
@ -183,576 +180,41 @@ perform a special action.
|
||||||
|
|
||||||
[MAIN] (see pacman.c)
|
[MAIN] (see pacman.c)
|
||||||
|
|
||||||
Calls for alpm_initialize(), and alpm_release().
|
Calls for alpm_lib_init(), and alpm_lib_release().
|
||||||
Read the configuration file, and parse command line arguments.
|
Read the configuration file, and parse command line arguments.
|
||||||
Based on the action requested, it initiates the appropriate transactions
|
Based on the action requested, it initiates the appropriate transactions
|
||||||
(see pacman_upgrade(), pacman_remove(), pacman_sync() in files upgrade.c,
|
(see pacman_add(), pacman_remove(), pacman_sync() in files add.c,
|
||||||
remove.c and sync.c).
|
remove.c and sync.c).
|
||||||
|
|
||||||
|
|
||||||
[CONFIGURATION] (see conf.h)
|
[CONFIGURATION] (see conf.c)
|
||||||
|
|
||||||
The frontend is using a configuration file, usually "/etc/pacman.conf". Some
|
The frontend is using a configuration file, usually "/etc/pacman.conf".
|
||||||
of these options are only useful for the frontend only (mainly the ones used to
|
Part of these options are only useful for the frontend only (mainly,
|
||||||
control the output like verbosepkglist, or the behavior with cleanmethod).
|
the download stuffs, and some options like HOLDPKG).
|
||||||
The rest is used to configure the library.
|
The rest is used to configure the library.
|
||||||
|
|
||||||
|
|
||||||
[UPGRADE/REMOVE/SYNC]
|
[ADD/UPGRADE/REMOVE/SYNC]
|
||||||
|
|
||||||
|
Nothing new here, excepted some reorganization.
|
||||||
|
|
||||||
The file pacman.c has been divided into several smaller files, namely
|
The file pacman.c has been divided into several smaller files, namely
|
||||||
upgrade.c, remove.c, sync.c and query.c, to hold the big parts: pacman_upgrade,
|
add.c, remove.c, sync.c and query.c, to hold the big parts: pacman_add,
|
||||||
pacman_remove, pacman_sync.
|
pacman_remove, pacman_sync.
|
||||||
|
|
||||||
These 3 functions have been split to ease the code reading.
|
These 3 functions have been split to ease the code reading.
|
||||||
|
|
||||||
|
|
||||||
|
LIMITATIONS/BEHAVIOR CHANGES COMPARED TO PACMAN 2.9
|
||||||
|
===================================================
|
||||||
|
|
||||||
API CHANGES BETWEEN 3.1 AND 3.2
|
Excepted missing features still needing to be implemented, one can
|
||||||
===============================
|
notice the following limitations:
|
||||||
|
|
||||||
[REMOVED]
|
- If pacman is out of date, the frontend displays a warning and recommends
|
||||||
- alpm_db_whatprovides()
|
to give up the on-going transanction. The frontend does not allow to
|
||||||
- alpm_splitdep (no longer public)
|
upgrade pacman itself on-the-fly, and thus it should be restarted with
|
||||||
- trans->targets was removed, so alpm_trans_get_targets() as well
|
only "pacman" as a target.
|
||||||
- error codes:
|
|
||||||
PM_ERR_OPT_*, PM_ERR_PKG_INSTALLED, PM_ERR_DLT_CORRUPTED,
|
|
||||||
PM_ERR_LIBARCHIVE_ERROR
|
|
||||||
- event: PM_TRANS_EVT_EXTRACT_DONE
|
|
||||||
- PM_TRANS_TYPE_ADD pmtranstype_t (add transaction)
|
|
||||||
- PM_TRANS_FLAG_DEPENDSONLY pmtransflag_t
|
|
||||||
|
|
||||||
[CHANGED]
|
- ...
|
||||||
- alpm_grp_get_pkgs returns with pmpkg_t list, not package-name list
|
|
||||||
- Swap parameters on PM_TRANS_CONV_INSTALL_IGNOREPKG callback function
|
|
||||||
- download callback API changed: alpm_cb_download, alpm_cb_totaldl split
|
|
||||||
(+ new alpm_option_get_totaldlcb(), alpm_option_set_totaldlcb() functions)
|
|
||||||
- unsigned long->off_t changes where size is used
|
|
||||||
- pmsyncpkg_t struct changes:
|
|
||||||
- pmsynctype_t and alpm_sync_get_type() were removed
|
|
||||||
- alpm_sync_get_data() was removed
|
|
||||||
- alpm_sync_get_removes() was added
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- alpm_delta_get_from_md5sum(), alpm_delta_get_to_md5sum()
|
|
||||||
- alpm_miss_get_causingpkg() (new causingpkg field in pmdepmissing_t)
|
|
||||||
- alpm_checkdbconflicts()
|
|
||||||
- alpm_sync_newversion()
|
|
||||||
- alpm_deptest()
|
|
||||||
- error codes:
|
|
||||||
PM_ERR_DLT_INVALID, PM_ERR_LIBARCHIVE, PM_ERR_LIBDOWNLOAD and
|
|
||||||
PM_ERR_EXTERNAL_DOWNLOAD
|
|
||||||
- flags:
|
|
||||||
PM_TRANS_FLAG_ALLEXPLICIT, PM_TRANS_FLAG_UNNEEDED and
|
|
||||||
PM_TRANS_FLAG_RECURSEALL
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 3.2 AND 3.3
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- pmsyncpkg_t struct (pmpkg_t is used for all types of transaction targets):
|
|
||||||
- alpm_sync_get_pkg()
|
|
||||||
- alpm_sync_get_removes() (use alpm_pkg_get_removes() instead)
|
|
||||||
- HoldPkg handling (it is the front-end's task):
|
|
||||||
- alpm_option_get_holdpkgs()
|
|
||||||
- alpm_option_add_holdpkg()
|
|
||||||
- alpm_option_set_holdpkgs()
|
|
||||||
- alpm_option_remove_holdpkg()
|
|
||||||
- PM_TRANS_CONV_REMOVE_HOLDPKG conversation
|
|
||||||
- Print URIs feature (it is the front-end's task):
|
|
||||||
- flag: PM_TRANS_FLAG_PRINTURIS
|
|
||||||
- event: PM_TRANS_EVT_PRINTURI
|
|
||||||
- alpm_delta_get_from_md5sum() and alpm_delta_get_to_md5sum()
|
|
||||||
- alpm_sync_sysupgrade()
|
|
||||||
- error codes:
|
|
||||||
PM_ERR_TRANS_COMMITING, PM_ERR_TRANS_DOWNLOADING, PM_ERR_PKG_LOAD,
|
|
||||||
PM_ERR_PKG_CANT_FRESH, PM_ERR_GRP_NOT_FOUND, PM_ERR_USER_ABORT,
|
|
||||||
PM_ERR_INTERNAL_ERROR, PM_ERR_DB_SYNC, PM_ERR_PKG_HOLD and
|
|
||||||
PM_ERR_LIBDOWNLOAD
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- XferCommand support was removed, any fetch callback function can be defined:
|
|
||||||
- alpm_option_get_xfercommand() and alpm_option_set_xfercommand() were removed
|
|
||||||
- alpm_option_get_fetchcb() and alpm_option_set_fetchcb() were added
|
|
||||||
- function renames:
|
|
||||||
- alpm_db_getpkgcache() -> alpm_db_get_pkgcache()
|
|
||||||
- alpm_db_getgrpcache() -> alpm_db_get_grpcache()
|
|
||||||
- alpm_dep_get_string() -> alpm_dep_compute_string()
|
|
||||||
- alpm_get_md5sum() -> alpm_compute_md5sum()
|
|
||||||
- alpm_checkdbconflicts() -> alpm_checkconflicts()
|
|
||||||
- alpm_trans_sysupgrade() has a new enable_downgrade parameter
|
|
||||||
- alpm_checkdeps() and alpm_checkconflicts() require local package list instead
|
|
||||||
of local database
|
|
||||||
- the to-be-upgraded package is passed to the callback function with
|
|
||||||
PM_TRANS_EVT_UPGRADE_START (as the second parameter)
|
|
||||||
- the "requiredby" package is never passed to the callback function with
|
|
||||||
PM_TRANS_CONV_INSTALL_IGNOREPKG (the second parameter is always NULL)
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- alpm_pkg_get_db()
|
|
||||||
- alpm_pkg_get_removes()
|
|
||||||
- conversation: PM_TRANS_CONV_REMOVE_PKGS (remove unresolvable targets)
|
|
||||||
- flag: PM_TRANS_FLAG_NOLOCK (do not lock database)
|
|
||||||
- error codes:
|
|
||||||
PM_ERR_SERVER_NONE, PM_ERR_TRANS_NOT_LOCKED, PM_ERR_PKG_IGNORED and
|
|
||||||
PM_ERR_LIBFETCH
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 3.3 AND 3.4
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- pmtranstype_t struct (transaction type), alpm_trans_get_type()
|
|
||||||
- alpm_option_get_nopassiveftp(), alpm_option_set_nopassiveftp()
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- interface for target loading:
|
|
||||||
- alpm_trans_addtarget() and alpm_trans_sysupgrade() were removed
|
|
||||||
- alpm_sync_target() and alpm_sync_dbtarget() can be used to add a sync target
|
|
||||||
- alpm_sync_sysupgrade() can be used to add outdated packages (for sysupgrade)
|
|
||||||
- alpm_add_target() can be used to add an add/upgrade target
|
|
||||||
- alpm_remove_target() can be used to add a remove target
|
|
||||||
- interface for target listing:
|
|
||||||
- alpm_trans_get_pkgs() was removed
|
|
||||||
- alpm_pkg_get_removes() was removed
|
|
||||||
- alpm_trans_get_add() can be used to list add/upgrade/sync targets
|
|
||||||
- alpm_trans_get_remove() can be used to list to-be-removed packages
|
|
||||||
- the type parameter of alpm_trans_init() was removed
|
|
||||||
- the type of alpm_db_fetch callback function: mtimeold and mtimenew parameters
|
|
||||||
were replaced by force parameter
|
|
||||||
- unsigned short -> int changes for Boolean variables
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- alpm_db_set_pkgreason()
|
|
||||||
- alpm_option_get_arch(), alpm_option_set_arch()
|
|
||||||
- alpm_option_get_usedelta()
|
|
||||||
- alpm_pkg_unused_deltas()
|
|
||||||
- alpm_conflict_get_reason()
|
|
||||||
- error code: PM_ERR_PKG_INVALID_ARCH
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 3.4 AND 3.5
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- alpm_db_register_local()
|
|
||||||
- alpm_pkg_has_force()
|
|
||||||
- alpm_depcmp()
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- alpm_trans_cb_progress type had some types changed from int to size_t
|
|
||||||
- alpm_cb_log format string is now const char *
|
|
||||||
- the interface to add/remove targets:
|
|
||||||
- functions take pmpkg_t * rather than char *.
|
|
||||||
- alpm_sync_target() and alpm_sync_dbtarget() are replaced by alpm_add_pkg()
|
|
||||||
- alpm_add_target() is replaced by alpm_add_pkg()
|
|
||||||
- alpm_remove_target() is replaced by alpm_remove_pkg()
|
|
||||||
- packages can come from:
|
|
||||||
- alpm_db_get_pkg() for normal targets
|
|
||||||
- alpm_find_dbs_satisfier() for versioned provisions
|
|
||||||
- alpm_find_grp_pkgs() for groups
|
|
||||||
- alpm_deptest() is replaced by the more flexible alpm_find_satisfier()
|
|
||||||
- size_t used for alpm_list_t sizes
|
|
||||||
- return type for alpm_list_count()
|
|
||||||
- parameter type in alpm_list_msort() and alpm_list_nth()
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- alpm_option_get_checkspace(), alpm_option_set_checkspace()
|
|
||||||
- alpm_find_grp_pkgs()
|
|
||||||
- alpm_trans_get_flags()
|
|
||||||
- error codes:
|
|
||||||
PM_ERR_DISK_SPACE, PM_ERR_WRITE
|
|
||||||
- flags:
|
|
||||||
PM_TRANS_FLAG_NODEPVERSION, PM_TRANS_EVT_DISKSPACE_START,
|
|
||||||
PM_TRANS_EVT_DISKSPACE_DONE, PM_TRANS_CONV_SELECT_PROVIDER,
|
|
||||||
PM_TRANS_PROGRESS_DISKSPACE_START, PM_TRANS_PROGRESS_INTEGRITY_START
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 3.5 AND 4.0
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- error codes:
|
|
||||||
PM_ERR_LIBFETCH, PM_ERR_WRITE
|
|
||||||
- alpm_option_set_root(), alpm_option_set_dbpath()
|
|
||||||
- alpm_list_first()
|
|
||||||
- alpm_grp_get_name(), alpm_grp_get_pkgs()
|
|
||||||
- alpm_delta_get_from(), alpm_delta_get_to(), alpm_delta_get_filename(),
|
|
||||||
alpm_delta_get_md5sum(), alpm_delta_get_size()
|
|
||||||
- alpm_miss_get_target(), alpm_miss_get_dep(), alpm_miss_get_causingpkg()
|
|
||||||
- alpm_dep_get_mod(), alpm_dep_get_name(), alpm_dep_get_version()
|
|
||||||
- alpm_conflict_get_package1(), alpm_conflict_get_package2(),
|
|
||||||
alpm_conflict_get_reason()
|
|
||||||
- alpm_fileconflict_get_target(), alpm_fileconflict_get_type(),
|
|
||||||
alpm_fileconflict_get_file(), alpm_fileconflict_get_ctarget()
|
|
||||||
- alpm_db_get_url()
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- PM_ prefixes for enum values are now ALPM_
|
|
||||||
- pm prefixes for structs and enums are now alpm_
|
|
||||||
- alpm_initialize now has parameters: char *root, char *dbpath,
|
|
||||||
alpm_errno_t *err and returns an alpm_handle_t struct.
|
|
||||||
- alpm_release now takes an alpm_handle_t *.
|
|
||||||
- alpm_db_register_sync() now requires a extra parameter of a alpm_siglevel_t.
|
|
||||||
- alpm_pkg_load() now requires an extra parameter of an alpm_siglevel_t
|
|
||||||
- alpm_db_setserver() replaced by alpm_db_set_servers(), alpm_db_add_server(),
|
|
||||||
alpm_db_remove_server()
|
|
||||||
- alpm_trans_init() no longer takes callbacks, set those using
|
|
||||||
alpm_option_set_*cb() functions
|
|
||||||
- many functions now require a first parameter of an alpm_handle_t *:
|
|
||||||
- alpm_option_get_*
|
|
||||||
- alpm_option_set_*
|
|
||||||
- alpm_option_add_*
|
|
||||||
- alpm_option_remove_*
|
|
||||||
- alpm_trans_*
|
|
||||||
- alpm_add_pkg
|
|
||||||
- alpm_checkconflicts
|
|
||||||
- alpm_checkdeps
|
|
||||||
- alpm_db_register_sync
|
|
||||||
- alpm_db_set_pkgreason
|
|
||||||
- alpm_db_unregister_all
|
|
||||||
- alpm_fetch_pkgurl
|
|
||||||
- alpm_find_dbs_satisfier
|
|
||||||
- alpm_logaction
|
|
||||||
- alpm_pkg_load
|
|
||||||
- alpm_release
|
|
||||||
- alpm_remove_pkg
|
|
||||||
- alpm_sync_sysupgrade
|
|
||||||
- several structs are no longer opaque:
|
|
||||||
- alpm_conflict_t
|
|
||||||
- alpm_delta_t
|
|
||||||
- alpm_depend_t
|
|
||||||
- alpm_depmissing_t
|
|
||||||
- alpm_depmod_t
|
|
||||||
- alpm_fileconflict_t
|
|
||||||
- alpm_group_t
|
|
||||||
- alpm_pkg_reason_t
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- option functions:
|
|
||||||
- alpm_{get,set}_eventcb()
|
|
||||||
- alpm_option_{get,set}_convcb()
|
|
||||||
- alpm_option_{get,set}_progresscb()
|
|
||||||
- package signing functions:
|
|
||||||
- alpm_option_get_default_siglevel()
|
|
||||||
- alpm_option_set_default_siglevel()
|
|
||||||
- alpm_option_get_gpgdir()
|
|
||||||
- alpm_option_set_gpgdir()
|
|
||||||
- alpm_db_get_siglevel()
|
|
||||||
- alpm_siglist_cleanup()
|
|
||||||
- alpm_db_check_pgp_signature()
|
|
||||||
- alpm_pkg_check_pgp_signature()
|
|
||||||
- alpm_pkg_get_origin()
|
|
||||||
- alpm_pkg_get_sha256sum()
|
|
||||||
- alpm_pkg_get_base64_sig()
|
|
||||||
- list functions:
|
|
||||||
- alpm_list_to_array()
|
|
||||||
- alpm_list_previous()
|
|
||||||
- structs:
|
|
||||||
- alpm_backup_t
|
|
||||||
- alpm_file_t
|
|
||||||
- alpm_filelist_t
|
|
||||||
- enums:
|
|
||||||
- alpm_siglevel_t
|
|
||||||
- alpm_sigstatus_t
|
|
||||||
- alpm_sigvalidity_t
|
|
||||||
- alpm_pkgfrom_t
|
|
||||||
- error codes:
|
|
||||||
ALPM_ERR_DB_INVALID, ALPM_ERR_DB_INVALID_SIG, ALPM_ERR_GPGME,
|
|
||||||
ALPM_ERR_PKG_INVALID_CHECKSUM, ALPM_ERR_PKG_INVALID_SIG, ALPM_ERR_SIG_INVALID,
|
|
||||||
ALPM_ERR_SIG_MISSING
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 4.0 AND 4.1
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- alpm_list_getdata()
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- alpm_pkgfrom_t members are now prefixed with ALPM_
|
|
||||||
- alpm_siglevel_t - added members ALPM_SIG_PACKAGE_SET, ALPM_SIG_PACKAGE_TRUST_SET
|
|
||||||
- alpm_depend_t - additional desc member
|
|
||||||
- alpm_filelist_t - additional resolved_path member
|
|
||||||
- alpm_pgpkey_t - added members length, revoked, pubkey_algo
|
|
||||||
- alpm_logaction - added caller identifier argument
|
|
||||||
- function renaming:
|
|
||||||
- alpm_option_get_localdb -> alpm_get_localdb
|
|
||||||
- alpm_option_get_syncdbs -> alpm_get_syncdbs
|
|
||||||
- alpm_db_register_sync -> alpm_register_syncdb
|
|
||||||
- alpm_db_unregister_all -> alpm_unregister_all_syncdbs
|
|
||||||
- alpm_db_readgroup -> alpm_db_get_group
|
|
||||||
- alpm_db_set_pkgreason -> alpm_pkg_set_reason (handle parameter removed)
|
|
||||||
- alpm_time_t typedef used for all times:
|
|
||||||
- members of alpm_pgpkey_t
|
|
||||||
- return types of alpm_pkg_get_builddate and alpm_pkg_get_installdate
|
|
||||||
- delta options now use required ratio rather than on/off:
|
|
||||||
- alpm_option_get_usedelta -> alpm_option_get_deltaratio
|
|
||||||
- alpm_option_set_usedelta -> alpm_option_set_deltaratio
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- tracking of how a package was validated:
|
|
||||||
- alpm_pkgvalidation_t
|
|
||||||
- alpm_pkg_get_validation()
|
|
||||||
- adjustable signature verification levels for upgrade operations:
|
|
||||||
- alpm_option_get_local_file_siglevel()
|
|
||||||
- alpm_option_set_local_file_siglevel()
|
|
||||||
- alpm_option_get_remote_file_siglevel()
|
|
||||||
- alpm_option_set_remote_file_siglevel()
|
|
||||||
- sync database usage functions:
|
|
||||||
- alpm_db_usage_t
|
|
||||||
- alpm_db_set_usage()
|
|
||||||
- alpm_db_get_usage()
|
|
||||||
- wrapper functions for reading mtree files:
|
|
||||||
- alpm_pkg_mtree_open()
|
|
||||||
- alpm_pkg_mtree_next()
|
|
||||||
- alpm_pkg_mtree_close()
|
|
||||||
- utility functions:
|
|
||||||
- alpm_pkg_find()
|
|
||||||
- alpm_pkg_compute_optionalfor()
|
|
||||||
- alpm_filelist_contains()
|
|
||||||
- types:
|
|
||||||
- alpm_time_t
|
|
||||||
- alpm_errno_t
|
|
||||||
- flags:
|
|
||||||
ALPM_EVENT_OPTDEP_REQUIRED, ALPM_EVENT_DATABASE_MISSING,
|
|
||||||
ALPM_EVENT_KEYRING_START, ALPM_EVENT_KEYRING_DONE, ALPM_EVENT_KEY_DOWNLOAD_START,
|
|
||||||
ALPM_EVENT_KEY_DOWNLOAD_DONE, ALPM_PROGRESS_KEYRING_START
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 4.1 AND 4.2
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- alpm_filelist_t - removed member resolved_path
|
|
||||||
- alpm_filelist_contains - now returns alpm_file_t
|
|
||||||
- event callback:
|
|
||||||
- alpm_event_t renamed to alpm_event_type_t
|
|
||||||
- alpm_event_t union added
|
|
||||||
- alpm_event_cb now takes only an alpm_event_t parameter
|
|
||||||
- alpm_event_any_t, alpm_package_operation_t, alpm_event_package_operation_t,
|
|
||||||
alpm_event_optdep_removal_t, alpm_event_delta_patch_t, alpm_event_scriptlet_info_t,
|
|
||||||
alpm_event_database_missing_t, alpm_event_pkgdownload_t, alpm_event_pacnew_created_t,
|
|
||||||
alpm_event_pacsave_created_t, alpm_event_pacorig_created_t added
|
|
||||||
- ALPM_EVENT_*_START -> ALPM_EVENT_PACKAGE_OPERATION_START
|
|
||||||
- ALPM_EVENT_*_DONE -> ALPM_EVENT_PACKAGE_OPERATION_DONE
|
|
||||||
- question callback:
|
|
||||||
- alpm_question_t renamed to alpm_question_type_t
|
|
||||||
- alpm_question_t union added
|
|
||||||
- alpm_cb_question now takes only an alpm_question_t parameter
|
|
||||||
- alpm_question_any_t, alpm_question_install_ignorepkg_t, alpm_question_replace_t
|
|
||||||
alpm_question_conflict_t, alpm_question_corrupted_t, alpm_question_remove_pkgs_t,
|
|
||||||
alpm_question_select_provider_t, alpm_question_import_key_t added
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- memory management:
|
|
||||||
- alpm_fileconflict_free()
|
|
||||||
- alpm_depmissing_free()
|
|
||||||
- alpm_conflict_free()
|
|
||||||
- alpm_dep_free()
|
|
||||||
- database usage:
|
|
||||||
- alpm_db_usage_t
|
|
||||||
- alpm_db_set_usage()
|
|
||||||
- alpm_db_get_usage()
|
|
||||||
- assume installed:
|
|
||||||
- alpm_option_get_assumeinstalled()
|
|
||||||
- alpm_option_add_assumeinstalled()
|
|
||||||
- alpm_option_set_assumeinstalled()
|
|
||||||
- alpm_option_remove_assumeinstalled()
|
|
||||||
- using noupgrade/noextract:
|
|
||||||
- alpm_option_match_noupgrade()
|
|
||||||
- alpm_option_match_noextract()
|
|
||||||
- utility functions:
|
|
||||||
- alpm_dep_from_string()
|
|
||||||
- alpm_pkg_should_ignore()
|
|
||||||
- alpm_decode_signature()
|
|
||||||
- alpm_extract_keyid()
|
|
||||||
- flags:
|
|
||||||
ALPM_EVENT_RETRIEVE_DONE, ALPM_EVENT_RETRIEVE_FAILED, ALPM_EVENT_PKGDOWNLOAD_START,
|
|
||||||
ALPM_EVENT_PKGDOWNLOAD_DONE, ALPM_EVENT_PKGDOWNLOAD_FAILED, ALPM_EVENT_OPTDEP_REMOVAL,
|
|
||||||
ALPM_EVENT_PACNEW_CREATED, ALPM_EVENT_PACSVAE_CREATED, ALPM_EVENT_PACORIG_CREATED
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 4.2 AND 5.0
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- alpm_siglevel_t - removed members ALPM_SIG_PACKAGE_SET, ALPM_SIG_PACKAGE_TRUST_SET
|
|
||||||
- removed .pacorig generation:
|
|
||||||
- ALPM_EVENT_PACORIG_CREATED
|
|
||||||
- alpm_event_pacorig_created_t
|
|
||||||
- alpm_event_t.pacorig_created
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- hook support:
|
|
||||||
- alpm_option_get_hookdirs()
|
|
||||||
- alpm_option_set_hookdirs()
|
|
||||||
- alpm_option_add_hookdir()
|
|
||||||
- alpm_option_remove_hookdir()
|
|
||||||
- alpm_event_hook_t, alpm_event_hook_run_t
|
|
||||||
- alpm_hook_when_t
|
|
||||||
- ALPM_EVENT_HOOK_START, ALPM_EVENT_HOOK_DONE
|
|
||||||
- ALPM_EVENT_HOOK_RUN_START, ALPM_EVENT_HOOK_RUN_DONE
|
|
||||||
- ALPM_ERR_TRANS_HOOK_FAILED
|
|
||||||
- different database extension support:
|
|
||||||
- alpm_option_get_dbext()
|
|
||||||
- alpm_option_set_dbext()
|
|
||||||
- pkgbase accessor:
|
|
||||||
- alpm_pkg_get_base()
|
|
||||||
- transaction events:
|
|
||||||
- ALPM_EVENT_TRANSACTION_START, ALPM_EVENT_TRANSACTION_DONE
|
|
||||||
- database unlocking:
|
|
||||||
- alpm_unlock()
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 5.0 AND 5.1
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- alpm_errno_t - added member ALPM_ERR_OK
|
|
||||||
- alpm_siglevel_t - value of ALPM_SIG_USE_DEFAULT changed
|
|
||||||
- functions using bitfields return/pass an int instead of an enum:
|
|
||||||
- alpm_option_get_default_siglevel()
|
|
||||||
- alpm_option_set_default_siglevel()
|
|
||||||
- alpm_option_get_remote_file_siglevel()
|
|
||||||
- alpm_option_set_remote_file_siglevel()
|
|
||||||
- alpm_register_syncdb()
|
|
||||||
- alpm_db_get_siglevel()
|
|
||||||
- alpm_db_set_usage()
|
|
||||||
- alpm_db_get_usage()
|
|
||||||
- alpm_pkg_load()
|
|
||||||
- alpm_pkg_get_validation()
|
|
||||||
- alpm_trans_get_flags()
|
|
||||||
- alpm_trans_init()
|
|
||||||
- alpm_option_get_local_file_siglevel()
|
|
||||||
- alpm_option_set_local_file_siglevel()
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- overwrite support:
|
|
||||||
- alpm_option_get_overwrite_files()
|
|
||||||
- alpm_option_set_overwrite_files()
|
|
||||||
- alpm_option_add_overwrite_file()
|
|
||||||
- alpm_option_remove_overwrite_file()
|
|
||||||
- download timeout control:
|
|
||||||
- alpm_option_set_disable_dl_timeout()
|
|
||||||
- access make/checkdepends info:
|
|
||||||
- alpm_pkg_get_checkdepends()
|
|
||||||
- alpm_pkg_get_makedepends()
|
|
||||||
- check pacman capabilities:
|
|
||||||
- alpm_capabilities()
|
|
||||||
- duplicate and add to list:
|
|
||||||
- alpm_list_append_strdup()
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 5.1 AND 5.2
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- package delta support:
|
|
||||||
- alpm_delta_t
|
|
||||||
- alpm_event_delta_patch_t
|
|
||||||
- alpm_event_t union - removed alpm_event_delta_patch_t
|
|
||||||
- ALPM_EVENT_DELTA_INTEGRITY_START, ALPM_EVENT_DELTA_INTEGRITY_DONE,
|
|
||||||
ALPM_EVENT_DELTA_PATCHES_START, ALPM_EVENT_DELTA_PATCHES_DONE,
|
|
||||||
ALPM_EVENT_DELTA_PATCH_START, ALPM_EVENT_DELTA_PATCH_DONE,
|
|
||||||
ALPM_EVENT_DELTA_PATCH_FAILED
|
|
||||||
- ALPM_ERR_DLT_INVALID, ALPM_ERR_DLT_PATCHFAILED
|
|
||||||
- alpm_option_get_deltaratio()
|
|
||||||
- alpm_option_set_deltaratio()
|
|
||||||
- alpm_pkg_get_deltas()
|
|
||||||
- alpm_pkg_unused_deltas()
|
|
||||||
- alpm_transflag_t - removed member ALPM_TRANS_FLAG_FORCE
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- alpm_errno_t - added member ALPM_ERR_MISSING_CAPABILITY_SIGNATURES
|
|
||||||
- alpm_sync_newversion() replaced with alpm_sync_get_new_version() which
|
|
||||||
does not filter on any ALPM_DB_USAGE_*.
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 5.2 AND 6.0
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- ALPM_EVENT_PKGDOWNLOAD_START, ALPM_EVENT_PKGDOWNLOAD_DONE, ALPM_EVENT_PKGDOWNLOAD_FAILED
|
|
||||||
- ALPM_ERR_PKG_REPO_NOT_FOUND
|
|
||||||
- old TotalDownload implementation:
|
|
||||||
- alpm_cb_totaldl
|
|
||||||
- alpm_option_get_totaldlcb()
|
|
||||||
- alpm_option_set_totaldlcb()
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- alpm_db_update() now accepts a list of databases rather than a single database.
|
|
||||||
- alpm_fetch_pkgurl() accepts a list of packages to download.
|
|
||||||
- alpm_db_search() now has an additional parameter and returns success status
|
|
||||||
- ALPM_EVENT_RETRIEVE_* -> ALPM_EVENT_DB_RETRIEVE_* and ALPM_EVENT_PKG_RETRIEVE_*
|
|
||||||
- alpm_cb_download pass event and data
|
|
||||||
- multi architecture support:
|
|
||||||
- alpm_option_get_arch() -> alpm_option_get_architectures()
|
|
||||||
- alpm_option_set_arch() -> alpm_option_set_architectures()
|
|
||||||
- alpm_db_get_servers() copies parameter data
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- parallel download support:
|
|
||||||
- alpm_option_set_parallel_downloads()
|
|
||||||
- alpm_option_get_parallel_downloads()
|
|
||||||
- file download events:
|
|
||||||
- alpm_download_event_type_t
|
|
||||||
- alpm_download_event_init_t
|
|
||||||
- alpm_download_event_progress_t
|
|
||||||
- alpm_download_event_completed_t
|
|
||||||
- download misc:
|
|
||||||
- ALPM_DOWNLOAD_RETRY
|
|
||||||
- alpm_download_event_retry_t
|
|
||||||
- alpm_event_pkg_retrieve_t
|
|
||||||
- multiarchitecture support:
|
|
||||||
- alpm_option_add_architecture()
|
|
||||||
- alpm_option_remove_architecture()
|
|
||||||
- misc:
|
|
||||||
- alpm_pkg_get_sig()
|
|
||||||
- callbacks add front-end provided context
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 6.0 AND 6.1
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[REMOVED]
|
|
||||||
- alpm_trans_t
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- alpm_conflict_t - full package added as member, removing package name and name
|
|
||||||
hash members
|
|
||||||
- alpm_question_import_key_t - holds key uid and fingerprint rather than alpm_pgpkey_t
|
|
||||||
- alpm_pkgreason_t - added ALPM_PKG_REASON_UNKNOWN
|
|
||||||
- alpm_transflag_t - added ALPM_TRANS_FLAG_NOHOOKS
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- extensible package data type:
|
|
||||||
- alpm_pkg_xdata_t
|
|
||||||
- alpm_pkg_get_xdata()
|
|
||||||
- accessor functions:
|
|
||||||
- alpm_db_get_handle()
|
|
||||||
- alpm_pkg_get_handle()
|
|
||||||
- cache server support:
|
|
||||||
- alpm_db_get_cache_servers()
|
|
||||||
- alpm_db_set_cache_servers()
|
|
||||||
- alpm_db_add_cache_server()
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 6.1 AND 7.0
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[ADDED]
|
|
||||||
- sandbox functions:
|
|
||||||
- alpm_option_get_sandboxuser()
|
|
||||||
- alpm_option_set_sandboxuser()
|
|
||||||
- alpm_option_set_disable_sandbox()
|
|
||||||
- alpm_sandbox_setup_child()
|
|
||||||
|
|
||||||
|
|
||||||
API CHANGES BETWEEN 7.0 AND 7.1
|
|
||||||
===============================
|
|
||||||
|
|
||||||
[CHANGED]
|
|
||||||
- error codes:
|
|
||||||
PM_ERR_TRANS_COMMITING renamed to PM_ERR_TRANS_COMMITTING
|
|
||||||
|
|
34
RELEASE
34
RELEASE
|
@ -1,34 +0,0 @@
|
||||||
The following checklist should be used for making a pacman release.
|
|
||||||
|
|
||||||
- Ensure "ninja dist" succeeds
|
|
||||||
- Call a freeze to development.
|
|
||||||
- Send translation updates to Transifex at least two weeks before a major
|
|
||||||
release (see below). At this stage, strings can only be changed for a
|
|
||||||
major issue.
|
|
||||||
- Update NEWS and README files
|
|
||||||
- Pull translation updates from Transifex
|
|
||||||
- Update version in meson.build as described in file
|
|
||||||
- Update doc/index.asciidoc
|
|
||||||
- Create a signed git tag (git tag -s vX.Y.Z -m "commit message")
|
|
||||||
- Create and sign release tarballs (generate with "ninja dist")
|
|
||||||
- Create release on gitlab project page
|
|
||||||
- Upload release tarball and signature to gitlab ("glab release upload ...")
|
|
||||||
- Create branch release/?.?.x (with ?.? replaced by major version number)
|
|
||||||
- Update .gitlab-ci.yml to point the website pages run at release branch
|
|
||||||
|
|
||||||
Transifex updates are handled using the transifex client. The basic process is:
|
|
||||||
- Pull updates from transifex ("tx pull -f --minimum-perc 75")
|
|
||||||
- Update po files ("./build-aux/update-po")
|
|
||||||
- Fix all translation errors found (e.g. using "mint-check-translations")
|
|
||||||
- Add any new locales to the relevant LINGUAS file
|
|
||||||
- Optional: Make any manual changes needed (e.g. fixing spacing in a string)
|
|
||||||
and update po files again
|
|
||||||
- Push updated po files to transifex ("tx push -s -t --skip")
|
|
||||||
|
|
||||||
Point releases:
|
|
||||||
- all bugs fixes slated for the release branch must first land on master
|
|
||||||
(unless no longer relevant)
|
|
||||||
- following the initial post-release period when the release and master
|
|
||||||
branches may be kept in sync, commits are backported to the release branch
|
|
||||||
using "git cherry-pick -x"
|
|
||||||
- translation updates should be pulled onto the release branch only
|
|
71
TODO.aaron
Normal file
71
TODO.aaron
Normal file
|
@ -0,0 +1,71 @@
|
||||||
|
== This is my custom TODO file ==
|
||||||
|
|
||||||
|
* transaction object should contain two package list (install and remove)
|
||||||
|
instead of a single list of syncpkgs - this should allow us to get rid of that
|
||||||
|
type. This also requires seperate functionality to return a list of
|
||||||
|
"replaces" packages to the front end, so the frontend can handle the QUESTION()
|
||||||
|
stuff in that case
|
||||||
|
|
||||||
|
* Look into other VCSs to use. The main CVS repo will remain, but having a
|
||||||
|
distributed system to allow for easy patching/pushing/pulling would be nice
|
||||||
|
- monotone and mercurial look like the top contenders in my book, but I need
|
||||||
|
to evaluate both a bit more.
|
||||||
|
|
||||||
|
* src/pacman:
|
||||||
|
There's quite a few single function headers which contain the pacman_*
|
||||||
|
functions. We should move these to a single header (pacman.h) to clean up
|
||||||
|
the source a bit.
|
||||||
|
|
||||||
|
* libalpm -> front end communication needs a work-up. Both progress functions
|
||||||
|
can be combined into one callback, IFF we adjust it to accept a prefix string
|
||||||
|
for the progress bars, and format it at the lib side. Question functions
|
||||||
|
should also do the same - create the string at the library side, and simply
|
||||||
|
call some sort of int yes_no = ask_question("Do foo with bar?");
|
||||||
|
|
||||||
|
* move logging (alpm_logaction) out of the library. log files should be
|
||||||
|
written by the app, not the library. Adding a PM_LOG_* constant that
|
||||||
|
frontends can recognize and send to a file is probably a good idea.
|
||||||
|
|
||||||
|
* clear up list allocation/deallocation - some lists need to be free'd, some
|
||||||
|
do not and there is no clear indication WHEN this should happen.
|
||||||
|
|
||||||
|
* remove DB entries (directories) on a read error?
|
||||||
|
|
||||||
|
* Add a pm_errstr error string, which will allow us to do things like:
|
||||||
|
pm_errno = PM_ERR_LIBARCHIVE;
|
||||||
|
pm_errstr = archive_error_string(archive);
|
||||||
|
or:
|
||||||
|
pm_errno = PM_ERR_LIBDOWNLOAD;
|
||||||
|
pm_errstr = downloadLastErrString;
|
||||||
|
This way we don't break abstraction when returning specific errors in
|
||||||
|
cases like the above.
|
||||||
|
|
||||||
|
* pacman: A LOT of functions are way too long. There should be an upper limit of
|
||||||
|
100-200 lines. _alpm_add_commit is around 600 lines, and is far too complex.
|
||||||
|
|
||||||
|
* pacman: fixup doxygen documentation for public interface
|
||||||
|
|
||||||
|
* libalpm: just because a function is in alpm.h doesn't mean it needs to be in
|
||||||
|
alpm.c - we should move functions around where they should be. In fact,
|
||||||
|
alpm.c might not be needed at all, if things were organized properly.
|
||||||
|
|
||||||
|
* feature for 3.1: package file hooks *
|
||||||
|
I've been planning on this one for some time. Here's a simple rundown:
|
||||||
|
in /etc/pacman.d/hooks:
|
||||||
|
Hook /usr/include/* : /usr/bin/ctags -R /usr/include/*.h -f /usr/include/systags
|
||||||
|
This will allow us to make "global hooks" to simplify a lot of repetitive
|
||||||
|
install files (scrollkeeper, depmod, etc). This also allows us to move
|
||||||
|
ldconfig out of pacman entirely.
|
||||||
|
possible: /etc/pacman.hooks/* files for hooks, so packages can add them too
|
||||||
|
|
||||||
|
* feature for 3.1: multiple search/match types
|
||||||
|
option: MatchType regex (current way)
|
||||||
|
MatchType fnmatch (use fnmatch to match things like 'pacman -S gnome*')
|
||||||
|
MatchType plain (no matching. expect plain text).
|
||||||
|
|
||||||
|
* feature for 3.1: revamp the autotools system. I'd LOVE to use a manual system
|
||||||
|
like wmii and friends do. It'd be real nice if we could just do away with
|
||||||
|
autotools altogether.
|
||||||
|
|
||||||
|
**** BUGS ****
|
||||||
|
* Removal of conflicts on -A and -U (INCOMPLETE)
|
146
TODO.dan
Normal file
146
TODO.dan
Normal file
|
@ -0,0 +1,146 @@
|
||||||
|
TODO.dan
|
||||||
|
========
|
||||||
|
|
||||||
|
This is my personal TODO list. No guarantees if it is out of date and things no
|
||||||
|
longer apply. If you want to help out with any of it, send me an email.
|
||||||
|
|
||||||
|
Only vaguely related to pacman:
|
||||||
|
-------------------------------
|
||||||
|
|
||||||
|
Port the libdownload (libfetch) manpage from BSD style to Linux style, or at
|
||||||
|
very least change references to BSD.
|
||||||
|
|
||||||
|
|
||||||
|
Pacman 3.0:
|
||||||
|
-----------
|
||||||
|
|
||||||
|
ideas mentioned here- http://bbs.archlinux.org/viewtopic.php?id=29450- add a
|
||||||
|
.install message about mirrors, maybe comment whole file, encourage rankmirrors
|
||||||
|
usage
|
||||||
|
|
||||||
|
|
||||||
|
Pacman 3.1:
|
||||||
|
-----------
|
||||||
|
|
||||||
|
Documentation- look into moving man page format to a more portable source
|
||||||
|
format to make translation easier to keep up-to-date (something like txt2tags,
|
||||||
|
docbook, asciidoc) This will need some research.
|
||||||
|
|
||||||
|
Update cache cleaning functionality - keep installed version, choose number to
|
||||||
|
keep, etc. Good python script in the forums that we should try to emulate.
|
||||||
|
|
||||||
|
Downgrade feature - allow users to see cached packages and downgrade to
|
||||||
|
(previous or any?) available options.
|
||||||
|
|
||||||
|
Extreme similarity between some of the sync and add code...we have to be able
|
||||||
|
to abstract more away from sync actions and add actions to just 'actions'
|
||||||
|
(example: sync,c, add.c, and deptest.c all contain a switch on PM_DEP_MOD_*).
|
||||||
|
Merge update, add, and sync code when possible, so we reduce duplication.
|
||||||
|
|
||||||
|
Review progress/transaction event subsystem. (from TODO)
|
||||||
|
|
||||||
|
Add Doxygen comments to every function in libalpm including private functions.
|
||||||
|
Ensure functions are doing exactly their purpose and nothing more. Find
|
||||||
|
functions that perform duplicate behavior and merge them. Combine and refactor
|
||||||
|
others. Delete unnecessary functions. Stop keeping everything clustered in
|
||||||
|
little add/sync/remove parts, allow transactions to share code.
|
||||||
|
|
||||||
|
Go through options list. Decide if namings are good, all options are still
|
||||||
|
relevant, etc. Ideas for -Re (#6273), changing meaning of -c (has two meanings,
|
||||||
|
another FS bug), etc. Remove the -A flag and possibly -D, -T, and -Y (-Y is
|
||||||
|
killed now in favor of vercmp binary) if they can be done by other actions.
|
||||||
|
Possible switch of -U --> -I (#5571).
|
||||||
|
|
||||||
|
Rewrite _alpm_sortbydeps to use Topological Sort. Should work using a standard
|
||||||
|
topo sort algorithm, once the crazy types can be fixed up a bit. Include a
|
||||||
|
cycle check - print a big error message if this happens.
|
||||||
|
-- http://en.wikipedia.org/wiki/Topological_sort
|
||||||
|
-- http://everything2.com/?node_id=556079
|
||||||
|
|
||||||
|
Review display and logging functions. There seems to be an abundance of them.
|
||||||
|
Make it extensible to use color, review what verbose/debug means. Perhaps
|
||||||
|
separate logging functionality- Pacman has its normal log, and alpm backend
|
||||||
|
keeps a very simple log file - listing only adds (including syncs) and removes.
|
||||||
|
This way a consistency list can be kept of what is currently installed and what
|
||||||
|
isn't, without all the logging junk from the front end.
|
||||||
|
|
||||||
|
If we stick with autotools, add more defines to configure.in, including
|
||||||
|
CACHEDIR, PKGEXT, so these can be specified at configure time for ease of use
|
||||||
|
by other distributions which may want to change the defaults. Also, review what
|
||||||
|
needs to be in config.h and what does not. There may be excess #depends which
|
||||||
|
are hard coded into the sources. (from TODO.autoconf)
|
||||||
|
|
||||||
|
Profile the code. Find the functions that are being called a lot, and see what
|
||||||
|
can be done about it. Find out if all these calls are necessary (e.g. excessive
|
||||||
|
alpm_list_count calls), and maybe think about changing data structures to speed
|
||||||
|
operations up (e.g. a 'count' field). NOTE: already found two huge issues with
|
||||||
|
quick profiling- excessive setlocale calls, and extremely excessive strcmp
|
||||||
|
calls.
|
||||||
|
|
||||||
|
Localize the date display done in --info output. Also, fix other localized
|
||||||
|
issues- use non-printf when necessary, make sure all two line printed messages
|
||||||
|
(especially usage instructions) are printed using one print statement. We
|
||||||
|
may need to use some wchar_t output on the progress bar as char/byte counts
|
||||||
|
differ here.
|
||||||
|
|
||||||
|
Rewrite makepkg to use terminal-safe coloring/bolding. tput utility should
|
||||||
|
allow us to do this. Make universal message functions for systemwide use,
|
||||||
|
including all pacman utilites- abs, pacman-optimize, etc.
|
||||||
|
|
||||||
|
Bugs/FRs to smash: 6468, 6437, 6430?, 6420, 6404, 6389, 6312?, 6284, 6273?,
|
||||||
|
6255?, 6208, 5987, 5885, 5571, 4182, 3492, 2810?, 1769, 1588, 1571
|
||||||
|
|
||||||
|
Remove _alpm from function names now that we have SYMHIDDEN and static
|
||||||
|
declarations.
|
||||||
|
|
||||||
|
Remove alpm.c, put functions where they should be.
|
||||||
|
|
||||||
|
Update doxygen comments, they may need some work. Try to document all of the
|
||||||
|
private internal functions too- it helps a ton for people just getting a
|
||||||
|
start on pacman hacking.
|
||||||
|
|
||||||
|
Other smaller things:
|
||||||
|
---------------------
|
||||||
|
|
||||||
|
unsigned int vs. unsigned- determine a standard and stick with it
|
||||||
|
|
||||||
|
FS #4185 - move where message is logged, perhaps?
|
||||||
|
|
||||||
|
Update copyrights (2007)
|
||||||
|
|
||||||
|
Update pacman website, and add/finish pacman coding style page
|
||||||
|
|
||||||
|
autogen.sh / autoclean.sh - these seem messy. Can we clean this up?
|
||||||
|
|
||||||
|
Refine makepkg error codes. Each kind of failure could have its own code:
|
||||||
|
--package already built
|
||||||
|
--failed integ checks
|
||||||
|
--failed build
|
||||||
|
--etc.
|
||||||
|
|
||||||
|
Add utility function to either frontend or backend to convert sizes: e.g. bytes
|
||||||
|
to KB, MB, GB.
|
||||||
|
|
||||||
|
Revamp the downloadprog function a bit. Seems kind of messy.
|
||||||
|
|
||||||
|
Add localized pkgdesc variables to makepkg.
|
||||||
|
|
||||||
|
--print-uri option to sync should not require saying yes or no to up to date
|
||||||
|
|
||||||
|
Add testing scripts to pactest for issues we have been working on (especially
|
||||||
|
files moving between packages). Also, take a look at cleaning up the output and
|
||||||
|
structure of the pactest.py program itself.
|
||||||
|
|
||||||
|
Build a replacement for this, or at least standardize its use. We shouldn't
|
||||||
|
always need to pass handle->root around, it is constant. Something like char*
|
||||||
|
buildpath(file).
|
||||||
|
/* build the new entryname relative to handle->root */
|
||||||
|
snprintf(filename, PATH_MAX, "%s%s", handle->root, entryname);
|
||||||
|
|
||||||
|
Random ideas:
|
||||||
|
-------------
|
||||||
|
|
||||||
|
Possibly split utilities/extras from pacman package
|
||||||
|
|
||||||
|
Make .indent.pro file for GNU indent (started, but didn't finish)
|
||||||
|
|
60
TRANSLATORS
60
TRANSLATORS
|
@ -1,60 +0,0 @@
|
||||||
Thanks to all of those who have helped translate pacman, both in the past and
|
|
||||||
currently. Our translations are currently maintained in Transifex; please read
|
|
||||||
doc/translation-help.txt for more details.
|
|
||||||
|
|
||||||
Below is a list of past translators before we switched to Transifex; more can
|
|
||||||
be found by looking in the Git history.
|
|
||||||
|
|
||||||
If your language is not already in the various po/ subdirectories and you wish
|
|
||||||
it was, set up a team in Transifex for your language and we will be happy to
|
|
||||||
add your language to the mix.
|
|
||||||
|
|
||||||
Catalan (ca):
|
|
||||||
Manuel Tortosa <manutortosa@chakra-project.org>
|
|
||||||
Czech (cs):
|
|
||||||
Vojtěch Gondžala <vojtech.gondzala@gmail.com>
|
|
||||||
German (de):
|
|
||||||
Matthias Gorissen <matthias@archlinux.de>
|
|
||||||
Greek (el):
|
|
||||||
Christos Nouskas <nouskas@gmail.com>
|
|
||||||
British English (en_GB):
|
|
||||||
Jeff Bailes <thepizzaking@gmail.com>
|
|
||||||
Spanish (es):
|
|
||||||
Juan Pablo González Tognarelli <lord_jotape@yahoo.com.ar>
|
|
||||||
Fernando Lagos <fernando@zerial.org>
|
|
||||||
French (fr):
|
|
||||||
Chantry Xavier <shiningxc@gmail.com>
|
|
||||||
Hungarian (hu):
|
|
||||||
Nagy Gabor <ngaba@bibl.u-szeged.hu>
|
|
||||||
Avramucz Péter <muczyjoe@gmail.com>
|
|
||||||
Italian (it):
|
|
||||||
Giovanni Scafora <giovanni@archlinux.org>
|
|
||||||
Kazakh (kk):
|
|
||||||
Baurzhan Muftakhidinov <baurthefirst@gmail.com>
|
|
||||||
Norwegian (nb):
|
|
||||||
Hans-Kristian Arntzen <maister@archlinux.us>
|
|
||||||
Polish (pl):
|
|
||||||
Mateusz Herych <heniekk@gmail.com>
|
|
||||||
Jaroslaw Swierczynski <swiergot@gmail.com>
|
|
||||||
Mateusz Jędrasik <m.jedrasik@gmail.com>
|
|
||||||
Brazilian Portuguese (pt_BR):
|
|
||||||
Armando M. Baratti <ambaratti@archlinux-br.org>
|
|
||||||
Rodrigo Flores <flores@archlinux-br.org>
|
|
||||||
Marcelo Cavalcante <kalibslack@gmail.com>
|
|
||||||
Romanian (ro):
|
|
||||||
Volodia Macovei <blog@volodia.ro>
|
|
||||||
Russian (ru):
|
|
||||||
Sergey Tereschenko <serg.partizan@gmail.com>
|
|
||||||
Vitaly Dolgov <ferhiord@gmail.com>
|
|
||||||
Oleg Finkelshteyn <olegfink@gmail.com>
|
|
||||||
Vladimir Bayrakovskiy <4rayven@gmail.com>
|
|
||||||
Swedish (sv):
|
|
||||||
Christian Larsson <congacx@gmail.com>
|
|
||||||
Turkish (tr):
|
|
||||||
Samed Beyribey <ras0ir@eventualis.org>
|
|
||||||
Alper KANAT <alperkanat@gmail.com>
|
|
||||||
Ukrainian (uk):
|
|
||||||
Roman Kyrylych (Роман Кирилич) <roman.kyrylych@gmail.com>
|
|
||||||
Ivan Kovnatsky (Іван Ковнацький) <sevenfourk@gmail.com>
|
|
||||||
Simplified Chinese (zh_CN):
|
|
||||||
甘露(Lu.Gan) <rhythm.gan@gmail.com>
|
|
6397
acinclude.m4
Normal file
6397
acinclude.m4
Normal file
File diff suppressed because it is too large
Load diff
34
autoclean.sh
Executable file
34
autoclean.sh
Executable file
|
@ -0,0 +1,34 @@
|
||||||
|
#!/bin/sh -xu
|
||||||
|
|
||||||
|
[ -f Makefile ] && make distclean
|
||||||
|
rm -rf autom4te.cache
|
||||||
|
rm -rf {Makefile.in,Makefile}
|
||||||
|
rm -rf {config.h.in,config.h}
|
||||||
|
rm -rf config.status
|
||||||
|
rm -rf configure
|
||||||
|
rm -rf stamp*
|
||||||
|
rm -rf aclocal.m4
|
||||||
|
rm -rf compile
|
||||||
|
rm -rf libtool
|
||||||
|
|
||||||
|
rm -rf lib/libalpm/{Makefile.in,Makefile}
|
||||||
|
rm -rf src/util/{Makefile.in,Makefile}
|
||||||
|
rm -rf src/pacman/{Makefile.in,Makefile}
|
||||||
|
rm -rf scripts/{Makefile.in,Makefile}
|
||||||
|
rm -rf etc/{Makefile.in,Makefile}
|
||||||
|
rm -rf etc/pacman.d/{Makefile.in,Makefile}
|
||||||
|
rm -rf etc/abs/{Makefile.in,Makefile}
|
||||||
|
rm -rf pactest/{Makefile.in,Makefile}
|
||||||
|
rm -rf doc/{Makefile.in,Makefile}
|
||||||
|
rm -rf doc/html/*.html
|
||||||
|
rm -rf doc/man3/*.3
|
||||||
|
|
||||||
|
rm -rf src/pacman/po/{Makefile.in,Makefile}
|
||||||
|
rm -rf src/pacman/po/POTFILES
|
||||||
|
rm -rf src/pacman/po/stamp-po
|
||||||
|
rm -rf src/pacman/po/*.gmo
|
||||||
|
|
||||||
|
rm -rf lib/libalpm/po/{Makefile.in,Makefile}
|
||||||
|
rm -rf lib/libalpm/po/POTFILES
|
||||||
|
rm -rf lib/libalpm/po/stamp-po
|
||||||
|
rm -rf lib/libalpm/po/*.gmo
|
6
autogen.sh
Executable file
6
autogen.sh
Executable file
|
@ -0,0 +1,6 @@
|
||||||
|
#!/bin/sh -xu
|
||||||
|
|
||||||
|
aclocal
|
||||||
|
autoheader
|
||||||
|
automake --foreign
|
||||||
|
autoconf
|
2
build-aux/.gitignore
vendored
2
build-aux/.gitignore
vendored
|
@ -1,2 +0,0 @@
|
||||||
*
|
|
||||||
!ltmain-asneeded.patch
|
|
|
@ -1,11 +0,0 @@
|
||||||
#!/usr/bin/python3
|
|
||||||
|
|
||||||
import sys
|
|
||||||
|
|
||||||
for path in sys.argv[1:]:
|
|
||||||
print('# -----------------------------------')
|
|
||||||
print('# ' + path + ':')
|
|
||||||
print('# -----------------------------------')
|
|
||||||
with open(path, 'r') as f:
|
|
||||||
for line in f:
|
|
||||||
print('# ' + line, end='')
|
|
|
@ -1,29 +0,0 @@
|
||||||
#!@BASH@
|
|
||||||
|
|
||||||
input=$1
|
|
||||||
output=$2
|
|
||||||
mode=$3
|
|
||||||
|
|
||||||
sed \
|
|
||||||
-e "s|@rootdir[@]|@ROOTDIR@|g" \
|
|
||||||
-e "s|@localedir[@]|@LOCALEDIR@|g" \
|
|
||||||
-e "s|@sysconfdir[@]|@sysconfdir@|g" \
|
|
||||||
-e "s|@localstatedir[@]|@localstatedir@|g" \
|
|
||||||
-e "s|@libmakepkgdir[@]|@LIBMAKEPKGDIR@|g" \
|
|
||||||
-e "s|@pkgdatadir[@]|@PKGDATADIR@|g" \
|
|
||||||
-e "s|@keyringdir[@]|@KEYRINGDIR@|g" \
|
|
||||||
-e "s|@prefix[@]|@PREFIX@|g" \
|
|
||||||
-e "1s|#!/bin/bash|#!@BASH@|g" \
|
|
||||||
-e "s|@PACKAGE_VERSION[@]|@PACKAGE_VERSION@|g" \
|
|
||||||
-e "s|@PACKAGE_NAME[@]|@PACKAGE_NAME@|g" \
|
|
||||||
-e "s|@BUILDSCRIPT[@]|@BUILDSCRIPT@|g" \
|
|
||||||
-e "s|@TEMPLATE_DIR[@]|@TEMPLATE_DIR@|g" \
|
|
||||||
-e "s|@DEBUGSUFFIX[@]|@DEBUGSUFFIX@|g" \
|
|
||||||
-e "s|@INODECMD[@]|@INODECMD@|g" \
|
|
||||||
-e "s|@FILECMD[@]|@FILECMD@|g" \
|
|
||||||
-e "s|@BSDTAR_NO_READ_SPARSE[@]|@BSDTAR_NO_READ_SPARSE@|g" \
|
|
||||||
"$input" >"$output"
|
|
||||||
|
|
||||||
if [[ $mode ]]; then
|
|
||||||
chmod "$mode" "$output"
|
|
||||||
fi
|
|
|
@ -1,10 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
# this is needed mostly because $DESTDIR is provided as a variable,
|
|
||||||
# and we need to create the target directory...
|
|
||||||
|
|
||||||
mkdir -vp "$(dirname "${DESTDIR:-}$2")"
|
|
||||||
|
|
||||||
rm -f "${DESTDIR:-}$2"
|
|
||||||
ln -vs "$1" "${DESTDIR:-}$2"
|
|
|
@ -1,17 +0,0 @@
|
||||||
#!/usr/bin/python
|
|
||||||
|
|
||||||
import json
|
|
||||||
import sys
|
|
||||||
|
|
||||||
def print_result(result):
|
|
||||||
print('==================================================================')
|
|
||||||
print(result['name'])
|
|
||||||
print(' '.join(result['command']))
|
|
||||||
print('==================================================================')
|
|
||||||
print(result['stdout'])
|
|
||||||
|
|
||||||
with open(sys.argv[1], 'r') as f:
|
|
||||||
for line in f:
|
|
||||||
result = json.loads(line)
|
|
||||||
if result['result'] == 'FAIL':
|
|
||||||
print_result(result)
|
|
|
@ -1,6 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# This script serves as a trampoline for running scripts which depend on
|
|
||||||
# libmakepkg with the libmakepkg within the build tree.
|
|
||||||
|
|
||||||
MAKEPKG_LIBRARY=@BUILDDIR@/libmakepkg exec @BASH@ -$- @REAL_PROGPATH@ "$@"
|
|
|
@ -1,8 +0,0 @@
|
||||||
#! /bin/sh
|
|
||||||
|
|
||||||
OLD=$1
|
|
||||||
NEW=$2
|
|
||||||
|
|
||||||
for file in $(git grep -l "Copyright .* Pacman Development" | grep -v "\.po"); do \
|
|
||||||
sed -i -e "/Copyright (/s/-${OLD}/-${NEW}/" -e "/Copyright (/s/ ${OLD}/ ${OLD}-${NEW}/" "$file"
|
|
||||||
done
|
|
|
@ -1,39 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
find_build_directory() {
|
|
||||||
local build_dirs=(*/build.ninja)
|
|
||||||
|
|
||||||
if [[ ! -e ${build_dirs[0]} ]]; then
|
|
||||||
echo "error: No build directory found. Have you run 'meson build' yet?" >&2
|
|
||||||
return 1
|
|
||||||
elif (( ${#build_dirs[*]} > 1 )); then
|
|
||||||
echo "error: Multiple build directories found. Unable to proceed." >&2
|
|
||||||
return 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
printf '%s\n' "${build_dirs[0]%/*}"
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
filter_targets_by_name() {
|
|
||||||
if command -v jq &>/dev/null; then
|
|
||||||
jq --arg re "$1" -r 'map(.name)[] | select(match($re))'
|
|
||||||
else
|
|
||||||
json_pp | awk -v filter="$1" -F'[:"]' \
|
|
||||||
'$2 == "name" && $(NF - 1) ~ filter { print $(NF - 1) }'
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# Make things simple and require that we're in the build root rather than
|
|
||||||
# trying to chase down the location of this script and the relative build dir.
|
|
||||||
if [[ ! -d .git ]]; then
|
|
||||||
echo "This script must be run from the root of the repository" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
build_dir=$(find_build_directory) || exit 1
|
|
||||||
|
|
||||||
mapfile -t targets < \
|
|
||||||
<(meson introspect "$build_dir" --targets | filter_targets_by_name "-update-po$")
|
|
||||||
|
|
||||||
ninja -C "$build_dir" "${targets[@]}"
|
|
1516
config.guess
vendored
Executable file
1516
config.guess
vendored
Executable file
File diff suppressed because it is too large
Load diff
614
config.rpath
Executable file
614
config.rpath
Executable file
|
@ -0,0 +1,614 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# Output a system dependent set of variables, describing how to set the
|
||||||
|
# run time search path of shared libraries in an executable.
|
||||||
|
#
|
||||||
|
# Copyright 1996-2006 Free Software Foundation, Inc.
|
||||||
|
# Taken from GNU libtool, 2001
|
||||||
|
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
|
||||||
|
#
|
||||||
|
# This file is free software; the Free Software Foundation gives
|
||||||
|
# unlimited permission to copy and/or distribute it, with or without
|
||||||
|
# modifications, as long as this notice is preserved.
|
||||||
|
#
|
||||||
|
# The first argument passed to this file is the canonical host specification,
|
||||||
|
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
|
||||||
|
# or
|
||||||
|
# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
|
||||||
|
# The environment variables CC, GCC, LDFLAGS, LD, with_gnu_ld
|
||||||
|
# should be set by the caller.
|
||||||
|
#
|
||||||
|
# The set of defined variables is at the end of this script.
|
||||||
|
|
||||||
|
# Known limitations:
|
||||||
|
# - On IRIX 6.5 with CC="cc", the run time search patch must not be longer
|
||||||
|
# than 256 bytes, otherwise the compiler driver will dump core. The only
|
||||||
|
# known workaround is to choose shorter directory names for the build
|
||||||
|
# directory and/or the installation directory.
|
||||||
|
|
||||||
|
# All known linkers require a `.a' archive for static linking (except MSVC,
|
||||||
|
# which needs '.lib').
|
||||||
|
libext=a
|
||||||
|
shrext=.so
|
||||||
|
|
||||||
|
host="$1"
|
||||||
|
host_cpu=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
|
||||||
|
host_vendor=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
|
||||||
|
host_os=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
|
||||||
|
|
||||||
|
# Code taken from libtool.m4's _LT_CC_BASENAME.
|
||||||
|
|
||||||
|
for cc_temp in $CC""; do
|
||||||
|
case $cc_temp in
|
||||||
|
compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
|
||||||
|
distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
|
||||||
|
\-*) ;;
|
||||||
|
*) break;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
cc_basename=`echo "$cc_temp" | sed -e 's%^.*/%%'`
|
||||||
|
|
||||||
|
# Code taken from libtool.m4's AC_LIBTOOL_PROG_COMPILER_PIC.
|
||||||
|
|
||||||
|
wl=
|
||||||
|
if test "$GCC" = yes; then
|
||||||
|
wl='-Wl,'
|
||||||
|
else
|
||||||
|
case "$host_os" in
|
||||||
|
aix*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
darwin*)
|
||||||
|
case $cc_basename in
|
||||||
|
xlc*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
mingw* | pw32* | os2*)
|
||||||
|
;;
|
||||||
|
hpux9* | hpux10* | hpux11*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
irix5* | irix6* | nonstopux*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
newsos6)
|
||||||
|
;;
|
||||||
|
linux*)
|
||||||
|
case $cc_basename in
|
||||||
|
icc* | ecc*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
pgcc | pgf77 | pgf90)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
ccc*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
como)
|
||||||
|
wl='-lopt='
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
case `$CC -V 2>&1 | sed 5q` in
|
||||||
|
*Sun\ C*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
osf3* | osf4* | osf5*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
sco3.2v5*)
|
||||||
|
;;
|
||||||
|
solaris*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
sunos4*)
|
||||||
|
wl='-Qoption ld '
|
||||||
|
;;
|
||||||
|
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
sysv4*MP*)
|
||||||
|
;;
|
||||||
|
unicos*)
|
||||||
|
wl='-Wl,'
|
||||||
|
;;
|
||||||
|
uts4*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Code taken from libtool.m4's AC_LIBTOOL_PROG_LD_SHLIBS.
|
||||||
|
|
||||||
|
hardcode_libdir_flag_spec=
|
||||||
|
hardcode_libdir_separator=
|
||||||
|
hardcode_direct=no
|
||||||
|
hardcode_minus_L=no
|
||||||
|
|
||||||
|
case "$host_os" in
|
||||||
|
cygwin* | mingw* | pw32*)
|
||||||
|
# FIXME: the MSVC++ port hasn't been tested in a loooong time
|
||||||
|
# When not using gcc, we currently assume that we are using
|
||||||
|
# Microsoft Visual C++.
|
||||||
|
if test "$GCC" != yes; then
|
||||||
|
with_gnu_ld=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
interix*)
|
||||||
|
# we just hope/assume this is gcc and not c89 (= MSVC++)
|
||||||
|
with_gnu_ld=yes
|
||||||
|
;;
|
||||||
|
openbsd*)
|
||||||
|
with_gnu_ld=no
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
ld_shlibs=yes
|
||||||
|
if test "$with_gnu_ld" = yes; then
|
||||||
|
# Set some defaults for GNU ld with shared library support. These
|
||||||
|
# are reset later if shared libraries are not supported. Putting them
|
||||||
|
# here allows them to be overridden if necessary.
|
||||||
|
# Unlike libtool, we use -rpath here, not --rpath, since the documented
|
||||||
|
# option of GNU ld is called -rpath, not --rpath.
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
||||||
|
case "$host_os" in
|
||||||
|
aix3* | aix4* | aix5*)
|
||||||
|
# On AIX/PPC, the GNU linker is very broken
|
||||||
|
if test "$host_cpu" != ia64; then
|
||||||
|
ld_shlibs=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
amigaos*)
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
|
||||||
|
# that the semantics of dynamic libraries on AmigaOS, at least up
|
||||||
|
# to version 4, is to share data among multiple programs linked
|
||||||
|
# with the same dynamic library. Since this doesn't match the
|
||||||
|
# behavior of shared libraries on other platforms, we cannot use
|
||||||
|
# them.
|
||||||
|
ld_shlibs=no
|
||||||
|
;;
|
||||||
|
beos*)
|
||||||
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
ld_shlibs=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
cygwin* | mingw* | pw32*)
|
||||||
|
# hardcode_libdir_flag_spec is actually meaningless, as there is
|
||||||
|
# no search path for DLLs.
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
ld_shlibs=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
interix3*)
|
||||||
|
hardcode_direct=no
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
||||||
|
;;
|
||||||
|
linux*)
|
||||||
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
ld_shlibs=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
netbsd*)
|
||||||
|
;;
|
||||||
|
solaris*)
|
||||||
|
if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
|
||||||
|
ld_shlibs=no
|
||||||
|
elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
ld_shlibs=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
|
||||||
|
case `$LD -v 2>&1` in
|
||||||
|
*\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
|
||||||
|
ld_shlibs=no
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
||||||
|
hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
|
||||||
|
else
|
||||||
|
ld_shlibs=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
sunos4*)
|
||||||
|
hardcode_direct=yes
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
ld_shlibs=no
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
if test "$ld_shlibs" = no; then
|
||||||
|
hardcode_libdir_flag_spec=
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
case "$host_os" in
|
||||||
|
aix3*)
|
||||||
|
# Note: this linker hardcodes the directories in LIBPATH if there
|
||||||
|
# are no directories specified by -L.
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
if test "$GCC" = yes; then
|
||||||
|
# Neither direct hardcoding nor static linking is supported with a
|
||||||
|
# broken collect2.
|
||||||
|
hardcode_direct=unsupported
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
aix4* | aix5*)
|
||||||
|
if test "$host_cpu" = ia64; then
|
||||||
|
# On IA64, the linker does run time linking by default, so we don't
|
||||||
|
# have to do anything special.
|
||||||
|
aix_use_runtimelinking=no
|
||||||
|
else
|
||||||
|
aix_use_runtimelinking=no
|
||||||
|
# Test if we are trying to use run time linking or normal
|
||||||
|
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
|
||||||
|
# need to do runtime linking.
|
||||||
|
case $host_os in aix4.[23]|aix4.[23].*|aix5*)
|
||||||
|
for ld_flag in $LDFLAGS; do
|
||||||
|
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
|
||||||
|
aix_use_runtimelinking=yes
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
hardcode_direct=yes
|
||||||
|
hardcode_libdir_separator=':'
|
||||||
|
if test "$GCC" = yes; then
|
||||||
|
case $host_os in aix4.[012]|aix4.[012].*)
|
||||||
|
collect2name=`${CC} -print-prog-name=collect2`
|
||||||
|
if test -f "$collect2name" && \
|
||||||
|
strings "$collect2name" | grep resolve_lib_name >/dev/null
|
||||||
|
then
|
||||||
|
# We have reworked collect2
|
||||||
|
hardcode_direct=yes
|
||||||
|
else
|
||||||
|
# We have old collect2
|
||||||
|
hardcode_direct=unsupported
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
hardcode_libdir_separator=
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
# Begin _LT_AC_SYS_LIBPATH_AIX.
|
||||||
|
echo 'int main () { return 0; }' > conftest.c
|
||||||
|
${CC} ${LDFLAGS} conftest.c -o conftest
|
||||||
|
aix_libpath=`dump -H conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
|
||||||
|
}'`
|
||||||
|
if test -z "$aix_libpath"; then
|
||||||
|
aix_libpath=`dump -HX64 conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
|
||||||
|
}'`
|
||||||
|
fi
|
||||||
|
if test -z "$aix_libpath"; then
|
||||||
|
aix_libpath="/usr/lib:/lib"
|
||||||
|
fi
|
||||||
|
rm -f conftest.c conftest
|
||||||
|
# End _LT_AC_SYS_LIBPATH_AIX.
|
||||||
|
if test "$aix_use_runtimelinking" = yes; then
|
||||||
|
hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
|
||||||
|
else
|
||||||
|
if test "$host_cpu" = ia64; then
|
||||||
|
hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
|
||||||
|
else
|
||||||
|
hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
amigaos*)
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
# see comment about different semantics on the GNU ld section
|
||||||
|
ld_shlibs=no
|
||||||
|
;;
|
||||||
|
bsdi[45]*)
|
||||||
|
;;
|
||||||
|
cygwin* | mingw* | pw32*)
|
||||||
|
# When not using gcc, we currently assume that we are using
|
||||||
|
# Microsoft Visual C++.
|
||||||
|
# hardcode_libdir_flag_spec is actually meaningless, as there is
|
||||||
|
# no search path for DLLs.
|
||||||
|
hardcode_libdir_flag_spec=' '
|
||||||
|
libext=lib
|
||||||
|
;;
|
||||||
|
darwin* | rhapsody*)
|
||||||
|
hardcode_direct=no
|
||||||
|
if test "$GCC" = yes ; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
case $cc_basename in
|
||||||
|
xlc*)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
ld_shlibs=no
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
dgux*)
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
;;
|
||||||
|
freebsd1*)
|
||||||
|
ld_shlibs=no
|
||||||
|
;;
|
||||||
|
freebsd2.2*)
|
||||||
|
hardcode_libdir_flag_spec='-R$libdir'
|
||||||
|
hardcode_direct=yes
|
||||||
|
;;
|
||||||
|
freebsd2*)
|
||||||
|
hardcode_direct=yes
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
;;
|
||||||
|
freebsd* | kfreebsd*-gnu | dragonfly*)
|
||||||
|
hardcode_libdir_flag_spec='-R$libdir'
|
||||||
|
hardcode_direct=yes
|
||||||
|
;;
|
||||||
|
hpux9*)
|
||||||
|
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
|
||||||
|
hardcode_libdir_separator=:
|
||||||
|
hardcode_direct=yes
|
||||||
|
# hardcode_minus_L: Not really in the search PATH,
|
||||||
|
# but as the default location of the library.
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
;;
|
||||||
|
hpux10*)
|
||||||
|
if test "$with_gnu_ld" = no; then
|
||||||
|
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
|
||||||
|
hardcode_libdir_separator=:
|
||||||
|
hardcode_direct=yes
|
||||||
|
# hardcode_minus_L: Not really in the search PATH,
|
||||||
|
# but as the default location of the library.
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
hpux11*)
|
||||||
|
if test "$with_gnu_ld" = no; then
|
||||||
|
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
|
||||||
|
hardcode_libdir_separator=:
|
||||||
|
case $host_cpu in
|
||||||
|
hppa*64*|ia64*)
|
||||||
|
hardcode_direct=no
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
hardcode_direct=yes
|
||||||
|
# hardcode_minus_L: Not really in the search PATH,
|
||||||
|
# but as the default location of the library.
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
irix5* | irix6* | nonstopux*)
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
||||||
|
hardcode_libdir_separator=:
|
||||||
|
;;
|
||||||
|
netbsd*)
|
||||||
|
hardcode_libdir_flag_spec='-R$libdir'
|
||||||
|
hardcode_direct=yes
|
||||||
|
;;
|
||||||
|
newsos6)
|
||||||
|
hardcode_direct=yes
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
||||||
|
hardcode_libdir_separator=:
|
||||||
|
;;
|
||||||
|
openbsd*)
|
||||||
|
hardcode_direct=yes
|
||||||
|
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
||||||
|
else
|
||||||
|
case "$host_os" in
|
||||||
|
openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
|
||||||
|
hardcode_libdir_flag_spec='-R$libdir'
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
os2*)
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
;;
|
||||||
|
osf3*)
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
||||||
|
hardcode_libdir_separator=:
|
||||||
|
;;
|
||||||
|
osf4* | osf5*)
|
||||||
|
if test "$GCC" = yes; then
|
||||||
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
||||||
|
else
|
||||||
|
# Both cc and cxx compiler support -rpath directly
|
||||||
|
hardcode_libdir_flag_spec='-rpath $libdir'
|
||||||
|
fi
|
||||||
|
hardcode_libdir_separator=:
|
||||||
|
;;
|
||||||
|
solaris*)
|
||||||
|
hardcode_libdir_flag_spec='-R$libdir'
|
||||||
|
;;
|
||||||
|
sunos4*)
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
hardcode_direct=yes
|
||||||
|
hardcode_minus_L=yes
|
||||||
|
;;
|
||||||
|
sysv4)
|
||||||
|
case $host_vendor in
|
||||||
|
sni)
|
||||||
|
hardcode_direct=yes # is this really true???
|
||||||
|
;;
|
||||||
|
siemens)
|
||||||
|
hardcode_direct=no
|
||||||
|
;;
|
||||||
|
motorola)
|
||||||
|
hardcode_direct=no #Motorola manual says yes, but my tests say they lie
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
sysv4.3*)
|
||||||
|
;;
|
||||||
|
sysv4*MP*)
|
||||||
|
if test -d /usr/nec; then
|
||||||
|
ld_shlibs=yes
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7*)
|
||||||
|
;;
|
||||||
|
sysv5* | sco3.2v5* | sco5v6*)
|
||||||
|
hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
|
||||||
|
hardcode_libdir_separator=':'
|
||||||
|
;;
|
||||||
|
uts4*)
|
||||||
|
hardcode_libdir_flag_spec='-L$libdir'
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
ld_shlibs=no
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Check dynamic linker characteristics
|
||||||
|
# Code taken from libtool.m4's AC_LIBTOOL_SYS_DYNAMIC_LINKER.
|
||||||
|
libname_spec='lib$name'
|
||||||
|
case "$host_os" in
|
||||||
|
aix3*)
|
||||||
|
;;
|
||||||
|
aix4* | aix5*)
|
||||||
|
;;
|
||||||
|
amigaos*)
|
||||||
|
;;
|
||||||
|
beos*)
|
||||||
|
;;
|
||||||
|
bsdi[45]*)
|
||||||
|
;;
|
||||||
|
cygwin* | mingw* | pw32*)
|
||||||
|
shrext=.dll
|
||||||
|
;;
|
||||||
|
darwin* | rhapsody*)
|
||||||
|
shrext=.dylib
|
||||||
|
;;
|
||||||
|
dgux*)
|
||||||
|
;;
|
||||||
|
freebsd1*)
|
||||||
|
;;
|
||||||
|
kfreebsd*-gnu)
|
||||||
|
;;
|
||||||
|
freebsd* | dragonfly*)
|
||||||
|
;;
|
||||||
|
gnu*)
|
||||||
|
;;
|
||||||
|
hpux9* | hpux10* | hpux11*)
|
||||||
|
case $host_cpu in
|
||||||
|
ia64*)
|
||||||
|
shrext=.so
|
||||||
|
;;
|
||||||
|
hppa*64*)
|
||||||
|
shrext=.sl
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
shrext=.sl
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
interix3*)
|
||||||
|
;;
|
||||||
|
irix5* | irix6* | nonstopux*)
|
||||||
|
case "$host_os" in
|
||||||
|
irix5* | nonstopux*)
|
||||||
|
libsuff= shlibsuff=
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
case $LD in
|
||||||
|
*-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= ;;
|
||||||
|
*-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 ;;
|
||||||
|
*-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 ;;
|
||||||
|
*) libsuff= shlibsuff= ;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
linux*oldld* | linux*aout* | linux*coff*)
|
||||||
|
;;
|
||||||
|
linux*)
|
||||||
|
;;
|
||||||
|
knetbsd*-gnu)
|
||||||
|
;;
|
||||||
|
netbsd*)
|
||||||
|
;;
|
||||||
|
newsos6)
|
||||||
|
;;
|
||||||
|
nto-qnx*)
|
||||||
|
;;
|
||||||
|
openbsd*)
|
||||||
|
;;
|
||||||
|
os2*)
|
||||||
|
libname_spec='$name'
|
||||||
|
shrext=.dll
|
||||||
|
;;
|
||||||
|
osf3* | osf4* | osf5*)
|
||||||
|
;;
|
||||||
|
solaris*)
|
||||||
|
;;
|
||||||
|
sunos4*)
|
||||||
|
;;
|
||||||
|
sysv4 | sysv4.3*)
|
||||||
|
;;
|
||||||
|
sysv4*MP*)
|
||||||
|
;;
|
||||||
|
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
|
||||||
|
;;
|
||||||
|
uts4*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
|
||||||
|
escaped_wl=`echo "X$wl" | sed -e 's/^X//' -e "$sed_quote_subst"`
|
||||||
|
shlibext=`echo "$shrext" | sed -e 's,^\.,,'`
|
||||||
|
escaped_hardcode_libdir_flag_spec=`echo "X$hardcode_libdir_flag_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
|
||||||
|
|
||||||
|
LC_ALL=C sed -e 's/^\([a-zA-Z0-9_]*\)=/acl_cv_\1=/' <<EOF
|
||||||
|
|
||||||
|
# How to pass a linker flag through the compiler.
|
||||||
|
wl="$escaped_wl"
|
||||||
|
|
||||||
|
# Static library suffix (normally "a").
|
||||||
|
libext="$libext"
|
||||||
|
|
||||||
|
# Shared library suffix (normally "so").
|
||||||
|
shlibext="$shlibext"
|
||||||
|
|
||||||
|
# Flag to hardcode \$libdir into a binary during linking.
|
||||||
|
# This must work even if \$libdir does not exist.
|
||||||
|
hardcode_libdir_flag_spec="$escaped_hardcode_libdir_flag_spec"
|
||||||
|
|
||||||
|
# Whether we need a single -rpath flag with a separated argument.
|
||||||
|
hardcode_libdir_separator="$hardcode_libdir_separator"
|
||||||
|
|
||||||
|
# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
|
||||||
|
# resulting binary.
|
||||||
|
hardcode_direct="$hardcode_direct"
|
||||||
|
|
||||||
|
# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
|
||||||
|
# resulting binary.
|
||||||
|
hardcode_minus_L="$hardcode_minus_L"
|
||||||
|
|
||||||
|
EOF
|
1622
config.sub
vendored
Executable file
1622
config.sub
vendored
Executable file
File diff suppressed because it is too large
Load diff
225
configure.ac
Normal file
225
configure.ac
Normal file
|
@ -0,0 +1,225 @@
|
||||||
|
ENV_CFLAGS=$CFLAGS
|
||||||
|
CFLAGS=""
|
||||||
|
|
||||||
|
AC_PREREQ(2.59)
|
||||||
|
dnl Update it right before the release since $pkgver_foo are all _post_ release snapshots
|
||||||
|
AC_INIT([Pacman package manager], 3.0.0, [pacman-dev@archlinux.org], [pacman])
|
||||||
|
AC_LANG([C])
|
||||||
|
AC_CONFIG_HEADERS(config.h)
|
||||||
|
AC_CANONICAL_HOST
|
||||||
|
AM_INIT_AUTOMAKE
|
||||||
|
AM_GNU_GETTEXT([external])
|
||||||
|
AM_GNU_GETTEXT_VERSION(0.13.1)
|
||||||
|
|
||||||
|
dnl Define the libalpm version number here
|
||||||
|
LIB_MAJOR_VERSION=1
|
||||||
|
LIB_MINOR_VERSION=0
|
||||||
|
LIB_MICRO_VERSION=0
|
||||||
|
LIB_VERSION=$LIB_MAJOR_VERSION.$LIB_MINOR_VERSION.$LIB_MICRO_VERSION
|
||||||
|
dnl Needed for libtool to create proper shared lib version.
|
||||||
|
dnl This is not completely correct- see
|
||||||
|
dnl http://sourceware.org/autobook/autobook/autobook_91.html for details.
|
||||||
|
LIB_VERSION_INFO=`expr $LIB_MAJOR_VERSION + $LIB_MINOR_VERSION`:$LIB_MICRO_VERSION:$LIB_MINOR_VERSION
|
||||||
|
|
||||||
|
dnl Set subsitution values for version stuff in Makefiles and anywhere else
|
||||||
|
AC_SUBST(LIB_VERSION)
|
||||||
|
AC_SUBST(LIB_VERSION_INFO)
|
||||||
|
|
||||||
|
dnl Put version number in config.h
|
||||||
|
AC_DEFINE_UNQUOTED([LIB_VERSION], ["$LIB_VERSION"], [libalpm version number])
|
||||||
|
|
||||||
|
dnl Configuration files
|
||||||
|
dnl AC_CONFIG_FILES([etc/makepkg.conf] [etc/pacman.conf])
|
||||||
|
|
||||||
|
AC_PROG_CC
|
||||||
|
AC_HEADER_STDC
|
||||||
|
AC_PROG_INSTALL
|
||||||
|
AC_CHECK_FUNCS([strverscmp])
|
||||||
|
AM_PROG_LIBTOOL
|
||||||
|
AM_CONDITIONAL(LINKSTATIC, test "$enable_static" = "yes")
|
||||||
|
|
||||||
|
dnl Help line for doxygen
|
||||||
|
AC_ARG_ENABLE(doxygen,
|
||||||
|
AC_HELP_STRING([--disable-doxygen], [Build API docs via Doxygen]),
|
||||||
|
[wantdoxygen=$enableval], [wantdoxygen=yes])
|
||||||
|
|
||||||
|
dnl Help line for config file
|
||||||
|
AC_ARG_WITH(config-file,
|
||||||
|
AC_HELP_STRING([--with-config-file=path], [Set the location of pacman's config file]),
|
||||||
|
[configfile=$withval], [configfile=/etc/pacman.conf])
|
||||||
|
|
||||||
|
dnl Help line for debug
|
||||||
|
AC_ARG_ENABLE(debug,
|
||||||
|
AC_HELP_STRING([--enable-debug], [Enable debugging support]),
|
||||||
|
[debug=$enableval], [debug=no])
|
||||||
|
|
||||||
|
dnl Help line for fakeroot
|
||||||
|
AC_ARG_ENABLE(fakeroot,
|
||||||
|
AC_HELP_STRING([--disable-fakeroot], [Disable fakeroot proof support]),
|
||||||
|
[fakeroot=$enableval], [fakeroot=yes])
|
||||||
|
|
||||||
|
dnl Host-dependant flags
|
||||||
|
case "${host}" in
|
||||||
|
*-*-cygwin*)
|
||||||
|
ENV_CFLAGS="$ENV_CFLAGS -DCYGWIN"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
dnl Check for architecture
|
||||||
|
case "${host}" in
|
||||||
|
i686-*)
|
||||||
|
CARCH="i686"
|
||||||
|
CARCHFLAGS="i686"
|
||||||
|
ARCHSWITCH="march"
|
||||||
|
;;
|
||||||
|
x86_64-*)
|
||||||
|
CARCH="x86_64"
|
||||||
|
CARCHFLAGS="x86-64"
|
||||||
|
ARCHSWITCH="march"
|
||||||
|
;;
|
||||||
|
ia64-*)
|
||||||
|
CARCH="ia64"
|
||||||
|
CARCHFLAGS="ia64"
|
||||||
|
ARCHSWITCH="march"
|
||||||
|
;;
|
||||||
|
sparc-*)
|
||||||
|
CARCH="sparc"
|
||||||
|
CARCHFLAGS="v9"
|
||||||
|
ARCHSWITCH="mcpu"
|
||||||
|
;;
|
||||||
|
ppc-* | powerpc-*)
|
||||||
|
CARCH="ppc"
|
||||||
|
CARCHFLAGS="750"
|
||||||
|
ARCHSWITCH="mcpu"
|
||||||
|
;;
|
||||||
|
i386-*)
|
||||||
|
CARCH="i386"
|
||||||
|
CARCHFLAGS="i386"
|
||||||
|
ARCHSWITCH="march"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
AC_MSG_ERROR([Your architecture is not supported])
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
dnl Now do some things common to all architectures
|
||||||
|
CHOST="${host}"
|
||||||
|
AC_SUBST(CARCH)
|
||||||
|
AC_SUBST(CARCHFLAGS)
|
||||||
|
AC_SUBST(ARCHSWITCH)
|
||||||
|
AC_SUBST(CHOST)
|
||||||
|
|
||||||
|
dnl Humor lowers blood pressure
|
||||||
|
AC_MSG_CHECKING(your blood pressure)
|
||||||
|
AC_MSG_RESULT([a bit high, but we can proceed])
|
||||||
|
|
||||||
|
dnl Check for doxygen support
|
||||||
|
AC_MSG_CHECKING(for doxygen)
|
||||||
|
if test "x$wantdoxygen" = "xyes" ; then
|
||||||
|
AC_CHECK_PROGS([DOXYGEN], [doxygen])
|
||||||
|
if test $DOXYGEN ; then
|
||||||
|
AC_MSG_RESULT(yes)
|
||||||
|
usedoxygen=yes
|
||||||
|
else
|
||||||
|
AC_MSG_RESULT(no, doxygen missing)
|
||||||
|
usedoxygen=no
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
AC_MSG_RESULT(no, disabled by configure)
|
||||||
|
usedoxygen=no
|
||||||
|
fi
|
||||||
|
AM_CONDITIONAL(HAS_DOXYGEN, test "x$usedoxygen" = "xyes")
|
||||||
|
|
||||||
|
dnl Check for math
|
||||||
|
AC_CHECK_LIB([m], [sqrt], [AC_CHECK_HEADER([math.h], [LIBM='-lm'])])
|
||||||
|
if test -z "$LIBM"; then
|
||||||
|
AC_MSG_ERROR("math library needed to compile pacman!");
|
||||||
|
fi
|
||||||
|
|
||||||
|
dnl Check for libarchive
|
||||||
|
AC_CHECK_LIB([archive], [archive_read_data], [AC_CHECK_HEADER([archive.h], [LIBARCHIVE='-larchive'])])
|
||||||
|
if test -z "$LIBARCHIVE"; then
|
||||||
|
AC_MSG_ERROR("libarchive is needed to compile pacman!");
|
||||||
|
fi
|
||||||
|
|
||||||
|
dnl Check for libdownload
|
||||||
|
AC_CHECK_LIB([download], [downloadParseURL], [AC_CHECK_HEADER([download.h], [LIBDOWNLOAD='-ldownload'])])
|
||||||
|
if test -z "$LIBDOWNLOAD"; then
|
||||||
|
AC_MSG_ERROR("libdownload is needed to compile pacman!");
|
||||||
|
fi
|
||||||
|
|
||||||
|
dnl Set config location
|
||||||
|
AC_MSG_CHECKING(for configuration file name)
|
||||||
|
if test -n "$configfile"; then
|
||||||
|
AC_DEFINE_UNQUOTED([PACCONF], "$configfile", [Location of pacman conf file])
|
||||||
|
AC_MSG_RESULT(["$configfile"])
|
||||||
|
else
|
||||||
|
AC_MSG_ERROR(["pacman config file (--with-config-file is not set"])
|
||||||
|
fi
|
||||||
|
|
||||||
|
dnl Enable or disable debug code
|
||||||
|
AC_MSG_CHECKING(for debug mode request)
|
||||||
|
if test "x$debug" = "xyes" ; then
|
||||||
|
AC_DEFINE([PACMAN_DEBUG], , [Enable debug code])
|
||||||
|
CFLAGS="$CFLAGS -g -Wall -Werror -fstack-protector -std=c99"
|
||||||
|
LDFLAGS="$LDFLAGS -lmcheck"
|
||||||
|
AC_MSG_RESULT(yes)
|
||||||
|
else
|
||||||
|
CFLAGS="$CFLAGS -Wall -std=c99"
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
|
fi
|
||||||
|
|
||||||
|
dnl Enable or disable fakeroot code
|
||||||
|
AC_MSG_CHECKING(for fakeroot proof support)
|
||||||
|
if test "x$fakeroot" = "xyes" ; then
|
||||||
|
AC_MSG_RESULT(yes)
|
||||||
|
else
|
||||||
|
AC_DEFINE([FAKEROOT], , [Disable fakeroot-proof code])
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
|
fi
|
||||||
|
|
||||||
|
dnl Set CFLAGS to both $CFLAGS and ones from env ($ENV_CFLAGS)
|
||||||
|
CFLAGS="$CFLAGS $ENV_CFLAGS"
|
||||||
|
|
||||||
|
dnl ==========================================================================
|
||||||
|
|
||||||
|
AC_OUTPUT([
|
||||||
|
lib/libalpm/Makefile
|
||||||
|
lib/libalpm/po/Makefile.in
|
||||||
|
src/pacman/Makefile
|
||||||
|
src/pacman/po/Makefile.in
|
||||||
|
src/util/Makefile
|
||||||
|
scripts/Makefile
|
||||||
|
doc/Makefile
|
||||||
|
etc/Makefile
|
||||||
|
etc/makepkg.conf
|
||||||
|
etc/pacman.conf
|
||||||
|
etc/pacman.d/Makefile
|
||||||
|
etc/pacman.d/mirrorlist
|
||||||
|
etc/abs/Makefile
|
||||||
|
pactest/Makefile
|
||||||
|
contrib/Makefile
|
||||||
|
Makefile
|
||||||
|
])
|
||||||
|
|
||||||
|
echo "
|
||||||
|
pacman-$VERSION:
|
||||||
|
|
||||||
|
prefix : ${prefix}
|
||||||
|
source code location : ${srcdir}
|
||||||
|
compiler : ${CC}
|
||||||
|
compiler flags : ${CFLAGS}
|
||||||
|
defines : ${DEFS}
|
||||||
|
|
||||||
|
Architecture : ${CARCH}
|
||||||
|
Architecture flags : -${ARCHSWITCH}=${CARCHFLAGS}
|
||||||
|
Host Type : ${CHOST}
|
||||||
|
|
||||||
|
libalpm version : ${LIB_VERSION}
|
||||||
|
pacman version : ${PACKAGE_VERSION}
|
||||||
|
pacman.conf location : ${configfile}
|
||||||
|
|
||||||
|
Doxygen support : ${usedoxygen}
|
||||||
|
debug support : ${debug}
|
||||||
|
fakeroot-proof support : ${fakeroot}
|
||||||
|
"
|
2
contrib/.cvsignore
Normal file
2
contrib/.cvsignore
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
Makefile
|
||||||
|
Makefile.in
|
8
contrib/Makefile.am
Normal file
8
contrib/Makefile.am
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
EXTRA_DIST = \
|
||||||
|
bash_completion \
|
||||||
|
pacsearch \
|
||||||
|
pacdiff \
|
||||||
|
re-pacman \
|
||||||
|
zsh_completion \
|
||||||
|
README
|
||||||
|
|
16
contrib/README
Normal file
16
contrib/README
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
Here is a brief description of the files included in this directory:
|
||||||
|
|
||||||
|
bash_completion - a bash completion script for pacman, install in
|
||||||
|
/etc/bash_completion.d/ for use (but rename to something descriptive!).
|
||||||
|
|
||||||
|
zsh_completion - a zsh completion script, install (with a rename) to
|
||||||
|
/usr/share/zsh/site-functions/.
|
||||||
|
|
||||||
|
pacsearch - a colorized search combining both -Ss and -Qs output. Installed
|
||||||
|
packages are easily identified with a *** and local-only packages are also
|
||||||
|
listed.
|
||||||
|
|
||||||
|
pacdiff - a simple pacnew/pacorig/pacsave updater for /etc/.
|
||||||
|
|
||||||
|
re-pacman - regenerate a pacman package based on installed files and the pacman
|
||||||
|
database entries. Useful for reuse, or possible config file extension.
|
363
contrib/bash_completion
Normal file
363
contrib/bash_completion
Normal file
|
@ -0,0 +1,363 @@
|
||||||
|
# vim: set ft=sh ts=2 sw=2 et:
|
||||||
|
# file: /etc/bash_completion.d/pacman
|
||||||
|
|
||||||
|
# Bash completion for pacman
|
||||||
|
# Original: Manolis Tzanidakis <mtzanidakis@freemail.gr>
|
||||||
|
#
|
||||||
|
# Distributed under the terms of the GNU General Public License, v2 or later.
|
||||||
|
#
|
||||||
|
|
||||||
|
## ChangeLog ##
|
||||||
|
#
|
||||||
|
# * 3.0 (2007-02-18)
|
||||||
|
# - Updated to pacman 3.0.0 options
|
||||||
|
# * 1.1 (2004-01-17)
|
||||||
|
# - Code cleanup
|
||||||
|
# - Updated to pacman 2.7.2-2
|
||||||
|
# * 2004-02-16 (orelien)
|
||||||
|
# - Improved available_{pkgs,groups) functions
|
||||||
|
# - Added support for querying groups
|
||||||
|
#
|
||||||
|
|
||||||
|
## initial functions
|
||||||
|
|
||||||
|
rem_selected ()
|
||||||
|
{
|
||||||
|
# (Adapted from bash_completion by Ian Macdonald <ian@caliban.org>)
|
||||||
|
# This removes any options from the list of completions that have
|
||||||
|
# already been specified on the command line.
|
||||||
|
COMPREPLY=($(echo "${COMP_WORDS[@]}" | \
|
||||||
|
(while read -d ' ' i; do
|
||||||
|
[ "${i}" == "" ] && continue
|
||||||
|
# flatten array with spaces on either side,
|
||||||
|
# otherwise we cannot grep on word boundaries of
|
||||||
|
# first and last word
|
||||||
|
COMPREPLY=" ${COMPREPLY[@]} "
|
||||||
|
# remove word from list of completions
|
||||||
|
COMPREPLY=(${COMPREPLY/ ${i%% *} / })
|
||||||
|
done
|
||||||
|
echo ${COMPREPLY[@]})))
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
_available_repos ()
|
||||||
|
{
|
||||||
|
COMPREPLY=( $( compgen -W "$(grep '\[' /etc/pacman.conf | grep -v -e 'options' -e '^#' | tr -d '[]' )" -- $cur ) )
|
||||||
|
}
|
||||||
|
|
||||||
|
_installed_pkgs ()
|
||||||
|
{
|
||||||
|
local installed_pkgs
|
||||||
|
installed_pkgs=$( ls /var/lib/pacman/local/ )
|
||||||
|
COMPREPLY=( $( compgen -W "$( for i in $installed_pkgs; do echo ${i%-*-*}; done )" -- $cur ) )
|
||||||
|
}
|
||||||
|
|
||||||
|
_available_pkgs ()
|
||||||
|
{
|
||||||
|
#find balks easilly on a find /foo/*/* type dir, especially one like
|
||||||
|
# /var/lib/pacman/*/*
|
||||||
|
# This little change-up removes the find *and* only uses enabled repos
|
||||||
|
local available_pkgs
|
||||||
|
local enabled_repos
|
||||||
|
enabled_repos=$( grep '\[' /etc/pacman.conf | grep -v -e 'options' -e '^#' | tr -d '[]' )
|
||||||
|
available_pkgs=$( for r in $enabled_repos; do echo /var/lib/pacman/$r/*; done )
|
||||||
|
COMPREPLY=( $( compgen -W "$( for i in $available_pkgs; do j=${i##*/}; echo ${j%-*-*}; done )" -- $cur ) )
|
||||||
|
}
|
||||||
|
|
||||||
|
_installed_groups ()
|
||||||
|
{
|
||||||
|
local installed_groups
|
||||||
|
installed_groups=$( find /var/lib/pacman/local -name desc -exec sed -ne '/%GROUPS%/,/^$/{//d; p}' {} \; | sort -u )
|
||||||
|
COMPREPLY=( $( compgen -W "$( for i in $installed_groups; do echo ${i%-*-*}; done )" -- $cur ) )
|
||||||
|
}
|
||||||
|
|
||||||
|
_available_groups ()
|
||||||
|
{
|
||||||
|
#find balks easilly on a find /foo/*/* type dir, especially one like
|
||||||
|
# /var/lib/pacman/*/*
|
||||||
|
# This little change-up removes the find *and* only uses enabled repos
|
||||||
|
local available_groups
|
||||||
|
local enabled_repos
|
||||||
|
enabled_repos=$( grep '\[' /etc/pacman.conf | grep -v -e 'options' -e '^#' | tr -d '[]' )
|
||||||
|
available_groups=$( for r in $enabled_repos; do sed '/%GROUPS%/,/^$/{//d; p}' /var/lib/pacman/$r/*/desc | sort -u; done )
|
||||||
|
COMPREPLY=( $( compgen -W "$( for i in $available_groups; do echo ${i%-*-*}; done )" -- $cur ) )
|
||||||
|
}
|
||||||
|
|
||||||
|
## makepkg completion
|
||||||
|
|
||||||
|
_makepkg ()
|
||||||
|
{
|
||||||
|
local cur prev
|
||||||
|
COMPREPLY=()
|
||||||
|
cur=${COMP_WORDS[COMP_CWORD]}
|
||||||
|
prev=${COMP_WORDS[COMP_CWORD-1]}
|
||||||
|
|
||||||
|
case "$prev" in
|
||||||
|
-p)
|
||||||
|
_filedir
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
--help|--cleancache)
|
||||||
|
COMPREPLY=''
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ "$cur" == -* ]]; then
|
||||||
|
COMPREPLY=( $( compgen -W '\
|
||||||
|
-b --builddeps \
|
||||||
|
-B --noccache \
|
||||||
|
-c --clean \
|
||||||
|
-C --cleancache \
|
||||||
|
-d --nodeps \
|
||||||
|
-e --noextract \
|
||||||
|
-f --force \
|
||||||
|
-g --geninteg \
|
||||||
|
-h --help \
|
||||||
|
-i --install \
|
||||||
|
-j \
|
||||||
|
-L --log \
|
||||||
|
-m --nocolor \
|
||||||
|
-o --nobuild \
|
||||||
|
-p \
|
||||||
|
-r --rmdeps \
|
||||||
|
-s --syncdeps \
|
||||||
|
-S --usesudo \
|
||||||
|
--noconfirm \
|
||||||
|
--noprogressbar' -- $cur ) )
|
||||||
|
fi
|
||||||
|
|
||||||
|
rem_selected
|
||||||
|
}
|
||||||
|
complete -o default -F _makepkg makepkg
|
||||||
|
|
||||||
|
## pacman completion
|
||||||
|
|
||||||
|
_instring ()
|
||||||
|
{
|
||||||
|
str="${1}"
|
||||||
|
shift 1
|
||||||
|
for c in "${@}"; do
|
||||||
|
if [ $(expr index "${str}" "${c}") -gt 0 ]; then
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
_pacman ()
|
||||||
|
{
|
||||||
|
local a arg toparse op mod cur
|
||||||
|
COMPREPLY=()
|
||||||
|
|
||||||
|
# This argument parsing is done so we can check for flag existance later
|
||||||
|
# right now it's a tad crappy, but does the job
|
||||||
|
for (( i=1; i < ${#COMP_WORDS[@]}-1; i++ )); do
|
||||||
|
a=${COMP_WORDS[i]}
|
||||||
|
arg="${a:0:2}"
|
||||||
|
toparse="${a:2}"
|
||||||
|
|
||||||
|
case "${arg}" in
|
||||||
|
-@(A|U|F|R|S|Q|h|V))
|
||||||
|
op="${arg/-}"
|
||||||
|
mod="${mod}${a:2}"
|
||||||
|
;;
|
||||||
|
--)
|
||||||
|
arg="${a:2}"
|
||||||
|
case "${arg}" in
|
||||||
|
add) op="A" ;;
|
||||||
|
remove) op="R" ;;
|
||||||
|
upgrade) op="U" ;;
|
||||||
|
freshen) op="F" ;;
|
||||||
|
query) op="Q" ;;
|
||||||
|
sync) op="S" ;;
|
||||||
|
help) op="h" ;;
|
||||||
|
version) op="V" ;;
|
||||||
|
verbose) mod="${mod}v" ;;
|
||||||
|
root) mod="${mod}r" ;;
|
||||||
|
dbpath) mod="${mod}b" ;;
|
||||||
|
nodeps) mod="${mod}d" ;;
|
||||||
|
force) mod="${mod}f" ;;
|
||||||
|
groups) mod="${mod}g" ;;
|
||||||
|
info) mod="${mod}i" ;;
|
||||||
|
list) mod="${mod}l" ;;
|
||||||
|
print-uris) mod="${mod}p" ;;
|
||||||
|
search) mod="${mod}s" ;;
|
||||||
|
sysupgrade) mod="${mod}u" ;;
|
||||||
|
downloadonly) mod="${mod}w" ;;
|
||||||
|
refresh) mod="${mod}y" ;;
|
||||||
|
orphans) mod="${mod}e" ;;
|
||||||
|
foreign) mod="${mod}m" ;;
|
||||||
|
owns) mod="${mod}o" ;;
|
||||||
|
file) mod="${mod}p" ;;
|
||||||
|
search) mod="${mod}s" ;;
|
||||||
|
cascade) mod="${mod}c" ;;
|
||||||
|
nodeps) mod="${mod}d" ;;
|
||||||
|
dbonly) mod="${mod}k" ;;
|
||||||
|
nosave) mod="${mod}n" ;;
|
||||||
|
recursive) mod="${mod}s" ;;
|
||||||
|
esac ;;
|
||||||
|
*) toparse="${a}" ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
arglen=$(( ${#toparse}-1 ))
|
||||||
|
for c in $(seq 0 "${arglen}"); do
|
||||||
|
arg=${toparse:$c:1}
|
||||||
|
[ "${arg}" != "-" ] && mod="${mod}${arg}"
|
||||||
|
done
|
||||||
|
done
|
||||||
|
|
||||||
|
cur=${COMP_WORDS[COMP_CWORD]}
|
||||||
|
|
||||||
|
if [ $COMP_CWORD -eq 1 ] && [[ "$cur" == -* ]]; then
|
||||||
|
COMPREPLY=( $( compgen -W '\
|
||||||
|
-A --add \
|
||||||
|
-F --freshen \
|
||||||
|
-h --help \
|
||||||
|
-Q --query \
|
||||||
|
-R --remove \
|
||||||
|
-S --sync \
|
||||||
|
-U --upgrade \
|
||||||
|
-V --version \
|
||||||
|
' -- $cur ) )
|
||||||
|
rem_selected
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$cur" == -* ]]; then
|
||||||
|
case "${op}" in
|
||||||
|
A|U|F)
|
||||||
|
COMPREPLY=( $( compgen -W '\
|
||||||
|
-d --nodeps \
|
||||||
|
-f --force \
|
||||||
|
-h --help \
|
||||||
|
--config \
|
||||||
|
--noconfirm \
|
||||||
|
--ask \
|
||||||
|
--noprogressbar \
|
||||||
|
--noscriptlet \
|
||||||
|
-v --verbose \
|
||||||
|
-r --root \
|
||||||
|
-b --dbpath \
|
||||||
|
--cachedir \
|
||||||
|
' -- $cur ) )
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
R)
|
||||||
|
COMPREPLY=( $( compgen -W '\
|
||||||
|
-c --cascade \
|
||||||
|
-d --nodeps \
|
||||||
|
-f --force \
|
||||||
|
-h --help \
|
||||||
|
-k --dbonly \
|
||||||
|
-n --nosave \
|
||||||
|
-s --recursive \
|
||||||
|
--config \
|
||||||
|
--noconfirm \
|
||||||
|
--ask \
|
||||||
|
--noprogressbar \
|
||||||
|
--noscriptlet \
|
||||||
|
-v --verbose \
|
||||||
|
-r --root \
|
||||||
|
-b --dbpath \
|
||||||
|
--cachedir \
|
||||||
|
' -- $cur ) )
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
S)
|
||||||
|
COMPREPLY=( $( compgen -W '\
|
||||||
|
-c --clean \
|
||||||
|
-d --nodeps \
|
||||||
|
-e --dependsonly \
|
||||||
|
-f --force \
|
||||||
|
-g --groups \
|
||||||
|
-h --help \
|
||||||
|
-i --info \
|
||||||
|
-l --list \
|
||||||
|
-p --print-uris \
|
||||||
|
-s --search \
|
||||||
|
-u --sysupgrade \
|
||||||
|
-w --downloadonly \
|
||||||
|
-y --refresh \
|
||||||
|
--ignore \
|
||||||
|
--config \
|
||||||
|
--noconfirm \
|
||||||
|
--ask \
|
||||||
|
--noprogressbar \
|
||||||
|
--noscriptlet \
|
||||||
|
-v --verbose \
|
||||||
|
-r --root \
|
||||||
|
-b --dbpath \
|
||||||
|
--cachedir \
|
||||||
|
' -- $cur ) )
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
Q)
|
||||||
|
COMPREPLY=( $( compgen -W '\
|
||||||
|
-c --changelog \
|
||||||
|
-e --orphans \
|
||||||
|
-g --groups \
|
||||||
|
-h --help \
|
||||||
|
-i --info \
|
||||||
|
-l --list \
|
||||||
|
-m --foreign \
|
||||||
|
-o --owns \
|
||||||
|
-p --file \
|
||||||
|
-s --search \
|
||||||
|
--config \
|
||||||
|
--noconfirm \
|
||||||
|
--ask \
|
||||||
|
--noprogressbar \
|
||||||
|
--noscriptlet \
|
||||||
|
-v --verbose \
|
||||||
|
-r --root \
|
||||||
|
-b --dbpath \
|
||||||
|
--cachedir \
|
||||||
|
' -- $cur ) )
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
rem_selected
|
||||||
|
else
|
||||||
|
case "${op}" in
|
||||||
|
A|U)
|
||||||
|
COMPREPLY=( $( compgen -d -- "$cur" ) \
|
||||||
|
$( compgen -f -X '!*.pkg.tar.gz' -- "$cur" ) )
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
h|V)
|
||||||
|
COMPREPLY=''
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
Q)
|
||||||
|
if _instring $mod g; then
|
||||||
|
_installed_groups
|
||||||
|
elif _instring $mod o; then
|
||||||
|
COMPREPLY=( $( compgen -d -- "$cur" ) \
|
||||||
|
$( compgen -f -- "$cur" ) )
|
||||||
|
elif _instring $mod p; then
|
||||||
|
COMPREPLY=( $( compgen -d -- "$cur" ) \
|
||||||
|
$( compgen -f -X '!*.pkg.tar.gz' -- "$cur" ) )
|
||||||
|
else
|
||||||
|
_installed_pkgs
|
||||||
|
fi
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
R)
|
||||||
|
_installed_pkgs
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
S)
|
||||||
|
if _instring $mod l; then
|
||||||
|
_available_repos
|
||||||
|
else
|
||||||
|
_available_pkgs
|
||||||
|
fi
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
|
rem_selected
|
||||||
|
}
|
||||||
|
complete -o filenames -F _pacman pacman
|
47
contrib/pacdiff
Normal file
47
contrib/pacdiff
Normal file
|
@ -0,0 +1,47 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# pacdiff : a simple pacnew/pacorig/pacsave updater for /etc/
|
||||||
|
#
|
||||||
|
# Copyright (c) 2007 Aaron Griffin <aaronmgriffin@gmail.com>
|
||||||
|
#
|
||||||
|
# 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
|
||||||
|
# USA.
|
||||||
|
#
|
||||||
|
|
||||||
|
# Original http://phraktured.net/config/bin/pacdiff
|
||||||
|
|
||||||
|
diffprog=${DIFFPROG:-vimdiff}
|
||||||
|
for x in $(find /etc/ -name *.pacnew -o -name *.pacorig -o -name *.pacsave)
|
||||||
|
do
|
||||||
|
echo "File: ${x%.pac*}"
|
||||||
|
chk="$(cmp $x ${x%.pac*})"
|
||||||
|
if [ -z "${chk}" ]; then
|
||||||
|
echo " Files are identical, removing..."
|
||||||
|
rm $x
|
||||||
|
else
|
||||||
|
echo -n " File differences found. (V)iew, (S)kip, (R)emove: [v/s/r] "
|
||||||
|
read c
|
||||||
|
c="$(echo $c| tr A-Z a-z)" #tolower
|
||||||
|
if [ "$c" = "r" ]; then
|
||||||
|
rm $x
|
||||||
|
elif [ "$c" = "s" ]; then
|
||||||
|
continue
|
||||||
|
else
|
||||||
|
[ "$c" = "n" -o "$c" = "N" ] || $diffprog $x ${x%.pac*}
|
||||||
|
echo -n " Remove file? [Y/n] "
|
||||||
|
read c
|
||||||
|
[ "$c" = "n" -o "$c" = "N" ] || rm $x
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
done
|
90
contrib/pacsearch
Executable file
90
contrib/pacsearch
Executable file
|
@ -0,0 +1,90 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# pacsearch - Adds color and install information to a 'pacman -Ss' search
|
||||||
|
#
|
||||||
|
# Copyright (C) 2006-2007 Dan McGee <dpmcgee@gmail.com>
|
||||||
|
#
|
||||||
|
# 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
|
||||||
|
|
||||||
|
#TODO: colors flag on commandline
|
||||||
|
|
||||||
|
readonly progname="pacsearch"
|
||||||
|
readonly version="1.0"
|
||||||
|
|
||||||
|
readonly CLR1='\\\e[0;34m'
|
||||||
|
readonly CLR2='\\\e[0;32m'
|
||||||
|
readonly CLR3='\\\e[0;35m'
|
||||||
|
readonly CLR4='\\\e[0;36m'
|
||||||
|
readonly CLR5='\\\e[0;31m'
|
||||||
|
readonly CLR6='\\\e[0;33m'
|
||||||
|
readonly CLR7='\\\e[1;36m'
|
||||||
|
readonly INST='\\\e[1;31m'
|
||||||
|
readonly BASE='\\\e[0m'
|
||||||
|
|
||||||
|
if [ "$1" = "--help" -o "$1" = "-h" ]; then
|
||||||
|
echo "Usage: $progname <pattern>"
|
||||||
|
echo "Ex: $progname ^gnome"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "--version" -o "$1" = "-v" ]; then
|
||||||
|
echo "$progname version $version"
|
||||||
|
echo "Copyright (C) 2006-2007 Dan McGee"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "$1" -o "${1:0:1}" = "-" ]; then
|
||||||
|
echo "Usage: $progname <pattern>"
|
||||||
|
echo "Ex: $progname ^gnome"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Make two temp files and send output of commands to these files
|
||||||
|
querydump=$(mktemp)
|
||||||
|
pacman -Qs $1 > $querydump
|
||||||
|
syncdump=$(mktemp)
|
||||||
|
pacman -Ss $1 > $syncdump
|
||||||
|
|
||||||
|
# Strip descriptions and 'local/' from -Qs query
|
||||||
|
instpkg=$(mktemp)
|
||||||
|
egrep '^[^ ]' $querydump | sed -e 's@^local/@@' > $instpkg
|
||||||
|
|
||||||
|
# Add pkgs not in sync db, mark pkgs that are installed
|
||||||
|
cat $instpkg | while read -r pkg; do
|
||||||
|
if [ -z "$(grep "$pkg" $syncdump)" ]; then
|
||||||
|
# grep package name; pipe to another grep that prints at most one
|
||||||
|
# line starting with 'local/', allows for comments >1 line
|
||||||
|
grep -A10 "$pkg" $querydump | grep -A10 -m1 "local/" >> $syncdump
|
||||||
|
fi
|
||||||
|
sed -i "s@^\(.\+/$pkg\)@\***\1@" $syncdump
|
||||||
|
done
|
||||||
|
|
||||||
|
# Print colorized package list and descriptions to screen
|
||||||
|
echo -e "$(sed -r \
|
||||||
|
-e "s@current/.*@$CLR1&$BASE@" \
|
||||||
|
-e "s@extra/.*@$CLR2&$BASE@" \
|
||||||
|
-e "s@community/.*@$CLR3&$BASE@" \
|
||||||
|
-e "s@testing/.*@$CLR4&$BASE@" \
|
||||||
|
-e "s@unstable/.*@$CLR5&$BASE@" \
|
||||||
|
-e "s@custom/.*@$CLR6&$BASE@" \
|
||||||
|
-e "s@local/.*@$CLR7&$BASE@" \
|
||||||
|
-e "s@(^|\*\*\*)([[:alnum:]]*/.* .*)@\1$CLR6\2$BASE@" \
|
||||||
|
-e "s@\*\*\*@$INST&@" \
|
||||||
|
< $syncdump )"
|
||||||
|
echo -en "\e[0m"
|
||||||
|
|
||||||
|
rm $querydump
|
||||||
|
rm $syncdump
|
||||||
|
rm $instpkg
|
||||||
|
|
79
contrib/re-pacman
Executable file
79
contrib/re-pacman
Executable file
|
@ -0,0 +1,79 @@
|
||||||
|
#!/bin/sh
|
||||||
|
#
|
||||||
|
# re-pacman: regenerate a pacman package based on installed files and the
|
||||||
|
# pacman database entries. Useful for reuse, or possible config file
|
||||||
|
# extension
|
||||||
|
#
|
||||||
|
# Copyright (c) 2006 Aaron Griffin <aaron@archlinux.org>
|
||||||
|
#
|
||||||
|
# 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
|
||||||
|
# USA.
|
||||||
|
#
|
||||||
|
|
||||||
|
#TODO
|
||||||
|
# * Check for md5 changes in backup lines and change pkgrel
|
||||||
|
|
||||||
|
pacinfo () {
|
||||||
|
[ $# -ne 2 ] && return 1
|
||||||
|
#use echo to strip spaces
|
||||||
|
echo $(pacman -Qi ${1} | grep "${2}" | cut -d: -f2-)
|
||||||
|
}
|
||||||
|
|
||||||
|
make_pkginfo () {
|
||||||
|
echo "# Generated by re-pacman 1.0.0"
|
||||||
|
echo "# On $(date)"
|
||||||
|
echo "pkgname =$(pacinfo ${1} Name)"
|
||||||
|
echo "pkgver =$(pacinfo ${1} Version)"
|
||||||
|
echo "pkgdesc =$(pacinfo ${1} Description)"
|
||||||
|
echo "url =$(pacinfo ${1} URL)"
|
||||||
|
echo "builddate =$(pacinfo ${1} 'Build Date')"
|
||||||
|
echo "packager =$(pacinfo ${1} Packager)"
|
||||||
|
echo "size =$(pacinfo ${1} Size)"
|
||||||
|
echo "arch =$(pacinfo ${1} Architecture)"
|
||||||
|
deps=$(pacinfo ${1} 'Depends On')
|
||||||
|
for d in ${deps}; do
|
||||||
|
echo "depend = ${d}"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ $# -ne 1 ]; then
|
||||||
|
echo "usage: re-pacman <installed package name>"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
ver=$(pacinfo ${1} Version)
|
||||||
|
if [ "x${ver}" = "x" ]; then
|
||||||
|
echo "Package '${1}' not found, aborting."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo ":: Cleaning up old files"
|
||||||
|
rm -f .PKGINFO .FILELIST "${1}-${ver}.pkg.tar.gz"
|
||||||
|
|
||||||
|
echo ":: Building PKGINFO"
|
||||||
|
make_pkginfo ${1} > .PKGINFO
|
||||||
|
echo ":: Building FILELIST"
|
||||||
|
pacman -Ql ${1} | cut -d' ' -f2- > .FILELIST
|
||||||
|
|
||||||
|
flist=".PKGINFO .FILELIST"
|
||||||
|
flist="${flist} $(pacman -Ql ${1} | sed 's|\w* \(.*\)|/\1|g' | grep -v '/$')"
|
||||||
|
|
||||||
|
echo ":: Building final package tarball"
|
||||||
|
echo ${flist} | tr ' ' '\n' | tar czf "${1}-${ver}.pkg.tar.gz" -T - 2>/dev/null
|
||||||
|
|
||||||
|
rm -f .PKGINFO .FILELIST
|
||||||
|
echo ":: Package '${1}-${ver}.pkg.tar.gz' is now ready for installation"
|
||||||
|
|
||||||
|
# vim: set ts=2 sw=2 noet:
|
101
contrib/vimproject
Normal file
101
contrib/vimproject
Normal file
|
@ -0,0 +1,101 @@
|
||||||
|
This is a project file for the vim-project
|
||||||
|
plugin. I like it, so decided to contribute
|
||||||
|
this to the main repo.
|
||||||
|
$ pacman -S vim-project
|
||||||
|
change the pacman= path below
|
||||||
|
$ vim
|
||||||
|
:Project vimproject
|
||||||
|
|
||||||
|
pacman=~/devel/pacman-lib CD=. flags=S {
|
||||||
|
Makefile.am
|
||||||
|
configure.ac
|
||||||
|
libalpm=lib/libalpm/ filter="*.c *.h *.am"{
|
||||||
|
add.c
|
||||||
|
alpm.c
|
||||||
|
alpm_list.c
|
||||||
|
backup.c
|
||||||
|
be_files.c
|
||||||
|
cache.c
|
||||||
|
conflict.c
|
||||||
|
db.c
|
||||||
|
deps.c
|
||||||
|
error.c
|
||||||
|
group.c
|
||||||
|
handle.c
|
||||||
|
log.c
|
||||||
|
md5.c
|
||||||
|
md5driver.c
|
||||||
|
package.c
|
||||||
|
provide.c
|
||||||
|
remove.c
|
||||||
|
server.c
|
||||||
|
sha1.c
|
||||||
|
sync.c
|
||||||
|
trans.c
|
||||||
|
util.c
|
||||||
|
versioncmp.c
|
||||||
|
add.h
|
||||||
|
alpm.h
|
||||||
|
alpm_list.h
|
||||||
|
backup.h
|
||||||
|
cache.h
|
||||||
|
conflict.h
|
||||||
|
db.h
|
||||||
|
deps.h
|
||||||
|
error.h
|
||||||
|
group.h
|
||||||
|
handle.h
|
||||||
|
log.h
|
||||||
|
md5.h
|
||||||
|
package.h
|
||||||
|
provide.h
|
||||||
|
remove.h
|
||||||
|
server.h
|
||||||
|
sha1.h
|
||||||
|
sync.h
|
||||||
|
trans.h
|
||||||
|
util.h
|
||||||
|
versioncmp.h
|
||||||
|
Makefile.am
|
||||||
|
Makefile.in
|
||||||
|
}
|
||||||
|
pacman=src/pacman/ filter="*.c *.h *.am" {
|
||||||
|
add.c
|
||||||
|
conf.c
|
||||||
|
deptest.c
|
||||||
|
downloadprog.c
|
||||||
|
log.c
|
||||||
|
package.c
|
||||||
|
pacman.c
|
||||||
|
query.c
|
||||||
|
remove.c
|
||||||
|
sync.c
|
||||||
|
trans.c
|
||||||
|
upgrade.c
|
||||||
|
util.c
|
||||||
|
add.h
|
||||||
|
conf.h
|
||||||
|
deptest.h
|
||||||
|
downloadprog.h
|
||||||
|
log.h
|
||||||
|
package.h
|
||||||
|
query.h
|
||||||
|
remove.h
|
||||||
|
sync.h
|
||||||
|
trans.h
|
||||||
|
upgrade.h
|
||||||
|
util.h
|
||||||
|
Makefile.am
|
||||||
|
}
|
||||||
|
utils=src/util filter="*.c *.h *.am" {
|
||||||
|
testpkg.c
|
||||||
|
vercmp.c
|
||||||
|
Makefile.am
|
||||||
|
}
|
||||||
|
contrib=contrib CD=. {
|
||||||
|
bash_completion
|
||||||
|
pacsearch
|
||||||
|
vimproject
|
||||||
|
zsh_completion
|
||||||
|
}
|
||||||
|
}
|
320
contrib/zsh_completion
Normal file
320
contrib/zsh_completion
Normal file
|
@ -0,0 +1,320 @@
|
||||||
|
# file: /usr/share/zsh/site-functions/_pacman
|
||||||
|
# use the following in your zsh config:
|
||||||
|
# compdef pacman pacman.static=pacman
|
||||||
|
|
||||||
|
typeset -A opt_args
|
||||||
|
|
||||||
|
# options for passing to _arguments: main pacman commands
|
||||||
|
_pacman_opts_commands=(
|
||||||
|
'-A[Add a package to the system]'
|
||||||
|
'-F[Upgrade an installed package]'
|
||||||
|
'-Q[Query the package database]'
|
||||||
|
'-R[Remove a package from the system]'
|
||||||
|
'-S[Synchronize packages]'
|
||||||
|
'-U[Upgrade a package]'
|
||||||
|
'-V[Display version and exit]'
|
||||||
|
'-h[Display usage]'
|
||||||
|
)
|
||||||
|
|
||||||
|
# options for passing to _arguments: options common to all commands
|
||||||
|
_pacman_opts_common=(
|
||||||
|
'-b[Alternate database location]:database_location:_files -/'
|
||||||
|
'-h[Display syntax for the given operation]'
|
||||||
|
'-r[Set alternate installation root]:installation root:_files -/'
|
||||||
|
'-v[Be more verbose]'
|
||||||
|
'--config[An alternate configuration file]:config file:_files'
|
||||||
|
'--noconfirm[Do not ask for confirmation]'
|
||||||
|
)
|
||||||
|
|
||||||
|
# options for passing to _arguments: options for --add, --freshen and --update commands
|
||||||
|
_pacman_opts_pkgfile=(
|
||||||
|
'-d[Skip dependency checks]'
|
||||||
|
'-f[Overwrite conflicting files]'
|
||||||
|
'*:package file:_files -g "*.pkg.tar.gz(.)"'
|
||||||
|
)
|
||||||
|
|
||||||
|
# options for passing to _arguments: subactions for --query command
|
||||||
|
_pacman_opts_query_actions=(
|
||||||
|
'-e[List orphaned packages]:*:orphans:->query_orphans'
|
||||||
|
'-g[View all members of a package group]:*:package groups:->query_group'
|
||||||
|
'-o[Query the package that owns a file]:file:_files'
|
||||||
|
'-p[Package file to query]:*:package file:->query_file'
|
||||||
|
'-s[Search package names and descriptions]:*:search text:->query_search'
|
||||||
|
)
|
||||||
|
|
||||||
|
# options for passing to _arguments: options for --query and subcommands
|
||||||
|
_pacman_opts_query_modifiers=(
|
||||||
|
'-i[View package information]'
|
||||||
|
'-l[List package contents]'
|
||||||
|
)
|
||||||
|
|
||||||
|
# options for passing to _arguments: options for --remove command
|
||||||
|
_pacman_opts_remove=(
|
||||||
|
'-c[Remove all dependent packages]'
|
||||||
|
'-d[Skip dependency checks]'
|
||||||
|
'-k[Only remove database entry, do not remove files]'
|
||||||
|
'-n[Remove protected configuration files]'
|
||||||
|
'-s[Remove dependencies not required by other packages]'
|
||||||
|
'*:installed package:_pacman_completions_installed_packages'
|
||||||
|
)
|
||||||
|
|
||||||
|
# options for passing to _arguments: options for --sync command
|
||||||
|
_pacman_opts_sync_actions=(
|
||||||
|
'*-c[Remove old packages from cache]:*:clean:->sync_clean'
|
||||||
|
'-g[View all members of a package group]:*:package groups:->sync_group'
|
||||||
|
'-s[Search package names and descriptions]:*:search text:->sync_search'
|
||||||
|
)
|
||||||
|
|
||||||
|
# options for passing to _arguments: options for --sync command
|
||||||
|
_pacman_opts_sync_modifiers=(
|
||||||
|
'-d[Skip dependency checks]'
|
||||||
|
'-f[Overwrite conflicting files]'
|
||||||
|
'-i[View package information]'
|
||||||
|
'-l[List all packages in a repository]'
|
||||||
|
'-p[Print download URIs for each package to be installed]'
|
||||||
|
'-u[Upgrade all out-of-date packages]'
|
||||||
|
'-w[Download packages only]'
|
||||||
|
'-y[Download fresh package databases]'
|
||||||
|
'*--ignore[Ignore a package upgrade]:package:_pacman_completions_installed_packages'
|
||||||
|
)
|
||||||
|
|
||||||
|
# handles --action subcommand
|
||||||
|
_pacman_action_add() {
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_pkgfile[@]"
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles --freshen subcommand
|
||||||
|
_pacman_action_freshen() {
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_pkgfile[@]"
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles --help subcommand
|
||||||
|
_pacman_action_help() {
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_commands[@]"
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles cases where no subcommand has yet been given
|
||||||
|
_pacman_action_none() {
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_commands[@]"
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles --query subcommand
|
||||||
|
_pacman_action_query() {
|
||||||
|
local context state line
|
||||||
|
typeset -A opt_args
|
||||||
|
|
||||||
|
# _arguments -s : \
|
||||||
|
# "$_pacman_opts_common[@]" \
|
||||||
|
# "$_pacman_opts_query_actions[@]" \
|
||||||
|
# "$_pacman_opts_query_modifiers[@]"
|
||||||
|
|
||||||
|
case $state in
|
||||||
|
query_file)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:package file:_files -g "*.pkg.tar.gz"'
|
||||||
|
;;
|
||||||
|
query_group)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:groups:_pacman_completions_installed_groups'
|
||||||
|
;;
|
||||||
|
query_orphans)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]"
|
||||||
|
;;
|
||||||
|
query_owner)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:file:_files'
|
||||||
|
;;
|
||||||
|
query_search)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:search text: '
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_actions[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:package:_pacman_completions_installed_packages'
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles --remove subcommand
|
||||||
|
_pacman_action_remove() {
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_remove[@]"
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles --sync subcommand
|
||||||
|
_pacman_action_sync() {
|
||||||
|
local context state line
|
||||||
|
typeset -A opt_args
|
||||||
|
|
||||||
|
# _arguments -s : \
|
||||||
|
# "$_pacman_opts_common[@]" \
|
||||||
|
# "$_pacman_opts_sync_actions[@]" #\
|
||||||
|
# #"$_pacman_opts_sync_modifiers[@]"
|
||||||
|
|
||||||
|
case $state in
|
||||||
|
sync_clean)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_sync_modifiers[@]" \
|
||||||
|
'*-c[Remove old packages from cache]' \
|
||||||
|
;;
|
||||||
|
sync_group)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_sync_modifiers[@]" \
|
||||||
|
'*:package group:_pacman_completions_all_groups'
|
||||||
|
;;
|
||||||
|
sync_search)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_sync_modifiers[@]" \
|
||||||
|
'*:search text: '
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_sync_modifiers[@]" \
|
||||||
|
'*:package:_pacman_completions_all_packages'
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles --upgrade subcommand
|
||||||
|
_pacman_action_upgrade() {
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_pkgfile[@]"
|
||||||
|
}
|
||||||
|
|
||||||
|
# handles --version subcommand
|
||||||
|
_pacman_action_version() {
|
||||||
|
# no further arguments
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
# provides completions for package groups
|
||||||
|
_pacman_completions_all_groups() {
|
||||||
|
local -a cmd groups
|
||||||
|
_pacman_get_command
|
||||||
|
groups=( $(_call_program groups $cmd[@] -Sg | grep -e \^$PREFIX) )
|
||||||
|
compadd "$@" -a groups
|
||||||
|
}
|
||||||
|
|
||||||
|
# provides completions for packages available from repositories
|
||||||
|
_pacman_completions_all_packages() {
|
||||||
|
local -a cmd packages repositories
|
||||||
|
|
||||||
|
repositories=( $(_call_program repositories cat /etc/pacman.conf | grep "^\[" | sed "s,\(\[\|\]\),,g" | grep -v "^options" | sort -u) )
|
||||||
|
# these can be specified as either 'package' or 'repository/package'
|
||||||
|
if [[ "$PREFIX" == "" ]] ; then
|
||||||
|
packages=( $(_call_program packages ls /var/lib/pacman/${^repositories} | grep -v "^/" | sed "s,\-[^-]*\-[^-]*$,," | sort -u) )
|
||||||
|
else
|
||||||
|
packages=( $(_call_program packages ls /var/lib/pacman/${^repositories} | grep -v "^/" | grep -e \^$PREFIX | sed "s,\-[^-]*\-[^-]*$,," | sort -u) )
|
||||||
|
fi
|
||||||
|
compadd "$@" -a packages
|
||||||
|
}
|
||||||
|
|
||||||
|
# provides completions for package groups
|
||||||
|
_pacman_completions_installed_groups() {
|
||||||
|
local -a cmd groups
|
||||||
|
_pacman_get_command
|
||||||
|
groups=( $(_call_program installed_groups $cmd[@] -Qg | cut -d' ' -f1 | grep -e \^$PREFIX | sort -u) )
|
||||||
|
compadd "$@" -a groups
|
||||||
|
}
|
||||||
|
|
||||||
|
# provides completions for installed packages
|
||||||
|
_pacman_completions_installed_packages() {
|
||||||
|
local -a cmd packages
|
||||||
|
packages=( $(_call_program installed_packages ls /var/lib/pacman/local | grep "^$PREFIX" | sed "s,\-[^-]*\-[^-]*$,,") )
|
||||||
|
compadd "$@" -a packages
|
||||||
|
}
|
||||||
|
|
||||||
|
# provides completions for repository names
|
||||||
|
_pacman_completions_repositories() {
|
||||||
|
local -a cmd repositories
|
||||||
|
repositories=( $(_call_program repositories cat /etc/pacman.conf | grep "^\[" | sed "s,\(\[\|\]\),,g" | grep -v "^options" | grep "^$PREFIX" | sort -u) )
|
||||||
|
compadd "$@" -a repositories
|
||||||
|
}
|
||||||
|
|
||||||
|
# builds command for invoking pacman in a _call_program command - extracts
|
||||||
|
# relevant options already specified (config file, etc)
|
||||||
|
# $cmd must be declared by calling function
|
||||||
|
_pacman_get_command() {
|
||||||
|
# this is mostly nicked from _perforce
|
||||||
|
cmd=( "pacman" )
|
||||||
|
integer i
|
||||||
|
for (( i = 2; i < CURRENT - 1; i++ )); do
|
||||||
|
if [[ ${words[i]} = "--config" || ${words[i]} = "--root" ]]; then
|
||||||
|
cmd+=( ${words[i,i+1]} )
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
# main dispatcher
|
||||||
|
_pacman() {
|
||||||
|
case $words[2] in
|
||||||
|
-A*) _pacman_action_add ;;
|
||||||
|
-F*) _pacman_action_freshen ;;
|
||||||
|
-Qg) # ipkg groups
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:groups:_pacman_completions_installed_groups'
|
||||||
|
;;
|
||||||
|
-Qo) # file *.pkg.tar.gz
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:package file:_files'
|
||||||
|
;;
|
||||||
|
-Qp) # file *.pkg.tar.gz
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_query_modifiers[@]" \
|
||||||
|
'*:package file:_files -g "*.pkg.tar.gz"'
|
||||||
|
;;
|
||||||
|
-Q*) _pacman_action_query ;;
|
||||||
|
-R*) _pacman_action_remove ;;
|
||||||
|
-Sl) # repos
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_sync_modifiers[@]" \
|
||||||
|
'*:package repo:_pacman_completions_repositories' \
|
||||||
|
;;
|
||||||
|
-Sg) # pkg groups
|
||||||
|
_arguments -s : \
|
||||||
|
"$_pacman_opts_common[@]" \
|
||||||
|
"$_pacman_opts_sync_modifiers[@]" \
|
||||||
|
'*:package group:_pacman_completions_all_groups'
|
||||||
|
;;
|
||||||
|
-S*) _pacman_action_sync ;;
|
||||||
|
-U*) _pacman_action_upgrade ;;
|
||||||
|
-V*) _pacman_action_version ;;
|
||||||
|
-h*) _pacman_action_help ;;
|
||||||
|
- ) _pacman_action_none ;;
|
||||||
|
* ) return 1 ;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
# run the main dispatcher
|
||||||
|
_pacman "$@"
|
584
depcomp
Executable file
584
depcomp
Executable file
|
@ -0,0 +1,584 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# depcomp - compile a program generating dependencies as side-effects
|
||||||
|
|
||||||
|
scriptversion=2006-10-15.18
|
||||||
|
|
||||||
|
# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006 Free Software
|
||||||
|
# Foundation, Inc.
|
||||||
|
|
||||||
|
# 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, 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.
|
||||||
|
|
||||||
|
# As a special exception to the GNU General Public License, if you
|
||||||
|
# distribute this file as part of a program that contains a
|
||||||
|
# configuration script generated by Autoconf, you may include it under
|
||||||
|
# the same distribution terms that you use for the rest of that program.
|
||||||
|
|
||||||
|
# Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>.
|
||||||
|
|
||||||
|
case $1 in
|
||||||
|
'')
|
||||||
|
echo "$0: No command. Try \`$0 --help' for more information." 1>&2
|
||||||
|
exit 1;
|
||||||
|
;;
|
||||||
|
-h | --h*)
|
||||||
|
cat <<\EOF
|
||||||
|
Usage: depcomp [--help] [--version] PROGRAM [ARGS]
|
||||||
|
|
||||||
|
Run PROGRAMS ARGS to compile a file, generating dependencies
|
||||||
|
as side-effects.
|
||||||
|
|
||||||
|
Environment variables:
|
||||||
|
depmode Dependency tracking mode.
|
||||||
|
source Source file read by `PROGRAMS ARGS'.
|
||||||
|
object Object file output by `PROGRAMS ARGS'.
|
||||||
|
DEPDIR directory where to store dependencies.
|
||||||
|
depfile Dependency file to output.
|
||||||
|
tmpdepfile Temporary file to use when outputing dependencies.
|
||||||
|
libtool Whether libtool is used (yes/no).
|
||||||
|
|
||||||
|
Report bugs to <bug-automake@gnu.org>.
|
||||||
|
EOF
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
-v | --v*)
|
||||||
|
echo "depcomp $scriptversion"
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if test -z "$depmode" || test -z "$source" || test -z "$object"; then
|
||||||
|
echo "depcomp: Variables source, object and depmode must be set" 1>&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po.
|
||||||
|
depfile=${depfile-`echo "$object" |
|
||||||
|
sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`}
|
||||||
|
tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
|
||||||
|
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
|
||||||
|
# Some modes work just like other modes, but use different flags. We
|
||||||
|
# parameterize here, but still list the modes in the big case below,
|
||||||
|
# to make depend.m4 easier to write. Note that we *cannot* use a case
|
||||||
|
# here, because this file can only contain one case statement.
|
||||||
|
if test "$depmode" = hp; then
|
||||||
|
# HP compiler uses -M and no extra arg.
|
||||||
|
gccflag=-M
|
||||||
|
depmode=gcc
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "$depmode" = dashXmstdout; then
|
||||||
|
# This is just like dashmstdout with a different argument.
|
||||||
|
dashmflag=-xM
|
||||||
|
depmode=dashmstdout
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "$depmode" in
|
||||||
|
gcc3)
|
||||||
|
## gcc 3 implements dependency tracking that does exactly what
|
||||||
|
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
|
||||||
|
## it if -MD -MP comes after the -MF stuff. Hmm.
|
||||||
|
## Unfortunately, FreeBSD c89 acceptance of flags depends upon
|
||||||
|
## the command line argument order; so add the flags where they
|
||||||
|
## appear in depend2.am. Note that the slowdown incurred here
|
||||||
|
## affects only configure: in makefiles, %FASTDEP% shortcuts this.
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
case $arg in
|
||||||
|
-c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;;
|
||||||
|
*) set fnord "$@" "$arg" ;;
|
||||||
|
esac
|
||||||
|
shift # fnord
|
||||||
|
shift # $arg
|
||||||
|
done
|
||||||
|
"$@"
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
mv "$tmpdepfile" "$depfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
gcc)
|
||||||
|
## There are various ways to get dependency output from gcc. Here's
|
||||||
|
## why we pick this rather obscure method:
|
||||||
|
## - Don't want to use -MD because we'd like the dependencies to end
|
||||||
|
## up in a subdir. Having to rename by hand is ugly.
|
||||||
|
## (We might end up doing this anyway to support other compilers.)
|
||||||
|
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
|
||||||
|
## -MM, not -M (despite what the docs say).
|
||||||
|
## - Using -M directly means running the compiler twice (even worse
|
||||||
|
## than renaming).
|
||||||
|
if test -z "$gccflag"; then
|
||||||
|
gccflag=-MD,
|
||||||
|
fi
|
||||||
|
"$@" -Wp,"$gccflag$tmpdepfile"
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
rm -f "$depfile"
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
|
||||||
|
## The second -e expression handles DOS-style file names with drive letters.
|
||||||
|
sed -e 's/^[^:]*: / /' \
|
||||||
|
-e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
|
||||||
|
## This next piece of magic avoids the `deleted header file' problem.
|
||||||
|
## The problem is that when a header file which appears in a .P file
|
||||||
|
## is deleted, the dependency causes make to die (because there is
|
||||||
|
## typically no way to rebuild the header). We avoid this by adding
|
||||||
|
## dummy dependencies for each header file. Too bad gcc doesn't do
|
||||||
|
## this for us directly.
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" |
|
||||||
|
## Some versions of gcc put a space before the `:'. On the theory
|
||||||
|
## that the space means something, we add a space to the output as
|
||||||
|
## well.
|
||||||
|
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
## correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
hp)
|
||||||
|
# This case exists only to let depend.m4 do its work. It works by
|
||||||
|
# looking at the text of this script. This case will never be run,
|
||||||
|
# since it is checked for above.
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
|
||||||
|
sgi)
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
"$@" "-Wp,-MDupdate,$tmpdepfile"
|
||||||
|
else
|
||||||
|
"$@" -MDupdate "$tmpdepfile"
|
||||||
|
fi
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
rm -f "$depfile"
|
||||||
|
|
||||||
|
if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
|
||||||
|
# Clip off the initial element (the dependent). Don't try to be
|
||||||
|
# clever and replace this with sed code, as IRIX sed won't handle
|
||||||
|
# lines with more than a fixed number of characters (4096 in
|
||||||
|
# IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
|
||||||
|
# the IRIX cc adds comments like `#:fec' to the end of the
|
||||||
|
# dependency line.
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" \
|
||||||
|
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
|
||||||
|
tr '
|
||||||
|
' ' ' >> $depfile
|
||||||
|
echo >> $depfile
|
||||||
|
|
||||||
|
# The second pass generates a dummy entry for each header file.
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" \
|
||||||
|
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
|
||||||
|
>> $depfile
|
||||||
|
else
|
||||||
|
# The sourcefile does not contain any dependencies, so just
|
||||||
|
# store a dummy comment line, to avoid errors with the Makefile
|
||||||
|
# "include basename.Plo" scheme.
|
||||||
|
echo "#dummy" > "$depfile"
|
||||||
|
fi
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
aix)
|
||||||
|
# The C for AIX Compiler uses -M and outputs the dependencies
|
||||||
|
# in a .u file. In older versions, this file always lives in the
|
||||||
|
# current directory. Also, the AIX compiler puts `$object:' at the
|
||||||
|
# start of each line; $object doesn't have directory information.
|
||||||
|
# Version 6 uses the directory in both cases.
|
||||||
|
stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'`
|
||||||
|
tmpdepfile="$stripped.u"
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
"$@" -Wc,-M
|
||||||
|
else
|
||||||
|
"$@" -M
|
||||||
|
fi
|
||||||
|
stat=$?
|
||||||
|
|
||||||
|
if test -f "$tmpdepfile"; then :
|
||||||
|
else
|
||||||
|
stripped=`echo "$stripped" | sed 's,^.*/,,'`
|
||||||
|
tmpdepfile="$stripped.u"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test -f "$tmpdepfile"; then
|
||||||
|
outname="$stripped.o"
|
||||||
|
# Each line is of the form `foo.o: dependent.h'.
|
||||||
|
# Do two passes, one to just change these to
|
||||||
|
# `$object: dependent.h' and one to simply `dependent.h:'.
|
||||||
|
sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile"
|
||||||
|
sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile"
|
||||||
|
else
|
||||||
|
# The sourcefile does not contain any dependencies, so just
|
||||||
|
# store a dummy comment line, to avoid errors with the Makefile
|
||||||
|
# "include basename.Plo" scheme.
|
||||||
|
echo "#dummy" > "$depfile"
|
||||||
|
fi
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
icc)
|
||||||
|
# Intel's C compiler understands `-MD -MF file'. However on
|
||||||
|
# icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c
|
||||||
|
# ICC 7.0 will fill foo.d with something like
|
||||||
|
# foo.o: sub/foo.c
|
||||||
|
# foo.o: sub/foo.h
|
||||||
|
# which is wrong. We want:
|
||||||
|
# sub/foo.o: sub/foo.c
|
||||||
|
# sub/foo.o: sub/foo.h
|
||||||
|
# sub/foo.c:
|
||||||
|
# sub/foo.h:
|
||||||
|
# ICC 7.1 will output
|
||||||
|
# foo.o: sub/foo.c sub/foo.h
|
||||||
|
# and will wrap long lines using \ :
|
||||||
|
# foo.o: sub/foo.c ... \
|
||||||
|
# sub/foo.h ... \
|
||||||
|
# ...
|
||||||
|
|
||||||
|
"$@" -MD -MF "$tmpdepfile"
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
rm -f "$depfile"
|
||||||
|
# Each line is of the form `foo.o: dependent.h',
|
||||||
|
# or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
|
||||||
|
# Do two passes, one to just change these to
|
||||||
|
# `$object: dependent.h' and one to simply `dependent.h:'.
|
||||||
|
sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
|
||||||
|
# Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
# correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" |
|
||||||
|
sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
hp2)
|
||||||
|
# The "hp" stanza above does not work with aCC (C++) and HP's ia64
|
||||||
|
# compilers, which have integrated preprocessors. The correct option
|
||||||
|
# to use with these is +Maked; it writes dependencies to a file named
|
||||||
|
# 'foo.d', which lands next to the object file, wherever that
|
||||||
|
# happens to be.
|
||||||
|
# Much of this is similar to the tru64 case; see comments there.
|
||||||
|
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
|
||||||
|
test "x$dir" = "x$object" && dir=
|
||||||
|
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
tmpdepfile1=$dir$base.d
|
||||||
|
tmpdepfile2=$dir.libs/$base.d
|
||||||
|
"$@" -Wc,+Maked
|
||||||
|
else
|
||||||
|
tmpdepfile1=$dir$base.d
|
||||||
|
tmpdepfile2=$dir$base.d
|
||||||
|
"$@" +Maked
|
||||||
|
fi
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile1" "$tmpdepfile2"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
|
||||||
|
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2"
|
||||||
|
do
|
||||||
|
test -f "$tmpdepfile" && break
|
||||||
|
done
|
||||||
|
if test -f "$tmpdepfile"; then
|
||||||
|
sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile"
|
||||||
|
# Add `dependent.h:' lines.
|
||||||
|
sed -ne '2,${; s/^ *//; s/ \\*$//; s/$/:/; p;}' "$tmpdepfile" >> "$depfile"
|
||||||
|
else
|
||||||
|
echo "#dummy" > "$depfile"
|
||||||
|
fi
|
||||||
|
rm -f "$tmpdepfile" "$tmpdepfile2"
|
||||||
|
;;
|
||||||
|
|
||||||
|
tru64)
|
||||||
|
# The Tru64 compiler uses -MD to generate dependencies as a side
|
||||||
|
# effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'.
|
||||||
|
# At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
|
||||||
|
# dependencies in `foo.d' instead, so we check for that too.
|
||||||
|
# Subdirectories are respected.
|
||||||
|
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
|
||||||
|
test "x$dir" = "x$object" && dir=
|
||||||
|
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
|
||||||
|
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
# With Tru64 cc, shared objects can also be used to make a
|
||||||
|
# static library. This mechanism is used in libtool 1.4 series to
|
||||||
|
# handle both shared and static libraries in a single compilation.
|
||||||
|
# With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d.
|
||||||
|
#
|
||||||
|
# With libtool 1.5 this exception was removed, and libtool now
|
||||||
|
# generates 2 separate objects for the 2 libraries. These two
|
||||||
|
# compilations output dependencies in $dir.libs/$base.o.d and
|
||||||
|
# in $dir$base.o.d. We have to check for both files, because
|
||||||
|
# one of the two compilations can be disabled. We should prefer
|
||||||
|
# $dir$base.o.d over $dir.libs/$base.o.d because the latter is
|
||||||
|
# automatically cleaned when .libs/ is deleted, while ignoring
|
||||||
|
# the former would cause a distcleancheck panic.
|
||||||
|
tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4
|
||||||
|
tmpdepfile2=$dir$base.o.d # libtool 1.5
|
||||||
|
tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5
|
||||||
|
tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504
|
||||||
|
"$@" -Wc,-MD
|
||||||
|
else
|
||||||
|
tmpdepfile1=$dir$base.o.d
|
||||||
|
tmpdepfile2=$dir$base.d
|
||||||
|
tmpdepfile3=$dir$base.d
|
||||||
|
tmpdepfile4=$dir$base.d
|
||||||
|
"$@" -MD
|
||||||
|
fi
|
||||||
|
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
|
||||||
|
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
|
||||||
|
do
|
||||||
|
test -f "$tmpdepfile" && break
|
||||||
|
done
|
||||||
|
if test -f "$tmpdepfile"; then
|
||||||
|
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
|
||||||
|
# That's a tab and a space in the [].
|
||||||
|
sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
|
||||||
|
else
|
||||||
|
echo "#dummy" > "$depfile"
|
||||||
|
fi
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
#nosideeffect)
|
||||||
|
# This comment above is used by automake to tell side-effect
|
||||||
|
# dependency tracking mechanisms from slower ones.
|
||||||
|
|
||||||
|
dashmstdout)
|
||||||
|
# Important note: in order to support this mode, a compiler *must*
|
||||||
|
# always write the preprocessed file to stdout, regardless of -o.
|
||||||
|
"$@" || exit $?
|
||||||
|
|
||||||
|
# Remove the call to Libtool.
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
while test $1 != '--mode=compile'; do
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Remove `-o $object'.
|
||||||
|
IFS=" "
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
case $arg in
|
||||||
|
-o)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
$object)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"
|
||||||
|
shift # fnord
|
||||||
|
shift # $arg
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
test -z "$dashmflag" && dashmflag=-M
|
||||||
|
# Require at least two characters before searching for `:'
|
||||||
|
# in the target name. This is to cope with DOS-style filenames:
|
||||||
|
# a dependency such as `c:/foo/bar' could be seen as target `c' otherwise.
|
||||||
|
"$@" $dashmflag |
|
||||||
|
sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile"
|
||||||
|
rm -f "$depfile"
|
||||||
|
cat < "$tmpdepfile" > "$depfile"
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" | \
|
||||||
|
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
## correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
dashXmstdout)
|
||||||
|
# This case only exists to satisfy depend.m4. It is never actually
|
||||||
|
# run, as this mode is specially recognized in the preamble.
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
|
||||||
|
makedepend)
|
||||||
|
"$@" || exit $?
|
||||||
|
# Remove any Libtool call
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
while test $1 != '--mode=compile'; do
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
# X makedepend
|
||||||
|
shift
|
||||||
|
cleared=no
|
||||||
|
for arg in "$@"; do
|
||||||
|
case $cleared in
|
||||||
|
no)
|
||||||
|
set ""; shift
|
||||||
|
cleared=yes ;;
|
||||||
|
esac
|
||||||
|
case "$arg" in
|
||||||
|
-D*|-I*)
|
||||||
|
set fnord "$@" "$arg"; shift ;;
|
||||||
|
# Strip any option that makedepend may not understand. Remove
|
||||||
|
# the object too, otherwise makedepend will parse it as a source file.
|
||||||
|
-*|$object)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"; shift ;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
obj_suffix="`echo $object | sed 's/^.*\././'`"
|
||||||
|
touch "$tmpdepfile"
|
||||||
|
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
|
||||||
|
rm -f "$depfile"
|
||||||
|
cat < "$tmpdepfile" > "$depfile"
|
||||||
|
sed '1,2d' "$tmpdepfile" | tr ' ' '
|
||||||
|
' | \
|
||||||
|
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
## correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile" "$tmpdepfile".bak
|
||||||
|
;;
|
||||||
|
|
||||||
|
cpp)
|
||||||
|
# Important note: in order to support this mode, a compiler *must*
|
||||||
|
# always write the preprocessed file to stdout.
|
||||||
|
"$@" || exit $?
|
||||||
|
|
||||||
|
# Remove the call to Libtool.
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
while test $1 != '--mode=compile'; do
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Remove `-o $object'.
|
||||||
|
IFS=" "
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
case $arg in
|
||||||
|
-o)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
$object)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"
|
||||||
|
shift # fnord
|
||||||
|
shift # $arg
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
"$@" -E |
|
||||||
|
sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
|
||||||
|
-e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' |
|
||||||
|
sed '$ s: \\$::' > "$tmpdepfile"
|
||||||
|
rm -f "$depfile"
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
cat < "$tmpdepfile" >> "$depfile"
|
||||||
|
sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
msvisualcpp)
|
||||||
|
# Important note: in order to support this mode, a compiler *must*
|
||||||
|
# always write the preprocessed file to stdout, regardless of -o,
|
||||||
|
# because we must use -o when running libtool.
|
||||||
|
"$@" || exit $?
|
||||||
|
IFS=" "
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
case "$arg" in
|
||||||
|
"-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
|
||||||
|
set fnord "$@"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
"$@" -E |
|
||||||
|
sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile"
|
||||||
|
rm -f "$depfile"
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile"
|
||||||
|
echo " " >> "$depfile"
|
||||||
|
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
none)
|
||||||
|
exec "$@"
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
|
echo "Unknown depmode $depmode" 1>&2
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
|
||||||
|
# Local Variables:
|
||||||
|
# mode: shell-script
|
||||||
|
# sh-indentation: 2
|
||||||
|
# eval: (add-hook 'write-file-hooks 'time-stamp)
|
||||||
|
# time-stamp-start: "scriptversion="
|
||||||
|
# time-stamp-format: "%:y-%02m-%02d.%02H"
|
||||||
|
# time-stamp-end: "$"
|
||||||
|
# End:
|
4
doc/.cvsignore
Normal file
4
doc/.cvsignore
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
Makefile
|
||||||
|
Makefile.in
|
||||||
|
*.html
|
||||||
|
man3
|
9
doc/.gitignore
vendored
9
doc/.gitignore
vendored
|
@ -1,9 +0,0 @@
|
||||||
*.[1-8]
|
|
||||||
asciidoc-manpage.css
|
|
||||||
asciidoc.css
|
|
||||||
asciidoc.js
|
|
||||||
*.html
|
|
||||||
*.xml
|
|
||||||
man3
|
|
||||||
website.tar.gz
|
|
||||||
Doxyfile
|
|
|
@ -1,79 +0,0 @@
|
||||||
BUILDINFO(5)
|
|
||||||
============
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
BUILDINFO - Makepkg package build information file
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
This manual page describes the format of a BUILDINFO file found in the root of
|
|
||||||
a package created by makepkg. The file contains a description of the package's
|
|
||||||
build environment. The information is formatted in key-value pairs separated by
|
|
||||||
a '=', one value per line. Arrays are represented as multiple key-value pairs
|
|
||||||
having the same key.
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
|
|
||||||
This is a description of the contents of version '2' of the
|
|
||||||
BUILDINFO file format.
|
|
||||||
|
|
||||||
*format*::
|
|
||||||
Denotes the file format version, represented by a plain positive integer.
|
|
||||||
|
|
||||||
*pkgname*::
|
|
||||||
The name of the package.
|
|
||||||
|
|
||||||
*pkgbase*::
|
|
||||||
|
|
||||||
The base name of a package, usually the same as the pkgname except for
|
|
||||||
split packages.
|
|
||||||
|
|
||||||
*pkgver*::
|
|
||||||
The version of the package including pkgrel and epoch.
|
|
||||||
|
|
||||||
*pkgarch*::
|
|
||||||
The architecture of the package.
|
|
||||||
|
|
||||||
*pkgbuild_sha256sum*::
|
|
||||||
The sha256sum in hex format of the PKGBUILD used to build the package.
|
|
||||||
|
|
||||||
*packager*::
|
|
||||||
The details of the packager that built the package.
|
|
||||||
|
|
||||||
*builddate*::
|
|
||||||
The build date of the package in epoch.
|
|
||||||
|
|
||||||
*builddir*::
|
|
||||||
The directory where the package was built.
|
|
||||||
|
|
||||||
*startdir*::
|
|
||||||
The directory from which makepkg was executed.
|
|
||||||
|
|
||||||
*buildtool*::
|
|
||||||
The name of the tool ecosystem used to set up the build environment. Used
|
|
||||||
for defining a spec for reproducible builds, e.g. the source of the
|
|
||||||
linkman:makepkg.conf[5] used.
|
|
||||||
|
|
||||||
*buildtoolver*::
|
|
||||||
The full version of the 'buildtool', for example:
|
|
||||||
"$pkgver-$pkgrel-$pkgarch".
|
|
||||||
|
|
||||||
*buildenv (array)*::
|
|
||||||
The build environment specified in makepkg.conf.
|
|
||||||
|
|
||||||
*options (array)*::
|
|
||||||
The options set specified when building the package.
|
|
||||||
|
|
||||||
*installed (array)*::
|
|
||||||
The installed packages at build time including the version information of
|
|
||||||
the package. Formatted as "$pkgname-$pkgver-$pkgrel-$pkgarch".
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:makepkg[8], linkman:pacman[8], linkman:makepkg.conf[5]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
342
doc/Doxyfile.in
342
doc/Doxyfile.in
|
@ -1,342 +0,0 @@
|
||||||
# Doxyfile 1.9.3
|
|
||||||
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Project related configuration options
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
DOXYFILE_ENCODING = UTF-8
|
|
||||||
PROJECT_NAME = libalpm
|
|
||||||
PROJECT_NUMBER =
|
|
||||||
PROJECT_BRIEF = "Arch Linux Package Manager Library"
|
|
||||||
PROJECT_LOGO =
|
|
||||||
OUTPUT_DIRECTORY = @OUTPUT_DIRECTORY@
|
|
||||||
CREATE_SUBDIRS = NO
|
|
||||||
ALLOW_UNICODE_NAMES = NO
|
|
||||||
OUTPUT_LANGUAGE = English
|
|
||||||
BRIEF_MEMBER_DESC = YES
|
|
||||||
REPEAT_BRIEF = YES
|
|
||||||
ABBREVIATE_BRIEF = "The $name class" \
|
|
||||||
"The $name widget" \
|
|
||||||
"The $name file" \
|
|
||||||
is \
|
|
||||||
provides \
|
|
||||||
specifies \
|
|
||||||
contains \
|
|
||||||
represents \
|
|
||||||
a \
|
|
||||||
an \
|
|
||||||
the
|
|
||||||
ALWAYS_DETAILED_SEC = YES
|
|
||||||
INLINE_INHERITED_MEMB = NO
|
|
||||||
FULL_PATH_NAMES = NO
|
|
||||||
STRIP_FROM_PATH =
|
|
||||||
STRIP_FROM_INC_PATH =
|
|
||||||
SHORT_NAMES = NO
|
|
||||||
JAVADOC_AUTOBRIEF = YES
|
|
||||||
JAVADOC_BANNER = NO
|
|
||||||
QT_AUTOBRIEF = NO
|
|
||||||
MULTILINE_CPP_IS_BRIEF = NO
|
|
||||||
PYTHON_DOCSTRING = YES
|
|
||||||
INHERIT_DOCS = YES
|
|
||||||
SEPARATE_MEMBER_PAGES = NO
|
|
||||||
TAB_SIZE = 4
|
|
||||||
ALIASES =
|
|
||||||
OPTIMIZE_OUTPUT_FOR_C = YES
|
|
||||||
OPTIMIZE_OUTPUT_JAVA = NO
|
|
||||||
OPTIMIZE_FOR_FORTRAN = NO
|
|
||||||
OPTIMIZE_OUTPUT_VHDL = NO
|
|
||||||
OPTIMIZE_OUTPUT_SLICE = NO
|
|
||||||
EXTENSION_MAPPING =
|
|
||||||
MARKDOWN_SUPPORT = YES
|
|
||||||
TOC_INCLUDE_HEADINGS = 5
|
|
||||||
AUTOLINK_SUPPORT = YES
|
|
||||||
BUILTIN_STL_SUPPORT = NO
|
|
||||||
CPP_CLI_SUPPORT = NO
|
|
||||||
SIP_SUPPORT = NO
|
|
||||||
IDL_PROPERTY_SUPPORT = YES
|
|
||||||
DISTRIBUTE_GROUP_DOC = NO
|
|
||||||
GROUP_NESTED_COMPOUNDS = NO
|
|
||||||
SUBGROUPING = YES
|
|
||||||
INLINE_GROUPED_CLASSES = NO
|
|
||||||
INLINE_SIMPLE_STRUCTS = YES
|
|
||||||
TYPEDEF_HIDES_STRUCT = YES
|
|
||||||
LOOKUP_CACHE_SIZE = 0
|
|
||||||
NUM_PROC_THREADS = 1
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Build related configuration options
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
EXTRACT_ALL = NO
|
|
||||||
EXTRACT_PRIVATE = NO
|
|
||||||
EXTRACT_PRIV_VIRTUAL = NO
|
|
||||||
EXTRACT_PACKAGE = NO
|
|
||||||
EXTRACT_STATIC = NO
|
|
||||||
EXTRACT_LOCAL_CLASSES = YES
|
|
||||||
EXTRACT_LOCAL_METHODS = NO
|
|
||||||
EXTRACT_ANON_NSPACES = NO
|
|
||||||
RESOLVE_UNNAMED_PARAMS = YES
|
|
||||||
HIDE_UNDOC_MEMBERS = NO
|
|
||||||
HIDE_UNDOC_CLASSES = NO
|
|
||||||
HIDE_FRIEND_COMPOUNDS = NO
|
|
||||||
HIDE_IN_BODY_DOCS = YES
|
|
||||||
INTERNAL_DOCS = NO
|
|
||||||
CASE_SENSE_NAMES = YES
|
|
||||||
HIDE_SCOPE_NAMES = NO
|
|
||||||
HIDE_COMPOUND_REFERENCE= NO
|
|
||||||
SHOW_HEADERFILE = YES
|
|
||||||
SHOW_INCLUDE_FILES = YES
|
|
||||||
SHOW_GROUPED_MEMB_INC = NO
|
|
||||||
FORCE_LOCAL_INCLUDES = NO
|
|
||||||
INLINE_INFO = YES
|
|
||||||
SORT_MEMBER_DOCS = YES
|
|
||||||
SORT_BRIEF_DOCS = NO
|
|
||||||
SORT_MEMBERS_CTORS_1ST = NO
|
|
||||||
SORT_GROUP_NAMES = NO
|
|
||||||
SORT_BY_SCOPE_NAME = NO
|
|
||||||
STRICT_PROTO_MATCHING = NO
|
|
||||||
GENERATE_TODOLIST = YES
|
|
||||||
GENERATE_TESTLIST = YES
|
|
||||||
GENERATE_BUGLIST = YES
|
|
||||||
GENERATE_DEPRECATEDLIST= YES
|
|
||||||
ENABLED_SECTIONS =
|
|
||||||
MAX_INITIALIZER_LINES = 30
|
|
||||||
SHOW_USED_FILES = YES
|
|
||||||
SHOW_FILES = YES
|
|
||||||
SHOW_NAMESPACES = YES
|
|
||||||
FILE_VERSION_FILTER =
|
|
||||||
LAYOUT_FILE =
|
|
||||||
CITE_BIB_FILES =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to warning and progress messages
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
QUIET = NO
|
|
||||||
WARNINGS = YES
|
|
||||||
WARN_IF_UNDOCUMENTED = YES
|
|
||||||
WARN_IF_DOC_ERROR = YES
|
|
||||||
WARN_IF_INCOMPLETE_DOC = YES
|
|
||||||
WARN_NO_PARAMDOC = NO
|
|
||||||
WARN_AS_ERROR = NO
|
|
||||||
WARN_FORMAT = "$file:$line: $text"
|
|
||||||
WARN_LOGFILE =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the input files
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
INPUT = @INPUT_DIRECTORY@/../lib/libalpm/alpm.h \
|
|
||||||
@INPUT_DIRECTORY@/../lib/libalpm/alpm_list.h
|
|
||||||
INPUT_ENCODING = UTF-8
|
|
||||||
FILE_PATTERNS =
|
|
||||||
RECURSIVE = NO
|
|
||||||
EXCLUDE =
|
|
||||||
EXCLUDE_SYMLINKS = NO
|
|
||||||
EXCLUDE_PATTERNS =
|
|
||||||
EXCLUDE_SYMBOLS = _alpm_* \
|
|
||||||
__alpm_*
|
|
||||||
EXAMPLE_PATH =
|
|
||||||
EXAMPLE_PATTERNS = *
|
|
||||||
EXAMPLE_RECURSIVE = NO
|
|
||||||
IMAGE_PATH =
|
|
||||||
INPUT_FILTER =
|
|
||||||
FILTER_PATTERNS =
|
|
||||||
FILTER_SOURCE_FILES = NO
|
|
||||||
FILTER_SOURCE_PATTERNS =
|
|
||||||
USE_MDFILE_AS_MAINPAGE =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to source browsing
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
SOURCE_BROWSER = NO
|
|
||||||
INLINE_SOURCES = NO
|
|
||||||
STRIP_CODE_COMMENTS = NO
|
|
||||||
REFERENCED_BY_RELATION = YES
|
|
||||||
REFERENCES_RELATION = YES
|
|
||||||
REFERENCES_LINK_SOURCE = YES
|
|
||||||
SOURCE_TOOLTIPS = YES
|
|
||||||
USE_HTAGS = NO
|
|
||||||
VERBATIM_HEADERS = YES
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the alphabetical class index
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
ALPHABETICAL_INDEX = NO
|
|
||||||
IGNORE_PREFIX =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the HTML output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_HTML = NO
|
|
||||||
HTML_OUTPUT = html
|
|
||||||
HTML_FILE_EXTENSION = .html
|
|
||||||
HTML_HEADER =
|
|
||||||
HTML_FOOTER =
|
|
||||||
HTML_STYLESHEET =
|
|
||||||
HTML_EXTRA_STYLESHEET =
|
|
||||||
HTML_EXTRA_FILES =
|
|
||||||
HTML_COLORSTYLE_HUE = 220
|
|
||||||
HTML_COLORSTYLE_SAT = 100
|
|
||||||
HTML_COLORSTYLE_GAMMA = 80
|
|
||||||
HTML_DYNAMIC_MENUS = YES
|
|
||||||
HTML_DYNAMIC_SECTIONS = NO
|
|
||||||
HTML_INDEX_NUM_ENTRIES = 100
|
|
||||||
GENERATE_DOCSET = NO
|
|
||||||
DOCSET_FEEDNAME = "Doxygen generated docs"
|
|
||||||
DOCSET_FEEDURL =
|
|
||||||
DOCSET_BUNDLE_ID = org.doxygen.Project
|
|
||||||
DOCSET_PUBLISHER_ID = org.doxygen.Publisher
|
|
||||||
DOCSET_PUBLISHER_NAME = Publisher
|
|
||||||
GENERATE_HTMLHELP = NO
|
|
||||||
CHM_FILE =
|
|
||||||
HHC_LOCATION =
|
|
||||||
GENERATE_CHI = NO
|
|
||||||
CHM_INDEX_ENCODING =
|
|
||||||
BINARY_TOC = NO
|
|
||||||
TOC_EXPAND = NO
|
|
||||||
GENERATE_QHP = NO
|
|
||||||
QCH_FILE =
|
|
||||||
QHP_NAMESPACE = org.doxygen.Project
|
|
||||||
QHP_VIRTUAL_FOLDER = doc
|
|
||||||
QHP_CUST_FILTER_NAME =
|
|
||||||
QHP_CUST_FILTER_ATTRS =
|
|
||||||
QHP_SECT_FILTER_ATTRS =
|
|
||||||
QHG_LOCATION =
|
|
||||||
GENERATE_ECLIPSEHELP = NO
|
|
||||||
ECLIPSE_DOC_ID = org.doxygen.Project
|
|
||||||
DISABLE_INDEX = NO
|
|
||||||
GENERATE_TREEVIEW = NO
|
|
||||||
FULL_SIDEBAR = NO
|
|
||||||
ENUM_VALUES_PER_LINE = 4
|
|
||||||
TREEVIEW_WIDTH = 250
|
|
||||||
EXT_LINKS_IN_WINDOW = NO
|
|
||||||
OBFUSCATE_EMAILS = YES
|
|
||||||
HTML_FORMULA_FORMAT = png
|
|
||||||
FORMULA_FONTSIZE = 10
|
|
||||||
FORMULA_MACROFILE =
|
|
||||||
USE_MATHJAX = NO
|
|
||||||
MATHJAX_VERSION = MathJax_2
|
|
||||||
MATHJAX_FORMAT = HTML-CSS
|
|
||||||
MATHJAX_RELPATH = http://www.mathjax.org/mathjax
|
|
||||||
MATHJAX_EXTENSIONS =
|
|
||||||
MATHJAX_CODEFILE =
|
|
||||||
SEARCHENGINE = NO
|
|
||||||
SERVER_BASED_SEARCH = NO
|
|
||||||
EXTERNAL_SEARCH = NO
|
|
||||||
SEARCHENGINE_URL =
|
|
||||||
SEARCHDATA_FILE = searchdata.xml
|
|
||||||
EXTERNAL_SEARCH_ID =
|
|
||||||
EXTRA_SEARCH_MAPPINGS =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the LaTeX output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_LATEX = NO
|
|
||||||
LATEX_OUTPUT = latex
|
|
||||||
LATEX_CMD_NAME = latex
|
|
||||||
MAKEINDEX_CMD_NAME = makeindex
|
|
||||||
LATEX_MAKEINDEX_CMD = makeindex
|
|
||||||
COMPACT_LATEX = NO
|
|
||||||
PAPER_TYPE = letter
|
|
||||||
EXTRA_PACKAGES =
|
|
||||||
LATEX_HEADER =
|
|
||||||
LATEX_FOOTER =
|
|
||||||
LATEX_EXTRA_STYLESHEET =
|
|
||||||
LATEX_EXTRA_FILES =
|
|
||||||
PDF_HYPERLINKS = NO
|
|
||||||
USE_PDFLATEX = NO
|
|
||||||
LATEX_BATCHMODE = NO
|
|
||||||
LATEX_HIDE_INDICES = NO
|
|
||||||
LATEX_BIB_STYLE = plain
|
|
||||||
LATEX_EMOJI_DIRECTORY =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the RTF output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_RTF = NO
|
|
||||||
RTF_OUTPUT = rtf
|
|
||||||
COMPACT_RTF = NO
|
|
||||||
RTF_HYPERLINKS = NO
|
|
||||||
RTF_STYLESHEET_FILE =
|
|
||||||
RTF_EXTENSIONS_FILE =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the man page output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_MAN = YES
|
|
||||||
MAN_OUTPUT = .
|
|
||||||
MAN_EXTENSION = .3
|
|
||||||
MAN_SUBDIR =
|
|
||||||
MAN_LINKS = NO
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the XML output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_XML = NO
|
|
||||||
XML_OUTPUT = xml
|
|
||||||
XML_PROGRAMLISTING = YES
|
|
||||||
XML_NS_MEMB_FILE_SCOPE = NO
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the DOCBOOK output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_DOCBOOK = NO
|
|
||||||
DOCBOOK_OUTPUT = docbook
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options for the AutoGen Definitions output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_AUTOGEN_DEF = NO
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the Perl module output
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
GENERATE_PERLMOD = NO
|
|
||||||
PERLMOD_LATEX = NO
|
|
||||||
PERLMOD_PRETTY = YES
|
|
||||||
PERLMOD_MAKEVAR_PREFIX =
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the preprocessor
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
ENABLE_PREPROCESSING = YES
|
|
||||||
MACRO_EXPANSION = YES
|
|
||||||
EXPAND_ONLY_PREDEF = YES
|
|
||||||
SEARCH_INCLUDES = YES
|
|
||||||
INCLUDE_PATH = ../..
|
|
||||||
INCLUDE_FILE_PATTERNS = *.h
|
|
||||||
PREDEFINED = HAVE_CONFIG_H= \
|
|
||||||
SYMEXPORT= \
|
|
||||||
HAVE_LIBARCHIVE \
|
|
||||||
HAVE_LIBCURL \
|
|
||||||
HAVE_LIBGPGME
|
|
||||||
EXPAND_AS_DEFINED =
|
|
||||||
SKIP_FUNCTION_MACROS = YES
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to external references
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
TAGFILES =
|
|
||||||
GENERATE_TAGFILE =
|
|
||||||
ALLEXTERNALS = NO
|
|
||||||
EXTERNAL_GROUPS = YES
|
|
||||||
EXTERNAL_PAGES = YES
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
# Configuration options related to the dot tool
|
|
||||||
#---------------------------------------------------------------------------
|
|
||||||
DIA_PATH =
|
|
||||||
HIDE_UNDOC_RELATIONS = YES
|
|
||||||
HAVE_DOT = YES
|
|
||||||
DOT_NUM_THREADS = 0
|
|
||||||
DOT_FONTPATH =
|
|
||||||
CLASS_GRAPH = YES
|
|
||||||
COLLABORATION_GRAPH = YES
|
|
||||||
GROUP_GRAPHS = YES
|
|
||||||
UML_LOOK = NO
|
|
||||||
UML_LIMIT_NUM_FIELDS = 10
|
|
||||||
DOT_UML_DETAILS = NO
|
|
||||||
DOT_WRAP_THRESHOLD = 17
|
|
||||||
TEMPLATE_RELATIONS = NO
|
|
||||||
INCLUDE_GRAPH = YES
|
|
||||||
INCLUDED_BY_GRAPH = YES
|
|
||||||
CALL_GRAPH = NO
|
|
||||||
CALLER_GRAPH = NO
|
|
||||||
GRAPHICAL_HIERARCHY = YES
|
|
||||||
DIRECTORY_GRAPH = YES
|
|
||||||
DIR_GRAPH_MAX_DEPTH = 1
|
|
||||||
DOT_IMAGE_FORMAT = png
|
|
||||||
INTERACTIVE_SVG = NO
|
|
||||||
DOT_PATH =
|
|
||||||
DOTFILE_DIRS =
|
|
||||||
MSCFILE_DIRS =
|
|
||||||
DIAFILE_DIRS =
|
|
||||||
PLANTUML_JAR_PATH =
|
|
||||||
PLANTUML_CFG_FILE =
|
|
||||||
PLANTUML_INCLUDE_PATH =
|
|
||||||
DOT_GRAPH_MAX_NODES = 50
|
|
||||||
MAX_DOT_GRAPH_DEPTH = 3
|
|
||||||
DOT_MULTI_TARGETS = NO
|
|
||||||
GENERATE_LEGEND = YES
|
|
||||||
DOT_CLEANUP = YES
|
|
17
doc/Makefile.am
Normal file
17
doc/Makefile.am
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
man_MANS = \
|
||||||
|
pacman.8 \
|
||||||
|
makepkg.8 \
|
||||||
|
PKGBUILD.5 \
|
||||||
|
makepkg.conf.5 \
|
||||||
|
pacman.conf.5 \
|
||||||
|
libalpm.3
|
||||||
|
|
||||||
|
if HAS_DOXYGEN
|
||||||
|
man_MANS += $(wildcard man3/*.3)
|
||||||
|
endif
|
||||||
|
|
||||||
|
EXTRA_DIST = $(man_MANS)
|
||||||
|
|
||||||
|
clean-local:
|
||||||
|
$(RM) man3/*.3
|
||||||
|
|
|
@ -1,27 +0,0 @@
|
||||||
# Maintainer: Joe User <joe.user@example.com>
|
|
||||||
|
|
||||||
pkgname=patch
|
|
||||||
pkgver=2.7.1
|
|
||||||
pkgrel=1
|
|
||||||
pkgdesc="A utility to apply patch files to original sources"
|
|
||||||
arch=('i686' 'x86_64')
|
|
||||||
url="https://www.gnu.org/software/patch/patch.html"
|
|
||||||
license=('GPL')
|
|
||||||
groups=('base-devel')
|
|
||||||
depends=('glibc')
|
|
||||||
makedepends=('ed')
|
|
||||||
optdepends=('ed: for "patch -e" functionality')
|
|
||||||
source=("ftp://ftp.gnu.org/gnu/$pkgname/$pkgname-$pkgver.tar.xz"{,.sig})
|
|
||||||
sha256sums=('9124ba46db0abd873d0995c2ca880e81252676bb6c03e0a37dfc5f608a9b0ceb'
|
|
||||||
'SKIP')
|
|
||||||
|
|
||||||
build() {
|
|
||||||
cd "$srcdir/$pkgname-$pkgver"
|
|
||||||
./configure --prefix=/usr
|
|
||||||
make
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
cd "$srcdir/$pkgname-$pkgver"
|
|
||||||
make DESTDIR="$pkgdir/" install
|
|
||||||
}
|
|
288
doc/PKGBUILD.5
Normal file
288
doc/PKGBUILD.5
Normal file
|
@ -0,0 +1,288 @@
|
||||||
|
." the string declarations are a start to try and make distro independent
|
||||||
|
.ds DS Arch Linux
|
||||||
|
.ds PB PKGBUILD
|
||||||
|
.ds VR 3.0.0
|
||||||
|
.TH \*(PB 5 "Feb 07, 2007" "\*(PB version \*(VR" "\*(DS Files"
|
||||||
|
.SH NAME
|
||||||
|
\*(PB \- \*(DS package build description file
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This manual page is meant to describe general rules about \fB\*(PB\fPs. Once
|
||||||
|
a \fB\*(PB\fP is written, the actual package is built using \fBmakepkg\fP and
|
||||||
|
installed with \fBpacman\fP.
|
||||||
|
|
||||||
|
\fBNOTE:\fP If you have a local copy of the Arch Build System (ABS) tree
|
||||||
|
on your computer, you can copy the \*(PB.proto file to your new package
|
||||||
|
build directory and edit it from there. To acquire/sync the ABS tree, use
|
||||||
|
the \fBabs\fP script included with \fBpacman\fP.
|
||||||
|
|
||||||
|
.SH OPTIONS AND DIRECTIVES
|
||||||
|
.TP
|
||||||
|
.B pkgname
|
||||||
|
The name of the package. This has be a unix-friendly name as it will be
|
||||||
|
used in the package filename.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B pkgver
|
||||||
|
The version of the software as released from the author (e.g. 2.7.1).
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B pkgrel
|
||||||
|
This is the release number specific to the \*(DSs release. This allows package
|
||||||
|
maintainers to make updates to the package's configure flags, for example.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B pkgdesc
|
||||||
|
This should be a brief description of the package and its functionality. Try to
|
||||||
|
keep the description to one line of text.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B url
|
||||||
|
This field contains a URL that is associated with the software being packaged.
|
||||||
|
This is typically the project's website.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B license (array)
|
||||||
|
This field specifies the license(s) that apply to the package. Commonly-used
|
||||||
|
licenses are found in \fI/usr/share/licenses/common\fP. If you see the
|
||||||
|
package's license there, simply reference it in the license field (e.g.
|
||||||
|
\fBlicense=("GPL")\fP). If the package provides a license not found in
|
||||||
|
\fI/usr/share/licenses/common\fP, then you should include the license in the
|
||||||
|
package itself and set \fBlicense=("custom")\fP or
|
||||||
|
\fBlicense=("custom:LicenseName")\fP. The license should be placed in
|
||||||
|
\fI$startdir/pkg/usr/share/licenses/$pkgname\fP when building the package. If
|
||||||
|
multiple licenses are applicable for a package, list all of them:
|
||||||
|
\fBlicenses=('GPL' 'FDL')\fP.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B install
|
||||||
|
Specifies a special install script that is to be included in the package. This
|
||||||
|
file should reside in the same directory as the \fB\*(PB\fP, and will be copied
|
||||||
|
into the package by \fBmakepkg\fP. It does not need to be included in the
|
||||||
|
\fIsource\fP array (e.g. \fBinstall=pkgname.install\fP).
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B source \fI(array)\fP
|
||||||
|
An array of source files required to build the package. Source files must
|
||||||
|
either reside in the same directory as the \fB\*(PB file\fP, or be a
|
||||||
|
fully-qualified URL that makepkg will use to download the file. In order to
|
||||||
|
make the PKGBUILD as useful as possible, use the \fB$pkgname\fP and
|
||||||
|
\fB$pkgver\fP variables if possible when specifying the download location.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B noextract \fI(array)\fP
|
||||||
|
An array of filenames corresponding to those from the \fBsource\fP array. Files
|
||||||
|
listed here will not be extracted with the rest of the source files. This is
|
||||||
|
useful for packages which use compressed data which is downloaded but not
|
||||||
|
necessary to uncompress.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B md5sums \fI(array)\fP
|
||||||
|
This array contains an MD5 hash for every source file specified in the
|
||||||
|
\fBsource\fP array (in the same order). \fBmakepkg\fP will use this to verify
|
||||||
|
source file integrity during subsequent builds. To easily generate md5sums, run
|
||||||
|
"makepkg -g >> \*(PB". If desired, move the \fBmd5sums\fP line to an
|
||||||
|
appropriate location. NOTE: \fBmakepkg\fP supports multiple integrity
|
||||||
|
algorithms and their corresponding arrays (i.e. sha1sums for the SHA1
|
||||||
|
algorithm); however, official packages use only md5sums for the time being.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B sha1sums, etc.
|
||||||
|
Alternative integrity checks that \fBmakepkg\fP supports, as noted in
|
||||||
|
\fBmd5sums\fP above.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B groups \fI(array)\fP
|
||||||
|
An array of symbolic names that represent groups of packages, allowing
|
||||||
|
you to install multiple packages by requesting a single target. For example,
|
||||||
|
one could install all KDE packages by installing the 'kde' group.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B arch \fI(array)\fP
|
||||||
|
Defines on which architectures the given package is available (e.g.
|
||||||
|
\fBarch=('i686' 'x86_64')\fP).
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B backup \fI(array)\fP
|
||||||
|
A space-delimited array of filenames, \fIwithout\fP preceding slashes, that
|
||||||
|
should be backed up if the package is removed or upgraded. This is commonly
|
||||||
|
used for packages placing configuration files in /etc. See \fBHANDLING CONFIG
|
||||||
|
FILES\fP in the \fBpacman\fP manpage for more information.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B depends \fI(array)\fP
|
||||||
|
An array of packages that this package depends on to run. Packages in this list
|
||||||
|
should be surrounded with single quotes and contain at least the package name.
|
||||||
|
Entries can also include a version requirement of the form
|
||||||
|
\fB'name<>version'\fP, where <> is one of three comparisons: \fI>=\fP (greater
|
||||||
|
than or equal to), \fI<=\fP (less than or equal to), or \fI=\fP (equal to).
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B makedepends \fI(array)\fP
|
||||||
|
An array of packages that this package depends on to build, but are not needed
|
||||||
|
at runtime. Packages in this list follow the same format as \fBdepends\fP.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B conflicts \fI(array)\fP
|
||||||
|
An array of packages that will conflict with this package (i.e. they cannot
|
||||||
|
both be installed at the same time). This directive follows the same format as
|
||||||
|
\fIdepends\fP, except you cannot specify versions.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B provides \fI(array)\fP
|
||||||
|
An array of "virtual provisions" that this package provides. This allows a
|
||||||
|
package to provide dependencies other than its own package name. For example,
|
||||||
|
the dcron package can provide 'cron', which allows packages to depend on 'cron'
|
||||||
|
rather than 'dcron OR fcron'.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B replaces \fI(array)\fP
|
||||||
|
An array of packages that this package should replace, and can be used to
|
||||||
|
handle renamed/combined packages. For example, if the 'j2re' package is renamed
|
||||||
|
to 'jre', this directive allows future upgrades to continue as expected even
|
||||||
|
though the package has moved.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B options \fI(array)\fP
|
||||||
|
This array allows you to override some of \fBmakepkg\fP's default behavior when
|
||||||
|
building packages. To set an option, just include the option name in the
|
||||||
|
\fBoptions\fP array. To reverse the default behavior, place an "!" at the front
|
||||||
|
of the option. Only specify the options you specifically want to override, the
|
||||||
|
rest will be taken from \fBmakepkg.conf\fP. NOTE: 'force' is a special option
|
||||||
|
only used in \fB\*(PB\fPs, do not use it unless you know what you are doing.
|
||||||
|
.RS
|
||||||
|
.TP
|
||||||
|
.B strip
|
||||||
|
Strip symbols from binaries and libraries. If you frequently use a debugger on
|
||||||
|
programs or libraries, it may be helpful to disable this option.
|
||||||
|
.TP
|
||||||
|
.B docs
|
||||||
|
Save doc and info directories. If you wish to delete doc and info directories,
|
||||||
|
specify "!docs" in the array.
|
||||||
|
.TP
|
||||||
|
.B libtool
|
||||||
|
Leave libtool (.la) files in packages. Specify "!libtool" to remove them.
|
||||||
|
.TP
|
||||||
|
.B emptydirs
|
||||||
|
Leave empty directories in packages.
|
||||||
|
.TP
|
||||||
|
.B ccache
|
||||||
|
Allow the use of \fBccache\fP during build. More useful in its negative form
|
||||||
|
"!ccache" with select packages that have problems building with \fBccache\fP.
|
||||||
|
.TP
|
||||||
|
.B distcc
|
||||||
|
Allow the use of \fBdistcc\fP during build. More useful in its negative form
|
||||||
|
"!distcc" with select packages that have problems building with \fBdistcc\fP.
|
||||||
|
.TP
|
||||||
|
.B makeflags
|
||||||
|
Allow the use of user-specific makeflags during build as specified in
|
||||||
|
\fBmakepkg.conf\fP. More useful in its negative form "!makeflags" with select
|
||||||
|
packages that have problems building with custom makeflags such as "-j2" (or
|
||||||
|
higher).
|
||||||
|
.TP
|
||||||
|
.B force
|
||||||
|
Force the package to be upgraded by a \fBpacman\fP system upgrade operation,
|
||||||
|
even if the version number would normally not trigger such an upgrade. This is
|
||||||
|
useful when the version numbering scheme of a package changes (or is
|
||||||
|
alphanumeric).
|
||||||
|
.RE
|
||||||
|
|
||||||
|
.SH INSTALL/UPGRADE/REMOVE SCRIPTING
|
||||||
|
\fBPacman\fP has the ability to store and execute a package-specific script
|
||||||
|
when it installs, removes, or upgrades a package. This allows a package to
|
||||||
|
configure itself after installation and do the opposite right before it is
|
||||||
|
removed.
|
||||||
|
|
||||||
|
The exact time the script is run varies with each operation:
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B pre_install
|
||||||
|
script is run right before files are extracted.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B post_install
|
||||||
|
script is run right after files are extracted.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B pre_upgrade
|
||||||
|
script is run right before files are extracted.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B post_upgrade
|
||||||
|
script is run after files are extracted.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B pre_remove
|
||||||
|
script is run right before files are removed.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B post_remove
|
||||||
|
script is run right after files are removed.
|
||||||
|
|
||||||
|
.P
|
||||||
|
To use this feature, create a file such as 'pkgname.install' and put it in
|
||||||
|
the same directory as the \fB\*(PB\fP script. Then use the \fBinstall\fP
|
||||||
|
directive:
|
||||||
|
|
||||||
|
.RS
|
||||||
|
.nf
|
||||||
|
install=pkgname.install
|
||||||
|
.fi
|
||||||
|
.RE
|
||||||
|
|
||||||
|
The install script does not need to be specified in the \fBsource\fP array.
|
||||||
|
A template install file is available in the ABS tree (/var/abs/install.proto).
|
||||||
|
|
||||||
|
.SH EXAMPLE
|
||||||
|
The following is an example \fB\*(PB\fP for the 'modutils' package. For more
|
||||||
|
examples, look through the ABS tree.
|
||||||
|
|
||||||
|
.nf
|
||||||
|
# Maintainer: John Doe <johndoe@archlinux.org>
|
||||||
|
# Contributor: Bill Smith <billsmith@archlinux.org>
|
||||||
|
pkgname=modutils
|
||||||
|
pkgver=2.4.25
|
||||||
|
pkgrel=1
|
||||||
|
pkgdesc="Utilities for inserting modules in the linux kernel"
|
||||||
|
url="http://www.kernel.org"
|
||||||
|
makedepends=('bash' 'mawk')
|
||||||
|
depends=('glibc' 'zlib')
|
||||||
|
backup=(etc/modules.conf)
|
||||||
|
source=(ftp://ftp.kernel.org/pub/linux/utils/kernel/$pkgname/v2.4/$pkgname-$pkgver.tar.bz2
|
||||||
|
modules.conf)
|
||||||
|
arch=('i686')
|
||||||
|
license=('GPL' 'custom') # dual licensed
|
||||||
|
md5sums=('2c0cca3ef6330a187c6ef4fe41ecaa4d'
|
||||||
|
'35175bee593a7cc7d6205584a94d8625')
|
||||||
|
options=(!libtool)
|
||||||
|
|
||||||
|
build() {
|
||||||
|
cd $startdir/src/$pkgname-$pkgver
|
||||||
|
./configure --prefix=/usr --enable-insmod-static
|
||||||
|
make || return 1
|
||||||
|
make prefix=$startdir/pkg/usr install
|
||||||
|
mv $startdir/pkg/usr/sbin $startdir/pkg
|
||||||
|
mkdir -p $startdir/pkg/etc
|
||||||
|
cp ../modules.conf $startdir/pkg/etc
|
||||||
|
}
|
||||||
|
.fi
|
||||||
|
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR makepkg (8),
|
||||||
|
.BR pacman (8),
|
||||||
|
.BR makepkg.conf (5)
|
||||||
|
|
||||||
|
See the Arch Linux website at <http://www.archlinux.org> for more current
|
||||||
|
information on the distribution and the \fBpacman\fP family of tools, and
|
||||||
|
<http://wiki.archlinux.org/index.php/Arch_Packaging_Standards> for
|
||||||
|
recommendations on packaging standards.
|
||||||
|
|
||||||
|
.SH AUTHORS
|
||||||
|
.nf
|
||||||
|
Judd Vinet <jvinet@zeroflux.org>
|
||||||
|
Aurelien Foret <aurelien@archlinux.org>
|
||||||
|
Aaron Griffin <aaron@archlinux.org>
|
||||||
|
Dan McGee <dan@archlinux.org>
|
||||||
|
.fi
|
||||||
|
|
||||||
|
See the 'AUTHORS' file for additional contributors.
|
|
@ -1,544 +0,0 @@
|
||||||
PKGBUILD(5)
|
|
||||||
===========
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
PKGBUILD - Package build description file
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
PKGBUILD
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
This manual page describes general rules about PKGBUILDs. Once a
|
|
||||||
PKGBUILD is written, the actual package is built using makepkg and installed
|
|
||||||
with pacman.
|
|
||||||
|
|
||||||
NOTE: An example PKGBUILD, useful for reference, is located in '{pkgdatadir}'
|
|
||||||
along with other example files such as an install script. You can copy the
|
|
||||||
provided PKGBUILD.proto file to a new package build directory and make
|
|
||||||
customizations to suit your needs.
|
|
||||||
|
|
||||||
|
|
||||||
Options and Directives
|
|
||||||
----------------------
|
|
||||||
The following is a list of standard options and directives available for use
|
|
||||||
in a PKGBUILD. These are all understood and interpreted by makepkg, and most
|
|
||||||
of them will be directly transferred to the built package. The mandatory
|
|
||||||
fields for a minimally functional PKGBUILD are *pkgname*, *pkgver*, *pkgrel*
|
|
||||||
and *arch*.
|
|
||||||
|
|
||||||
If you need to create any custom variables for use in your build process, it is
|
|
||||||
recommended to prefix their name with an '_' (underscore).
|
|
||||||
This will prevent any possible name clashes with internal makepkg variables.
|
|
||||||
For example, to store the base kernel version in a variable, use something
|
|
||||||
similar to `$_basekernver`.
|
|
||||||
|
|
||||||
*pkgname (array)*::
|
|
||||||
Either the name of the package or an array of names for split packages.
|
|
||||||
Valid characters for members of this array are alphanumerics, and any of
|
|
||||||
the following characters: ```@ . _ + -`''. Additionally, names are not
|
|
||||||
allowed to start with hyphens or dots.
|
|
||||||
|
|
||||||
*pkgver*::
|
|
||||||
The version of the software as released from the author (e.g., '2.7.1').
|
|
||||||
The variable is not allowed to contain colons, forward slashes, hyphens
|
|
||||||
or whitespace.
|
|
||||||
+
|
|
||||||
The `pkgver` variable can be automatically updated by providing a `pkgver()`
|
|
||||||
function in the PKGBUILD that outputs the new package version.
|
|
||||||
This is run after downloading and extracting the sources and running the
|
|
||||||
`prepare()` function (if present), so it can use those files in determining the
|
|
||||||
new `pkgver`. This is most useful when used with sources from version control
|
|
||||||
systems (see below).
|
|
||||||
|
|
||||||
*pkgrel*::
|
|
||||||
This is the release number specific to the distribution. This
|
|
||||||
allows package maintainers to make updates to the package's configure
|
|
||||||
flags, for example. This is typically set to '1' for each new upstream
|
|
||||||
software release and incremented for intermediate PKGBUILD updates. The
|
|
||||||
variable is a positive integer, with an optional subrelease level
|
|
||||||
specified by adding another positive integer separated by a period
|
|
||||||
(i.e. in the form x.y).
|
|
||||||
|
|
||||||
*epoch*::
|
|
||||||
Used to force the package to be seen as newer than any previous versions
|
|
||||||
with a lower epoch, even if the version number would normally not trigger
|
|
||||||
such an upgrade. This value is required to be a positive integer; the
|
|
||||||
default value if left unspecified is '0'. This is useful when the version
|
|
||||||
numbering scheme of a package changes (or is alphanumeric), breaking normal
|
|
||||||
version comparison logic. See linkman:pacman[8] for more information on
|
|
||||||
version comparisons.
|
|
||||||
|
|
||||||
*pkgdesc*::
|
|
||||||
This should be a brief description of the package and its functionality.
|
|
||||||
Try to keep the description to one line of text and to not use the package's
|
|
||||||
name.
|
|
||||||
|
|
||||||
*url*::
|
|
||||||
This field contains a URL that is associated with the software being
|
|
||||||
packaged. This is typically the project's web site.
|
|
||||||
|
|
||||||
*license (array)*::
|
|
||||||
This field specifies the license(s) that apply to the package.
|
|
||||||
If multiple licenses are applicable, list all of them:
|
|
||||||
`license=('GPL' 'FDL')`.
|
|
||||||
|
|
||||||
*install*::
|
|
||||||
Specifies a special install script that is to be included in the package.
|
|
||||||
This file should reside in the same directory as the PKGBUILD and will
|
|
||||||
be copied into the package by makepkg. It does not need to be included
|
|
||||||
in the source array (e.g., `install=$pkgname.install`).
|
|
||||||
|
|
||||||
*changelog*::
|
|
||||||
Specifies a changelog file that is to be included in the package.
|
|
||||||
The changelog file should end in a single newline.
|
|
||||||
This file should reside in the same directory as the PKGBUILD and will
|
|
||||||
be copied into the package by makepkg. It does not need to be included
|
|
||||||
in the source array (e.g., `changelog=$pkgname.changelog`).
|
|
||||||
|
|
||||||
*source (array)*::
|
|
||||||
An array of source files required to build the package. Source files
|
|
||||||
must either reside in the same directory as the PKGBUILD, or be a
|
|
||||||
fully-qualified URL that makepkg can use to download the file.
|
|
||||||
To simplify the maintenance of PKGBUILDs, use the `$pkgname` and `$pkgver`
|
|
||||||
variables when specifying the download location, if possible.
|
|
||||||
Compressed files will be extracted automatically unless found in the
|
|
||||||
noextract array described below.
|
|
||||||
+
|
|
||||||
Additional architecture-specific sources can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'source_x86_64=()'. There must be a
|
|
||||||
corresponding integrity array with checksums, e.g. 'cksums_x86_64=()'.
|
|
||||||
+
|
|
||||||
It is also possible to change the name of the downloaded file, which is helpful
|
|
||||||
with weird URLs and for handling multiple source files with the same
|
|
||||||
name. The syntax is: `source=('filename::url')`.
|
|
||||||
+
|
|
||||||
makepkg also supports building developmental versions of packages using sources
|
|
||||||
downloaded from version control systems (VCS). For more information, see
|
|
||||||
<<VCS,Using VCS Sources>> below.
|
|
||||||
+
|
|
||||||
Files in the source array with extensions `.sig`, `.sign` or, `.asc` are
|
|
||||||
recognized by makepkg as PGP signatures and will be automatically used to verify
|
|
||||||
the integrity of the corresponding source file.
|
|
||||||
|
|
||||||
*validpgpkeys (array)*::
|
|
||||||
An array of PGP fingerprints. If this array is non-empty, makepkg will
|
|
||||||
only accept signatures from the keys listed here and will ignore the
|
|
||||||
trust values from the keyring. If the source file was signed with a
|
|
||||||
subkey, makepkg will still use the primary key for comparison.
|
|
||||||
+
|
|
||||||
Only full fingerprints are accepted. They must be uppercase and must not
|
|
||||||
contain whitespace characters.
|
|
||||||
|
|
||||||
*noextract (array)*::
|
|
||||||
An array of file names corresponding to those from the source array. Files
|
|
||||||
listed here will not be extracted with the rest of the source files. This
|
|
||||||
is useful for packages that use compressed data directly.
|
|
||||||
|
|
||||||
*cksums (array)*::
|
|
||||||
This array contains CRC checksums for every source file specified in the
|
|
||||||
source array (in the same order). makepkg will use this to verify source
|
|
||||||
file integrity during subsequent builds. If 'SKIP' is put in the array
|
|
||||||
in place of a normal hash, the integrity check for that source file will
|
|
||||||
be skipped. To easily generate cksums, run ``makepkg -g >> PKGBUILD''.
|
|
||||||
If desired, move the cksums line to an appropriate location. Note that
|
|
||||||
checksums generated by "makepkg -g" should be verified using checksum
|
|
||||||
values provided by the software developer.
|
|
||||||
|
|
||||||
*md5sums, sha1sums, sha224sums, sha256sums, sha384sums, sha512sums, b2sums (arrays)*::
|
|
||||||
Alternative integrity checks that makepkg supports; these all behave
|
|
||||||
similar to the cksums option described above. To enable use and generation
|
|
||||||
of these checksums, be sure to set up the `INTEGRITY_CHECK` option in
|
|
||||||
linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
*groups (array)*::
|
|
||||||
An array of symbolic names that represent groups of packages, allowing
|
|
||||||
you to install multiple packages by requesting a single target. For
|
|
||||||
example, one could install all KDE packages by installing the 'kde' group.
|
|
||||||
|
|
||||||
*arch (array)*::
|
|
||||||
Defines on which architectures the given package is available (e.g.,
|
|
||||||
`arch=('i686' 'x86_64')`). Packages that contain no architecture specific
|
|
||||||
files should use `arch=('any')`. Valid characters for members of this array
|
|
||||||
are alphanumerics and ```_`''.
|
|
||||||
|
|
||||||
*backup (array)*::
|
|
||||||
An array of file names, without preceding slashes, that
|
|
||||||
should be backed up if the package is removed or upgraded. This is
|
|
||||||
commonly used for packages placing configuration files in '/etc'. See
|
|
||||||
`"Handling Config Files"` in linkman:pacman[8] for more information.
|
|
||||||
|
|
||||||
*depends (array)*::
|
|
||||||
An array of packages this package depends on to run. Entries in
|
|
||||||
this list should be surrounded with single quotes and contain at least
|
|
||||||
the package name. Entries can also include a version requirement of the
|
|
||||||
form 'name<>version', where `<>` is one of five comparisons: `>=` (greater
|
|
||||||
than or equal to), `<=` (less than or equal to), `=` (equal to), `>`
|
|
||||||
(greater than), or `<` (less than).
|
|
||||||
+
|
|
||||||
Additional architecture-specific depends can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'depends_x86_64=()'.
|
|
||||||
|
|
||||||
*makedepends (array)*::
|
|
||||||
An array of packages this package depends on to build but are not
|
|
||||||
needed at runtime. Packages in this list follow the same format as
|
|
||||||
depends.
|
|
||||||
+
|
|
||||||
Additional architecture-specific makedepends can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'makedepends_x86_64=()'.
|
|
||||||
|
|
||||||
*checkdepends (array)*::
|
|
||||||
An array of packages this package depends on to run its test suite
|
|
||||||
but are not needed at runtime. Packages in this list follow the same
|
|
||||||
format as depends. These dependencies are only considered when the
|
|
||||||
check() function is present and is to be run by makepkg.
|
|
||||||
+
|
|
||||||
Additional architecture-specific checkdepends can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'checkdepends_x86_64=()'.
|
|
||||||
|
|
||||||
*optdepends (array)*::
|
|
||||||
An array of packages (and accompanying reasons) that are not essential for
|
|
||||||
base functionality, but may be necessary to make full use of the contents
|
|
||||||
of this package. optdepends are currently for informational purposes only
|
|
||||||
and are not utilized by pacman during dependency resolution. Packages in
|
|
||||||
this list follow the same format as depends, with an optional description
|
|
||||||
appended. The format for specifying optdepends descriptions is:
|
|
||||||
|
|
||||||
optdepends=('python: for library bindings')
|
|
||||||
+
|
|
||||||
Additional architecture-specific optdepends can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'optdepends_x86_64=()'.
|
|
||||||
|
|
||||||
*conflicts (array)*::
|
|
||||||
An array of packages that will conflict with this package (i.e. they
|
|
||||||
cannot both be installed at the same time). This directive follows the
|
|
||||||
same format as depends. Versioned conflicts are supported using the
|
|
||||||
operators as described in `depends`.
|
|
||||||
+
|
|
||||||
Additional architecture-specific conflicts can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'conflicts_x86_64=()'.
|
|
||||||
|
|
||||||
*provides (array)*::
|
|
||||||
An array of ``virtual provisions'' this package provides. This allows
|
|
||||||
a package to provide dependencies other than its own package name. For
|
|
||||||
example, the dcron package can provide 'cron', which allows packages to
|
|
||||||
depend on 'cron' rather than 'dcron OR fcron'.
|
|
||||||
+
|
|
||||||
Versioned provisions are also possible, in the 'name=version' format. For
|
|
||||||
example, dcron can provide 'cron=2.0' to satisfy the 'cron>=2.0' dependency of
|
|
||||||
other packages. Provisions involving the `>` and `<` operators are invalid as
|
|
||||||
only specific versions of a package may be provided.
|
|
||||||
+
|
|
||||||
Additional architecture-specific provides can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'provides_x86_64=()'.
|
|
||||||
|
|
||||||
*replaces (array)*::
|
|
||||||
An array of packages this package should replace. This can be used
|
|
||||||
to handle renamed/combined packages. For example, if the 'j2re' package
|
|
||||||
is renamed to 'jre', this directive allows future upgrades to continue
|
|
||||||
as expected even though the package has moved. Versioned replaces are
|
|
||||||
supported using the operators as described in `depends`.
|
|
||||||
+
|
|
||||||
Sysupgrade is currently the only pacman operation that utilizes this field.
|
|
||||||
A normal sync or upgrade will not use its value.
|
|
||||||
+
|
|
||||||
Additional architecture-specific replaces can be added by appending an
|
|
||||||
underscore and the architecture name e.g., 'replaces_x86_64=()'.
|
|
||||||
|
|
||||||
*options (array)*::
|
|
||||||
This array allows you to override some of makepkg's default behavior
|
|
||||||
when building packages. To set an option, just include the option name
|
|
||||||
in the options array. To reverse the default behavior, place an ``!'' at
|
|
||||||
the front of the option. Only specify the options you specifically want
|
|
||||||
to override, the rest will be taken from linkman:makepkg.conf[5].
|
|
||||||
*NOTE:* 'force' is a now-removed option in favor of the top level 'epoch'
|
|
||||||
variable.
|
|
||||||
|
|
||||||
*strip*;;
|
|
||||||
Strip symbols from binaries and libraries. If you frequently
|
|
||||||
use a debugger on programs or libraries, it may be helpful to
|
|
||||||
disable this option.
|
|
||||||
|
|
||||||
*docs*;;
|
|
||||||
Save doc directories. If you wish to delete doc directories,
|
|
||||||
specify `!docs` in the array.
|
|
||||||
|
|
||||||
*libtool*;;
|
|
||||||
Leave libtool (.la) files in packages. Specify `!libtool` to
|
|
||||||
remove them.
|
|
||||||
|
|
||||||
*staticlibs*;;
|
|
||||||
Leave static library (.a) files in packages. Specify `!staticlibs` to
|
|
||||||
remove them (if they have a shared counterpart).
|
|
||||||
|
|
||||||
*emptydirs*;;
|
|
||||||
Leave empty directories in packages.
|
|
||||||
|
|
||||||
*zipman*;;
|
|
||||||
Compress man and info pages with gzip.
|
|
||||||
|
|
||||||
*ccache*;;
|
|
||||||
Allow the use of ccache during `build()`. More useful in its negative
|
|
||||||
form `!ccache` with select packages that have problems building
|
|
||||||
with ccache.
|
|
||||||
|
|
||||||
*distcc*;;
|
|
||||||
Allow the use of distcc during `build()`. More useful in its negative
|
|
||||||
form `!distcc` with select packages that have problems building
|
|
||||||
with distcc.
|
|
||||||
|
|
||||||
*buildflags*;;
|
|
||||||
Allow the use of user-specific buildflags (CPPFLAGS, CFLAGS, CXXFLAGS,
|
|
||||||
LDFLAGS) during `build()` as specified in linkman:makepkg.conf[5]. More
|
|
||||||
useful in its negative form `!buildflags` with select packages that
|
|
||||||
have problems building with custom buildflags.
|
|
||||||
|
|
||||||
*makeflags*;;
|
|
||||||
Allow the use of user-specific makeflags during `build()` as specified
|
|
||||||
in linkman:makepkg.conf[5]. More useful in its negative form
|
|
||||||
`!makeflags` with select packages that have problems building with
|
|
||||||
custom makeflags such as `-j2` (or higher).
|
|
||||||
|
|
||||||
*debug*;;
|
|
||||||
Add the user-specified debug flags (DEBUG_CFLAGS, DEBUG_CXXFLAGS) to
|
|
||||||
their counterpart buildflags as specified in linkman:makepkg.conf[5].
|
|
||||||
When used in combination with the `strip' option, a separate package
|
|
||||||
containing the debug symbols is created.
|
|
||||||
|
|
||||||
*lto*;;
|
|
||||||
Enable building packages using link time optimization. Adds '-flto'
|
|
||||||
to both CFLAGS and CXXFLAGS.
|
|
||||||
|
|
||||||
*xdata (array)*::
|
|
||||||
This array allows you to add additional metadata to the package.
|
|
||||||
This data is neither used by pacman nor by makepkg;
|
|
||||||
It has purely informational purpose, or may be interpreted by third-party tools.
|
|
||||||
+
|
|
||||||
All entries in that array must have the form 'key=value', where
|
|
||||||
'key' is an arbitrary non-empty string and 'value' must not contain an equal sign.
|
|
||||||
Furthermore, the key ``pkgtype'' is reserved for the makepkg program.
|
|
||||||
|
|
||||||
|
|
||||||
Packaging Functions
|
|
||||||
-------------------
|
|
||||||
In addition to the above directives, PKGBUILDs require a set of functions that
|
|
||||||
provide instructions to build and install the package. As a minimum, the
|
|
||||||
PKGBUILD must contain a `package()` function which installs all the package's
|
|
||||||
files into the packaging directory, with optional `prepare()`, `build()`, and
|
|
||||||
`check()` functions being used to create those files from source.
|
|
||||||
|
|
||||||
This is directly sourced and executed by makepkg, so anything that Bash or the
|
|
||||||
system has available is available for use here. Be sure any exotic commands
|
|
||||||
used are covered by the `makedepends` array.
|
|
||||||
|
|
||||||
If you create any variables of your own in any of these functions, it is
|
|
||||||
recommended to use the Bash `local` keyword to scope the variable to inside the
|
|
||||||
function.
|
|
||||||
|
|
||||||
*package() Function*::
|
|
||||||
The `package()` function is used to install files into the directory that
|
|
||||||
will become the root directory of the built package and is run after all
|
|
||||||
the optional functions listed below. The packaging stage is run using
|
|
||||||
fakeroot to ensure correct file permissions in the resulting package.
|
|
||||||
All other functions will be run as the user calling makepkg.
|
|
||||||
This function is run inside `$srcdir`.
|
|
||||||
|
|
||||||
*verify() Function*::
|
|
||||||
An optional `verify()` function can be specified to implement arbitrary
|
|
||||||
source authentication. The function should return a non-zero exit code when
|
|
||||||
verification fails. This function is run before sources are extracted.
|
|
||||||
This function is run inside `$startdir`.
|
|
||||||
|
|
||||||
*prepare() Function*::
|
|
||||||
An optional `prepare()` function can be specified in which operations to
|
|
||||||
prepare the sources for building, such as patching, are performed. This
|
|
||||||
function is run after the source extraction and before the `build()`
|
|
||||||
function. The `prepare()` function is skipped when source extraction
|
|
||||||
is skipped.
|
|
||||||
This function is run inside `$srcdir`.
|
|
||||||
|
|
||||||
*build() Function*::
|
|
||||||
The optional `build()` function is used to compile and/or adjust the source
|
|
||||||
files in preparation to be installed by the `package()` function.
|
|
||||||
This function is run inside `$srcdir`.
|
|
||||||
|
|
||||||
*check() Function*::
|
|
||||||
An optional `check()` function can be specified in which a package's
|
|
||||||
test-suite may be run. This function is run between the `build()` and
|
|
||||||
`package()` functions. Be sure any exotic commands used are covered by the
|
|
||||||
`checkdepends` array.
|
|
||||||
This function is run inside `$srcdir`.
|
|
||||||
|
|
||||||
All of the above variables such as `$pkgname` and `$pkgver` are available for
|
|
||||||
use in the packaging functions. In addition, makepkg defines the following
|
|
||||||
variables:
|
|
||||||
|
|
||||||
*srcdir*::
|
|
||||||
This contains the directory where makepkg extracts, or copies, all source
|
|
||||||
files.
|
|
||||||
+
|
|
||||||
|
|
||||||
*pkgdir*::
|
|
||||||
This contains the directory where makepkg bundles the installed package.
|
|
||||||
This directory will become the root directory of your built package. This
|
|
||||||
variable should only be used in the `package()` function.
|
|
||||||
|
|
||||||
*startdir*::
|
|
||||||
This contains the absolute path to the directory where the PKGBUILD is
|
|
||||||
located, which is usually the output of `$(pwd)` when makepkg is started.
|
|
||||||
Use of this variable is deprecated and strongly discouraged.
|
|
||||||
|
|
||||||
|
|
||||||
Package Splitting
|
|
||||||
-----------------
|
|
||||||
makepkg supports building multiple packages from a single PKGBUILD. This is
|
|
||||||
achieved by assigning an array of package names to the `pkgname` directive.
|
|
||||||
Each split package uses a corresponding packaging function with name
|
|
||||||
`package_foo()`, where `foo` is the name of the split package.
|
|
||||||
|
|
||||||
All options and directives for the split packages default to the global values
|
|
||||||
given in the PKGBUILD. Nevertheless, the following ones can be overridden within
|
|
||||||
each split package's packaging function:
|
|
||||||
`pkgdesc`, `arch`, `url`, `license`, `groups`, `depends`, `optdepends`,
|
|
||||||
`provides`, `conflicts`, `replaces`, `backup`, `options`, `install`, and
|
|
||||||
`changelog`.
|
|
||||||
|
|
||||||
Note that makepkg does not consider split package `depends` when checking
|
|
||||||
if dependencies are installed before package building and with `--syncdeps`.
|
|
||||||
All packages required to make the package are required to be specified in
|
|
||||||
the global `depends` and `makedepends` arrays.
|
|
||||||
|
|
||||||
An optional global directive is available when building a split package:
|
|
||||||
|
|
||||||
*pkgbase*::
|
|
||||||
The name used to refer to the group of packages in the output of makepkg
|
|
||||||
and in the naming of source-only tarballs. If not specified, the first
|
|
||||||
element in the `pkgname` array is used. Valid characters for this
|
|
||||||
variable are alphanumerics, and any of the following characters:
|
|
||||||
```@ . _ + -`''. Additionally, the variable is not allowed to start with
|
|
||||||
hyphens or dots.
|
|
||||||
|
|
||||||
|
|
||||||
Install/Upgrade/Remove Scripting
|
|
||||||
--------------------------------
|
|
||||||
Pacman has the ability to store and execute a package-specific script when it
|
|
||||||
installs, removes, or upgrades a package. This allows a package to configure
|
|
||||||
itself after installation and perform an opposite action upon removal.
|
|
||||||
|
|
||||||
The exact time the script is run varies with each operation, and should be
|
|
||||||
self-explanatory. Note that during an upgrade operation, none of the install
|
|
||||||
or remove functions will be called.
|
|
||||||
|
|
||||||
Scripts are passed either one or two ``full version strings'', where a full
|
|
||||||
version string is either 'pkgver-pkgrel' or 'epoch:pkgver-pkgrel', if epoch is
|
|
||||||
non-zero.
|
|
||||||
|
|
||||||
*pre_install*::
|
|
||||||
Run right before files are extracted. One argument is passed:
|
|
||||||
new package full version string.
|
|
||||||
|
|
||||||
*post_install*::
|
|
||||||
Run right after files are extracted. One argument is passed:
|
|
||||||
new package full version string.
|
|
||||||
|
|
||||||
*pre_upgrade*::
|
|
||||||
Run right before files are extracted. Two arguments are passed in this
|
|
||||||
order: new package full version string, old package full version string.
|
|
||||||
|
|
||||||
*post_upgrade*::
|
|
||||||
Run after files are extracted. Two arguments are passed in this order:
|
|
||||||
new package full version string, old package full version string.
|
|
||||||
|
|
||||||
*pre_remove*::
|
|
||||||
Run right before files are removed. One argument is passed:
|
|
||||||
old package full version string.
|
|
||||||
|
|
||||||
*post_remove*::
|
|
||||||
Run right after files are removed. One argument is passed:
|
|
||||||
old package full version string.
|
|
||||||
|
|
||||||
To use this feature, create a file such as 'pkgname.install' and put it in the
|
|
||||||
same directory as the PKGBUILD script. Then use the install directive:
|
|
||||||
|
|
||||||
install=pkgname.install
|
|
||||||
|
|
||||||
The install script does not need to be specified in the source array. A
|
|
||||||
template install file is available in '{pkgdatadir}' as 'proto.install' for
|
|
||||||
reference with all of the available functions defined.
|
|
||||||
|
|
||||||
|
|
||||||
Using VCS Sources[[VCS]]
|
|
||||||
------------------------
|
|
||||||
Building a developmental version of a package using sources from a version
|
|
||||||
control system (VCS) is enabled by specifying the source in the form:
|
|
||||||
|
|
||||||
source=('directory::url#fragment?query')
|
|
||||||
|
|
||||||
Currently makepkg supports the Bazaar, Git, Subversion, Fossil and Mercurial
|
|
||||||
version control systems. For other version control systems, manual cloning of
|
|
||||||
upstream repositories must be done in the `prepare()` function.
|
|
||||||
|
|
||||||
Some <<VCS,VCS Sources>> like Git support pinning the checkout by a checksum of
|
|
||||||
its content using deterministic export functionality like ``git archive''.
|
|
||||||
|
|
||||||
The source URL is divided into four components:
|
|
||||||
|
|
||||||
*directory*::
|
|
||||||
(optional) Specifies an alternate directory name for makepkg to download
|
|
||||||
the VCS source into.
|
|
||||||
|
|
||||||
*url*::
|
|
||||||
The URL to the VCS repository. This must include the VCS in the URL protocol
|
|
||||||
for makepkg to recognize this as a VCS source. If the protocol does not
|
|
||||||
include the VCS name, it can be added by prefixing the URL with `vcs+`. For
|
|
||||||
example, using a Git repository over HTTPS would have a source URL in the
|
|
||||||
form:
|
|
||||||
`git+https://...`.
|
|
||||||
|
|
||||||
*fragment*::
|
|
||||||
(optional) Allows specifying a revision number or branch for makepkg to checkout
|
|
||||||
from the VCS. A fragment has the form `type=value`, for example to checkout a
|
|
||||||
given revision the source line would be `source=(url#revision=123)`. The
|
|
||||||
available types depends on the VCS being used:
|
|
||||||
|
|
||||||
*bzr*;;
|
|
||||||
revision (see `'bzr help revisionspec'` for details)
|
|
||||||
|
|
||||||
*fossil*;;
|
|
||||||
branch, commit, tag
|
|
||||||
|
|
||||||
*git*;;
|
|
||||||
branch, commit, tag
|
|
||||||
|
|
||||||
*hg*;;
|
|
||||||
branch, revision, tag
|
|
||||||
|
|
||||||
*svn*;;
|
|
||||||
revision
|
|
||||||
|
|
||||||
*query*::
|
|
||||||
(optional) Allows specifying whether a VCS checkout should be checked for
|
|
||||||
PGP-signed revisions. The source line should have the format
|
|
||||||
`source=(url#fragment?signed)` or `source=(url?signed#fragment)`. Currently
|
|
||||||
only supported by Git.
|
|
||||||
|
|
||||||
Example
|
|
||||||
-------
|
|
||||||
The following is an example PKGBUILD for the 'patch' package. For more
|
|
||||||
examples, look through the build files of your distribution's packages.
|
|
||||||
|
|
||||||
[source,sh]
|
|
||||||
-------------------------------
|
|
||||||
include::PKGBUILD-example.txt[]
|
|
||||||
-------------------------------
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:makepkg[8], linkman:pacman[8], linkman:makepkg.conf[5]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,133 +0,0 @@
|
||||||
alpm-hooks(5)
|
|
||||||
=============
|
|
||||||
|
|
||||||
NAME
|
|
||||||
----
|
|
||||||
|
|
||||||
alpm-hooks - alpm hook file format
|
|
||||||
|
|
||||||
SYNOPSIS
|
|
||||||
--------
|
|
||||||
|
|
||||||
--------
|
|
||||||
[Trigger] (Required, Repeatable)
|
|
||||||
Operation = Install|Upgrade|Remove (Required, Repeatable)
|
|
||||||
Type = Path|Package (Required)
|
|
||||||
Target = <Path|PkgName> (Required, Repeatable)
|
|
||||||
|
|
||||||
[Action] (Required)
|
|
||||||
Description = ... (Optional)
|
|
||||||
When = PreTransaction|PostTransaction (Required)
|
|
||||||
Exec = <Command> (Required)
|
|
||||||
Depends = <PkgName> (Optional)
|
|
||||||
AbortOnFail (Optional, PreTransaction only)
|
|
||||||
NeedsTargets (Optional)
|
|
||||||
--------
|
|
||||||
|
|
||||||
DESCRIPTION
|
|
||||||
-----------
|
|
||||||
|
|
||||||
libalpm provides the ability to specify hooks to run before or after
|
|
||||||
transactions based on the packages and/or files being modified. Hooks consist
|
|
||||||
of a single '[Action]' section describing the action to be run and one or more
|
|
||||||
'[Trigger]' section describing which transactions it should be run for.
|
|
||||||
|
|
||||||
Hooks are read from files located in the system hook directory
|
|
||||||
+{datarootdir}/libalpm/hooks+, and additional custom directories specified in
|
|
||||||
linkman:pacman.conf[5] (the default is +{sysconfdir}/pacman.d/hooks+). The
|
|
||||||
file names are required to have the suffix ".hook". Hooks are run in
|
|
||||||
alphabetical order of their file name, where the ordering ignores the suffix.
|
|
||||||
|
|
||||||
TRIGGERS
|
|
||||||
--------
|
|
||||||
|
|
||||||
Hooks must contain at least one '[Trigger]' section that determines which
|
|
||||||
transactions will cause the hook to run. If multiple trigger sections are
|
|
||||||
defined the hook will run if the transaction matches *any* of the triggers.
|
|
||||||
|
|
||||||
*Operation =* Install|Upgrade|Remove::
|
|
||||||
Select the type of operation to match targets against. May be specified
|
|
||||||
multiple times. Installations are considered an upgrade if the package or
|
|
||||||
file is already present on the system regardless of whether the new package
|
|
||||||
version is actually greater than the currently installed version. For Path
|
|
||||||
triggers, this is true even if the file changes ownership from one package
|
|
||||||
to another. Required.
|
|
||||||
|
|
||||||
*Type =* Path|Package::
|
|
||||||
Select whether targets are matched against transaction packages or files.
|
|
||||||
See CAVEATS for special notes regarding Path triggers. 'File' is a deprecated
|
|
||||||
alias for 'Path' and will be removed in a future release. Required.
|
|
||||||
|
|
||||||
*Target =* <path|package>::
|
|
||||||
The path or package name to match against the active transaction.
|
|
||||||
Paths refer to the files in the package archive; the installation root
|
|
||||||
should *not* be included in the path. Shell-style glob patterns are
|
|
||||||
allowed. It is possible to invert matches by prepending a target with an
|
|
||||||
exclamation mark. May be specified multiple times. Required.
|
|
||||||
|
|
||||||
ACTIONS
|
|
||||||
-------
|
|
||||||
|
|
||||||
*Description =* ...::
|
|
||||||
An optional description that describes the action being taken by the
|
|
||||||
hook for use in front-end output.
|
|
||||||
|
|
||||||
*Exec =* <command>::
|
|
||||||
Command to run. Command arguments are split on whitespace. Values
|
|
||||||
containing whitespace should be enclosed in quotes. Required.
|
|
||||||
|
|
||||||
*When =* PreTransaction|PostTransaction::
|
|
||||||
When to run the hook. Required.
|
|
||||||
|
|
||||||
*Depends =* <package>::
|
|
||||||
Packages that must be installed for the hook to run. May be specified
|
|
||||||
multiple times.
|
|
||||||
|
|
||||||
*AbortOnFail*::
|
|
||||||
Causes the transaction to be aborted if the hook exits non-zero. Only
|
|
||||||
applies to PreTransaction hooks.
|
|
||||||
|
|
||||||
*NeedsTargets*::
|
|
||||||
Causes the list of matched trigger targets to be passed to the running hook
|
|
||||||
on 'stdin'.
|
|
||||||
|
|
||||||
OVERRIDING HOOKS
|
|
||||||
----------------
|
|
||||||
|
|
||||||
Hooks may be overridden by placing a file with the same name in a higher
|
|
||||||
priority hook directory. Hooks may be disabled by overriding them with
|
|
||||||
a symlink to '/dev/null'.
|
|
||||||
|
|
||||||
EXAMPLES
|
|
||||||
--------
|
|
||||||
|
|
||||||
--------
|
|
||||||
# Force disks to sync to reduce the risk of data corruption
|
|
||||||
|
|
||||||
[Trigger]
|
|
||||||
Operation = Install
|
|
||||||
Operation = Upgrade
|
|
||||||
Operation = Remove
|
|
||||||
Type = Package
|
|
||||||
Target = *
|
|
||||||
|
|
||||||
[Action]
|
|
||||||
Depends = coreutils
|
|
||||||
When = PostTransaction
|
|
||||||
Exec = /usr/bin/sync
|
|
||||||
--------
|
|
||||||
|
|
||||||
CAVEATS
|
|
||||||
-------
|
|
||||||
|
|
||||||
There are situations when path triggers may act in unexpected ways. Hooks are
|
|
||||||
triggered using the file list of the installed, upgraded, or removed package.
|
|
||||||
When installing or upgrading a file that is extracted with a '.pacnew'
|
|
||||||
extension, the original file name is used in triggering the hook. When
|
|
||||||
removing a package, all files owned by that package can trigger a hook whether
|
|
||||||
or not they were actually present on the file system before package removal.
|
|
||||||
|
|
||||||
PostTransaction hooks will *not* run if the transaction fails to complete for
|
|
||||||
any reason.
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,7 +0,0 @@
|
||||||
table th, table td {
|
|
||||||
padding: 0.2em 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
table td p.table {
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
|
@ -1,72 +0,0 @@
|
||||||
## linkman: macro
|
|
||||||
# Inspired by/borrowed from the Git source tree at Documentation/asciidoc.conf
|
|
||||||
#
|
|
||||||
# Usage: linkman:command[manpage-section]
|
|
||||||
#
|
|
||||||
# Note, {0} is the manpage section, while {target} is the command.
|
|
||||||
#
|
|
||||||
# Show man link as: <command>(<section>); if section is defined, else just show
|
|
||||||
# the command.
|
|
||||||
|
|
||||||
[macros]
|
|
||||||
(?su)[\\]?(?P<name>linkman):(?P<target>\S*?)\[(?P<attrlist>.*?)\]=
|
|
||||||
|
|
||||||
[attributes]
|
|
||||||
asterisk=*
|
|
||||||
plus=+
|
|
||||||
caret=^
|
|
||||||
startsb=[
|
|
||||||
endsb=]
|
|
||||||
backslash=\
|
|
||||||
tilde=~
|
|
||||||
apostrophe='
|
|
||||||
backtick=`
|
|
||||||
litdd=--
|
|
||||||
|
|
||||||
ifdef::backend-docbook[]
|
|
||||||
[linkman-inlinemacro]
|
|
||||||
{0%{target}}
|
|
||||||
{0#<citerefentry>}
|
|
||||||
{0#<refentrytitle>{target}</refentrytitle><manvolnum>{0}</manvolnum>}
|
|
||||||
{0#</citerefentry>}
|
|
||||||
endif::backend-docbook[]
|
|
||||||
|
|
||||||
ifdef::backend-docbook[]
|
|
||||||
ifndef::docbook-xsl-172[]
|
|
||||||
# "unbreak" docbook-xsl v1.68 for manpages. v1.69 works with or without this.
|
|
||||||
# v1.72 breaks with this because it replaces dots not in roff requests.
|
|
||||||
[listingblock]
|
|
||||||
<example><title>{title}</title>
|
|
||||||
<literallayout>
|
|
||||||
|
|
|
||||||
</literallayout>
|
|
||||||
{title#}</example>
|
|
||||||
endif::docbook-xsl-172[]
|
|
||||||
endif::backend-docbook[]
|
|
||||||
|
|
||||||
ifdef::doctype-manpage[]
|
|
||||||
ifdef::backend-docbook[]
|
|
||||||
[header]
|
|
||||||
template::[header-declarations]
|
|
||||||
<refentry>
|
|
||||||
<refentryinfo>
|
|
||||||
<date>{localdate}</date>
|
|
||||||
</refentryinfo>
|
|
||||||
<refmeta>
|
|
||||||
<refentrytitle>{mantitle}</refentrytitle>
|
|
||||||
<manvolnum>{manvolnum}</manvolnum>
|
|
||||||
<refmiscinfo class="source">Pacman</refmiscinfo>
|
|
||||||
<refmiscinfo class="version">{pacman_version}</refmiscinfo>
|
|
||||||
<refmiscinfo class="manual">Pacman Manual</refmiscinfo>
|
|
||||||
</refmeta>
|
|
||||||
<refnamediv>
|
|
||||||
<refname>{manname}</refname>
|
|
||||||
<refpurpose>{manpurpose}</refpurpose>
|
|
||||||
</refnamediv>
|
|
||||||
endif::backend-docbook[]
|
|
||||||
endif::doctype-manpage[]
|
|
||||||
|
|
||||||
ifdef::backend-xhtml11[]
|
|
||||||
[linkman-inlinemacro]
|
|
||||||
<a href="{target}.{0}.html">{target}{0?({0})}</a>
|
|
||||||
endif::backend-xhtml11[]
|
|
|
@ -1,36 +0,0 @@
|
||||||
|
|
||||||
See the pacman website at https://archlinux.org/pacman/[] for current
|
|
||||||
information on pacman and its related tools.
|
|
||||||
|
|
||||||
|
|
||||||
Bugs
|
|
||||||
----
|
|
||||||
Bugs? You must be kidding; there are no bugs in this software. But if we
|
|
||||||
happen to be wrong, please report them to the issue tracker at
|
|
||||||
link:https://gitlab.archlinux.org/pacman/pacman/-/issues[] with specific
|
|
||||||
information such as your command-line, the nature of the bug, and even
|
|
||||||
the package database if it helps.
|
|
||||||
|
|
||||||
|
|
||||||
Authors
|
|
||||||
-------
|
|
||||||
|
|
||||||
Current maintainers:
|
|
||||||
|
|
||||||
* Allan McRae <allan@archlinux.org>
|
|
||||||
* Andrew Gregory <andrew.gregory.8@gmail.com>
|
|
||||||
* Morgan Adamiec <morganamilo@archlinux.org>
|
|
||||||
|
|
||||||
Past major contributors:
|
|
||||||
|
|
||||||
* Judd Vinet <jvinet@zeroflux.org>
|
|
||||||
* Aurelien Foret <aurelien@archlinux.org>
|
|
||||||
* Aaron Griffin <aaron@archlinux.org>
|
|
||||||
* Dan McGee <dan@archlinux.org>
|
|
||||||
* Xavier Chantry <shiningxc@gmail.com>
|
|
||||||
* Nagy Gabor <ngaba@bibl.u-szeged.hu>
|
|
||||||
* Dave Reisner <dreisner@archlinux.org>
|
|
||||||
* Eli Schwartz <eschwartz@archlinux.org>
|
|
||||||
|
|
||||||
For additional contributors, use `git shortlog -s` on the pacman.git
|
|
||||||
repository.
|
|
|
@ -1,258 +0,0 @@
|
||||||
Pacman Home Page
|
|
||||||
================
|
|
||||||
|
|
||||||
A simple library-based package manager.
|
|
||||||
|
|
||||||
Introduction
|
|
||||||
------------
|
|
||||||
pacman is a utility which manages software packages in Linux. It uses simple
|
|
||||||
compressed files as a package format, and maintains a text-based package
|
|
||||||
database (more of a hierarchy), just in case some hand tweaking is necessary.
|
|
||||||
|
|
||||||
pacman does not strive to "do everything." It will add, remove and upgrade
|
|
||||||
packages in the system, and it will allow you to query the package database for
|
|
||||||
installed packages, files and owners. It also attempts to handle dependencies
|
|
||||||
automatically and can download packages from a remote server.
|
|
||||||
|
|
||||||
History
|
|
||||||
~~~~~~~
|
|
||||||
Version 2.0 of pacman introduced the ability to sync packages (the '\--sync'
|
|
||||||
option) with a master server through the use of package databases. Prior to
|
|
||||||
this, packages would have to be installed manually using the '\--add' and
|
|
||||||
'\--upgrade' operations.
|
|
||||||
|
|
||||||
Version 3.0 was the switch to a two-part pacman -- a back-end named libalpm
|
|
||||||
(library for Arch Linux Package Management) and the familiar pacman front-end.
|
|
||||||
Speed in many cases was improved, along with dependency and conflict resolution
|
|
||||||
being able to handle a much wider variety of cases. The switch to a
|
|
||||||
library-based program should also make it easier in the future to develop
|
|
||||||
alternative front ends.
|
|
||||||
|
|
||||||
Version 4.0 added package signing and verification capabilities to the entire
|
|
||||||
makepkg/repo-add/pacman toolchain via GnuPG and GPGME.
|
|
||||||
|
|
||||||
Version 5.0 added support for pre/post-transaction hooks and sync database file
|
|
||||||
list operations.
|
|
||||||
|
|
||||||
Version 6.0 added support for parallel downloads.
|
|
||||||
|
|
||||||
Documentation
|
|
||||||
-------------
|
|
||||||
|
|
||||||
Man Pages
|
|
||||||
~~~~~~~~~
|
|
||||||
There are several man pages available for the programs, utilities, and
|
|
||||||
configuration files dealing with pacman.
|
|
||||||
|
|
||||||
* linkman:alpm-hooks[5]
|
|
||||||
* linkman:BUILDINFO[5]
|
|
||||||
* linkman:PKGBUILD[5]
|
|
||||||
* linkman:libalpm[3]
|
|
||||||
* linkman:makepkg[8]
|
|
||||||
* linkman:makepkg-template[1]
|
|
||||||
* linkman:makepkg.conf[5]
|
|
||||||
* linkman:pacman[8]
|
|
||||||
* linkman:pacman-key[8]
|
|
||||||
* linkman:pacman-conf[8]
|
|
||||||
* linkman:pacman.conf[5]
|
|
||||||
* linkman:repo-add[8]
|
|
||||||
* linkman:vercmp[8]
|
|
||||||
|
|
||||||
Changelog
|
|
||||||
~~~~~~~~~
|
|
||||||
For a good idea of what is going on in pacman development, take a look at the
|
|
||||||
link:https://gitlab.archlinux.org/pacman/pacman[Git summary page] for the
|
|
||||||
project.
|
|
||||||
|
|
||||||
See the most recent
|
|
||||||
link:https://gitlab.archlinux.org/pacman/pacman/-/blob/master/NEWS[NEWS]
|
|
||||||
file for a not-as-frequently-updated list of changes. However, this should
|
|
||||||
contain the biggest changes in a format more concise than the commit log.
|
|
||||||
|
|
||||||
|
|
||||||
Releases
|
|
||||||
--------
|
|
||||||
|
|
||||||
[frame="none",grid="none",options="autowidth",cols="3*a"]
|
|
||||||
|======
|
|
||||||
|
|
|
||||||
[frame="topbot",grid="none",options="header,autowidth"]
|
|
||||||
!======
|
|
||||||
!Version !Date
|
|
||||||
!7.0.0 !2024-07-14
|
|
||||||
!6.1.0 !2024-03-04
|
|
||||||
!6.0.1 !2021-09-04
|
|
||||||
!6.0.0 !2021-05-20
|
|
||||||
!6.0.0alpha1 !2020-12-04
|
|
||||||
!5.2.1 !2019-11-01
|
|
||||||
!5.2.0 !2019-10-21
|
|
||||||
!5.1.3 !2019-03-01
|
|
||||||
!5.1.2 !2018-12-25
|
|
||||||
!5.1.1 !2018-07-27
|
|
||||||
!5.1.0 !2018-05-28
|
|
||||||
!5.0.2 !2017-06-03
|
|
||||||
!5.0.1 !2016-02-23
|
|
||||||
!5.0.0 !2016-01-30
|
|
||||||
!4.2.1 !2015-02-20
|
|
||||||
!4.2.0 !2014-12-19
|
|
||||||
!4.1.2 !2013-06-18
|
|
||||||
!4.1.1 !2013-05-07
|
|
||||||
!4.1.0 !2013-04-01
|
|
||||||
!4.1.0rc1 !2013-03-09
|
|
||||||
!4.0.3 !2012-04-07
|
|
||||||
!4.0.2 !2012-02-11
|
|
||||||
!4.0.1 !2011-11-20
|
|
||||||
!4.0.0 !2011-10-13
|
|
||||||
!4.0.0rc2 !2011-09-22
|
|
||||||
!4.0.0rc1 !2011-08-11
|
|
||||||
!3.5.4 !2011-08-10
|
|
||||||
!3.5.3 !2011-06-07
|
|
||||||
!3.5.2 !2011-04-18
|
|
||||||
!3.5.1 !2011-03-23
|
|
||||||
!3.5.0 !2011-03-16
|
|
||||||
!3.4.3 !2011-01-22
|
|
||||||
!3.4.2 !2010-12-29
|
|
||||||
!3.4.1 !2010-09-03
|
|
||||||
!======
|
|
||||||
|
|
|
||||||
[frame="topbot",grid="none",options="header,autowidth"]
|
|
||||||
!======
|
|
||||||
!Version !Date
|
|
||||||
!3.4.0 !2010-06-16
|
|
||||||
!3.3.3 !2009-11-10
|
|
||||||
!3.3.2 !2009-10-05
|
|
||||||
!3.3.1 !2009-09-22
|
|
||||||
!3.3.0 !2009-08-02
|
|
||||||
!3.2.2 !2009-01-05
|
|
||||||
!3.2.1 !2008-08-26
|
|
||||||
!3.2.0 !2008-07-30
|
|
||||||
!3.1.4 !2008-04-01
|
|
||||||
!3.1.3 !2008-03-06
|
|
||||||
!3.1.2 !2008-02-20
|
|
||||||
!3.1.1 !2008-01-20
|
|
||||||
!3.1.0 !2008-01-09
|
|
||||||
!3.0.6 !2007-09-16
|
|
||||||
!3.0.5 !2007-06-17
|
|
||||||
!3.0.4 !2007-05-08
|
|
||||||
!3.0.3 !2007-04-28
|
|
||||||
!3.0.2 !2007-04-23
|
|
||||||
!3.0.1 !2007-04-04
|
|
||||||
!3.0.0 !2007-03-25
|
|
||||||
!2.9.8 !2006-02-02
|
|
||||||
!2.9.7 !2005-09-16
|
|
||||||
!2.9.7-TEST3 !2005-09-11
|
|
||||||
!2.9.7-TEST2 !2005-09-07
|
|
||||||
!2.9.7-TEST !2005-08-19
|
|
||||||
!2.9.6 !2005-06-10
|
|
||||||
!2.9.5 !2005-01-11
|
|
||||||
!2.9.4 !2004-12-20
|
|
||||||
!2.9.3 !2004-12-19
|
|
||||||
!2.9.2 !2004-09-25
|
|
||||||
!2.9.1 !2004-09-25
|
|
||||||
!2.9 !2004-09-18
|
|
||||||
!2.8.4 !2004-08-23
|
|
||||||
!2.8.3 !2004-08-04
|
|
||||||
!======
|
|
||||||
|
|
|
||||||
[frame="topbot",grid="none",options="header,autowidth"]
|
|
||||||
!======
|
|
||||||
!Version !Date
|
|
||||||
!2.8.2 !2004-07-22
|
|
||||||
!2.8.1 !2004-07-17
|
|
||||||
!2.8 !2004-07-03
|
|
||||||
!2.7.9 !2004-04-30
|
|
||||||
!2.7.8 !2004-04-29
|
|
||||||
!2.7.7 !2004-04-15
|
|
||||||
!2.7.6 !2004-04-04
|
|
||||||
!2.7.5 !2004-03-02
|
|
||||||
!2.7.4 !2004-02-18
|
|
||||||
!2.7.3 !2004-02-07
|
|
||||||
!2.7.2 !2004-01-04
|
|
||||||
!2.7.1 !2003-12-21
|
|
||||||
!2.7 !2003-11-25
|
|
||||||
!2.6.4 !2003-10-17
|
|
||||||
!2.6.3 !2003-10-01
|
|
||||||
!2.6.2 !2003-09-29
|
|
||||||
!2.6.1 !2003-09-15
|
|
||||||
!2.6 !2003-09-03
|
|
||||||
!2.5.1 !2003-07-12
|
|
||||||
!2.5 !2003-05-30
|
|
||||||
!2.4.1 !2003-04-19
|
|
||||||
!2.4 !2003-04-11
|
|
||||||
!2.3.2 !2003-03-17
|
|
||||||
!2.3.1 !2003-03-14
|
|
||||||
!2.3 !2003-02-27
|
|
||||||
!2.2 !2002-12-11
|
|
||||||
!2.1 !2002-09-16
|
|
||||||
!2.0 !2002-08-09
|
|
||||||
!1.23 !2002-04-30
|
|
||||||
!1.22 !2002-04-12
|
|
||||||
!1.21 !2002-04-03
|
|
||||||
!1.2 !2002-03-18
|
|
||||||
!1.1 !2002-03-10
|
|
||||||
!1.0 !2002-02-25
|
|
||||||
!======
|
|
||||||
|
|
||||||
|======
|
|
||||||
|
|
||||||
Source code for releases since moving to gitlab is available at
|
|
||||||
link:https://gitlab.archlinux.org/pacman/pacman/-/releases[].
|
|
||||||
Source code for historical releases is available at
|
|
||||||
link:https://sources.archlinux.org/other/pacman/[]. To install, download the newest
|
|
||||||
available source tarball, unpack it in a directory, and run the three magic
|
|
||||||
commands:
|
|
||||||
|
|
||||||
$ meson build
|
|
||||||
$ ninja -C build
|
|
||||||
# ninja -C build install
|
|
||||||
|
|
||||||
You may wish to read the options presented by `meson` in order to
|
|
||||||
set appropriate paths and build options that are correct for your system.
|
|
||||||
|
|
||||||
Development
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Mailing List
|
|
||||||
~~~~~~~~~~~~
|
|
||||||
There is a mailing list devoted to pacman development, hosted by Arch Linux.
|
|
||||||
link:https://lists.archlinux.org/listinfo/pacman-dev/[Subscribe] or
|
|
||||||
link:https://lists.archlinux.org/pipermail/pacman-dev/[view the archives].
|
|
||||||
|
|
||||||
Source Code
|
|
||||||
~~~~~~~~~~~
|
|
||||||
Development of pacman is currently done in Git. The central repository is
|
|
||||||
hosted by Arch Linux, although some of the developers have their own trees (ask
|
|
||||||
on the above mailing lists if you are interested in finding the locations of
|
|
||||||
these trees).
|
|
||||||
|
|
||||||
The current development tree can be fetched with the following command:
|
|
||||||
|
|
||||||
git clone https://gitlab.archlinux.org/pacman/pacman.git
|
|
||||||
|
|
||||||
which will fetch the full development history into a directory named pacman.
|
|
||||||
You can browse the source as well using
|
|
||||||
link:https://gitlab.archlinux.org/pacman/pacman/[gitlab].
|
|
||||||
|
|
||||||
If you are interested in hacking on pacman, it is highly recommended you join
|
|
||||||
the mailing list mentioned above, as well as take a quick glance at our
|
|
||||||
link:HACKING.html[HACKING] document.
|
|
||||||
link:submitting-patches.html[submitting-patches] is also a recommended read.
|
|
||||||
|
|
||||||
Not as familiar with code as you'd like to be, but still want to help out? If
|
|
||||||
you speak a foreign language, you can help by either creating or updating a
|
|
||||||
translation file for your native language. Instructions can be found in
|
|
||||||
link:translation-help.html[translation-help].
|
|
||||||
|
|
||||||
Bugs
|
|
||||||
----
|
|
||||||
If you find bugs (which is quite likely), please report them to the issue
|
|
||||||
tracker at link:https://gitlab.archlinux.org/pacman/pacman/-/issues[] with
|
|
||||||
specific information such as your command-line, the nature of the bug, and even
|
|
||||||
the package database if it helps.
|
|
||||||
|
|
||||||
Copyright
|
|
||||||
---------
|
|
||||||
pacman is Copyright (C) 2006-2025 Pacman Development Team
|
|
||||||
<pacman-dev@lists.archlinux.org> and Copyright (C) 2002-2006 Judd Vinet
|
|
||||||
<jvinet@zeroflux.org> and is licensed through the GNU General Public License,
|
|
||||||
version 2 or later.
|
|
53
doc/libalpm.3
Normal file
53
doc/libalpm.3
Normal file
|
@ -0,0 +1,53 @@
|
||||||
|
." the string declarations are a start to try and make distro independent
|
||||||
|
.ds DS Arch Linux
|
||||||
|
.ds PB PKGBUILD
|
||||||
|
.ds VR 3.0.0
|
||||||
|
.ds LV 1.0.0
|
||||||
|
.TH libalpm 3 "Feb 08, 2007" "libalpm version \*(LV" "\*(DS Utilities"
|
||||||
|
.SH NAME
|
||||||
|
libalpm \- Arch Linux Package Management (ALPM) library
|
||||||
|
|
||||||
|
.SH SYNOPSIS
|
||||||
|
For ease of access, the libalpm manual has been split up into several sections.
|
||||||
|
|
||||||
|
(TODO) Yes, this man page needs a lot of work. Once we get around to doing good
|
||||||
|
Doxygen documentation, it will improve. We promise.
|
||||||
|
|
||||||
|
.nf
|
||||||
|
alpm_databases Database Functions
|
||||||
|
alpm_interface Interface Functions
|
||||||
|
alpm_list List Functions
|
||||||
|
alpm_log Logging Functions
|
||||||
|
alpm_misc Miscellaneous Functions
|
||||||
|
alpm_packages Package Functions
|
||||||
|
alpm_sync Sync Functions
|
||||||
|
alpm_trans Transaction Functions
|
||||||
|
.fi
|
||||||
|
|
||||||
|
.SH CONFIGURATION
|
||||||
|
See
|
||||||
|
.BR pacman.conf (5)
|
||||||
|
for more details on configuring \fBlibalpm\fP using the \fBpacman.conf\fP file.
|
||||||
|
|
||||||
|
.SH BUGS
|
||||||
|
Bugs? You must be kidding, there are no bugs in this software. But if we happen
|
||||||
|
to be wrong, send us an email with as much detail as possible to
|
||||||
|
<pacman-dev@archlinux.org>.
|
||||||
|
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR pacman (8),
|
||||||
|
.BR makepkg (8),
|
||||||
|
.BR pacman.conf (5)
|
||||||
|
|
||||||
|
See the Arch Linux website at <http://www.archlinux.org> for more current
|
||||||
|
information on the distribution and the \fBpacman\fP family of tools.
|
||||||
|
|
||||||
|
.SH AUTHORS
|
||||||
|
.nf
|
||||||
|
Judd Vinet <jvinet@zeroflux.org>
|
||||||
|
Aurelien Foret <aurelien@archlinux.org>
|
||||||
|
Aaron Griffin <aaron@archlinux.org>
|
||||||
|
Dan McGee <dan@archlinux.org>
|
||||||
|
.fi
|
||||||
|
|
||||||
|
See the 'AUTHORS' file for additional contributors.
|
|
@ -1,118 +0,0 @@
|
||||||
makepkg-template(1)
|
|
||||||
===================
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
makepkg-template - package build templating utility
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'makepkg-template' [options]
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'makepkg-template' is a script to ease the work of maintaining multiple similar
|
|
||||||
PKGBUILDs. It allows you to move most of the code from the PKGBUILD into a
|
|
||||||
template file and uses markers to allow in-place updating of existing PKGBUILDs
|
|
||||||
if the template has been changed.
|
|
||||||
|
|
||||||
Template files can contain any code allowed in a PKGBUILD. You can think of
|
|
||||||
them like external files included with "." or "source", but they will be
|
|
||||||
inlined into the PKGBUILD by 'makepkg-template' so you do not depend on the
|
|
||||||
template file when building the package.
|
|
||||||
|
|
||||||
Markers are bash comments in the form of:
|
|
||||||
|
|
||||||
# template start; key=value; key2=value2; ...
|
|
||||||
|
|
||||||
and
|
|
||||||
|
|
||||||
# template end;
|
|
||||||
|
|
||||||
Currently used keys are: name (mandatory) and version. Template names are limited to
|
|
||||||
alphanumerics, "@", "+", ".", "-", and "_". Versions are limited to numbers and ".".
|
|
||||||
|
|
||||||
For initial creation there is a one line short cut which does not need an end marker:
|
|
||||||
|
|
||||||
# template input; key=value;
|
|
||||||
|
|
||||||
Using this short-cut will result in 'makepkg-template' replacing it with start
|
|
||||||
and end markers and the template code on the first run.
|
|
||||||
|
|
||||||
Template files should be stored in one directory and filenames should be
|
|
||||||
"$template_name-$version.template" with a symlink "$template_name.template"
|
|
||||||
pointing to the most recent template. If the version is not set in the marker,
|
|
||||||
'makepkg-template' will automatically use the target of "$template_name.template",
|
|
||||||
otherwise the specified version will be used. This allows for easier
|
|
||||||
verification of untrusted PKGBUILDs if the template is trusted. You verify the
|
|
||||||
non-template code and then use a command similar to this:
|
|
||||||
|
|
||||||
diff -u <(makepkg-template -o -) PKGBUILD
|
|
||||||
|
|
||||||
Template files may also contain markers leading to nested templates in the
|
|
||||||
resulting PKGBUILD. If you use markers in a template, please set the version
|
|
||||||
you used/tested with in the start/input marker so other people can properly
|
|
||||||
recreate from templates.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
*-p, \--input* <build script>::
|
|
||||||
Read the package script `build script` instead of the default.
|
|
||||||
|
|
||||||
*-o, \--output* <build script>::
|
|
||||||
Write the updated file to `build script` instead of overwriting the input file.
|
|
||||||
|
|
||||||
*-n, \--newest*::
|
|
||||||
Always use the newest available template file.
|
|
||||||
|
|
||||||
*\--template-dir* <dir>::
|
|
||||||
Change the dir where we are looking for template files. This option may be
|
|
||||||
given multiple times in which case files found in directory given last will
|
|
||||||
take precedence.
|
|
||||||
|
|
||||||
|
|
||||||
Example PKGBUILD
|
|
||||||
----------------
|
|
||||||
|
|
||||||
pkgname=perl-config-simple
|
|
||||||
pkgver=4.58
|
|
||||||
pkgrel=1
|
|
||||||
pkgdesc="simple configuration file class"
|
|
||||||
arch=('any')
|
|
||||||
license=('PerlArtistic' 'GPL')
|
|
||||||
depends=('perl')
|
|
||||||
source=("http://search.cpan.org/CPAN/authors/id/S/SH/SHERZODR/Config-Simple-${pkgver}.tar.gz")
|
|
||||||
sha256sums=('dd9995706f0f9384a15ccffe116c3b6e22f42ba2e58d8f24ed03c4a0e386edb4')
|
|
||||||
_distname="Config-Simple"
|
|
||||||
|
|
||||||
# template start; name=perl-module; version=1.0;
|
|
||||||
_distdir="${_distname}-${pkgver}"
|
|
||||||
url="https://metacpan.org/release/${_distname}"
|
|
||||||
options+=('!emptydirs')
|
|
||||||
|
|
||||||
build() {
|
|
||||||
cd "$srcdir/$_distdir"
|
|
||||||
perl Makefile.PL INSTALLDIRS=vendor
|
|
||||||
make
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
cd "$srcdir/$_distdir"
|
|
||||||
make test
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
cd "$srcdir/$_distdir"
|
|
||||||
make DESTDIR="$pkgdir" install
|
|
||||||
}
|
|
||||||
# template end;
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:makepkg[8], linkman:PKGBUILD[5]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
142
doc/makepkg.8
Normal file
142
doc/makepkg.8
Normal file
|
@ -0,0 +1,142 @@
|
||||||
|
." the string declarations are a start to try and make distro independent
|
||||||
|
.ds DS Arch Linux
|
||||||
|
.ds PB PKGBUILD
|
||||||
|
.ds VR 3.0.0
|
||||||
|
.TH makepkg 8 "Feb 07, 2007" "makepkg version \*(VR" "\*(DS Utilities"
|
||||||
|
.SH NAME
|
||||||
|
makepkg \- package build utility
|
||||||
|
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.B makepkg
|
||||||
|
[\fIoptions\fR]
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fBmakepkg\fP is a script to automate the building of packages. All it needs is
|
||||||
|
a build-capable Linux platform and a custom build script for each package you
|
||||||
|
wish to build (known as a \fB\*(PB\fP). See
|
||||||
|
.BR \*(PB (5)
|
||||||
|
for details on creating your own build scripts.
|
||||||
|
|
||||||
|
The advantage to a script-based build is that the work is only done once. Once
|
||||||
|
you have the build script for a package, makepkg will do the rest: download and
|
||||||
|
validate source files, check dependencies, configure the build-time settings,
|
||||||
|
build the package, install the package into a temporary root, make
|
||||||
|
customizations, generate meta-info, and package the whole thing up for
|
||||||
|
\fBpacman\fP to use.
|
||||||
|
|
||||||
|
\fBmakeworld\fP can be used to rebuild an entire package group or the entire
|
||||||
|
build tree. See \fBmakeworld --help\fP for syntax.
|
||||||
|
|
||||||
|
.SH OPTIONS
|
||||||
|
.TP
|
||||||
|
.B \-b, --builddeps
|
||||||
|
Build missing dependencies from source. When \fBmakepkg\fP finds missing
|
||||||
|
build-time or run-time dependencies, it will look for the dependencies'
|
||||||
|
\fB\*(PB\fP files under \fIABSROOT\fP (set in \fBmakepkg.conf\fP). If it finds
|
||||||
|
them it will call \fBmakepkg\fP to build and install the missing dependencies.
|
||||||
|
The child calls will be made with the \fB-b\fP and \fB-i\fP options.
|
||||||
|
.TP
|
||||||
|
.B \-c, --clean
|
||||||
|
Clean up leftover work files and directories after a successful build.
|
||||||
|
.TP
|
||||||
|
.B \-C, --cleancache
|
||||||
|
Removes all cached source files from the directory specified in \fISRCDEST\fP
|
||||||
|
in \fBmakepkg.conf\fP.
|
||||||
|
.TP
|
||||||
|
.B \-d, --nodeps
|
||||||
|
Do not perform any dependency checks. This will let you override and ignore any
|
||||||
|
dependencies required. There is a good chance this option will break the build
|
||||||
|
process if all of the dependencies are not installed.
|
||||||
|
.TP
|
||||||
|
.B \-e, --noextract
|
||||||
|
Do not extract source files; use whatever source already exists in the src/
|
||||||
|
directory. This is handy if you want to go into src and manually patch or tweak
|
||||||
|
code, then make a package out of the result. Keep in mind that creating a patch
|
||||||
|
may be a better solution to allow others to use your \fB\*(PB\fP.
|
||||||
|
.TP
|
||||||
|
.B \-f, --force
|
||||||
|
\fBmakepkg\fP will not build a package if a built package already exists in the
|
||||||
|
\fIPKGDEST\fP (set in \fBmakepkg.conf\fP) directory, which may default to the
|
||||||
|
current directory. This allows the built package to be overwritten.
|
||||||
|
.TP
|
||||||
|
.B \-g, --geninteg
|
||||||
|
For each source file in the source array of \fB\*(PB\fP, download the file if
|
||||||
|
required and generate integrity checks. The integrity checks generated are
|
||||||
|
determined by the value of the \fIINTEGRITY_CHECK\fP array in makepkg.conf.
|
||||||
|
This output can be redirected into your \fB\*(PB\fP for source validation
|
||||||
|
(makepkg -g >> \*(PB).
|
||||||
|
.TP
|
||||||
|
.B \-h, --help
|
||||||
|
Output syntax and command line options.
|
||||||
|
.TP
|
||||||
|
.B \-i, --install
|
||||||
|
Install or upgrade the package after a successful build using \fBpacman\fP.
|
||||||
|
.TP
|
||||||
|
.B \-m, --nocolor
|
||||||
|
Disable color in output messages.
|
||||||
|
.TP
|
||||||
|
.B \-o, --nobuild
|
||||||
|
Download and extract files only, but do not build them. Useful with the
|
||||||
|
\fB--noextract\fP option if you wish to tweak the files in src/ before
|
||||||
|
building.
|
||||||
|
.TP
|
||||||
|
.B \-p \fIbuildscript\fP
|
||||||
|
Read the package script \fIbuildscript\fP instead of the default, \fI\*(PB\fP.
|
||||||
|
.TP
|
||||||
|
.B \-r, --rmdeps
|
||||||
|
Upon successful build, remove any dependencies installed by \fBmakepkg\fP
|
||||||
|
during dependency auto-resolution (using \fB-b\fP or \fB-s\fP).
|
||||||
|
.TP
|
||||||
|
.B \-R, --repackage
|
||||||
|
Repackage contents of pkg/ without rebuilding the package. This is useful if
|
||||||
|
you forgot a depend or install file in your \fB\*(PB\fP and the build itself
|
||||||
|
will not change.
|
||||||
|
.TP
|
||||||
|
.B \-s, --syncdeps
|
||||||
|
Install missing dependencies using \fBpacman\fP. When missing build-time or
|
||||||
|
run-time dependencies are found, \fBpacman\fP will try to resolve them. If
|
||||||
|
successful, the missing packages will be downloaded and installed.
|
||||||
|
.TP
|
||||||
|
.B \-S, --usesudo
|
||||||
|
Use \fBsudo\fP to perform all operations that require \fBpacman\fP. This is
|
||||||
|
useful for \fB--install\fP, \fB--rmdeps\fP, and \fB--syncdeps\fP. If you are
|
||||||
|
building packages as a non-root user as recommended, this option should be used
|
||||||
|
if using any option that calls \fBpacman\fP.
|
||||||
|
.TP
|
||||||
|
.B \--noconfirm
|
||||||
|
(Passed to \fBpacman\fP) Prevent \fBpacman\fP from waiting for user input
|
||||||
|
before proceeding with operations.
|
||||||
|
.TP
|
||||||
|
.B \--noprogressbar
|
||||||
|
(Passed to \fBpacman\fP) Prevent \fBpacman\fP from displaying a progress bar;
|
||||||
|
useful if you are redirecting makepkg output to file.
|
||||||
|
|
||||||
|
.SH CONFIGURATION
|
||||||
|
See
|
||||||
|
.BR makepkg.conf (5)
|
||||||
|
for more details on configuring \fBmakepkg\fP using the \fBmakepkg.conf\fP file.
|
||||||
|
|
||||||
|
.SH BUGS
|
||||||
|
Bugs? You must be kidding, there are no bugs in this software. But if we happen
|
||||||
|
to be wrong, send us an email with as much detail as possible to
|
||||||
|
<pacman-dev@archlinux.org>.
|
||||||
|
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR makepkg.conf (5),
|
||||||
|
.BR \*(PB (5),
|
||||||
|
.BR pacman (8)
|
||||||
|
|
||||||
|
See the Arch Linux website at <http://www.archlinux.org> for more current
|
||||||
|
information on the distribution and the \fBpacman\fP family of tools, and
|
||||||
|
<http://wiki.archlinux.org/index.php/Arch_Packaging_Standards> for
|
||||||
|
recommendations on packaging standards.
|
||||||
|
|
||||||
|
.SH AUTHORS
|
||||||
|
.nf
|
||||||
|
Judd Vinet <jvinet@zeroflux.org>
|
||||||
|
Aurelien Foret <aurelien@archlinux.org>
|
||||||
|
Aaron Griffin <aaron@archlinux.org>
|
||||||
|
Dan McGee <dan@archlinux.org>
|
||||||
|
.fi
|
||||||
|
|
||||||
|
See the 'AUTHORS' file for additional contributors.
|
|
@ -1,382 +0,0 @@
|
||||||
makepkg(8)
|
|
||||||
==========
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
makepkg - package build utility
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'makepkg' [options] [ENVVAR=value] [ENVVAR+=value] ...
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'makepkg' is a script to automate the building of packages. The requirements for
|
|
||||||
using the script are a build-capable *nix platform and a custom build script
|
|
||||||
for each package you wish to build (known as a PKGBUILD). See
|
|
||||||
linkman:PKGBUILD[5] for details on creating your own build scripts.
|
|
||||||
|
|
||||||
The advantage to a script-based build is that the work is only done once. Once
|
|
||||||
you have the build script for a package, 'makepkg' will do the rest: download and
|
|
||||||
validate source files, check dependencies, configure the build-time settings,
|
|
||||||
build the package, install the package into a temporary root, make
|
|
||||||
customizations, generate meta-info, and package the whole thing up for pacman
|
|
||||||
to use.
|
|
||||||
|
|
||||||
NOTE: 'makepkg' uses your current locale by default and does not unset it when
|
|
||||||
building packages. If you wish to share your build output with others when
|
|
||||||
seeking help or for other purposes, you may wish to run "`LC_ALL=C makepkg`" so
|
|
||||||
your logs and output are not localized.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
*-A, \--ignorearch*::
|
|
||||||
Ignore a missing or incomplete arch field in the build script. This is
|
|
||||||
for rebuilding packages from source when the PKGBUILD may be slightly
|
|
||||||
outdated and not updated with an `arch=('yourarch')` field.
|
|
||||||
|
|
||||||
*-c, \--clean*::
|
|
||||||
Clean up leftover work files and directories after a successful build.
|
|
||||||
|
|
||||||
*\--config* <file>::
|
|
||||||
Use an alternate configuration file instead of the +{sysconfdir}/makepkg.conf+
|
|
||||||
default.
|
|
||||||
|
|
||||||
*-d, \--nodeps*::
|
|
||||||
Do not perform any dependency checks. This will let you override and
|
|
||||||
ignore any dependencies required. There is a good chance this option
|
|
||||||
will break the build process if all of the dependencies are not
|
|
||||||
installed.
|
|
||||||
|
|
||||||
*-e, \--noextract*::
|
|
||||||
Do not extract source files or run the prepare() function (if present);
|
|
||||||
use whatever source already exists in the $srcdir/ directory. This is
|
|
||||||
handy if you want to go into $srcdir/ and manually patch or tweak code,
|
|
||||||
then make a package out of the result. Keep in mind that creating a
|
|
||||||
patch may be a better solution to allow others to use your PKGBUILD.
|
|
||||||
|
|
||||||
*\--verifysource*::
|
|
||||||
For each source file in the source array of PKGBUILD, download the file
|
|
||||||
if required and perform the integrity checks. No extraction or build is
|
|
||||||
performed. Dependencies specified in the PKGBUILD will not be handled
|
|
||||||
unless `--syncdeps` is used. Useful for performing subsequent offline
|
|
||||||
builds.
|
|
||||||
|
|
||||||
*-f, \--force*::
|
|
||||||
makepkg will not build a package if a built package already exists in
|
|
||||||
the `PKGDEST` (set in linkman:makepkg.conf[5]) directory, which may
|
|
||||||
default to the current directory. This allows the built package to be
|
|
||||||
overwritten.
|
|
||||||
|
|
||||||
*-g, \--geninteg*::
|
|
||||||
For each source file in the source array of PKGBUILD, download the file
|
|
||||||
if required and generate integrity checks. The integrity checks generated
|
|
||||||
are determined by the checks present in the PKGBUILD, falling back to the
|
|
||||||
value of the INTEGRITY_CHECK array in makepkg.conf(5) if these are absent.
|
|
||||||
This output can be redirected into your PKGBUILD for source validation
|
|
||||||
using "`makepkg -g >> PKGBUILD`".
|
|
||||||
|
|
||||||
*--skipinteg*::
|
|
||||||
Do not perform any integrity checks (checksum and PGP) on source files.
|
|
||||||
|
|
||||||
*\--skipchecksums*::
|
|
||||||
Do not verify checksums of source files.
|
|
||||||
|
|
||||||
*\--skippgpcheck*::
|
|
||||||
Do not verify PGP signatures of source files.
|
|
||||||
|
|
||||||
*-h, \--help*::
|
|
||||||
Output syntax and command line options.
|
|
||||||
|
|
||||||
*--holdver*::
|
|
||||||
When using VCS sources (linkman:PKGBUILD[5]) any currently checked out source
|
|
||||||
will not be updated to the latest revision.
|
|
||||||
|
|
||||||
*-i, \--install*::
|
|
||||||
Install or upgrade the package after a successful build using
|
|
||||||
linkman:pacman[8].
|
|
||||||
|
|
||||||
*-L, \--log*::
|
|
||||||
Enable logging. This will use the *tee* program to send the output of each
|
|
||||||
of the PKGBUILD functions to both the console and to a text file in the
|
|
||||||
build directory named `pkgbase-pkgver-pkgrel-arch-<function>.log`.
|
|
||||||
As mentioned above, the logs will be localized so you may want to set your
|
|
||||||
locale accordingly if sharing the log output with others.
|
|
||||||
|
|
||||||
*-m, \--nocolor*::
|
|
||||||
Disable color in output messages.
|
|
||||||
|
|
||||||
*-o, \--nobuild*::
|
|
||||||
Download and extract files, run the prepare() function, but do not build
|
|
||||||
them. Useful with the '\--noextract' option if you wish to tweak the files
|
|
||||||
in $srcdir/ before building.
|
|
||||||
|
|
||||||
*-p* <buildscript>::
|
|
||||||
Read the package script `buildscript` instead of the `PKGBUILD` default;
|
|
||||||
see linkman:PKGBUILD[5]. The `buildscript` must be located in the directory
|
|
||||||
makepkg is called from.
|
|
||||||
|
|
||||||
*-r, \--rmdeps*::
|
|
||||||
Upon successful build, remove any dependencies installed by makepkg
|
|
||||||
during dependency auto-resolution and installation when using `-s`.
|
|
||||||
|
|
||||||
*-R, \--repackage*::
|
|
||||||
Repackage contents of the package without rebuilding the package. This
|
|
||||||
is useful if you forgot, for example, a dependency or install file in your
|
|
||||||
PKGBUILD and the build itself will not change.
|
|
||||||
|
|
||||||
*-s, \--syncdeps*::
|
|
||||||
Install missing dependencies using pacman. When build-time or run-time
|
|
||||||
dependencies are not found, pacman will try to resolve them. If
|
|
||||||
successful, the missing packages will be downloaded and installed.
|
|
||||||
|
|
||||||
*-S, \--source*::
|
|
||||||
Do not actually build the package, but build a source-only tarball that
|
|
||||||
does not include sources that can be fetched via a download URL. This is
|
|
||||||
useful for passing a single tarball to another program such as a chroot,
|
|
||||||
remote builder, or a tarball upload. Because integrity checks are verified,
|
|
||||||
all source files of the package need to be present or downloadable.
|
|
||||||
|
|
||||||
*-V, \--version*::
|
|
||||||
Display version information.
|
|
||||||
|
|
||||||
*-C, \--cleanbuild*::
|
|
||||||
Clean build artifacts from previous runs of makepkg in the current
|
|
||||||
directory by removing $srcdir before building the package.
|
|
||||||
|
|
||||||
*-D* <dir>, *\--dir* <dir> ::
|
|
||||||
Change to directory <dir> before reading the PKGBUILD or doing anything else.
|
|
||||||
|
|
||||||
*\--allsource*::
|
|
||||||
Do not actually build the package, but build a source-only tarball that
|
|
||||||
includes all sources, including those that are normally downloaded via
|
|
||||||
makepkg. This is useful for passing a single tarball to another program
|
|
||||||
such as a chroot or remote builder. It will also satisfy requirements of
|
|
||||||
the GPL when distributing binary packages.
|
|
||||||
|
|
||||||
*\--check*::
|
|
||||||
Run the check() function in the PKGBUILD, overriding the setting in
|
|
||||||
linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
*\--noarchive*::
|
|
||||||
Do not create the archive at the end of the build process. This can be
|
|
||||||
useful to test the package() function or if your target distribution does
|
|
||||||
not use pacman.
|
|
||||||
|
|
||||||
*\--nocheck*::
|
|
||||||
Do not run the check() function in the PKGBUILD or handle the checkdepends.
|
|
||||||
|
|
||||||
*\--noprepare*::
|
|
||||||
Do not run the prepare() function in the PKGBUILD.
|
|
||||||
|
|
||||||
*\--noverify*::
|
|
||||||
Do not run the verify() function in the PKGBUILD.
|
|
||||||
|
|
||||||
*\--sign*::
|
|
||||||
Sign the resulting package with gpg, overriding the setting in
|
|
||||||
linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
*\--nosign*::
|
|
||||||
Do not create a signature for the built package.
|
|
||||||
|
|
||||||
*\--key* <key>::
|
|
||||||
Specify a key to use when signing packages, overriding the GPGKEY setting
|
|
||||||
in linkman:makepkg.conf[5]. If not specified in either location, the
|
|
||||||
default key from the keyring will be used.
|
|
||||||
|
|
||||||
*\--noconfirm*::
|
|
||||||
(Passed to pacman) Prevent pacman from waiting for user input before
|
|
||||||
proceeding with operations.
|
|
||||||
|
|
||||||
*\--needed*::
|
|
||||||
(Passed to pacman) Tell pacman not to reinstall a target if it is already
|
|
||||||
up-to-date. (used with '-i' / '\--install').
|
|
||||||
|
|
||||||
*\--asdeps*::
|
|
||||||
(Passed to pacman) Install packages as non-explicitly installed (used
|
|
||||||
with '-i' / '\--install').
|
|
||||||
|
|
||||||
*\--noprogressbar*::
|
|
||||||
(Passed to pacman) Prevent pacman from displaying a progress bar;
|
|
||||||
useful if you are redirecting makepkg output to file.
|
|
||||||
|
|
||||||
*\--packagelist*::
|
|
||||||
List the package filenames that would be produced without building. Listed
|
|
||||||
package filenames include PKGDEST and PKGEXT.
|
|
||||||
|
|
||||||
*\--printsrcinfo*::
|
|
||||||
Generate and print the SRCINFO file to stdout.
|
|
||||||
|
|
||||||
|
|
||||||
Additional Features
|
|
||||||
-------------------
|
|
||||||
makepkg supports building development versions of packages without having to
|
|
||||||
manually update the pkgver in the PKGBUILD. This was formerly done using the
|
|
||||||
separate utility 'versionpkg'. See linkman:PKGBUILD[5] for details on how to
|
|
||||||
set up a development PKGBUILD.
|
|
||||||
|
|
||||||
|
|
||||||
Reproducibility
|
|
||||||
---------------
|
|
||||||
makepkg is designed to be compatible with
|
|
||||||
link:https://reproducible-builds.org/docs/[Reproducible Builds]. If the
|
|
||||||
**SOURCE_DATE_EPOCH** environment variable is set, it will be exported to
|
|
||||||
subprocesses, and source and package file modification times and package
|
|
||||||
metadata will be unified based on the timestamp specified.
|
|
||||||
|
|
||||||
If the **SOURCE_DATE_EPOCH** environment variable is not set, makepkg will use
|
|
||||||
its own start date for internal use, but will not unify source file timestamps
|
|
||||||
before building.
|
|
||||||
|
|
||||||
|
|
||||||
Environment Variables
|
|
||||||
---------------------
|
|
||||||
**MAKEPKG_LIBRARY**="/path/to/directory"::
|
|
||||||
Use an alternative libmakepkg path instead of the {libmakepkgdir} default.
|
|
||||||
|
|
||||||
**PACMAN**::
|
|
||||||
The command that will be used to check for missing dependencies and to
|
|
||||||
install and remove packages. Pacman's '-Qq', '-Rns', '-S', '-T', and '-U'
|
|
||||||
operations must be supported by this command. If the variable is not
|
|
||||||
set or empty, makepkg will fall back to `pacman'.
|
|
||||||
|
|
||||||
**MAKEPKG_CONF=**"/path/to/file"::
|
|
||||||
Use an alternate config file instead of the +{sysconfdir}/makepkg.conf+
|
|
||||||
default.
|
|
||||||
|
|
||||||
**MAKEPKG_GIT_CONFIG=**"/path/to/file"::
|
|
||||||
Use an alternate config file for Git instead of the
|
|
||||||
+{sysconfdir}/makepkg.d/gitconfig+ default. makepkg always prevents Git
|
|
||||||
from loading any other config files.
|
|
||||||
|
|
||||||
**PKGDEST=**"/path/to/directory"::
|
|
||||||
Directory where the resulting packages will be stored. Overrides the
|
|
||||||
corresponding value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**SRCDEST=**"/path/to/directory"::
|
|
||||||
Directory where the downloaded sources will be stored. Overrides the
|
|
||||||
corresponding value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**SRCPKGDEST=**"/path/to/directory"::
|
|
||||||
Directory where source package files will be stored. Overrides the
|
|
||||||
corresponding value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**LOGDEST=**"/path/to/directory"::
|
|
||||||
Directory where generated log files will be stored. Overrides the
|
|
||||||
corresponding value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**PACKAGER=**"John Doe <john@doe.com>"::
|
|
||||||
String to identify the creator of the resulting package. Overrides
|
|
||||||
the corresponding value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**BUILDDIR=**"/path/to/directory"::
|
|
||||||
Directory where the package will be built. Overrides the corresponding
|
|
||||||
value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**CARCH=**"(i686|x86_64)"::
|
|
||||||
Force build for a specific architecture. Useful for cross-compiling.
|
|
||||||
Overrides the corresponding value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**PKGEXT=**".pkg.tar.gz", **SRCEXT=**".src.tar.gz"::
|
|
||||||
Sets the compression used when making compiled or source packages.
|
|
||||||
Overrides the corresponding value defined in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**GNUPGHOME=**"/path/to/directory"::
|
|
||||||
Directory where the gpg keyring for signing the built package is stored.
|
|
||||||
|
|
||||||
**GPGKEY=**"keyid"::
|
|
||||||
Specify a key to use when signing packages, overriding the GPGKEY setting
|
|
||||||
in linkman:makepkg.conf[5].
|
|
||||||
|
|
||||||
**SOURCE_DATE_EPOCH=**"<date>"::
|
|
||||||
Used for link:https://reproducible-builds.org/docs/[Reproducible Builds].
|
|
||||||
|
|
||||||
**BUILDTOOL=**"<name>"::
|
|
||||||
The name of a tool ecosystem used to set up the build environment. Used for
|
|
||||||
defining a spec for reproducible builds, e.g. the linkman:makepkg.conf[5]
|
|
||||||
used.
|
|
||||||
|
|
||||||
**BUILDTOOLVER=**"<version>"::
|
|
||||||
The version of the '$BUILDTOOL' used.
|
|
||||||
|
|
||||||
**MAKEPKG_LINT_PKGBUILD=**0::
|
|
||||||
Setting to 0 disables PKGBUILD linting within makepkg. Useful on systems
|
|
||||||
with slow bash subshell operations, or on PKGBUILDs with extreme amounts of
|
|
||||||
package splitting.
|
|
||||||
|
|
||||||
|
|
||||||
Configuration
|
|
||||||
-------------
|
|
||||||
See linkman:makepkg.conf[5] for more details on configuring makepkg using the
|
|
||||||
'makepkg.conf' file.
|
|
||||||
|
|
||||||
|
|
||||||
Errors
|
|
||||||
------
|
|
||||||
On exit, makepkg will return one of the following error codes.
|
|
||||||
|
|
||||||
0::
|
|
||||||
Normal exit condition.
|
|
||||||
|
|
||||||
1::
|
|
||||||
Unknown cause of failure.
|
|
||||||
|
|
||||||
2::
|
|
||||||
Error in configuration file.
|
|
||||||
|
|
||||||
3::
|
|
||||||
User specified an invalid option.
|
|
||||||
|
|
||||||
4::
|
|
||||||
Error in user-supplied function in PKGBUILD.
|
|
||||||
|
|
||||||
5::
|
|
||||||
Failed to create a viable package.
|
|
||||||
|
|
||||||
6::
|
|
||||||
A source or auxiliary file specified in the PKGBUILD is
|
|
||||||
missing.
|
|
||||||
|
|
||||||
7::
|
|
||||||
The PKGDIR is missing.
|
|
||||||
|
|
||||||
8::
|
|
||||||
Failed to install dependencies.
|
|
||||||
|
|
||||||
9::
|
|
||||||
Failed to remove dependencies.
|
|
||||||
|
|
||||||
10::
|
|
||||||
User attempted to run makepkg as root.
|
|
||||||
|
|
||||||
11::
|
|
||||||
User lacks permissions to build or install to a given
|
|
||||||
location.
|
|
||||||
|
|
||||||
12::
|
|
||||||
Error parsing PKGBUILD.
|
|
||||||
|
|
||||||
13::
|
|
||||||
A package has already been built.
|
|
||||||
|
|
||||||
14::
|
|
||||||
The package failed to install.
|
|
||||||
|
|
||||||
15::
|
|
||||||
Programs necessary to run makepkg are missing.
|
|
||||||
|
|
||||||
16::
|
|
||||||
Specified GPG key does not exist or failed to sign package.
|
|
||||||
|
|
||||||
17::
|
|
||||||
The local repository is not a clone of the source repository
|
|
||||||
specified in PKGBUILD.
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:makepkg.conf[5], linkman:PKGBUILD[5], linkman:pacman[8]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
146
doc/makepkg.conf.5
Normal file
146
doc/makepkg.conf.5
Normal file
|
@ -0,0 +1,146 @@
|
||||||
|
." the string declarations are a start to try and make distro independent
|
||||||
|
.ds DS Arch Linux
|
||||||
|
.ds PB PKGBUILD
|
||||||
|
.ds VR 3.0.0
|
||||||
|
.TH \*(PB 5 "Feb 08, 2007" "makepkg.conf version \*(VR" "\*(DS Files"
|
||||||
|
.SH NAME
|
||||||
|
makepkg.conf \- makepkg configuration file
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Configuration options for \fBmakekpg\fP are stored in \fBmakepkg.conf\fP. This
|
||||||
|
file is sourced, so you can include any special compiler flags you wish to use.
|
||||||
|
This is helpful for building for different architectures, or with different
|
||||||
|
optimizations.
|
||||||
|
|
||||||
|
\fBNOTE:\fP This does not guarantee that all package Makefiles will use your
|
||||||
|
exported variables. Some of them are non-standard...
|
||||||
|
|
||||||
|
The default file is fairly well commented, so it may be easiest to simply
|
||||||
|
follow directions given there for customization.
|
||||||
|
|
||||||
|
.SH OPTIONS
|
||||||
|
.TP
|
||||||
|
.B FTPAGENT="\fI/path/to/command\fP [\fIoptions\fP]"
|
||||||
|
Sets the download agent used to fetch source files specified with a URL in the
|
||||||
|
\fB\*(PB\fP file. Flags can be specified as well; the download URL is then
|
||||||
|
placed on the end of the command.
|
||||||
|
.TP
|
||||||
|
.B CARCH="\fIcarch\fP"
|
||||||
|
Specifies your computer architecture; possible values include such things as
|
||||||
|
"i686", "x86_64", "ppc", etc. This should be automatically set on installation.
|
||||||
|
.TP
|
||||||
|
.B CHOST="\fIchost\fP"
|
||||||
|
A string such as "i686-pc-linux-gnu", do not touch unless you know what you are
|
||||||
|
doing.
|
||||||
|
.TP
|
||||||
|
.B CFLAGS="\fIcflags\fP"
|
||||||
|
Flags used for the C compiler. This is a key part to the use of makepkg.
|
||||||
|
Usually several options are specified, and the most common string resembles
|
||||||
|
something like this: "-march=i686 -O2 -pipe". Another useful option may be
|
||||||
|
-mcpu in place of -march. Read
|
||||||
|
.BR gcc (1)
|
||||||
|
for more details on the wide variety of compiler flags available.
|
||||||
|
.TP
|
||||||
|
.B CXXFLAGS="\fIcxxflags\fP"
|
||||||
|
Flags used for the C++ compiler; see \fBCFLAGS\fP for more info.
|
||||||
|
.TP
|
||||||
|
.B MAKEFLAGS="\fImakeflags\fP"
|
||||||
|
This is often used to set the number of jobs used, for example, "-j2". Other
|
||||||
|
flags that make accepts can also be passed.
|
||||||
|
.TP
|
||||||
|
.B BUILDENV=(fakeroot !distcc color !ccache)
|
||||||
|
This array contains four options that affect the build environment, the
|
||||||
|
defaults are shown here. All options should always be left in the array; to
|
||||||
|
enable or disable an option simply remove or place an "!" at the front of the
|
||||||
|
option. Each works as follows:
|
||||||
|
.RS
|
||||||
|
.TP
|
||||||
|
.B fakeroot
|
||||||
|
Allow building packages as a non-root user. This is \fIhighly\fP recommended.
|
||||||
|
.TP
|
||||||
|
.B distcc
|
||||||
|
Use the distributed C/C++/ObjC compiler to spread compilation among multiple
|
||||||
|
machines. If this is enabled, \fBDISTCC_HOSTS\fP must be specified as well.
|
||||||
|
.TP
|
||||||
|
.B color
|
||||||
|
Colorize output messages, making output easier to read.
|
||||||
|
.TP
|
||||||
|
.B ccache
|
||||||
|
Use ccache to cache compilation by default. This allows for faster compiles if
|
||||||
|
you are continuously recompiling the same packages. It can be disabled for
|
||||||
|
individual packages by placing \fB!ccache\fP in the \fB\*(PB\fP options array.
|
||||||
|
.RE
|
||||||
|
.TP
|
||||||
|
.B DISTCC_HOSTS="\fIhost1 ...\fP"
|
||||||
|
If using DistCC, this is used to specify a space-delimited list of hosts
|
||||||
|
running in the DistCC cluster. In addition, you will want to modify your
|
||||||
|
\fBMAKEFLAGS\fP.
|
||||||
|
.TP
|
||||||
|
.B OPTIONS=(strip !docs libtool emptydirs)
|
||||||
|
This array contains four options that affect the default packaging. All four
|
||||||
|
are equivalent to options that can be placed in the PKGBUILD; the defaults are
|
||||||
|
shown here. All options should always be left in the array; to enable or
|
||||||
|
disable an option simply remove or place an "!" at the front of the option.
|
||||||
|
Each works as follows:
|
||||||
|
.RS
|
||||||
|
.TP
|
||||||
|
.B strip
|
||||||
|
Strip symbols from binaries and libraries. If you frequently use a debugger on
|
||||||
|
programs or libraries, it may be helpful to disable this option.
|
||||||
|
.TP
|
||||||
|
.B docs
|
||||||
|
Save doc and info directories. If you wish to delete doc and info directories,
|
||||||
|
specify "!docs" in the array.
|
||||||
|
.TP
|
||||||
|
.B libtool
|
||||||
|
Leave libtool (.la) files in packages. Specify "!libtool" to remove them.
|
||||||
|
.TP
|
||||||
|
.B emptydirs
|
||||||
|
Leave empty directories in packages.
|
||||||
|
.RE
|
||||||
|
.TP
|
||||||
|
.B INTEGRITY_CHECK=(\fIcheck1 ...\fP)
|
||||||
|
File integrity checks to use. Multiple checks may be specified; this affects
|
||||||
|
both generation and checking. The current valid options are: md5, sha1, sha256,
|
||||||
|
sha384, and sha512.
|
||||||
|
.TP
|
||||||
|
.B DOC_DIRS=(usr/{,share/}{info,doc} ...)
|
||||||
|
If "!docs" is specified in the \fBOPTIONS\fP array, this variable will instruct
|
||||||
|
makepkg where to look to remove docs. If you build packages that are located in
|
||||||
|
opt/, you may need to add the directory to this array. NOTE: do not add the
|
||||||
|
leading slash to the directory name.
|
||||||
|
.TP
|
||||||
|
.B PKGDEST=\fI/path/to/folder\fP
|
||||||
|
If this value is not set, packages will by default be placed in the current
|
||||||
|
directory (location of the \fB\*(PB\fP). Many people like to keep all their
|
||||||
|
packages in one place so this option allows this behavior. A common location is
|
||||||
|
"/home/packages".
|
||||||
|
.TP
|
||||||
|
.B SRCDEST=\fI/path/to/folder\fP
|
||||||
|
If this value is not set, downloaded source files will only be stored in the
|
||||||
|
current directory. Many people like to keep all source files in a central
|
||||||
|
location for easy cleanup, so this path can be set here.
|
||||||
|
.TP
|
||||||
|
.B PACKAGER="\fIJohn Doe <john@doe.com>\fP"
|
||||||
|
This value is used when querying a package to see who was the builder. It is
|
||||||
|
recommended you change this to your name and email address.
|
||||||
|
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR makepkg (8),
|
||||||
|
.BR pacman (8),
|
||||||
|
.BR \*(PB (5)
|
||||||
|
|
||||||
|
See the Arch Linux website at <http://www.archlinux.org> for more current
|
||||||
|
information on the distribution and the \fBpacman\fP family of tools, and
|
||||||
|
<http://wiki.archlinux.org/index.php/Arch_Packaging_Standards> for
|
||||||
|
recommendations on packaging standards.
|
||||||
|
|
||||||
|
.SH AUTHORS
|
||||||
|
.nf
|
||||||
|
Judd Vinet <jvinet@zeroflux.org>
|
||||||
|
Aurelien Foret <aurelien@archlinux.org>
|
||||||
|
Aaron Griffin <aaron@archlinux.org>
|
||||||
|
Dan McGee <dan@archlinux.org>
|
||||||
|
.fi
|
||||||
|
|
||||||
|
See the 'AUTHORS' file for additional contributors.
|
|
@ -1,312 +0,0 @@
|
||||||
makepkg.conf(5)
|
|
||||||
===============
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
makepkg.conf - makepkg configuration file
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
{sysconfdir}/makepkg.conf, $XDG_CONFIG_HOME/pacman/makepkg.conf, ~/.makepkg.conf
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
Configuration options for makepkg are stored in makepkg.conf. This file is
|
|
||||||
sourced so you can include any special compiler flags you wish to use. This is
|
|
||||||
helpful when building for different architectures or with different
|
|
||||||
optimizations. However, only the variables described below are exported to the
|
|
||||||
build environment.
|
|
||||||
|
|
||||||
NOTE: This does not guarantee that all package Makefiles will use your exported
|
|
||||||
variables. Some of them are non-standard.
|
|
||||||
|
|
||||||
The system-wide configuration file is found in {sysconfdir}/makepkg.conf.
|
|
||||||
Specific additions (e.g. build flags for additional languages) can be placed
|
|
||||||
in {sysconfdir}/makepkg.conf.d/*.conf.
|
|
||||||
|
|
||||||
Individual options can be overridden (or added to) on a per-user basis in
|
|
||||||
$XDG_CONFIG_HOME/pacman/makepkg.conf or ~/.makepkg.conf, with the former
|
|
||||||
taking priority.
|
|
||||||
|
|
||||||
The default file is fairly well commented, so it may be easiest to simply
|
|
||||||
follow directions given there for customization.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
**DLAGENTS=(**\'protocol::/path/to/command [options]' ...**)**::
|
|
||||||
Sets the download agents used to fetch source files specified with a URL in
|
|
||||||
the linkman:PKGBUILD[5] file. Options can be specified for each command as
|
|
||||||
well, and any protocol can have a download agent. Any spaces in option
|
|
||||||
arguments are required to be escaped to avoid being split. Several
|
|
||||||
examples are provided in the default makepkg.conf.
|
|
||||||
+
|
|
||||||
If present, `%u` will be replaced with the download URL. Otherwise, the
|
|
||||||
download URL will be placed on the end of the command. If present, `%o` will
|
|
||||||
be replaced with the local file name, plus a ``.part'' extension, which allows
|
|
||||||
makepkg to handle resuming file downloads.
|
|
||||||
|
|
||||||
**VCSCLIENTS=(**\'protocol::package' ...**)**::
|
|
||||||
Sets the packages required to fetch version controlled source files. When
|
|
||||||
required, makepkg will check that these packages are installed or are included
|
|
||||||
in the `depends` or `makedepends` arrays in the PKGBUILD.
|
|
||||||
|
|
||||||
**CARCH=**"carch"::
|
|
||||||
Specifies your computer architecture; possible values include such things
|
|
||||||
as ``i686'', ``x86_64'', ``ppc'', etc. This should be automatically set on
|
|
||||||
installation.
|
|
||||||
|
|
||||||
**CHOST=**"chost"::
|
|
||||||
A string such as ``i686-pc-linux-gnu''; do not touch this unless you know what
|
|
||||||
you are doing. This can be commented out by most users if desired.
|
|
||||||
|
|
||||||
**NPROC=**""::
|
|
||||||
Sets the number of processors to use for parallel jobs in makepkg.
|
|
||||||
Note: this does not affect parallelization of tasks during ``build()`` and
|
|
||||||
related functions.
|
|
||||||
|
|
||||||
**CPPFLAGS=**"cppflags"::
|
|
||||||
Flags used for the C preprocessor; see CFLAGS for more information.
|
|
||||||
|
|
||||||
**CFLAGS=**"cflags"::
|
|
||||||
Flags used for the C compiler. This is a key part to the use of makepkg.
|
|
||||||
Usually several options are specified, and the most common string resembles
|
|
||||||
something like this: ``-march=i686 -O2 -pipe''. Another useful option may
|
|
||||||
be `-mcpu` in place of `-march`. Read gcc(1) for more details on the wide
|
|
||||||
variety of compiler flags available.
|
|
||||||
|
|
||||||
**CXXFLAGS=**"cxxflags"::
|
|
||||||
Flags used for the C++ compiler; see CFLAGS for more info.
|
|
||||||
|
|
||||||
**LDFLAGS=**"ldflags"::
|
|
||||||
Flags used for the linker. Several options may be specified with common
|
|
||||||
usage resembling ``-Wl,--hash-style=gnu''. Read ld(1) for more details on
|
|
||||||
available linker flags.
|
|
||||||
|
|
||||||
**LTOFLAGS=**"ltoflags"::
|
|
||||||
Additional compiler and linker flags appended to `CFLAGS`, `CXXFLAGS`
|
|
||||||
and `LDFLAGS` when building with link time optimization. If empty,
|
|
||||||
``-flto'' is used.
|
|
||||||
|
|
||||||
**MAKEFLAGS=**"makeflags"::
|
|
||||||
This is often used to set the number of jobs used; for example, `-j2`.
|
|
||||||
Other flags that make accepts can also be passed.
|
|
||||||
|
|
||||||
**DEBUG_CFLAGS=**"debug_cflags"::
|
|
||||||
Additional compiler flags appended to `CFLAGS` for use in debugging. Usually
|
|
||||||
this would include: ``-g''. Read gcc(1) for more details on the wide
|
|
||||||
variety of compiler flags available.
|
|
||||||
|
|
||||||
**DEBUG_CXXFLAGS=**"debug_cxxflags"::
|
|
||||||
Debug flags used for the C++ compiler; see DEBUG_CFLAGS for more info.
|
|
||||||
|
|
||||||
**BUILDENV=(**!distcc !color !ccache check !sign**)**::
|
|
||||||
This array contains options that affect the build environment; the defaults
|
|
||||||
are shown here. All options should always be left in the array; to enable
|
|
||||||
or disable an option, simply remove or add an ``!'' at the front of the
|
|
||||||
option. If an option is specified multiple times, the final value takes
|
|
||||||
precedence. Each option works as follows:
|
|
||||||
|
|
||||||
*distcc*;;
|
|
||||||
Use the distributed C/C++/ObjC compiler to spread compilation among
|
|
||||||
multiple machines. If this is enabled, `DISTCC_HOSTS` must be specified
|
|
||||||
as well.
|
|
||||||
|
|
||||||
*color*;;
|
|
||||||
Colorize output messages, making output easier to read.
|
|
||||||
|
|
||||||
*ccache*;;
|
|
||||||
Use ccache to cache compilation by default. This allows for faster
|
|
||||||
compiles if you are continuously recompiling the same packages. It can
|
|
||||||
be disabled for individual packages by placing `!ccache` in the
|
|
||||||
PKGBUILD options array.
|
|
||||||
|
|
||||||
*check*;;
|
|
||||||
Run the check() function if present in the PKGBUILD. This can be
|
|
||||||
enabled or disabled for individual packages through the use of
|
|
||||||
makepkg's '\--check' and '\--nocheck' options, respectively.
|
|
||||||
|
|
||||||
*sign*;;
|
|
||||||
Generate a PGP signature file using GnuPG. This will execute 'gpg
|
|
||||||
\--detach-sign' on the built package to generate a detached
|
|
||||||
signature file, using the GPG agent, if it is available. The signature
|
|
||||||
file will be the entire file name of the package with a ``.sig''
|
|
||||||
extension.
|
|
||||||
|
|
||||||
**DISTCC_HOSTS=**"host1 ..."::
|
|
||||||
If using DistCC, this is used to specify a space-delimited list of hosts
|
|
||||||
running in the DistCC cluster. In addition, you will want to modify your
|
|
||||||
`MAKEFLAGS`.
|
|
||||||
|
|
||||||
**BUILDDIR=**"/path/to/directory"::
|
|
||||||
If this value is not set, packages will, by default, be built in
|
|
||||||
subdirectories of the directory that makepkg is called from. This
|
|
||||||
option allows setting the build location to another directory.
|
|
||||||
Incorrect use of `$startdir` in a PKGBUILD may cause building with
|
|
||||||
this option to fail.
|
|
||||||
|
|
||||||
**GPGKEY=**""::
|
|
||||||
Specify a key to use for GPG signing instead of the default key in the
|
|
||||||
keyring. Can be overridden with makepkg's '\--key' option.
|
|
||||||
|
|
||||||
**OPTIONS=(**!strip docs libtool staticlibs emptydirs ...**)**::
|
|
||||||
This array contains options that affect default packaging. They are
|
|
||||||
equivalent to options that can be placed in the PKGBUILD; the defaults are
|
|
||||||
shown here. All options should always be left in the array; to enable or
|
|
||||||
disable an option, simply remove or add an ``!'' at the front of the
|
|
||||||
option. If an option is specified multiple times, the final value takes
|
|
||||||
precedence. Each option works as follows:
|
|
||||||
|
|
||||||
*strip*;;
|
|
||||||
Strip symbols from binaries and libraries. If you frequently use a
|
|
||||||
debugger on programs or libraries, it may be helpful to disable this
|
|
||||||
option.
|
|
||||||
|
|
||||||
*docs*;;
|
|
||||||
Save doc directories. If you wish to delete doc directories, specify
|
|
||||||
`!docs` in the array. The directories affected are specified by the
|
|
||||||
`DOC_DIRS` variable.
|
|
||||||
|
|
||||||
*libtool*;;
|
|
||||||
Leave libtool (.la) files in packages. Specify `!libtool` to remove
|
|
||||||
them.
|
|
||||||
|
|
||||||
*staticlibs*;;
|
|
||||||
Leave static library (.a) files in packages. Specify `!staticlibs` to
|
|
||||||
remove them, if they have a shared counterpart.
|
|
||||||
|
|
||||||
*emptydirs*;;
|
|
||||||
Leave empty directories in packages.
|
|
||||||
|
|
||||||
*zipman*;;
|
|
||||||
Compress manual (man and info) pages with gzip. The directories
|
|
||||||
affected are specified by the `MAN_DIRS` variable.
|
|
||||||
|
|
||||||
*purge*;;
|
|
||||||
Remove files specified by the `PURGE_TARGETS` variable from the
|
|
||||||
package.
|
|
||||||
|
|
||||||
*debug*;;
|
|
||||||
Add the user-specified debug flags as specified in DEBUG_CFLAGS and
|
|
||||||
DEBUG_CXXFLAGS to their counterpart buildflags. Creates a separate
|
|
||||||
package containing the debug symbols when used with `strip'.
|
|
||||||
|
|
||||||
*lto*;;
|
|
||||||
Enable building packages using link time optimization. Adds the
|
|
||||||
flags specified in LTOFLAGS to CFLAGS, CXXFLAGS and LDFLAGS (or
|
|
||||||
``-flto'' if LTOFLAGS is empty).
|
|
||||||
|
|
||||||
*autodeps*;;
|
|
||||||
Enable the automatic addition of libraries to the depends and
|
|
||||||
provides arrays. Search library directories are controlled by
|
|
||||||
the LIB_DIRS variable defined below.
|
|
||||||
|
|
||||||
**INTEGRITY_CHECK=(**check1 ...**)**::
|
|
||||||
File integrity checks to use. Multiple checks may be specified; this
|
|
||||||
affects both generation and checking. The current valid options are:
|
|
||||||
`ck`, `md5`, `sha1`, `sha224`, `sha256`, `sha384`, `sha512`, and `b2`.
|
|
||||||
|
|
||||||
**STRIP_BINARIES=**"--strip-all"::
|
|
||||||
Options to be used when stripping binaries. See linkman:strip[1]
|
|
||||||
for details.
|
|
||||||
|
|
||||||
**STRIP_SHARED=**"--strip-unneeded"::
|
|
||||||
Options to be used when stripping shared libraries or PIE executables.
|
|
||||||
See linkman:strip[1] for details.
|
|
||||||
|
|
||||||
**STRIP_STATIC=**"--strip-debug"::
|
|
||||||
Options to be used when stripping static libraries. See linkman:strip[1]
|
|
||||||
for details.
|
|
||||||
|
|
||||||
**MAN_DIRS=(**{usr{,/local}{,/share},opt/*}/{man,info} ...**)**::
|
|
||||||
If `zipman` is specified in the `OPTIONS` array, this variable will
|
|
||||||
instruct makepkg where to look to compress manual (man and info)
|
|
||||||
pages. If you build packages that are located in opt/, you may need
|
|
||||||
to add the directory to this array. *NOTE:* Do not add the leading
|
|
||||||
slash to the directory name.
|
|
||||||
|
|
||||||
**DOC_DIRS=(**usr/{,share/}{doc,gtk-doc} ...**)**::
|
|
||||||
If `!docs` is specified in the `OPTIONS` array, this variable will
|
|
||||||
instruct makepkg where to look to remove docs. If you build packages
|
|
||||||
that are located in opt/, you may need to add the directory to this
|
|
||||||
array. *NOTE:* Do not add the leading slash to the directory name.
|
|
||||||
|
|
||||||
**LIB_DIRS=(**lib:usr/lib ...**)**::
|
|
||||||
If `autodeps` is specified in the `OPTIONS` array, this variable will
|
|
||||||
instruct makepkg where to look to find libraries to add to the `provides`
|
|
||||||
array. The format is "prefix:path", where provides will be added for
|
|
||||||
libraries found in "path" with the specified prefix added.
|
|
||||||
|
|
||||||
**PURGE_TARGETS=(**usr/{,share}/info/dir .podlist *.pod...**)**::
|
|
||||||
If `purge` is specified in the `OPTIONS` array, this variable will
|
|
||||||
instruct makepkg which files to remove from the package. This is
|
|
||||||
useful for index files that are added by multiple packages.
|
|
||||||
|
|
||||||
**DBGSRCDIR=**"/usr/src/debug"::
|
|
||||||
If `strip` and `debug` are specified in the `OPTIONS` array, this variable
|
|
||||||
will instruct makepkg where to place source files for installed binaries.
|
|
||||||
The binaries will be modified to link this directory for the debugger
|
|
||||||
search path.
|
|
||||||
|
|
||||||
**PKGDEST=**"/path/to/directory"::
|
|
||||||
If this value is not set, packages will, by default, be placed in the
|
|
||||||
current directory (location of the linkman:PKGBUILD[5]). Many people
|
|
||||||
like to keep all their packages in one place so this option allows
|
|
||||||
for this behavior. A common location is ``/home/packages''.
|
|
||||||
|
|
||||||
**SRCDEST=**"/path/to/directory"::
|
|
||||||
If this value is not set, downloaded source files will only be stored
|
|
||||||
in the current directory. Many people like to keep all source files in
|
|
||||||
a central location for easy cleanup, so this path can be set here.
|
|
||||||
|
|
||||||
**SRCPKGDEST=**"/path/to/directory"::
|
|
||||||
If this value is not set, source package files will be stored in
|
|
||||||
in the current directory. Many people like to keep all source package files
|
|
||||||
in a central location for easy cleanup, so this path can be set here.
|
|
||||||
|
|
||||||
**LOGDEST=**"/path/to/directory"::
|
|
||||||
If this value is not set, log files are written to the current
|
|
||||||
directory. This centralizes the log location, facilitating cleanup
|
|
||||||
and compression.
|
|
||||||
|
|
||||||
**PACKAGER=**"John Doe <john@example.com>"::
|
|
||||||
This value is used when querying a package to see who was the builder.
|
|
||||||
The given format is required for PGP key lookup through WKD.
|
|
||||||
It is recommended to change this to your name and email address.
|
|
||||||
|
|
||||||
**COMPRESSGZ=**"(gzip -c -f -n)"::
|
|
||||||
**COMPRESSBZ2=**"(bzip2 -c -f)"::
|
|
||||||
**COMPRESSXZ=**"(xz -c -z -)"::
|
|
||||||
**COMPRESSZST=**"(zstd -c -z -)"::
|
|
||||||
**COMPRESSLZO**"(lzop -q)"::
|
|
||||||
**COMPRESSLRZ=**"(lrzip -q)"::
|
|
||||||
**COMPRESSLZ4=**"(lz4 -q)"::
|
|
||||||
**COMPRESSZ=**"(compress -c -f)"::
|
|
||||||
**COMPRESSLZ=**"(lzip -c -f)"::
|
|
||||||
Sets the command and options used when compressing compiled or source
|
|
||||||
packages in the named format.
|
|
||||||
|
|
||||||
**PKGEXT=**"{pkgext}", **SRCEXT=**"{srcext}"::
|
|
||||||
Sets the compression used when making compiled or source packages.
|
|
||||||
Valid suffixes are `.pkg` or `.src` (for PKGEXT and SRCEXT respectively)
|
|
||||||
followed by one of `.tar.gz`, `.tar.bz2`, `.tar.xz`, `.tar.zst`, `.tar.lzo`,
|
|
||||||
`.tar.lrz`, `.tar.lz4`, `.tar.lz` and `.tar.Z`, or simply `.tar` to
|
|
||||||
disable compression entirely.
|
|
||||||
|
|
||||||
**PACMAN_AUTH=()**::
|
|
||||||
Specify a command prefix for running pacman as root. If unset, makepkg will
|
|
||||||
check for the presence of sudo(8) and su(1) in turn, and try the first one
|
|
||||||
it finds.
|
|
||||||
+
|
|
||||||
If present, `%c` will be replaced with the shell-quoted form of the command
|
|
||||||
to run. Otherwise, the command to run is appended to the auth command.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:makepkg[8], linkman:pacman[8], linkman:PKGBUILD[5]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
157
doc/meson.build
157
doc/meson.build
|
@ -1,157 +0,0 @@
|
||||||
manpages = [
|
|
||||||
{ 'name': 'alpm-hooks.5' },
|
|
||||||
{ 'name': 'pacman.8' },
|
|
||||||
{ 'name': 'makepkg.8' },
|
|
||||||
{ 'name': 'makepkg-template.1' },
|
|
||||||
{ 'name': 'repo-add.8' },
|
|
||||||
{ 'name': 'vercmp.8' },
|
|
||||||
{ 'name': 'testpkg.8' },
|
|
||||||
{ 'name': 'pacman-key.8' },
|
|
||||||
{ 'name': 'pacman-db-upgrade.8' },
|
|
||||||
{ 'name': 'PKGBUILD.5', 'extra_depends' : [ 'PKGBUILD-example.txt' ] },
|
|
||||||
{ 'name': 'makepkg.conf.5' },
|
|
||||||
{ 'name': 'pacman.conf.5' },
|
|
||||||
{ 'name': 'BUILDINFO.5' },
|
|
||||||
{ 'name': 'pacman-conf.8' },
|
|
||||||
]
|
|
||||||
|
|
||||||
sitepages = [
|
|
||||||
{ 'name': 'submitting-patches' },
|
|
||||||
{ 'name': 'translation-help' },
|
|
||||||
{ 'name': 'HACKING', 'source': '../HACKING' },
|
|
||||||
{ 'name': 'index' },
|
|
||||||
]
|
|
||||||
|
|
||||||
asciidoc_conf = join_paths(meson.current_source_dir(), 'asciidoc.conf')
|
|
||||||
|
|
||||||
asciidoc_opts = [
|
|
||||||
'-f', asciidoc_conf,
|
|
||||||
'-a', 'pacman_version="@0@"'.format(PACKAGE_VERSION),
|
|
||||||
'-a', 'srcext=@0@'.format(get_option('src-ext')),
|
|
||||||
'-a', 'pkgext=@0@'.format(get_option('pkg-ext')),
|
|
||||||
'-a', 'pkgdatadir=@0@'.format(PKGDATADIR),
|
|
||||||
'-a', 'keyringdir=@0@'.format(KEYRINGDIR),
|
|
||||||
'-a', 'localstatedir=@0@'.format(LOCALSTATEDIR),
|
|
||||||
'-a', 'sysconfdir=@0@'.format(SYSCONFDIR),
|
|
||||||
'-a', 'datarootdir=@0@'.format(DATAROOTDIR),
|
|
||||||
'-a', 'rootdir=@0@'.format(ROOTDIR),
|
|
||||||
'-a', 'libmakepkgdir=@0@'.format(LIBMAKEPKGDIR),
|
|
||||||
]
|
|
||||||
|
|
||||||
html_targets = []
|
|
||||||
html_files = []
|
|
||||||
|
|
||||||
foreach page : manpages
|
|
||||||
manpage = page['name']
|
|
||||||
htmlpage = '@0@.html'.format(manpage)
|
|
||||||
input = '@0@.asciidoc'.format(manpage)
|
|
||||||
|
|
||||||
section = page['name'].split('.')[-1]
|
|
||||||
|
|
||||||
mandirn = join_paths(MANDIR, 'man' + section)
|
|
||||||
|
|
||||||
custom_target(
|
|
||||||
manpage,
|
|
||||||
command : [
|
|
||||||
A2X,
|
|
||||||
'--no-xmllint',
|
|
||||||
'-d', 'manpage',
|
|
||||||
'-f', 'manpage',
|
|
||||||
'--xsltproc-opts', '-param man.endnotes.list.enabled 0 -param man.endnotes.are.numbered 0',
|
|
||||||
'-D', '@OUTDIR@',
|
|
||||||
'--asciidoc-opts', ' '.join(asciidoc_opts),
|
|
||||||
'@INPUT@',
|
|
||||||
],
|
|
||||||
input : input,
|
|
||||||
output : [manpage],
|
|
||||||
depend_files : [
|
|
||||||
asciidoc_conf,
|
|
||||||
] + page.get('extra_depends', []),
|
|
||||||
install : true,
|
|
||||||
install_dir : mandirn,
|
|
||||||
)
|
|
||||||
endforeach
|
|
||||||
|
|
||||||
foreach page: manpages + sitepages
|
|
||||||
manpage = page['name']
|
|
||||||
htmlpage = '@0@.html'.format(manpage)
|
|
||||||
input = page.get('source', '@0@.asciidoc'.format(manpage))
|
|
||||||
|
|
||||||
html = custom_target(
|
|
||||||
htmlpage,
|
|
||||||
command : [
|
|
||||||
ASCIIDOC,
|
|
||||||
] + asciidoc_opts + [
|
|
||||||
'-a', 'linkcss',
|
|
||||||
'-a', 'toc',
|
|
||||||
'-a', 'icons',
|
|
||||||
'-a', 'max-width=960px',
|
|
||||||
'-a', 'stylesheet=asciidoc-override.css',
|
|
||||||
'-o', '@OUTPUT@',
|
|
||||||
'@INPUT@',
|
|
||||||
],
|
|
||||||
input : input,
|
|
||||||
output : [htmlpage],
|
|
||||||
depend_files : [
|
|
||||||
asciidoc_conf,
|
|
||||||
'asciidoc-override.css',
|
|
||||||
] + page.get('extra_depends', []),
|
|
||||||
build_by_default : false,
|
|
||||||
install : false,
|
|
||||||
)
|
|
||||||
html_targets += [html]
|
|
||||||
html_files += [htmlpage]
|
|
||||||
endforeach
|
|
||||||
|
|
||||||
run_target('html',
|
|
||||||
command : ['/bin/true'],
|
|
||||||
depends : html_targets)
|
|
||||||
|
|
||||||
custom_target(
|
|
||||||
'website.tar.gz',
|
|
||||||
command : [
|
|
||||||
'bsdtar', 'czf', '@OUTPUT@',
|
|
||||||
'-C', meson.current_build_dir(),
|
|
||||||
] + html_files + [
|
|
||||||
'-C', meson.current_source_dir(),
|
|
||||||
'asciidoc-override.css',
|
|
||||||
'-C', '/etc/asciidoc/stylesheets/',
|
|
||||||
'asciidoc.css',
|
|
||||||
'-C', '/etc/asciidoc/javascripts/',
|
|
||||||
'asciidoc.js',
|
|
||||||
'-C', '/etc/asciidoc/',
|
|
||||||
'images',
|
|
||||||
],
|
|
||||||
output : ['website.tar.gz'],
|
|
||||||
build_by_default : false,
|
|
||||||
depends : html_targets,
|
|
||||||
)
|
|
||||||
|
|
||||||
meson.add_install_script(MESON_MAKE_SYMLINK,
|
|
||||||
'repo-add.8',
|
|
||||||
join_paths(MANDIR, 'man8/repo-remove.8'))
|
|
||||||
|
|
||||||
meson.add_install_script(MESON_MAKE_SYMLINK,
|
|
||||||
'alpm-hooks.5',
|
|
||||||
join_paths(MANDIR, 'man5/pacman-hooks.5'))
|
|
||||||
|
|
||||||
doxygen = find_program('doxygen', required : get_option('doxygen'))
|
|
||||||
if doxygen.found() and not get_option('doxygen').disabled()
|
|
||||||
doxyconf = configuration_data()
|
|
||||||
doxyconf.set('INPUT_DIRECTORY', meson.current_source_dir())
|
|
||||||
doxyconf.set('OUTPUT_DIRECTORY', meson.current_build_dir())
|
|
||||||
doxyfile = configure_file(
|
|
||||||
input : 'Doxyfile.in',
|
|
||||||
output : 'Doxyfile',
|
|
||||||
configuration : doxyconf,
|
|
||||||
install : false)
|
|
||||||
|
|
||||||
custom_target(
|
|
||||||
'doxygen',
|
|
||||||
input : doxyfile,
|
|
||||||
output : ['man3'],
|
|
||||||
command : [doxygen, doxyfile],
|
|
||||||
build_by_default : true,
|
|
||||||
install : true,
|
|
||||||
install_dir : MANDIR)
|
|
||||||
endif
|
|
|
@ -1,67 +0,0 @@
|
||||||
pacman-conf(8)
|
|
||||||
==============
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
pacman-conf - query pacman's configuration file
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'pacman-conf' [options] [<directive> ...]
|
|
||||||
|
|
||||||
'pacman-conf' (--repo-list|--help|--version)
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'pacman-conf' is a utility for parsing the 'pacman' configuration file
|
|
||||||
and returning script-friendly output. It is designed to properly handle
|
|
||||||
non-trivial configuration features such as variable interpolation and
|
|
||||||
the use of the Include directive, and guarantees that it will return the
|
|
||||||
same configuration values which 'pacman' itself would use.
|
|
||||||
|
|
||||||
'pacman-conf' will output the fully-resolved contents of the
|
|
||||||
configuration file by default, or, if provided with the name of a
|
|
||||||
configuration directive, output the contents of the given directive alone.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
*-c, \--config* <path>::
|
|
||||||
Specify an alternate configuration file.
|
|
||||||
|
|
||||||
*-R, \--rootdir* <path>::
|
|
||||||
Specify an alternate installation root (default is `/`).
|
|
||||||
|
|
||||||
*-r, \--repo* <repository>::
|
|
||||||
Query options for a specific repository.
|
|
||||||
|
|
||||||
*-v, \--verbose*::
|
|
||||||
Always shown directive names.
|
|
||||||
|
|
||||||
*-l, \--repo-list*::
|
|
||||||
List configured repositories.
|
|
||||||
|
|
||||||
*-h, \--help*::
|
|
||||||
Output syntax and command line options.
|
|
||||||
|
|
||||||
*-V, \--version*::
|
|
||||||
Display version and exit.
|
|
||||||
|
|
||||||
|
|
||||||
Examples
|
|
||||||
--------
|
|
||||||
|
|
||||||
pacman-conf -r core Usage::
|
|
||||||
Show the value of the Usage configuration option for core repository.
|
|
||||||
|
|
||||||
pacman-conf HoldPkg::
|
|
||||||
Show the value of the HoldPkg configuration option.
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:pacman.conf[5]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,36 +0,0 @@
|
||||||
pacman-db-upgrade(8)
|
|
||||||
====================
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
pacman-db-upgrade - upgrade the local pacman database to a newer format
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'pacman-db-upgrade' [options]
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'pacman-db-upgrade' is a script that upgrades the local database used
|
|
||||||
by linkman:pacman[8] to a newer format.
|
|
||||||
|
|
||||||
Options
|
|
||||||
--------------
|
|
||||||
*-h, \--help*::
|
|
||||||
Show the built-in help message and exit.
|
|
||||||
*-V, \--version*::
|
|
||||||
Show version information and exit.
|
|
||||||
*-d, \--dbpath* <path>::
|
|
||||||
Set an alternate database location.
|
|
||||||
*-r, \--root* <path>::
|
|
||||||
Set an alternate installation root.
|
|
||||||
*\--config* <path>::
|
|
||||||
Set an alternate configuration file.
|
|
||||||
*\--nocolor*::
|
|
||||||
Remove color from output.
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:pacman[8]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,151 +0,0 @@
|
||||||
pacman-key(8)
|
|
||||||
=============
|
|
||||||
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
pacman-key - manage pacman's list of trusted keys
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'pacman-key' [options] operation [targets]
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'pacman-key' is a wrapper script for GnuPG used to manage pacman's keyring, which
|
|
||||||
is the collection of PGP keys used to check signed packages and databases. It
|
|
||||||
provides the ability to import and export keys, fetch keys from keyservers and
|
|
||||||
update the key trust database.
|
|
||||||
|
|
||||||
More complex keyring management can be achieved using GnuPG directly combined with
|
|
||||||
the '\--homedir' option pointing at the pacman keyring (located in
|
|
||||||
+{sysconfdir}/pacman.d/gnupg+ by default).
|
|
||||||
|
|
||||||
Invoking pacman-key consists of supplying an operation with any potential
|
|
||||||
options and targets to operate on. Depending on the operation, a 'target' may
|
|
||||||
be a valid key identifier, filename, or directory.
|
|
||||||
|
|
||||||
|
|
||||||
Operations
|
|
||||||
----------
|
|
||||||
*-a, \--add*::
|
|
||||||
Add the key(s) contained in the specified file or files to pacman's
|
|
||||||
keyring. If a key already exists, update it.
|
|
||||||
|
|
||||||
*-d, \--delete*::
|
|
||||||
Remove the key(s) identified by the specified keyid(s) from pacman's
|
|
||||||
keyring.
|
|
||||||
|
|
||||||
*-e, \--export*::
|
|
||||||
Export key(s) identified by the specified keyid(s) to 'stdout'. If no keyid
|
|
||||||
is specified, all keys will be exported.
|
|
||||||
|
|
||||||
*\--edit-key*::
|
|
||||||
Present a menu for key management task on the specified keyid(s). Useful
|
|
||||||
for adjusting a keys trust level.
|
|
||||||
|
|
||||||
*-f, \--finger*::
|
|
||||||
List a fingerprint for each specified keyid, or for all known keys if no
|
|
||||||
keyids are specified.
|
|
||||||
|
|
||||||
*-h, \--help*::
|
|
||||||
Output syntax and command line options.
|
|
||||||
|
|
||||||
*\--import*::
|
|
||||||
Imports keys from `pubring.gpg` into the public keyring from the specified
|
|
||||||
directories.
|
|
||||||
|
|
||||||
*\--import-trustdb*::
|
|
||||||
Imports ownertrust values from `trustdb.gpg` into the shared trust database
|
|
||||||
from the specified directories.
|
|
||||||
|
|
||||||
*\--init*::
|
|
||||||
Ensure the keyring is properly initialized and has the required access
|
|
||||||
permissions.
|
|
||||||
|
|
||||||
*-l, \--list-keys*::
|
|
||||||
Lists all or specified keys from the public keyring.
|
|
||||||
|
|
||||||
*\--list-sigs*::
|
|
||||||
Same as '\--list-keys', but the signatures are listed too.
|
|
||||||
|
|
||||||
*\--lsign-key*::
|
|
||||||
Locally sign the given key. This is primarily used to root the web of trust
|
|
||||||
in the local private key generated by '\--init'.
|
|
||||||
|
|
||||||
*\--nocolor*::
|
|
||||||
Disable colored output from pacman-key.
|
|
||||||
|
|
||||||
*-r, \--recv-keys*::
|
|
||||||
Equivalent to '\--recv-keys' in GnuPG.
|
|
||||||
|
|
||||||
*\--refresh-keys*::
|
|
||||||
Equivalent to '\--refresh-keys' in GnuPG.
|
|
||||||
|
|
||||||
*\--populate*::
|
|
||||||
Reload the default keys from the (optionally provided) keyrings in
|
|
||||||
+{keyringdir}+. For more information, see
|
|
||||||
<<PK,Providing a Keyring for Import>> below.
|
|
||||||
|
|
||||||
*-u, \--updatedb*::
|
|
||||||
Equivalent to '\--check-trustdb' in GnuPG. This operation can be specified with
|
|
||||||
other operations.
|
|
||||||
|
|
||||||
*-V, \--version*::
|
|
||||||
Displays the program version.
|
|
||||||
|
|
||||||
*-v, \--verify*::
|
|
||||||
Assume that the first argument is a signature and verify it. If a second
|
|
||||||
argument is provided, it is the file to be verified.
|
|
||||||
+
|
|
||||||
With only one argument given, assume that the signature is a detached
|
|
||||||
signature, and look for a matching data file to verify by stripping the file
|
|
||||||
extension. If no matching data file is found, fall back on GnuPG semantics and
|
|
||||||
attempt to verify a file with an embedded signature.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
*\--config* <file>::
|
|
||||||
Use an alternate configuration file instead of the +{sysconfdir}/pacman.conf+
|
|
||||||
default.
|
|
||||||
|
|
||||||
*\--gpgdir* <dir>::
|
|
||||||
Set an alternate home directory for GnuPG. If unspecified, the value is
|
|
||||||
read from +{sysconfdir}/pacman.conf+.
|
|
||||||
|
|
||||||
*\--keyserver* <keyserver>::
|
|
||||||
Use the specified keyserver if the operation requires one. This will take
|
|
||||||
precedence over any keyserver option specified in a `gpg.conf`
|
|
||||||
configuration file. Running '\--init' with this option will set the default
|
|
||||||
keyserver if one was not already configured.
|
|
||||||
|
|
||||||
|
|
||||||
Providing a Keyring for Import[[PK]]
|
|
||||||
------------------------------------
|
|
||||||
A distribution or other repository provided may want to provide a set of
|
|
||||||
PGP keys used in the signing of its packages and repository databases that can
|
|
||||||
be readily imported into the pacman keyring. This is achieved by providing a
|
|
||||||
PGP keyring file `foo.gpg` that contains the keys for the foo keyring in the
|
|
||||||
directory +{keyringdir}+.
|
|
||||||
|
|
||||||
Optionally, the file `foo-trusted` can be provided containing a list of trusted
|
|
||||||
key IDs for that keyring. This is a file in a format compatible with 'gpg
|
|
||||||
\--export-ownertrust' output. This file will inform the user which keys a user
|
|
||||||
needs to verify and sign to build a local web of trust, in addition to
|
|
||||||
assigning provided owner trust values.
|
|
||||||
|
|
||||||
Also optionally, the file `foo-revoked` can be provided containing a list of
|
|
||||||
revoked key IDs for that keyring. Revoked is defined as "no longer valid for
|
|
||||||
any signing", so should be used with prudence. A key being marked as revoked
|
|
||||||
will be disabled in the keyring and no longer treated as valid, so this always
|
|
||||||
takes priority over it's trusted state in any other keyring.
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:pacman[8], linkman:pacman.conf[5]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
276
doc/pacman.8
Normal file
276
doc/pacman.8
Normal file
|
@ -0,0 +1,276 @@
|
||||||
|
." the string declarations are a start to try and make distro independent
|
||||||
|
.ds DS Arch Linux
|
||||||
|
.ds PB PKGBUILD
|
||||||
|
.ds VR 3.0.0
|
||||||
|
.ds LV 1.0.0
|
||||||
|
.TH pacman 8 "Feb 07, 2007" "pacman version \*(VR" "\*(DS Utilities"
|
||||||
|
.SH NAME
|
||||||
|
pacman \- package manager utility
|
||||||
|
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.B pacman
|
||||||
|
<\fIoperation\fR> [\fIoptions\fR] [\fIpackages\fR]
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fBpacman\fP is a \fIpackage management\fP utility that tracks installed
|
||||||
|
packages on a Linux system. It features dependency support, package groups,
|
||||||
|
install and uninstall hooks, and the ability to sync your local machine with a
|
||||||
|
remote ftp server to automatically upgrade packages. \fBpacman\fP packages are
|
||||||
|
a zipped tar format.
|
||||||
|
|
||||||
|
Since version 3.0.0, \fBpacman\fP has been the frontend to \fBlibalpm\fP, the
|
||||||
|
"Arch Linux Package Management" library. This library allows alternative front
|
||||||
|
ends to be written (for instance, a GUI front end).
|
||||||
|
|
||||||
|
.SH OPERATIONS
|
||||||
|
.TP
|
||||||
|
.B \-A, --add (deprecated)
|
||||||
|
Add a package to the system. Either a URL or file path can be specified. The
|
||||||
|
package will be uncompressed into the installation root and the database will
|
||||||
|
be updated. The package will not be installed if another version is already
|
||||||
|
installed. NOTE: please use \fB--upgrade\fP in place of this option.
|
||||||
|
.TP
|
||||||
|
.B \-F, --freshen
|
||||||
|
This is like \fB--upgrade\fP except it will only upgrade packages already
|
||||||
|
installed on the system.
|
||||||
|
.TP
|
||||||
|
.B \-Q, --query
|
||||||
|
Query the package database. This operation allows you to view installed
|
||||||
|
packages and their files, as well as meta-information about individual packages
|
||||||
|
(dependencies, conflicts, install date, build date, size). This can be run
|
||||||
|
against the local package database or can be used on individual .tar.gz
|
||||||
|
packages. See \fBQUERY OPTIONS\fP below.
|
||||||
|
.TP
|
||||||
|
.B \-R, --remove
|
||||||
|
Remove a package from the system. Files belonging to the specified package
|
||||||
|
will be deleted, and the database will be updated. Most configuration files
|
||||||
|
will be saved with a \fI.pacsave\fP extension unless the \fB--nosave\fP option
|
||||||
|
is used. See \fBREMOVE OPTIONS\fP below.
|
||||||
|
.TP
|
||||||
|
.B \-S, --sync
|
||||||
|
Synchronize packages. Packages are installed directly from the ftp servers,
|
||||||
|
including all dependencies required to run the packages. For example,
|
||||||
|
\fBpacman -S qt\fP will download and install \fBqt\fP and all the packages it
|
||||||
|
depends on. You can also use \fBpacman -Su\fP to upgrade all packages that are
|
||||||
|
out of date. See \fBSYNC OPTIONS\fP below.
|
||||||
|
.TP
|
||||||
|
.B \-U, --upgrade
|
||||||
|
Upgrade or add a package to the system. Either a URL or file path can be
|
||||||
|
specified. This is a "remove-then-add" process. See \fBHANDLING CONFIG
|
||||||
|
FILES\fP for an explanation on how pacman takes care of config files.
|
||||||
|
.TP
|
||||||
|
.B \-V, --version
|
||||||
|
Display version and exit.
|
||||||
|
.TP
|
||||||
|
.B \-h, --help
|
||||||
|
Display syntax for the given operation. If no operation was supplied then the
|
||||||
|
general syntax is shown.
|
||||||
|
|
||||||
|
.SH OPTIONS
|
||||||
|
.TP
|
||||||
|
.B \-b, --dbpath \fIpath\fP
|
||||||
|
Specify an alternative database location (default is "/var/lib/pacman/"). This
|
||||||
|
should not be used unless you know what you are doing.
|
||||||
|
.TP
|
||||||
|
.B \-d, --nodeps
|
||||||
|
Skips all dependency checks. Normally, pacman will always check a package's
|
||||||
|
dependency fields to ensure that all dependencies are installed and there are
|
||||||
|
no package conflicts in the system.
|
||||||
|
.TP
|
||||||
|
.B \-f, --force
|
||||||
|
Bypass file conflict checks and overwrite conflicting files. If the package
|
||||||
|
that is about to be installed contains files that are already installed, this
|
||||||
|
option will cause all those files to be overwritten. This option should be
|
||||||
|
used with care, ideally not at all.
|
||||||
|
.TP
|
||||||
|
.B \-r, --root \fIpath\fP
|
||||||
|
Specify an alternative installation root (default is "/"). This should
|
||||||
|
\fInot\fP be used as a way to install software into /usr/local instead of /usr.
|
||||||
|
This option is used if you want to install a package on a temporary mounted
|
||||||
|
partition which is "owned" by another system. By using this option you not only
|
||||||
|
specify where the software should be installed, but you also specify which
|
||||||
|
package database and cache location to use.
|
||||||
|
.TP
|
||||||
|
.B \-v, --verbose
|
||||||
|
Output more status messages, such as the Root and DBPath.
|
||||||
|
.TP
|
||||||
|
.B \--cachedir \fIdir\fP
|
||||||
|
Specify an alternative package cache location (default is
|
||||||
|
"/var/cache/pacman/pkg/"). This should not be used unless you know what you are
|
||||||
|
doing.
|
||||||
|
.TP
|
||||||
|
.B \--config \fIfilepath\fP
|
||||||
|
Specify an alternate configuration file.
|
||||||
|
.TP
|
||||||
|
.B \--noconfirm
|
||||||
|
Bypass any and all "Are you sure?" messages. It's not a good idea to do this
|
||||||
|
unless you want to run pacman from a script.
|
||||||
|
.TP
|
||||||
|
.B \--noprogressbar
|
||||||
|
Do not show a progress bar when downloading files. This can be useful for
|
||||||
|
scripts that call pacman and capture the output.
|
||||||
|
|
||||||
|
.SH QUERY OPTIONS
|
||||||
|
.TP
|
||||||
|
.B \-e, --orphans
|
||||||
|
List all packages that were pulled in by a previously installed package but no
|
||||||
|
longer required by any installed package.
|
||||||
|
.TP
|
||||||
|
.B \-g, --groups
|
||||||
|
Display all packages that are members of a named group. If not name is
|
||||||
|
specified, list all grouped packages.
|
||||||
|
.TP
|
||||||
|
.B \-i, --info
|
||||||
|
Display information on a given package. The \fB-p\fP option can be used if
|
||||||
|
querying a package file instead of the local database.
|
||||||
|
.TP
|
||||||
|
.B \-l, --list
|
||||||
|
List all files owned by a given package. Multiple packages can be specified on
|
||||||
|
the command line.
|
||||||
|
.TP
|
||||||
|
.B \-m, --foreign
|
||||||
|
List all packages that were not found in the sync database(s). Typically these
|
||||||
|
are packages that were downloaded manually and installed with \fB--upgrade\fP.
|
||||||
|
.TP
|
||||||
|
.B \-o, --owns \fIfile\fP
|
||||||
|
Search for the package that owns \fIfile\fP.
|
||||||
|
.TP
|
||||||
|
.B \-p, --file
|
||||||
|
Signifies that the package supplied on the command line is a file and not an
|
||||||
|
entry in the database. The file will be decompressed and queried. This is
|
||||||
|
useful in combination with \fB--info\fP and \fB--list\fP.
|
||||||
|
.TP
|
||||||
|
.B \-s, --search \fIregexp\fP
|
||||||
|
This will search each locally-installed package for names or descriptions that
|
||||||
|
matche \fIregexp\fP.
|
||||||
|
.TP
|
||||||
|
.B \-u, --upgrades
|
||||||
|
Lists all packages that are out of date on the local system. This option works
|
||||||
|
best if the sync database is refreshed using \fB-Sy\fP.
|
||||||
|
|
||||||
|
.SH REMOVE OPTIONS
|
||||||
|
.TP
|
||||||
|
.B \-c, --cascade
|
||||||
|
Remove all target packages, as well as all packages that depend on one or more
|
||||||
|
target packages. This operation is recursive.
|
||||||
|
.TP
|
||||||
|
.B \-k, --keep
|
||||||
|
Removes the database entry only. Leaves all files in place.
|
||||||
|
.TP
|
||||||
|
.B \-n, --nosave
|
||||||
|
Instructs pacman to ignore file backup designations. Normally, when a file is
|
||||||
|
removed from the system the database is checked to see if the file should be
|
||||||
|
renamed with a .pacsave extension.
|
||||||
|
.TP
|
||||||
|
.B \-s, --recursive
|
||||||
|
Remove each target specified including all dependencies, provided that (A) they
|
||||||
|
are not required by other packages; and (B) they were not explicitly installed
|
||||||
|
by the user. This option is analogous to a backwards \fB--sync\fP operation.
|
||||||
|
|
||||||
|
.SH SYNC OPTIONS
|
||||||
|
.TP
|
||||||
|
.B \-c, --clean
|
||||||
|
Remove old packages from the cache to free up disk space. When \fBpacman\fP
|
||||||
|
downloads packages, it saves them in \fI/var/cache/pacman/pkg\fP. Use one
|
||||||
|
\fB--clean\fP switch to remove \fIold\fP packages; use two to remove \fIall\fP
|
||||||
|
packages from the cache.
|
||||||
|
.TP
|
||||||
|
.B \-g, --groups
|
||||||
|
Display all the members for each package group specified. If no group names
|
||||||
|
are provided, all groups will be listed; pass the flag twice to view all
|
||||||
|
groups and their members.
|
||||||
|
.TP
|
||||||
|
.B \-i, --info
|
||||||
|
Display dependency and other information for a given package. This will search
|
||||||
|
through all repositories for a matching package.
|
||||||
|
.TP
|
||||||
|
.B \-l, --list
|
||||||
|
List all packages in the specified repositories. Multiple repositories can be
|
||||||
|
specified on the command line.
|
||||||
|
.TP
|
||||||
|
.B \-p, --print-uris
|
||||||
|
Print out URIs for each package that will be installed, including any
|
||||||
|
dependencies yet to be installed. These can be piped to a file and downloaded
|
||||||
|
at a later time, using a program like wget.
|
||||||
|
.TP
|
||||||
|
.B \-s, --search \fIregexp\fP
|
||||||
|
This will search each package in the sync databases for names or descriptions
|
||||||
|
that match \fIregexp\fP.
|
||||||
|
.TP
|
||||||
|
.B \-u, --sysupgrade
|
||||||
|
Upgrades all packages that are out of date. Each currently-installed package
|
||||||
|
will be examined and upgraded if a newer package exists. A report of all
|
||||||
|
packages to upgrade will be presented and the operation will not proceed
|
||||||
|
without user confirmation. Dependencies are automatically resolved at this
|
||||||
|
level and will be installed/upgraded if necessary.
|
||||||
|
.TP
|
||||||
|
.B \-w, --downloadonly
|
||||||
|
Retrieve all packages from the server, but do not install/upgrade anything.
|
||||||
|
.TP
|
||||||
|
.B \-y, --refresh
|
||||||
|
Download a fresh copy of the master package list from the server(s) defined in
|
||||||
|
\fBpacman.conf\fP. This should typically be used each time you use
|
||||||
|
\fB--sysupgrade\fP or \fB-u\fP. Passing two \fB--refresh\fP or \fB-y\fP flags
|
||||||
|
will force a refresh of all package lists even if they are thought to be
|
||||||
|
up to date.
|
||||||
|
.TP
|
||||||
|
.B \--ignore \fIpackage\fP
|
||||||
|
Directs \fBpacman\fP to ignore upgrades of \fIpackage\fP even if there is one
|
||||||
|
available.
|
||||||
|
|
||||||
|
.SH HANDLING CONFIG FILES
|
||||||
|
pacman uses the same logic as rpm to determine action against files that are
|
||||||
|
designated to be backed up. During an upgrade, 3 md5 hashes are used for each
|
||||||
|
backup file to determine the required action: one for the original file
|
||||||
|
installed, one for the new file that's about to be installed, and one for the
|
||||||
|
actual file existing on the filesystem. After comparing these 3 hashes, the
|
||||||
|
follow scenarios can result:
|
||||||
|
.TP
|
||||||
|
original=\fBX\fP, current=\fBX\fP, new=\fBX\fP
|
||||||
|
All three files are the same, so overwrites are not an issue Install the new
|
||||||
|
file.
|
||||||
|
.TP
|
||||||
|
original=\fBX\fP, current=\fBX\fP, new=\fBY\fP
|
||||||
|
The current file is the same as the original but the new one differs. Since
|
||||||
|
the user did not ever modify the file, and the new one may contain improvements
|
||||||
|
or bugfixes, install the new file.
|
||||||
|
.TP
|
||||||
|
original=\fBX\fP, current=\fBY\fP, new=\fBX\fP
|
||||||
|
Both package versions contain the exact same file, but the one on the
|
||||||
|
filesystem has been modified. Leave the current file in place.
|
||||||
|
.TP
|
||||||
|
original=\fBX\fP, current=\fBY\fP, new=\fBY\fP
|
||||||
|
The new file is identical to the current file. Install the new file.
|
||||||
|
.TP
|
||||||
|
original=\fBX\fP, current=\fBY\fP, new=\fBZ\fP
|
||||||
|
All three files are different, so install the new file with a .pacnew extension
|
||||||
|
and warn the user. The user must then manually merge any necessary changes into
|
||||||
|
the original file.
|
||||||
|
|
||||||
|
.SH CONFIGURATION
|
||||||
|
See
|
||||||
|
.BR pacman.conf (5)
|
||||||
|
for more details on configuring \fBpacman\fP using the \fBpacman.conf\fP file.
|
||||||
|
|
||||||
|
.SH BUGS
|
||||||
|
Bugs? You must be kidding, there are no bugs in this software. But if we happen
|
||||||
|
to be wrong, send us an email with as much detail as possible to
|
||||||
|
<pacman-dev@archlinux.org>.
|
||||||
|
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR pacman.conf (5),
|
||||||
|
.BR makepkg (8),
|
||||||
|
.BR libalpm (3)
|
||||||
|
|
||||||
|
See the Arch Linux website at <http://www.archlinux.org> for more current
|
||||||
|
information on the distribution and the \fBpacman\fP family of tools.
|
||||||
|
|
||||||
|
.SH AUTHORS
|
||||||
|
.nf
|
||||||
|
Judd Vinet <jvinet@zeroflux.org>
|
||||||
|
Aurelien Foret <aurelien@archlinux.org>
|
||||||
|
Aaron Griffin <aaron@archlinux.org>
|
||||||
|
Dan McGee <dan@archlinux.org>
|
||||||
|
.fi
|
||||||
|
|
||||||
|
See the 'AUTHORS' file for additional contributors.
|
|
@ -1,583 +0,0 @@
|
||||||
pacman(8)
|
|
||||||
=========
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
pacman - package manager utility
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'pacman' <operation> [options] [targets]
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
Pacman is a package management utility that tracks installed packages on a Linux
|
|
||||||
system. It features dependency support, package groups, install and uninstall
|
|
||||||
scripts, and the ability to sync your local machine with a remote repository to
|
|
||||||
automatically upgrade packages. Pacman packages are a zipped tar format.
|
|
||||||
|
|
||||||
Since version 3.0.0, pacman has been the front-end to linkman:libalpm[3], the
|
|
||||||
``Arch Linux Package Management'' library. This library allows alternative
|
|
||||||
front-ends to be written (for instance, a GUI front-end).
|
|
||||||
|
|
||||||
Invoking pacman involves specifying an operation with any potential options and
|
|
||||||
targets to operate on. A 'target' is usually a package name, file name, URL, or
|
|
||||||
a search string. Targets can be provided as command line arguments.
|
|
||||||
Additionally, if stdin is not from a terminal and a single hyphen (-) is passed
|
|
||||||
as an argument, targets will be read from stdin.
|
|
||||||
|
|
||||||
|
|
||||||
Operations
|
|
||||||
----------
|
|
||||||
*-D, \--database*::
|
|
||||||
Operate on the package database. This operation allows you to modify
|
|
||||||
certain attributes of the installed packages in pacman's database. It
|
|
||||||
also allows you to check the databases for internal consistency.
|
|
||||||
See <<DO,Database Options>> below.
|
|
||||||
|
|
||||||
*-Q, \--query*::
|
|
||||||
Query the package database. This operation allows you to view installed
|
|
||||||
packages and their files, as well as meta-information about individual
|
|
||||||
packages (dependencies, conflicts, install date, build date, size). This
|
|
||||||
can be run against the local package database or can be used on
|
|
||||||
individual package files. In the first case, if no package names
|
|
||||||
are provided in the command line, all installed packages will be
|
|
||||||
queried. Additionally, various filters can be applied on the package
|
|
||||||
list. See <<QO,Query Options>> below.
|
|
||||||
|
|
||||||
*-R, \--remove*::
|
|
||||||
Remove package(s) from the system. Groups can also be specified to be
|
|
||||||
removed, in which case every package in that group will be removed.
|
|
||||||
Files belonging to the specified package will be deleted, and the
|
|
||||||
database will be updated. Most configuration files will be saved
|
|
||||||
with a '.pacsave' extension unless the '\--nosave' option is used.
|
|
||||||
See <<RO,Remove Options>> below.
|
|
||||||
|
|
||||||
*-S, \--sync*::
|
|
||||||
Synchronize packages. Packages are installed directly from the remote
|
|
||||||
repositories, including all dependencies required to run the packages. For
|
|
||||||
example, `pacman -S qt` will download and install qt and all the
|
|
||||||
packages it depends on. If a package name exists in more than one
|
|
||||||
repository, the repository can be explicitly specified to clarify the
|
|
||||||
package to install: `pacman -S testing/qt`. You can also specify version
|
|
||||||
requirements: `pacman -S "bash>=3.2"`. Quotes are needed, otherwise the
|
|
||||||
shell interprets ">" as redirection to a file.
|
|
||||||
+
|
|
||||||
In addition to packages, groups can be specified as well. For example, if
|
|
||||||
gnome is a defined package group, then `pacman -S gnome` will provide a
|
|
||||||
prompt allowing you to select which packages to install from a numbered list.
|
|
||||||
The package selection is specified using a space- and/or comma-separated list of
|
|
||||||
package numbers. Sequential packages may be selected by specifying the first
|
|
||||||
and last package numbers separated by a hyphen (`-`). Excluding packages is
|
|
||||||
achieved by prefixing a number or range of numbers with a caret (`^`).
|
|
||||||
+
|
|
||||||
Packages that provide other packages are also handled. For example, `pacman -S
|
|
||||||
foo` will first look for a foo package. If foo is not found, packages that
|
|
||||||
provide the same functionality as foo will be searched for. If any package is
|
|
||||||
found, it will be installed. A selection prompt is provided if multiple packages
|
|
||||||
providing foo are found.
|
|
||||||
+
|
|
||||||
You can also use `pacman -Su` to upgrade all packages that are out-of-date. See
|
|
||||||
<<SO,Sync Options>> below. When upgrading, pacman performs version comparison
|
|
||||||
to determine which packages need upgrading. This behavior operates as follows:
|
|
||||||
|
|
||||||
Alphanumeric:
|
|
||||||
1.0a < 1.0b < 1.0beta < 1.0p < 1.0pre < 1.0rc < 1.0 < 1.0.a < 1.0.1
|
|
||||||
Numeric:
|
|
||||||
1 < 1.0 < 1.1 < 1.1.1 < 1.2 < 2.0 < 3.0.0
|
|
||||||
+
|
|
||||||
Additionally, version strings can have an 'epoch' value defined that will
|
|
||||||
overrule any version comparison, unless the epoch values are equal. This is
|
|
||||||
specified in an `epoch:version-rel` format. For example, `2:1.0-1` is always
|
|
||||||
greater than `1:3.6-1`.
|
|
||||||
|
|
||||||
*-T, \--deptest*::
|
|
||||||
Check dependencies; this is useful in scripts such as makepkg to check
|
|
||||||
installed packages. This operation will check each dependency specified and
|
|
||||||
return a list of dependencies that are not currently satisfied on the system.
|
|
||||||
This operation accepts no other options. Example usage: `pacman -T qt
|
|
||||||
"bash>=3.2"`.
|
|
||||||
|
|
||||||
*-U, \--upgrade*::
|
|
||||||
Upgrade or add package(s) to the system and install the required
|
|
||||||
dependencies from sync repositories. Either a URL or file path can be
|
|
||||||
specified. This is a ``remove-then-add'' process. See <<UO,Upgrade
|
|
||||||
Options>> below; also see <<HCF,Handling Config Files>> for an explanation
|
|
||||||
on how pacman takes care of configuration files.
|
|
||||||
|
|
||||||
*-F, \--files*::
|
|
||||||
Query the files database. This operation allows you to look for packages
|
|
||||||
owning certain files or display files owned by certain packages. Only
|
|
||||||
packages that are part of your sync databases are searched. See
|
|
||||||
<<FO,File Options>> below.
|
|
||||||
|
|
||||||
*-V, \--version*::
|
|
||||||
Display version and exit.
|
|
||||||
|
|
||||||
*-h, \--help*::
|
|
||||||
Display syntax for the given operation. If no operation was supplied,
|
|
||||||
then the general syntax is shown.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
*-b, \--dbpath* <path>::
|
|
||||||
Specify an alternative database location (the default is
|
|
||||||
+{localstatedir}/lib/pacman+). This should not be used unless you know what
|
|
||||||
you are doing.
|
|
||||||
*NOTE*: If specified, this is an absolute path, and the root path is
|
|
||||||
not automatically prepended.
|
|
||||||
|
|
||||||
*-r, \--root* <path>::
|
|
||||||
Specify an alternative installation root (default is +{rootdir}+). This should
|
|
||||||
not be used as a way to install software into `/usr/local` instead of
|
|
||||||
`/usr`.
|
|
||||||
*NOTE*: If database path or log file are not specified on either the
|
|
||||||
command line or in linkman:pacman.conf[5], their default location will
|
|
||||||
be inside this root path.
|
|
||||||
*NOTE*: This option is not suitable for performing operations on a mounted
|
|
||||||
guest system. See '\--sysroot' instead.
|
|
||||||
|
|
||||||
*-v, \--verbose*::
|
|
||||||
Output paths such as the Root, Conf File, DB Path, Cache Dirs, etc.
|
|
||||||
|
|
||||||
*\--arch* <arch>::
|
|
||||||
Specify an alternate architecture.
|
|
||||||
|
|
||||||
*\--cachedir* <dir>::
|
|
||||||
Specify an alternative package cache location (the default is
|
|
||||||
+{localstatedir}/cache/pacman/pkg+). Multiple cache directories can be
|
|
||||||
specified, and they are tried in the order they are passed to pacman.
|
|
||||||
*NOTE*: This is an absolute path, and the root path is not automatically
|
|
||||||
prepended. If DownloadUser is set in linkman:pacman.conf[5], then the
|
|
||||||
specified user must have permission to access the cache directory.
|
|
||||||
|
|
||||||
*\--color* <when>::
|
|
||||||
Specify when to enable coloring. Valid options are 'always', 'never', or
|
|
||||||
'auto'. 'always' forces colors on; 'never' forces colors off; and 'auto' only
|
|
||||||
automatically enables colors when outputting onto a tty.
|
|
||||||
|
|
||||||
*\--config* <file>::
|
|
||||||
Specify an alternate configuration file.
|
|
||||||
|
|
||||||
*\--debug*::
|
|
||||||
Display debug messages. When reporting bugs, this option is recommended
|
|
||||||
to be used.
|
|
||||||
|
|
||||||
*\--gpgdir* <dir>::
|
|
||||||
Specify a directory of files used by GnuPG to verify package signatures
|
|
||||||
(the default is +{sysconfdir}/pacman.d/gnupg+). This directory should contain
|
|
||||||
two files: `pubring.gpg` and `trustdb.gpg`. `pubring.gpg` holds the public keys
|
|
||||||
of all packagers. `trustdb.gpg` contains a so-called trust database, which
|
|
||||||
specifies that the keys are authentic and trusted. *NOTE*: This is an absolute
|
|
||||||
path, and the root path is not automatically prepended.
|
|
||||||
|
|
||||||
*\--hookdir* <dir>::
|
|
||||||
Specify a alternative directory containing hook files (the default is
|
|
||||||
+{sysconfdir}/pacman.d/hooks+). Multiple hook directories can be specified
|
|
||||||
with hooks in later directories taking precedence over hooks in earlier
|
|
||||||
directories. *NOTE*: This is an absolute path, and the root path is not
|
|
||||||
automatically prepended.
|
|
||||||
|
|
||||||
*\--logfile* <file>::
|
|
||||||
Specify an alternate log file. This is an absolute path, regardless of
|
|
||||||
the installation root setting.
|
|
||||||
|
|
||||||
*\--noconfirm*::
|
|
||||||
Bypass any and all ``Are you sure?'' messages. It's not a good idea to do
|
|
||||||
this unless you want to run pacman from a script.
|
|
||||||
|
|
||||||
*\--confirm*::
|
|
||||||
Cancels the effects of a previous '\--noconfirm'.
|
|
||||||
|
|
||||||
*\--disable-download-timeout*::
|
|
||||||
Disable defaults for low speed limit and timeout on downloads. Use this
|
|
||||||
if you have issues downloading files with proxy and/or security gateway.
|
|
||||||
|
|
||||||
*\--sysroot* <dir>:: Specify an alternative system root. This path will be
|
|
||||||
prepended to all other configuration directories and any repository servers
|
|
||||||
beginning with `file://`. Any paths or URLs passed as targets will not be
|
|
||||||
modified. This allows mounted guest systems to be properly operated on.
|
|
||||||
|
|
||||||
*\--disable-sandbox*::
|
|
||||||
Disable the default sandbox applied to the process downloading files on Linux
|
|
||||||
systems. Useful if experiencing landlock related failures while downloading
|
|
||||||
files when running a Linux kernel that does not support this feature.
|
|
||||||
|
|
||||||
Transaction Options (apply to '-S', '-R' and '-U')
|
|
||||||
--------------------------------------------------
|
|
||||||
*-d, \--nodeps*::
|
|
||||||
Skips dependency version checks. Package names are still checked. Normally,
|
|
||||||
pacman will always check a package's dependency fields to ensure that all
|
|
||||||
dependencies are installed and there are no package conflicts in the
|
|
||||||
system. Specify this option twice to skip all dependency checks.
|
|
||||||
|
|
||||||
*\--assume-installed* <package=version>::
|
|
||||||
Add a virtual package "package" with version "version" to the transaction
|
|
||||||
to satisfy dependencies. This allows disabling the specific dependency checks
|
|
||||||
without affecting all dependency checks. To disable all dependency
|
|
||||||
checking, see the '\--nodeps' option.
|
|
||||||
|
|
||||||
*\--dbonly*::
|
|
||||||
Adds/removes the database entry only, leaving all files in place.
|
|
||||||
|
|
||||||
*\--noprogressbar*::
|
|
||||||
Do not show a progress bar when downloading files. This can be useful
|
|
||||||
for scripts that call pacman and capture the output.
|
|
||||||
|
|
||||||
*\--noscriptlet*::
|
|
||||||
If an install scriptlet exists, do not execute it. Do not use this
|
|
||||||
unless you know what you are doing.
|
|
||||||
|
|
||||||
*-p, \--print*::
|
|
||||||
Only print the targets instead of performing the actual operation (sync,
|
|
||||||
remove or upgrade). Use '\--print-format' to specify how targets are
|
|
||||||
displayed. The default format string is "%l", which displays URLs with
|
|
||||||
'-S', file names with '-U', and pkgname-pkgver with '-R'.
|
|
||||||
|
|
||||||
*\--print-format* <format>::
|
|
||||||
Specify a printf-like format to control the output of the '\--print'
|
|
||||||
operation. The possible attributes are: "%a" for arch, "%b" for
|
|
||||||
builddate, "%d" for description, "%e" for pkgbase, "%f" for filename,
|
|
||||||
"%g" for base64 encoded PGP signature, "%h" for sha256sum, "%m" for
|
|
||||||
md5sum, "%n" for pkgname, "%p" for packager, "%v" for pkgver, "%l" for
|
|
||||||
location, "%r" for repository, "%s" for size, "%C" for checkdepends,
|
|
||||||
"%D" for depends, "%G" for groups, "%H" for conflicts, "%L" for
|
|
||||||
licenses, "%M" for makedepends, "%O" for optional depends, "%P" for
|
|
||||||
provides and "%R" for replaces.
|
|
||||||
Implies '\--print'.
|
|
||||||
|
|
||||||
|
|
||||||
Upgrade Options (apply to '-S' and '-U')[[UO]]
|
|
||||||
----------------------------------------------
|
|
||||||
*-w, \--downloadonly*::
|
|
||||||
Retrieve all packages from the server, but do not install/upgrade anything.
|
|
||||||
|
|
||||||
*\--asdeps*::
|
|
||||||
Install packages non-explicitly; in other words, fake their install reason
|
|
||||||
to be installed as a dependency. This is useful for makepkg and other
|
|
||||||
build-from-source tools that need to install dependencies before building
|
|
||||||
the package.
|
|
||||||
|
|
||||||
*\--asexplicit*::
|
|
||||||
Install packages explicitly; in other words, fake their install reason to
|
|
||||||
be explicitly installed. This is useful if you want to mark a dependency
|
|
||||||
as explicitly installed so it will not be removed by the '\--recursive'
|
|
||||||
remove operation.
|
|
||||||
|
|
||||||
*\--ignore* <package>::
|
|
||||||
Directs pacman to ignore upgrades of package even if there is one
|
|
||||||
available. Multiple packages can be specified by separating them
|
|
||||||
with a comma.
|
|
||||||
|
|
||||||
*\--ignoregroup* <group>::
|
|
||||||
Directs pacman to ignore upgrades of all packages in 'group', even if
|
|
||||||
there is one available. Multiple groups can be specified by
|
|
||||||
separating them with a comma.
|
|
||||||
|
|
||||||
*\--needed*::
|
|
||||||
Do not reinstall the targets that are already up-to-date.
|
|
||||||
|
|
||||||
*\--overwrite* <glob>::
|
|
||||||
Bypass file conflict checks and overwrite conflicting files. If the
|
|
||||||
package that is about to be installed contains files that are already
|
|
||||||
installed and match 'glob', this option will cause all those files to be
|
|
||||||
overwritten. Using '\--overwrite' will not allow overwriting a directory
|
|
||||||
with a file or installing packages with conflicting files and directories.
|
|
||||||
Multiple patterns can be specified by separating them with a comma. May be
|
|
||||||
specified multiple times. Patterns can be negated, such that files
|
|
||||||
matching them will not be overwritten, by prefixing them with an
|
|
||||||
exclamation mark. Subsequent matches will override previous ones. A leading
|
|
||||||
literal exclamation mark or backslash needs to be escaped.
|
|
||||||
|
|
||||||
|
|
||||||
Query Options (apply to '-Q')[[QO]]
|
|
||||||
-----------------------------------
|
|
||||||
*-c, \--changelog*::
|
|
||||||
View the ChangeLog of a package if it exists.
|
|
||||||
|
|
||||||
*-d, \--deps*::
|
|
||||||
Restrict or filter output to packages installed as dependencies. This
|
|
||||||
option can be combined with '-t' for listing real orphans - packages that
|
|
||||||
were installed as dependencies but are no longer required by any
|
|
||||||
installed package.
|
|
||||||
|
|
||||||
*-e, \--explicit*::
|
|
||||||
Restrict or filter output to explicitly installed packages. This option
|
|
||||||
can be combined with '-t' to list explicitly installed packages that
|
|
||||||
are not required by any other package.
|
|
||||||
|
|
||||||
*-g, \--groups*::
|
|
||||||
Display all packages that are members of a named group. If a name is not
|
|
||||||
specified, list all grouped packages.
|
|
||||||
|
|
||||||
*-i, \--info*::
|
|
||||||
Display information on a given package. The '-p' option can be used if
|
|
||||||
querying a package file instead of the local database. Passing two
|
|
||||||
'\--info' or '-i' flags will also display the list of backup files and
|
|
||||||
their modification states.
|
|
||||||
|
|
||||||
*-k, \--check*::
|
|
||||||
Check that all files owned by the given package(s) are present on the
|
|
||||||
system. If packages are not specified or filter flags are not provided,
|
|
||||||
check all installed packages. Specifying this option twice will perform
|
|
||||||
more detailed file checking (including permissions, file sizes, and
|
|
||||||
modification times) for packages that contain the needed mtree file.
|
|
||||||
|
|
||||||
*-l, \--list*::
|
|
||||||
List all files owned by a given package. Multiple packages can be
|
|
||||||
specified on the command line.
|
|
||||||
|
|
||||||
*-m, \--foreign*::
|
|
||||||
Restrict or filter output to packages that were not found in the sync
|
|
||||||
database(s). Typically these are packages that were downloaded manually
|
|
||||||
and installed with '\--upgrade'.
|
|
||||||
|
|
||||||
*-n, \--native*::
|
|
||||||
Restrict or filter output to packages that are found in the sync
|
|
||||||
database(s). This is the inverse filter of '\--foreign'.
|
|
||||||
|
|
||||||
*-o, \--owns* <file>::
|
|
||||||
Search for packages that own the specified file(s). The path can be
|
|
||||||
relative or absolute, and one or more files can be specified.
|
|
||||||
|
|
||||||
*-p, \--file*::
|
|
||||||
Signifies that the package supplied on the command line is a file and
|
|
||||||
not an entry in the database. The file will be decompressed and queried.
|
|
||||||
This is useful in combination with '\--info' and '\--list'.
|
|
||||||
|
|
||||||
*-q, \--quiet*::
|
|
||||||
Show less information for certain query operations. This is useful when
|
|
||||||
pacman's output is processed in a script. Search will only show package
|
|
||||||
names and not version, group, and description information; owns will
|
|
||||||
only show package names instead of "file is owned by pkg" messages; group
|
|
||||||
will only show package names and omit group names; list will only show
|
|
||||||
files and omit package names; check will only show pairs of package names
|
|
||||||
and missing files; a bare query will only show package names
|
|
||||||
rather than names and versions.
|
|
||||||
|
|
||||||
*-s, \--search* <regexp>::
|
|
||||||
Search each locally-installed package for names or descriptions that
|
|
||||||
match `regexp`. When including multiple search terms, only packages
|
|
||||||
with descriptions matching ALL of those terms are returned.
|
|
||||||
|
|
||||||
*-t, \--unrequired*::
|
|
||||||
Restrict or filter output to print only packages neither required nor
|
|
||||||
optionally required by any currently installed package. Specify this
|
|
||||||
option twice to include packages which are optionally, but not directly,
|
|
||||||
required by another package.
|
|
||||||
|
|
||||||
*-u, \--upgrades*::
|
|
||||||
Restrict or filter output to packages that are out-of-date on the local
|
|
||||||
system. Only package versions are used to find outdated packages;
|
|
||||||
replacements are not checked here. This option works best if the sync
|
|
||||||
database is refreshed using '-Sy'.
|
|
||||||
|
|
||||||
|
|
||||||
Remove Options (apply to '-R')[[RO]]
|
|
||||||
------------------------------------
|
|
||||||
*-c, \--cascade*::
|
|
||||||
Remove all target packages, as well as all packages that depend on one
|
|
||||||
or more target packages. This operation is recursive and must be used
|
|
||||||
with care, since it can remove many potentially needed packages.
|
|
||||||
|
|
||||||
*-n, \--nosave*::
|
|
||||||
Instructs pacman to ignore file backup designations. Normally, when a
|
|
||||||
file is removed from the system, the database is checked to see if the
|
|
||||||
file should be renamed with a '.pacsave' extension.
|
|
||||||
|
|
||||||
*-s, \--recursive*::
|
|
||||||
Remove each target specified including all of their dependencies, provided
|
|
||||||
that (A) they are not required by other packages; and (B) they were not
|
|
||||||
explicitly installed by the user. This operation is recursive and analogous
|
|
||||||
to a backwards '\--sync' operation, and it helps keep a clean system without
|
|
||||||
orphans. If you want to omit condition (B), pass this option twice.
|
|
||||||
|
|
||||||
*-u, \--unneeded*::
|
|
||||||
Removes targets that are not required by any other packages.
|
|
||||||
This is mostly useful when removing a group without using the '-c' option,
|
|
||||||
to avoid breaking any dependencies.
|
|
||||||
|
|
||||||
|
|
||||||
Sync Options (apply to '-S')[[SO]]
|
|
||||||
----------------------------------
|
|
||||||
*-c, \--clean*::
|
|
||||||
Remove packages that are no longer installed from the cache as well as
|
|
||||||
currently unused sync databases to free up disk space. When pacman
|
|
||||||
downloads packages, it saves them in a cache directory. In addition,
|
|
||||||
databases are saved for every sync DB you download from and are not
|
|
||||||
deleted even if they are removed from the configuration file
|
|
||||||
linkman:pacman.conf[5]. Use one '\--clean' switch to only remove
|
|
||||||
packages that are no longer installed; use two to remove all files
|
|
||||||
from the cache. In both cases, you will have a yes or no option to
|
|
||||||
remove packages and/or unused downloaded databases.
|
|
||||||
+
|
|
||||||
If you use a network shared cache, see the 'CleanMethod' option in
|
|
||||||
linkman:pacman.conf[5].
|
|
||||||
|
|
||||||
*-g, \--groups*::
|
|
||||||
Display all the members for each package group specified. If no group
|
|
||||||
names are provided, all groups will be listed; pass the flag twice to
|
|
||||||
view all groups and their members.
|
|
||||||
|
|
||||||
*-i, \--info*::
|
|
||||||
Display information on a given sync database package. Passing two '\--info'
|
|
||||||
or '-i' flags will also display those packages in all repositories that
|
|
||||||
depend on this package.
|
|
||||||
|
|
||||||
*-l, \--list*::
|
|
||||||
List all packages in the specified repositories. Multiple repositories
|
|
||||||
can be specified on the command line.
|
|
||||||
|
|
||||||
*-q, \--quiet*::
|
|
||||||
Show less information for certain sync operations. This is useful when
|
|
||||||
pacman's output is processed in a script. Search will only show package
|
|
||||||
names and not repository, version, group, and description information; list
|
|
||||||
will only show package names and omit databases and versions; group will
|
|
||||||
only show package names and omit group names.
|
|
||||||
|
|
||||||
*-s, \--search* <regexp>::
|
|
||||||
This will search each package in the sync databases for names or
|
|
||||||
descriptions that match `regexp`. When you include multiple search
|
|
||||||
terms, only packages with descriptions matching ALL of those terms will
|
|
||||||
be returned.
|
|
||||||
|
|
||||||
*-u, \--sysupgrade*::
|
|
||||||
Upgrades all packages that are out-of-date. Each currently-installed
|
|
||||||
package will be examined and upgraded if a newer package exists. A
|
|
||||||
report of all packages to upgrade will be presented, and the operation
|
|
||||||
will not proceed without user confirmation. Dependencies are
|
|
||||||
automatically resolved at this level and will be installed/upgraded if
|
|
||||||
necessary.
|
|
||||||
+
|
|
||||||
Pass this option twice to enable package downgrades; in this case, pacman will
|
|
||||||
select sync packages whose versions do not match with the local versions. This
|
|
||||||
can be useful when the user switches from a testing repository to a stable one.
|
|
||||||
+
|
|
||||||
Additional targets can also be specified manually, so that '-Su foo' will do a
|
|
||||||
system upgrade and install/upgrade the "foo" package in the same operation.
|
|
||||||
|
|
||||||
*-y, \--refresh*::
|
|
||||||
Download a fresh copy of the master package databases '(repo.db)' from the
|
|
||||||
server(s) defined in linkman:pacman.conf[5]. This should typically be used
|
|
||||||
each time you use '\--sysupgrade' or '-u'. Passing two '\--refresh' or '-y'
|
|
||||||
flags will force a refresh of all package databases, even if they appear to
|
|
||||||
be up-to-date.
|
|
||||||
|
|
||||||
|
|
||||||
Database Options (apply to '-D')[[QO]]
|
|
||||||
--------------------------------------
|
|
||||||
*\--asdeps* <package>::
|
|
||||||
Mark a package as non-explicitly installed; in other words, set their install
|
|
||||||
reason to be installed as a dependency.
|
|
||||||
|
|
||||||
*\--asexplicit* <package>::
|
|
||||||
Mark a package as explicitly installed; in other words, set their install
|
|
||||||
reason to be explicitly installed. This is useful if you want to keep a
|
|
||||||
package installed even when it was initially installed as a dependency
|
|
||||||
of another package.
|
|
||||||
|
|
||||||
*-k, \--check*::
|
|
||||||
Check the local package database is internally consistent. This will
|
|
||||||
check all required files are present and that installed packages have
|
|
||||||
the required dependencies, do not conflict and that multiple packages
|
|
||||||
do not own the same file. Specifying this option twice will perform
|
|
||||||
a check on the sync databases to ensure all specified dependencies
|
|
||||||
are available.
|
|
||||||
|
|
||||||
*-q, \--quiet*::
|
|
||||||
Suppress messages on successful completion of database operations.
|
|
||||||
|
|
||||||
File Options (apply to '-F')[[FO]]
|
|
||||||
----------------------------------
|
|
||||||
*-y, --refresh*::
|
|
||||||
Download fresh package file databases '(repo.files)' from the server.
|
|
||||||
Use twice to force a refresh even if databases are up to date.
|
|
||||||
|
|
||||||
*-l, \--list*::
|
|
||||||
List the files owned by the queried package.
|
|
||||||
|
|
||||||
*-x, --regex*::
|
|
||||||
Interpret each query as a regular expression.
|
|
||||||
|
|
||||||
*-q, \--quiet*::
|
|
||||||
Show less information for certain file operations. This is useful when
|
|
||||||
pacman's output is processed in a script, however, you may want to use
|
|
||||||
'--machinereadable' instead.
|
|
||||||
|
|
||||||
*--machinereadable*::
|
|
||||||
Print each match in a machine readable output format. The format is
|
|
||||||
'repository\0pkgname\0pkgver\0path\n' with '\0' being the NULL character
|
|
||||||
and '\n' a linefeed.
|
|
||||||
|
|
||||||
Handling Config Files[[HCF]]
|
|
||||||
----------------------------
|
|
||||||
Pacman uses the same logic as 'rpm' to determine action against files that are
|
|
||||||
designated to be backed up. During an upgrade, three MD5 hashes are used for
|
|
||||||
each backup file to determine the required action: one for the original file
|
|
||||||
installed, one for the new file that is about to be installed, and one for the
|
|
||||||
actual file existing on the file system. After comparing these three hashes, the
|
|
||||||
following scenarios can result:
|
|
||||||
|
|
||||||
original=X, current=X, new=X::
|
|
||||||
All three files are the same, so overwrites are not an issue. Install the
|
|
||||||
new file.
|
|
||||||
|
|
||||||
original=X, current=X, new=Y::
|
|
||||||
The current file is the same as the original, but the new one differs.
|
|
||||||
Since the user did not ever modify the file, and the new one may contain
|
|
||||||
improvements or bug fixes, install the new file.
|
|
||||||
|
|
||||||
original=X, current=Y, new=X::
|
|
||||||
Both package versions contain the exact same file, but the one on the
|
|
||||||
file system has been modified. Leave the current file in place.
|
|
||||||
|
|
||||||
original=X, current=Y, new=Y::
|
|
||||||
The new file is identical to the current file. Install the new file.
|
|
||||||
|
|
||||||
original=X, current=Y, new=Z::
|
|
||||||
All three files are different, so install the new file with a '.pacnew'
|
|
||||||
extension and warn the user. The user must then manually merge any
|
|
||||||
necessary changes into the original file.
|
|
||||||
|
|
||||||
original=NULL, current=Y, new=Z::
|
|
||||||
The package was not previously installed, and the file already exists on the
|
|
||||||
file system. Install the new file with a '.pacnew' extension and warn the
|
|
||||||
user. The user must then manually merge any necessary changes into the
|
|
||||||
original file.
|
|
||||||
|
|
||||||
|
|
||||||
Examples
|
|
||||||
--------
|
|
||||||
|
|
||||||
pacman -Ss ne.hack::
|
|
||||||
Search for regexp "ne.hack" in package database.
|
|
||||||
|
|
||||||
pacman -S gpm::
|
|
||||||
Download and install gpm including dependencies.
|
|
||||||
|
|
||||||
pacman -U /home/user/ceofhack-0.6-1-x86_64.pkg.tar.gz::
|
|
||||||
Install ceofhack-0.6-1 package from a local file.
|
|
||||||
|
|
||||||
pacman -Syu::
|
|
||||||
Update package list and upgrade all packages afterwards.
|
|
||||||
|
|
||||||
pacman -Syu gpm::
|
|
||||||
Update package list, upgrade all packages, and then install gpm if it
|
|
||||||
wasn't already installed.
|
|
||||||
|
|
||||||
|
|
||||||
Configuration
|
|
||||||
-------------
|
|
||||||
See linkman:pacman.conf[5] for more details on configuring pacman using the
|
|
||||||
'pacman.conf' file.
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:alpm-hooks[5], linkman:libalpm[3], linkman:makepkg[8],
|
|
||||||
linkman:pacman.conf[5]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
142
doc/pacman.conf.5
Normal file
142
doc/pacman.conf.5
Normal file
|
@ -0,0 +1,142 @@
|
||||||
|
." the string declarations are a start to try and make distro independent
|
||||||
|
.ds DS Arch Linux
|
||||||
|
.ds PB PKGBUILD
|
||||||
|
.ds VR 3.0.0
|
||||||
|
.ds LV 1.0.0
|
||||||
|
.TH \*(PB 5 "Feb 07, 2007" "pacman.conf version \*(VR" "\*(DS Files"
|
||||||
|
.SH NAME
|
||||||
|
pacman.conf \- pacman package manager configuration file
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fBpacman\fP, using \fBlibalpm\fP, will attempt to read \fBpacman.conf\fP each
|
||||||
|
time it is invoked. This configuration file is divided into sections or
|
||||||
|
\fIrepositories\fP. Each section defines a package repository that \fBpacman\fP
|
||||||
|
can use when searching for packages in \fB--sync\fP mode. The exception to this
|
||||||
|
is the \fIoptions\fP section, which defines global options.
|
||||||
|
|
||||||
|
.SH EXAMPLE
|
||||||
|
.RS
|
||||||
|
.nf
|
||||||
|
#
|
||||||
|
# pacman.conf
|
||||||
|
#
|
||||||
|
[options]
|
||||||
|
NoUpgrade = etc/passwd etc/group etc/shadow
|
||||||
|
NoUpgrade = etc/fstab
|
||||||
|
|
||||||
|
[current]
|
||||||
|
Include = /etc/pacman.d/current
|
||||||
|
|
||||||
|
[custom]
|
||||||
|
Server = file:///home/pkgs
|
||||||
|
.fi
|
||||||
|
.RE
|
||||||
|
|
||||||
|
.SH OPTIONS
|
||||||
|
.TP
|
||||||
|
.B DBPath = \fIpath/to/db/dir\fP
|
||||||
|
Overrides the default location of the toplevel database directory. The default
|
||||||
|
is \fIvar/lib/pacman\fP.
|
||||||
|
.TP
|
||||||
|
.B CacheDir = \fIpath/to/cache/dir\fP
|
||||||
|
Overrides the default location of the package cache directory. The default is
|
||||||
|
\fIvar/cache/pacman\fP.
|
||||||
|
.TP
|
||||||
|
.B HoldPkg = \fIpackage\fP ...
|
||||||
|
If a user tries to \fB--remove\fP a package that's listed in \fBHoldPkg\fI,
|
||||||
|
\fBpacman\fP will ask for confirmation before proceeding.
|
||||||
|
.TP
|
||||||
|
.B IgnorePkg = \fIpackage\fP ...
|
||||||
|
Instructs \fBpacman\fP to ignore any upgrades for this package when performing a
|
||||||
|
\fB--sysupgrade\fP.
|
||||||
|
.TP
|
||||||
|
.B Include = \fIpath\fP
|
||||||
|
Include another config file. This file can include repositories or general
|
||||||
|
configuration options.
|
||||||
|
.TP
|
||||||
|
.B ProxyServer = <\fIhost\fP|\fIip\fP>[:\fIport\fP]
|
||||||
|
If set, \fBpacman\fP will use this proxy server for all ftp/http transfers.
|
||||||
|
.TP
|
||||||
|
.B XferCommand = \fI/path/to/command %u\fP
|
||||||
|
If set, an external program will be used to download all remote files. All
|
||||||
|
instances of \fB%u\fP will be replaced with the download URL. If present,
|
||||||
|
instances of \fB%o\fP will be replaced with the local filename, plus a ".part"
|
||||||
|
extension, which allows programs like wget to do file resumes properly.
|
||||||
|
|
||||||
|
This option is useful for users who experience problems with built-in
|
||||||
|
http/ftp support, or need the more advanced proxy support that comes with
|
||||||
|
utilities like wget.
|
||||||
|
.TP
|
||||||
|
.B NoPassiveFtp
|
||||||
|
Disables passive ftp connections when downloading packages. (aka Active Mode)
|
||||||
|
.TP
|
||||||
|
.B NoUpgrade = \fIfile\fP ...
|
||||||
|
All files listed with a \fBNoUpgrade\fP directive will never be touched during
|
||||||
|
a package install/upgrade. Do \fInot\fP include the leading slash when
|
||||||
|
specifying files.
|
||||||
|
.TP
|
||||||
|
.B NoExtract = \fIfile\fP ...
|
||||||
|
All files listed with a \fBNoExtract\fP directive will never be extracted from
|
||||||
|
a package into the filesystem. This can be useful when you don't want part of a
|
||||||
|
package to be installed. For example, if your httpd root uses an index.php,
|
||||||
|
then you would not want the index.html file to be extracted from the
|
||||||
|
\fBapache\fP package.
|
||||||
|
.TP
|
||||||
|
.B UseSyslog
|
||||||
|
Log action messages through \fBsyslog()\fP. This will insert log entries into
|
||||||
|
\fI/var/log/messages\fP or equivalent.
|
||||||
|
.TP
|
||||||
|
.B LogFile = \fI/path/to/file\fP
|
||||||
|
Log actions directly to a file. Default is \fI/var/log/pacman.log\fP.
|
||||||
|
|
||||||
|
.SH REPOSITORY SECTIONS
|
||||||
|
Each repository section defines a section name and at least one location where
|
||||||
|
the packages can be found. The section name is defined by the string within
|
||||||
|
square brackets (the two above are 'current' and 'custom'). Locations are
|
||||||
|
defined with the \fBServer\fP directive and follow a URL naming structure. If
|
||||||
|
you want to use a local directory, you can specify the full path with
|
||||||
|
a 'file://' prefix, as shown above.
|
||||||
|
|
||||||
|
The order of repositories in the file matters; repositories listed first will
|
||||||
|
take precedence over those listed later in the file when packages in two
|
||||||
|
repositories have identical names, regardless of version number.
|
||||||
|
|
||||||
|
.SH USING YOUR OWN REPOSITORY
|
||||||
|
If you have numerous custom packages of your own, it is often easier to
|
||||||
|
generate your own custom local repository than install them all with the
|
||||||
|
\fB--upgrade\fP option. All you need to do is generate a compressed package
|
||||||
|
database in the directory with these packages so \fBpacman\fP can find it when
|
||||||
|
run with \fB--refresh\fP.
|
||||||
|
|
||||||
|
.RS
|
||||||
|
.nf
|
||||||
|
repo-add /home/pkgs/custom.db.tar.gz /home/pkgs/*.pkg.tar.gz
|
||||||
|
.fi
|
||||||
|
.RE
|
||||||
|
|
||||||
|
The above command will generate a compressed database named
|
||||||
|
\fI/home/pkgs/custom.db.tar.gz\fP. Note that the database must be of the form
|
||||||
|
\fI{treename}.db.tar.gz\fP, where {treename} is the name of the section defined
|
||||||
|
in the configuration file. That's it! Now configure your \fIcustom\fP section
|
||||||
|
in the configuration file as shown in the config example above. Pacman will
|
||||||
|
now use your package repository. If you add new packages to the repository,
|
||||||
|
remember to re-generate the database and use \fBpacman\fP's --refresh option.
|
||||||
|
|
||||||
|
For more information on the \fBrepo-add\fP command, use \fB repo-add --help\fP.
|
||||||
|
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR pacman (8),
|
||||||
|
.BR libalpm (3)
|
||||||
|
|
||||||
|
See the Arch Linux website at <http://www.archlinux.org> for more current
|
||||||
|
information on the distribution and the \fBpacman\fP family of tools.
|
||||||
|
|
||||||
|
.SH AUTHORS
|
||||||
|
.nf
|
||||||
|
Judd Vinet <jvinet@zeroflux.org>
|
||||||
|
Aurelien Foret <aurelien@archlinux.org>
|
||||||
|
Aaron Griffin <aaron@archlinux.org>
|
||||||
|
Dan McGee <dan@archlinux.org>
|
||||||
|
.fi
|
||||||
|
|
||||||
|
See the 'AUTHORS' file for additional contributors.
|
|
@ -1,382 +0,0 @@
|
||||||
pacman.conf(5)
|
|
||||||
==============
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
pacman.conf - pacman package manager configuration file
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
{sysconfdir}/pacman.conf
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
Pacman, using linkman:libalpm[3], will attempt to read pacman.conf each time it
|
|
||||||
is invoked. This configuration file is divided into sections or repositories.
|
|
||||||
Each section defines a package repository that pacman can use when searching
|
|
||||||
for packages in '\--sync' mode. The exception to this is the options section,
|
|
||||||
which defines global options.
|
|
||||||
|
|
||||||
Comments are only supported by beginning a line with the hash (#) symbol.
|
|
||||||
Comments cannot begin in the middle of a line.
|
|
||||||
|
|
||||||
|
|
||||||
Example
|
|
||||||
-------
|
|
||||||
|
|
||||||
--------
|
|
||||||
#
|
|
||||||
# pacman.conf
|
|
||||||
#
|
|
||||||
[options]
|
|
||||||
NoUpgrade = etc/passwd etc/group etc/shadow
|
|
||||||
NoUpgrade = etc/fstab
|
|
||||||
|
|
||||||
[core]
|
|
||||||
Include = /etc/pacman.d/core
|
|
||||||
|
|
||||||
[custom]
|
|
||||||
Server = file:///home/pkgs
|
|
||||||
--------
|
|
||||||
|
|
||||||
NOTE: Each directive must be in CamelCase. If the case isn't respected, the
|
|
||||||
directive won't be recognized. For example. noupgrade or NOUPGRADE will not
|
|
||||||
work.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
*RootDir =* /path/to/root/dir::
|
|
||||||
Set the default root directory for pacman to install to. This option is
|
|
||||||
used if you want to install a package on a temporary mounted partition
|
|
||||||
which is "owned" by another system, or for a chroot install.
|
|
||||||
*NOTE*: If database path or log file are not specified on either the
|
|
||||||
command line or in linkman:pacman.conf[5], their default location will
|
|
||||||
be inside this root path.
|
|
||||||
|
|
||||||
*DBPath =* /path/to/db/dir::
|
|
||||||
Overrides the default location of the toplevel database directory. The
|
|
||||||
default is +{localstatedir}/lib/pacman/+. Most users will not need to set
|
|
||||||
this option. *NOTE*: if specified, this is an absolute path and the root
|
|
||||||
path is not automatically prepended.
|
|
||||||
|
|
||||||
*CacheDir =* /path/to/cache/dir::
|
|
||||||
Overrides the default location of the package cache directory. The
|
|
||||||
default is +{localstatedir}/cache/pacman/pkg/+. Multiple cache directories can be
|
|
||||||
specified, and they are tried in the order they are listed in the config
|
|
||||||
file. If a file is not found in any cache directory, it will be downloaded
|
|
||||||
to the first cache directory with write access. *NOTE*: this is an absolute
|
|
||||||
path, the root path is not automatically prepended.
|
|
||||||
|
|
||||||
*HookDir =* /path/to/hook/dir::
|
|
||||||
Add directories to search for alpm hooks in addition to the system hook
|
|
||||||
directory (+{datarootdir}/libalpm/hooks/+). The default is
|
|
||||||
+{sysconfdir}/pacman.d/hooks+. Multiple directories can be specified with
|
|
||||||
hooks in later directories taking precedence over hooks in earlier
|
|
||||||
directories. *NOTE*: this is an absolute path, the root path is not
|
|
||||||
automatically prepended. For more information on the alpm hooks, see
|
|
||||||
linkman:alpm-hooks[5].
|
|
||||||
|
|
||||||
*GPGDir =* /path/to/gpg/dir::
|
|
||||||
Overrides the default location of the directory containing configuration
|
|
||||||
files for GnuPG. The default is +{sysconfdir}/pacman.d/gnupg/+.
|
|
||||||
This directory should contain two files: `pubring.gpg` and `trustdb.gpg`.
|
|
||||||
`pubring.gpg` holds the public keys of all packagers. `trustdb.gpg`
|
|
||||||
contains a so-called trust database, which specifies that the keys are
|
|
||||||
authentic and trusted.
|
|
||||||
*NOTE*: this is an absolute path, the root path is not automatically
|
|
||||||
prepended.
|
|
||||||
|
|
||||||
*LogFile =* /path/to/log/file::
|
|
||||||
Overrides the default location of the pacman log file. The default
|
|
||||||
is +{localstatedir}/log/pacman.log+. This is an absolute path and the root directory
|
|
||||||
is not prepended.
|
|
||||||
|
|
||||||
*HoldPkg =* package ...::
|
|
||||||
If a user tries to '\--remove' a package that's listed in `HoldPkg`,
|
|
||||||
pacman will ask for confirmation before proceeding. Shell-style glob
|
|
||||||
patterns are allowed.
|
|
||||||
|
|
||||||
*IgnorePkg =* package ...::
|
|
||||||
Instructs pacman to ignore any upgrades for this package when performing
|
|
||||||
a '\--sysupgrade'. Shell-style glob patterns are allowed.
|
|
||||||
|
|
||||||
*IgnoreGroup =* group ...::
|
|
||||||
Instructs pacman to ignore any upgrades for all packages in this
|
|
||||||
group when performing a '\--sysupgrade'. Shell-style glob patterns are
|
|
||||||
allowed.
|
|
||||||
|
|
||||||
*Include =* /path/to/config/file::
|
|
||||||
Include another configuration file. This file can include repositories or
|
|
||||||
general configuration options. Wildcards in the specified paths will get
|
|
||||||
expanded based on linkman:glob[7] rules.
|
|
||||||
|
|
||||||
*Architecture =* auto &| i686 &| x86_64 | ...::
|
|
||||||
If set, pacman will only allow installation of packages with the given
|
|
||||||
architectures (e.g. 'i686', 'x86_64', etc). The special value 'auto' will
|
|
||||||
use the system architecture, provided via ``uname -m''. If unset, no
|
|
||||||
architecture checks are made. *NOTE*: Packages with the special
|
|
||||||
architecture 'any' can always be installed, as they are meant to be
|
|
||||||
architecture independent.
|
|
||||||
|
|
||||||
*XferCommand =* /path/to/command %u [%o]::
|
|
||||||
If set, an external program will be used to download all remote files.
|
|
||||||
All instances of `%u` will be replaced with the download URL. If present,
|
|
||||||
instances of `%o` will be replaced with the local filename, plus a
|
|
||||||
``.part'' extension, which allows programs like wget to do file resumes
|
|
||||||
properly.
|
|
||||||
+
|
|
||||||
This option is useful for users who experience problems with built-in
|
|
||||||
HTTP/FTP support, or need the more advanced proxy support that comes with
|
|
||||||
utilities like wget.
|
|
||||||
|
|
||||||
*NoUpgrade =* file ...::
|
|
||||||
All files listed with a `NoUpgrade` directive will never be touched during
|
|
||||||
a package install/upgrade, and the new files will be installed with a
|
|
||||||
'.pacnew' extension.
|
|
||||||
These files refer to files in the package archive, so do not include the
|
|
||||||
leading slash (the RootDir) when specifying them. Shell-style glob patterns
|
|
||||||
are allowed. It is possible to invert matches by prepending a file with
|
|
||||||
an exclamation mark. Inverted files will result in previously blacklisted
|
|
||||||
files being whitelisted again. Subsequent matches will override previous
|
|
||||||
ones. A leading literal exclamation mark or backslash needs to be escaped.
|
|
||||||
|
|
||||||
*NoExtract =* file ...::
|
|
||||||
All files listed with a `NoExtract` directive will never be extracted from
|
|
||||||
a package into the filesystem. This can be useful when you don't want part
|
|
||||||
of a package to be installed. For example, if your httpd root uses an
|
|
||||||
'index.php', then you would not want the 'index.html' file to be extracted
|
|
||||||
from the 'apache' package.
|
|
||||||
These files refer to files in the package archive, so do not include the
|
|
||||||
leading slash (the RootDir) when specifying them. Shell-style glob patterns
|
|
||||||
are allowed. It is possible to invert matches by prepending a file with
|
|
||||||
an exclamation mark. Inverted files will result in previously blacklisted
|
|
||||||
files being whitelisted again. Subsequent matches will override previous
|
|
||||||
ones. A leading literal exclamation mark or backslash needs to be escaped.
|
|
||||||
|
|
||||||
*CleanMethod =* KeepInstalled &| KeepCurrent::
|
|
||||||
If set to `KeepInstalled` (the default), the '-Sc' operation will clean
|
|
||||||
packages that are no longer installed (not present in the local database).
|
|
||||||
If set to `KeepCurrent`, '-Sc' will clean outdated packages (not present in
|
|
||||||
any sync database).
|
|
||||||
The second behavior is useful when the package cache is shared among
|
|
||||||
multiple machines, where the local databases are usually different, but the
|
|
||||||
sync databases in use could be the same. If both values are specified,
|
|
||||||
packages are only cleaned if not installed locally and not present in any
|
|
||||||
known sync database.
|
|
||||||
|
|
||||||
*SigLevel =* ...::
|
|
||||||
Set the default signature verification level. For more information, see
|
|
||||||
<<SC,Package and Database Signature Checking>> below.
|
|
||||||
|
|
||||||
*LocalFileSigLevel =* ...::
|
|
||||||
Set the signature verification level for installing packages using the "-U"
|
|
||||||
operation on a local file. Uses the value from SigLevel as the default.
|
|
||||||
|
|
||||||
*RemoteFileSigLevel =* ...::
|
|
||||||
Set the signature verification level for installing packages using the "-U"
|
|
||||||
operation on a remote file URL. Uses the value from SigLevel as the default.
|
|
||||||
|
|
||||||
*UseSyslog*::
|
|
||||||
Log action messages through syslog(). This will insert log entries into
|
|
||||||
+{localstatedir}/log/messages+ or equivalent.
|
|
||||||
|
|
||||||
*Color*::
|
|
||||||
Automatically enable colors only when pacman's output is on a tty.
|
|
||||||
|
|
||||||
*NoProgressBar*::
|
|
||||||
Disables progress bars. This is useful for terminals which do
|
|
||||||
not support escape characters.
|
|
||||||
|
|
||||||
*CheckSpace*::
|
|
||||||
Performs an approximate check for adequate available disk space before
|
|
||||||
installing packages.
|
|
||||||
|
|
||||||
*VerbosePkgLists*::
|
|
||||||
Displays name, version and size of target packages formatted
|
|
||||||
as a table for upgrade, sync and remove operations.
|
|
||||||
|
|
||||||
*DisableDownloadTimeout*::
|
|
||||||
Disable defaults for low speed limit and timeout on downloads. Use this
|
|
||||||
if you have issues downloading files with proxy and/or security gateway.
|
|
||||||
|
|
||||||
*ParallelDownloads =* ...::
|
|
||||||
Specifies number of concurrent download streams. The value needs to be a
|
|
||||||
positive integer. If this config option is not set then only one download
|
|
||||||
stream is used (i.e. downloads happen sequentially).
|
|
||||||
|
|
||||||
*DownloadUser =* username::
|
|
||||||
Specifies the user to switch to for downloading files. If this config
|
|
||||||
option is not set then the downloads are done as the user running pacman.
|
|
||||||
|
|
||||||
*DisableSandbox*::
|
|
||||||
Disable the default sandbox applied to the process downloading files on Linux
|
|
||||||
systems. Useful if experiencing landlock related failures while downloading
|
|
||||||
files when running a Linux kernel that does not support this feature.
|
|
||||||
|
|
||||||
Repository Sections
|
|
||||||
-------------------
|
|
||||||
Each repository section defines a section name and at least one location where
|
|
||||||
the packages can be found. The section name is defined by the string within
|
|
||||||
square brackets (the two above are 'core' and 'custom'). Repository names
|
|
||||||
must be unique and the name 'local' is reserved for the database of installed
|
|
||||||
packages. Locations are defined with the 'Server' directive and follow a URL
|
|
||||||
naming structure. If you want to use a local directory, you can specify the
|
|
||||||
full path with a ``file://'' prefix, as shown above.
|
|
||||||
|
|
||||||
A common way to define DB locations utilizes the 'Include' directive. For each
|
|
||||||
repository defined in the configuration file, a single 'Include' directive can
|
|
||||||
contain a file that lists the servers for that repository.
|
|
||||||
|
|
||||||
--------
|
|
||||||
[core]
|
|
||||||
# use this server first
|
|
||||||
Server = ftp://ftp.archlinux.org/$repo/os/$arch
|
|
||||||
# next use servers as defined in the mirrorlist below
|
|
||||||
Include = /etc/pacman.d/mirrorlist
|
|
||||||
--------
|
|
||||||
|
|
||||||
The order of repositories in the configuration files matters; repositories
|
|
||||||
listed first will take precedence over those listed later in the file when
|
|
||||||
packages in two repositories have identical names, regardless of version
|
|
||||||
number.
|
|
||||||
|
|
||||||
*Include =* path::
|
|
||||||
Include another config file. This file can include repositories or
|
|
||||||
general configuration options. Wildcards in the specified paths will get
|
|
||||||
expanded based on linkman:glob[7] rules.
|
|
||||||
|
|
||||||
*CacheServer =* url::
|
|
||||||
A full URL to a location where the packages, and signatures (if
|
|
||||||
available) for this repository can be found. Cache servers will be tried
|
|
||||||
before any non-cache servers, will not be removed from the server pool for
|
|
||||||
404 download errors, and will not be used for database files.
|
|
||||||
|
|
||||||
*Server =* url::
|
|
||||||
A full URL to a location where the database, packages, and signatures (if
|
|
||||||
available) for this repository can be found.
|
|
||||||
+
|
|
||||||
During parsing, pacman will define the `$repo` variable to the name of the
|
|
||||||
current section. This is often utilized in files specified using the 'Include'
|
|
||||||
directive so all repositories can use the same mirrorfile. pacman also defines
|
|
||||||
the `$arch` variable to the first (or only) value of the `Architecture` option,
|
|
||||||
so the same mirrorfile can even be used for different architectures.
|
|
||||||
|
|
||||||
*SigLevel =* ...::
|
|
||||||
Set the signature verification level for this repository. For more
|
|
||||||
information, see <<SC,Package and Database Signature Checking>> below.
|
|
||||||
|
|
||||||
*Usage =* ...::
|
|
||||||
Set the usage level for this repository. This option takes a list of tokens
|
|
||||||
which must be at least one of the following:
|
|
||||||
*Sync*;;
|
|
||||||
Enables refreshes for this repository.
|
|
||||||
*Search*;;
|
|
||||||
Enables searching for this repository.
|
|
||||||
*Install*;;
|
|
||||||
Enables installation of packages from this repository during a '\--sync'
|
|
||||||
operation.
|
|
||||||
*Upgrade*;;
|
|
||||||
Allows this repository to be a valid source of packages when performing
|
|
||||||
a '\--sysupgrade'.
|
|
||||||
*All*;;
|
|
||||||
Enables all of the above features for the repository. This is the default
|
|
||||||
if not specified.
|
|
||||||
+
|
|
||||||
Note that an enabled repository can be operated on explicitly, regardless of the Usage
|
|
||||||
level set.
|
|
||||||
|
|
||||||
|
|
||||||
Package and Database Signature Checking[[SC]]
|
|
||||||
---------------------------------------------
|
|
||||||
The 'SigLevel' directive is valid in both the `[options]` and repository
|
|
||||||
sections. If used in `[options]`, it sets a default value for any repository
|
|
||||||
that does not provide the setting.
|
|
||||||
|
|
||||||
* If set to *Never*, no signature checking will take place.
|
|
||||||
* If set to *Optional* , signatures will be checked when present, but unsigned
|
|
||||||
databases and packages will also be accepted.
|
|
||||||
* If set to *Required*, signatures will be required on all packages and
|
|
||||||
databases.
|
|
||||||
|
|
||||||
Alternatively, you can get more fine-grained control by combining some of
|
|
||||||
the options and prefixes described below. All options in a config file are
|
|
||||||
processed in top-to-bottom, left-to-right fashion, where later options override
|
|
||||||
and/or supplement earlier ones. If 'SigLevel' is specified in a repository
|
|
||||||
section, the starting value is that from the `[options]` section, or the
|
|
||||||
built-in system default as shown below if not specified.
|
|
||||||
|
|
||||||
The options are split into two main groups, described below. Terms used such as
|
|
||||||
``marginally trusted'' are terms used by GnuPG, for more information please
|
|
||||||
consult linkman:gpg[1].
|
|
||||||
|
|
||||||
When to Check::
|
|
||||||
These options control if and when signature checks should take place.
|
|
||||||
|
|
||||||
*Never*;;
|
|
||||||
All signature checking is suppressed, even if signatures are present.
|
|
||||||
|
|
||||||
*Optional* (default);;
|
|
||||||
Signatures are checked if present; absence of a signature is not an
|
|
||||||
error. An invalid signature is a fatal error, as is a signature from a
|
|
||||||
key not in the keyring.
|
|
||||||
|
|
||||||
*Required*;;
|
|
||||||
Signatures are required; absence of a signature or an invalid signature
|
|
||||||
is a fatal error, as is a signature from a key not in the keyring.
|
|
||||||
|
|
||||||
What is Allowed::
|
|
||||||
These options control what signatures are viewed as permissible. Note that
|
|
||||||
neither of these options allows acceptance of invalid or expired
|
|
||||||
signatures, or those from revoked keys.
|
|
||||||
|
|
||||||
*TrustedOnly* (default);;
|
|
||||||
If a signature is checked, it must be in the keyring and fully trusted;
|
|
||||||
marginal trust does not meet this criteria.
|
|
||||||
|
|
||||||
*TrustAll*;;
|
|
||||||
If a signature is checked, it must be in the keyring, but is not
|
|
||||||
required to be assigned a trust level (e.g., unknown or marginal
|
|
||||||
trust).
|
|
||||||
|
|
||||||
Options in both groups can additionally be prefixed with either *Package* or
|
|
||||||
*Database*, which will cause it to only take effect on the specified object
|
|
||||||
type. For example, `PackageTrustAll` would allow marginal and unknown trust
|
|
||||||
level signatures for packages.
|
|
||||||
|
|
||||||
The built-in default is the following:
|
|
||||||
|
|
||||||
--------
|
|
||||||
SigLevel = Optional TrustedOnly
|
|
||||||
--------
|
|
||||||
|
|
||||||
|
|
||||||
Using Your Own Repository
|
|
||||||
-------------------------
|
|
||||||
If you have numerous custom packages of your own, it is often easier to generate
|
|
||||||
your own custom local repository than install them all with the '\--upgrade'
|
|
||||||
option. All you need to do is generate a compressed package database in the
|
|
||||||
directory with these packages so pacman can find it when run with '\--refresh'.
|
|
||||||
|
|
||||||
repo-add /home/pkgs/custom.db.tar.gz /home/pkgs/*.pkg.tar.gz
|
|
||||||
|
|
||||||
The above command will generate a compressed database named
|
|
||||||
'/home/pkgs/custom.db.tar.gz'. Note that the database must be of the form
|
|
||||||
'\{treename\}.db.tar.{ext}', where '\{treename\}' is the name of the section
|
|
||||||
defined in the configuration file and '\{ext\}' is a valid compression type as
|
|
||||||
documented in linkman:repo-add[8]. That's it! Now configure your custom section
|
|
||||||
in the configuration file as shown in the config example above. Pacman will now
|
|
||||||
use your package repository. If you add new packages to the repository,
|
|
||||||
remember to re-generate the database and use pacman's '\--refresh' option.
|
|
||||||
|
|
||||||
For more information on the repo-add command, see ``repo-add \--help'' or
|
|
||||||
linkman:repo-add[8].
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:pacman[8], linkman:libalpm[3]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,95 +0,0 @@
|
||||||
repo-add(8)
|
|
||||||
==========
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
repo-add - package database maintenance utility
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'repo-add' [options] <path-to-db> <package> [<package> ...]
|
|
||||||
|
|
||||||
'repo-remove' [options] <path-to-db> <packagename> [<packagename> ...]
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'repo-add' and 'repo-remove' are two scripts to help build a package database for
|
|
||||||
packages built with linkman:makepkg[8] and installed with linkman:pacman[8].
|
|
||||||
|
|
||||||
'repo-add' will update a package database by reading a built package file.
|
|
||||||
Multiple packages to add can be specified on the command line.
|
|
||||||
|
|
||||||
If a matching ``.sig'' file is found alongside a package file, the signature
|
|
||||||
will automatically be embedded into the database.
|
|
||||||
|
|
||||||
'repo-remove' will update a package database by removing the package name
|
|
||||||
specified on the command line. Multiple packages to remove can be specified
|
|
||||||
on the command line.
|
|
||||||
|
|
||||||
A package database is a tar file, optionally compressed. Valid extensions are
|
|
||||||
``.db'' followed by an archive extension of ``.tar'', ``.tar.bz2'',
|
|
||||||
``.tar.gz'', ``.tar.lrz'', ``.tar.lz'', ``.tar.lz4'', ``.tar.lzo'',
|
|
||||||
``.tar.xz'', ``.tar.zst'' or ``.tar.Z''. The file does not need to exist, but
|
|
||||||
all parent directories must exist.
|
|
||||||
|
|
||||||
|
|
||||||
Common Options
|
|
||||||
--------------
|
|
||||||
*-q, \--quiet*::
|
|
||||||
Force this program to keep quiet and run silently except for warning and
|
|
||||||
error messages.
|
|
||||||
|
|
||||||
*-s, \--sign*::
|
|
||||||
Generate a PGP signature file using GnuPG. This will execute `gpg
|
|
||||||
--detach-sign` on the generated database to generate a detached
|
|
||||||
signature file, using the GPG agent if it is available. The signature file
|
|
||||||
will be the entire filename of the database with a ``.sig'' extension.
|
|
||||||
|
|
||||||
*-k, \--key* <key>::
|
|
||||||
Specify a key to use when signing packages. Can also be specified using
|
|
||||||
the GPGKEY environment variable. If not specified in either location, the
|
|
||||||
default key from the keyring will be used.
|
|
||||||
|
|
||||||
*-v, \--verify*::
|
|
||||||
Verify the PGP signature of the database before updating the database.
|
|
||||||
If the signature is invalid, an error is produced and the update does not
|
|
||||||
proceed.
|
|
||||||
|
|
||||||
*\--nocolor*::
|
|
||||||
Remove color from 'repo-add' and 'repo-remove' output.
|
|
||||||
|
|
||||||
*-R, \--remove*::
|
|
||||||
Remove old package files from the disk when updating or removing their
|
|
||||||
entry in the database.
|
|
||||||
|
|
||||||
*-w, \--wait-for-lock*::
|
|
||||||
Wait for the lock file to be acquired. If unset, command will fail with
|
|
||||||
exit code 2 if acquiring the lock fails. If set, it will retry to acquire
|
|
||||||
lock until success.
|
|
||||||
|
|
||||||
repo-add Options
|
|
||||||
----------------
|
|
||||||
*-n, \--new*::
|
|
||||||
Only add packages that are not already in the database. Warnings will be
|
|
||||||
printed upon detection of existing packages, but they will not be re-added.
|
|
||||||
|
|
||||||
*\--include-sigs*::
|
|
||||||
Include package PGP signatures in the repository database (if available)
|
|
||||||
|
|
||||||
Example
|
|
||||||
-------
|
|
||||||
'repo-add' foo.db.tar.xz <pkg1> [<pkg2> ...]
|
|
||||||
|
|
||||||
This creates two separate databases; a smaller database ``foo.db.tar.xz'' used by
|
|
||||||
pacman and a large database containing package file lists ``foo.files.tar.xz'' for
|
|
||||||
use by other utilities. While pacman can use the large database (if renamed with a
|
|
||||||
db.tar* extension), there is currently no additional benefit for the larger download.
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:makepkg[8], linkman:pacman[8]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,97 +0,0 @@
|
||||||
Pacman - Submitting Patches
|
|
||||||
===========================
|
|
||||||
|
|
||||||
This document is here mainly to make the job of those who review patches
|
|
||||||
easier and is more of a guideline and not a strict set of rules. However,
|
|
||||||
please try to follow as much as you can.
|
|
||||||
|
|
||||||
NOTE: Some of this is paraphrased from the kernel documentation's
|
|
||||||
"SubmittingPatches" file.
|
|
||||||
|
|
||||||
|
|
||||||
Getting the most recent source
|
|
||||||
------------------------------
|
|
||||||
Patches need to be submitted in Git format and are best if they are against the
|
|
||||||
latest version of the code. There are several helpful tutorials for getting
|
|
||||||
started with Git if you have not worked with it before.
|
|
||||||
|
|
||||||
* https://www.kernel.org/pub/software/scm/git/docs/gittutorial.html
|
|
||||||
* https://wiki.archlinux.org/index.php/Super_Quick_Git_Guide
|
|
||||||
|
|
||||||
The pacman code can be fetched using the following command:
|
|
||||||
|
|
||||||
git clone https://gitlab.archlinux.org/pacman/pacman.git
|
|
||||||
|
|
||||||
|
|
||||||
Before making large changes
|
|
||||||
---------------------------
|
|
||||||
|
|
||||||
--
|
|
||||||
* Discuss your idea
|
|
||||||
|
|
||||||
There is nothing worse that spending time making a change only for it to be
|
|
||||||
rejected immediately. Ensure ideas are discussed beforehand to avoid
|
|
||||||
disappointment. Appropriate locations for discussion are the issue tracker
|
|
||||||
on gitlab, or the pacman-dev mailing list. Transient discussion channels
|
|
||||||
such as IRC are not appropriate.
|
|
||||||
|
|
||||||
--
|
|
||||||
|
|
||||||
|
|
||||||
Creating your patch
|
|
||||||
-------------------
|
|
||||||
|
|
||||||
--
|
|
||||||
* Use `git commit -s` for creating a commit of your changes.
|
|
||||||
|
|
||||||
The -s allows you to credit yourself by adding a "Signed Off By" line to
|
|
||||||
indicate who has "signed" the patch - who has approved it.
|
|
||||||
|
|
||||||
Signed-off-by: Aaron Griffin <aaron@archlinux.org>
|
|
||||||
|
|
||||||
Please use your real name and email address. Feel free to "scramble" the
|
|
||||||
address if you're afraid of spam.
|
|
||||||
|
|
||||||
* Describe your patch.
|
|
||||||
|
|
||||||
It helps if you describe the overview and goals of the patch in the git commit
|
|
||||||
log. This allows others to see what you intended so as to compare it to what
|
|
||||||
was actually done, and allows better feedback.
|
|
||||||
|
|
||||||
--
|
|
||||||
|
|
||||||
Submitting your patch
|
|
||||||
---------------------
|
|
||||||
|
|
||||||
--
|
|
||||||
* Submit patches with a gitlab merge request
|
|
||||||
|
|
||||||
The pacman gitlab instance is the primary queue for review and acceptance.
|
|
||||||
Here you will get feedback, and let the reviewers know the details of your
|
|
||||||
patch.
|
|
||||||
|
|
||||||
|
|
||||||
--
|
|
||||||
|
|
||||||
After you submit
|
|
||||||
----------------
|
|
||||||
|
|
||||||
--
|
|
||||||
* Don't get discouraged
|
|
||||||
|
|
||||||
Any feedback you get, positive or negative, has nothing to do with you. If a
|
|
||||||
patch is rejected, try taking the suggestions into account and re-submitting.
|
|
||||||
We welcome most submissions here, and some may take a bit longer to get
|
|
||||||
looked over than others. If you think your patch got lost in the shuffle,
|
|
||||||
send another email to the list in reply to the original asking if anyone has
|
|
||||||
looked at it yet.
|
|
||||||
|
|
||||||
* Respond to feedback
|
|
||||||
|
|
||||||
When you do get feedback, it usually merits a response, whether this be a
|
|
||||||
resubmission of the patch with corrections or a follow-up email asking for
|
|
||||||
clarifications. When neither of these occurs, don't expect your patch to get
|
|
||||||
further review. The all-volunteer staff don't have time to fix up patches that
|
|
||||||
aren't their own.
|
|
||||||
|
|
||||||
--
|
|
|
@ -1,20 +0,0 @@
|
||||||
testpkg(8)
|
|
||||||
==========
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
testpkg - test a pacman package for validity
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'testpkg' <package file>
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'testpkg' is a script used to make sure that a pacman package is valid.
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:pacman[8]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,159 +0,0 @@
|
||||||
Pacman - Translating
|
|
||||||
====================
|
|
||||||
|
|
||||||
This document is here to guide you in helping translate pacman messages,
|
|
||||||
libalpm messages, and the manual pages for the entire pacman package.
|
|
||||||
|
|
||||||
We are currently using https://app.transifex.com/[Transifex] as the translation
|
|
||||||
platform for pacman and libalpm. You will need to sign up for an account there
|
|
||||||
and then register with a translation team on the
|
|
||||||
https://explore.transifex.com/toofishes/archlinux-pacman/[pacman project page].
|
|
||||||
|
|
||||||
NOTE: This may be old information due to our switch to Transifex, but the
|
|
||||||
gettext website is a very useful guide to read before embarking on translation
|
|
||||||
work, as it describes many of the commands in more detail than I will here:
|
|
||||||
https://www.gnu.org/software/gettext/manual/html_node/gettext.html[].
|
|
||||||
|
|
||||||
|
|
||||||
Translating Messages
|
|
||||||
--------------------
|
|
||||||
|
|
||||||
Overview
|
|
||||||
~~~~~~~~
|
|
||||||
|
|
||||||
There are two separate message catalogs in pacman: one for the back-end
|
|
||||||
(libalpm) and one for the front-end (pacman and scripts). These correspond to
|
|
||||||
the `lib/libalpm/po` and `po` directories in the pacman source, respectively.
|
|
||||||
|
|
||||||
Translation message files are a specially formatted text file containing the
|
|
||||||
original message and the corresponding translation. These po files can then
|
|
||||||
either be hand-edited, or modified with a tool such as poedit, gtranslator or
|
|
||||||
kbabel. Using a translation tool tends to make the job easier.
|
|
||||||
|
|
||||||
Please read up on Transifex usage using the
|
|
||||||
https://help.transifex.com/[Transifex Help] if you are not familiar.
|
|
||||||
|
|
||||||
Transifex provides a command-line client to help with translations. Here is
|
|
||||||
an example set of commands if you have a source code checkout and are not
|
|
||||||
worried about any local translations being overwritten. The .tx/ directory is
|
|
||||||
checked into the git repository so is preconfigured with the two project
|
|
||||||
resources (See `tx status` output for a quick overview).
|
|
||||||
|
|
||||||
tx pull -f
|
|
||||||
poedit po/<mylang>.po
|
|
||||||
poedit lib/libalpm/po/<mylang>.po
|
|
||||||
tx push -t -l <mylang>
|
|
||||||
|
|
||||||
Or to just push one of the two available resources:
|
|
||||||
|
|
||||||
tx push -r archlinux-pacman.pacman-pot -t -l <mylang>
|
|
||||||
tx push -r archlinux-pacman.libalpm-pot -t -l <mylang>
|
|
||||||
|
|
||||||
See the <<Notes,Notes>> section for additional hints on translating.
|
|
||||||
|
|
||||||
Pre-release Updates
|
|
||||||
~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
A week or two before each release, the codebase will go into a string freeze
|
|
||||||
and an email will be sent to the mailto:pacman-dev@lists.archlinux.org[pacman-dev]
|
|
||||||
mailing list asking for translations. An announcement in Transifex is also made,
|
|
||||||
which reaches everyone that is member of the translation team.
|
|
||||||
|
|
||||||
At this time, the latest `.po` language files will be made available at the
|
|
||||||
Transifex project page. Each language will have three files available (libalpm,
|
|
||||||
pacman and pacman-scripts). Translators interested in helping are encouraged to use the
|
|
||||||
features of Transifex to let others know they are currently translating their
|
|
||||||
language.
|
|
||||||
|
|
||||||
Once a translator has completed the translation offline (*OR* realizes they do not have
|
|
||||||
time to finish), please upload your progress back to the Transifex site.
|
|
||||||
|
|
||||||
NOTE: Please upload your translations as soon as possible - this will give other
|
|
||||||
speakers of your language time to review your translations and update them as
|
|
||||||
necessary.
|
|
||||||
|
|
||||||
Incremental Updates
|
|
||||||
~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
If you have more advanced needs you will have to get a copy of the pacman
|
|
||||||
repository.
|
|
||||||
|
|
||||||
git clone https://gitlab.archlinux.org/pacman/pacman.git
|
|
||||||
|
|
||||||
Next, you will need to configure the build environment. From the base directory,
|
|
||||||
run:
|
|
||||||
|
|
||||||
meson setup . build
|
|
||||||
|
|
||||||
If any required dependencies are missing, please install. After that,
|
|
||||||
update the template translation (.pot) files to the latest state of
|
|
||||||
the source code by running:
|
|
||||||
|
|
||||||
meson compile -C build pacman-scripts-pot pacman-pot libalpm-pot
|
|
||||||
|
|
||||||
We need to first update the main message catalog file. Navigate into either
|
|
||||||
the `lib/libalpm/po`, `scripts/po` or `src/pacman/po` directory depending
|
|
||||||
on which translation you wish to work on first, and execute the following
|
|
||||||
command to update your specific language's translation file
|
|
||||||
(replace `lang_code` with your language code e.g. 'pt_BR', and `pot_file`
|
|
||||||
with `libalpm.pot`, `pacman.pot` or `pacman-scripts.pot`):
|
|
||||||
|
|
||||||
msgmerge --update --previous <lang_code>.po <pot_filename>.pot
|
|
||||||
|
|
||||||
At this point, you can do the translation. To submit your changes, either email
|
|
||||||
the new `.po` file to the mailing-list with *[translation]* in the subject, or
|
|
||||||
submit a Git-formatted patch (please do not include any `.pot` file changes).
|
|
||||||
|
|
||||||
As a shortcut, all translation files (including `.pot` files) can be updated
|
|
||||||
with the following command:
|
|
||||||
|
|
||||||
./build-aux/update-po
|
|
||||||
|
|
||||||
Adding a New Language
|
|
||||||
~~~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
Making a new language is not too hard, but be sure to follow all the steps.
|
|
||||||
You will have to do the following steps in both the `lib/libalpm/po/` and `po/`
|
|
||||||
directories, substituting where appropriate. First, edit the `LINGUAS` file and
|
|
||||||
add your new language code at the bottom. Next, run the following command,
|
|
||||||
substituting `libalpm.pot` or `pacman.pot` for potfile depending on which
|
|
||||||
directory you are currently working in:
|
|
||||||
|
|
||||||
msginit -l <lang_code> -o <lang_code>.po -i <potfile>
|
|
||||||
|
|
||||||
You can then also add your language code to the end of the `LINGUAS` file
|
|
||||||
located in each po directory.
|
|
||||||
|
|
||||||
Look at the current message files for more guidance if necessary. Once you
|
|
||||||
create the new language file, you may need to slightly modify the headers;
|
|
||||||
try to make them look similar to the other .po file headers. In addition, for
|
|
||||||
all new translations we would strongly recommend using UTF-8 encoding.
|
|
||||||
|
|
||||||
Notes[[Notes]]
|
|
||||||
~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
msgid and msgstr 'variables' can be on as many lines as necessary. Line breaks
|
|
||||||
are ignored; if you need a literal line break, use an `\n` in your string. The
|
|
||||||
following two translations are equivalent:
|
|
||||||
|
|
||||||
msgstr "This is a test translation"
|
|
||||||
|
|
||||||
msgstr ""
|
|
||||||
"This is a test translation"
|
|
||||||
|
|
||||||
If you want to test the translation (copy the .po file you want to test,
|
|
||||||
you may ignore the rest), replacing `<lang_code>` accordingly:
|
|
||||||
|
|
||||||
meson compile -C build pacman-scripts-gmo pacman-gmo libalpm-gmo
|
|
||||||
cp ./build/lib/libalpm/po/<lang_code>/LC_MESSAGES/libalpm.mo /usr/share/locale/<lang_code>/LC_MESSAGES/libalpm.mo
|
|
||||||
cp ./build/scripts/po/<lang_code>/LC_MESSAGES/pacman-scripts.mo /usr/share/locale/<lang_code>/LC_MESSAGES/pacman-scripts.mo
|
|
||||||
cp ./build/src/pacman/po/<lang_code>/LC_MESSAGES/pacman.mo /usr/share/locale/<lang_code>/LC_MESSAGES/pacman.mo
|
|
||||||
|
|
||||||
|
|
||||||
Translating Manpages
|
|
||||||
--------------------
|
|
||||||
There are currently no efforts underway to include translated manual pages in
|
|
||||||
the pacman codebase. However, this is not to say translations are unwelcome. If
|
|
||||||
someone has experience with i18n man pages and how to best include them with our
|
|
||||||
source, please contact the pacman-dev mailing list at
|
|
||||||
mailto:pacman-dev@lists.archlinux.org[].
|
|
|
@ -1,72 +0,0 @@
|
||||||
vercmp(8)
|
|
||||||
=========
|
|
||||||
|
|
||||||
Name
|
|
||||||
----
|
|
||||||
vercmp - version comparison utility
|
|
||||||
|
|
||||||
|
|
||||||
Synopsis
|
|
||||||
--------
|
|
||||||
'vercmp' [-h] [--help] <version1> <version2>
|
|
||||||
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
'vercmp' is used to determine the relationship between two given version
|
|
||||||
numbers. It outputs values as follows:
|
|
||||||
|
|
||||||
* < 0 : if ver1 < ver2
|
|
||||||
* = 0 : if ver1 == ver2
|
|
||||||
* > 0 : if ver1 > ver2
|
|
||||||
|
|
||||||
Version comparison operates as follows:
|
|
||||||
|
|
||||||
Alphanumeric:
|
|
||||||
1.0a < 1.0b < 1.0beta < 1.0p < 1.0pre < 1.0rc < 1.0 < 1.0.a < 1.0.1
|
|
||||||
Numeric:
|
|
||||||
1 < 1.0 < 1.1 < 1.1.1 < 1.2 < 2.0 < 3.0.0
|
|
||||||
|
|
||||||
Additionally, version strings can have an 'epoch' value defined that will
|
|
||||||
overrule any version comparison, unless the epoch values are equal. This is
|
|
||||||
specified in an `epoch:version-rel` format. For example, `2:1.0-1` is always
|
|
||||||
greater than `1:3.6-1`.
|
|
||||||
|
|
||||||
Keep in mind that the 'pkgrel' is only compared if it is available on both
|
|
||||||
versions given to this tool. For example, comparing `1.5-1` and `1.5` will
|
|
||||||
yield 0; comparing `1.5-1` and `1.5-2` will yield < 0 as expected. This is
|
|
||||||
mainly for supporting versioned dependencies that do not include the 'pkgrel'.
|
|
||||||
|
|
||||||
|
|
||||||
Options
|
|
||||||
-------
|
|
||||||
*-h, \--help*::
|
|
||||||
|
|
||||||
Display summary of the available return codes. Must be the first option
|
|
||||||
specified.
|
|
||||||
|
|
||||||
|
|
||||||
Examples
|
|
||||||
--------
|
|
||||||
|
|
||||||
$ vercmp 1 2
|
|
||||||
-1
|
|
||||||
|
|
||||||
$ vercmp 2 1
|
|
||||||
1
|
|
||||||
|
|
||||||
$ vercmp 2.0-1 1.7-6
|
|
||||||
1
|
|
||||||
|
|
||||||
$ vercmp 2.0 2.0-13
|
|
||||||
0
|
|
||||||
|
|
||||||
$ vercmp 4.34 1:001
|
|
||||||
-1
|
|
||||||
|
|
||||||
|
|
||||||
See Also
|
|
||||||
--------
|
|
||||||
linkman:pacman[8], linkman:makepkg[8], linkman:libalpm[3]
|
|
||||||
|
|
||||||
include::footer.asciidoc[]
|
|
|
@ -1,2 +1,4 @@
|
||||||
|
Makefile
|
||||||
|
Makefile.in
|
||||||
makepkg.conf
|
makepkg.conf
|
||||||
pacman.conf
|
pacman.conf
|
4
etc/Makefile.am
Normal file
4
etc/Makefile.am
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
SUBDIRS = pacman.d abs
|
||||||
|
|
||||||
|
EXTRA_DIST = makepkg.conf pacman.conf
|
||||||
|
dist_sysconf_DATA = makepkg.conf pacman.conf
|
2
etc/abs/.cvsignore
Normal file
2
etc/abs/.cvsignore
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
Makefile
|
||||||
|
Makefile.in
|
17
etc/abs/Makefile.am
Normal file
17
etc/abs/Makefile.am
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
EXTRA_DIST = abs.conf \
|
||||||
|
supfile.arch \
|
||||||
|
supfile.community \
|
||||||
|
supfile.extra \
|
||||||
|
supfile.testing \
|
||||||
|
supfile.unstable
|
||||||
|
|
||||||
|
install-data-hook:
|
||||||
|
mkdir -p $(DESTDIR)$(sysconfdir)/abs ; \
|
||||||
|
for j in $(EXTRA_DIST); do \
|
||||||
|
$(INSTALL) -c -m 644 $(srcdir)/$$j $(DESTDIR)$(sysconfdir)/abs/$$j ; \
|
||||||
|
done
|
||||||
|
|
||||||
|
uninstall-hook:
|
||||||
|
for j in $(EXTRA_DIST); do \
|
||||||
|
rm -f $(DESTDIR)$(sysconfdir)/abs/$$j ; \
|
||||||
|
done
|
13
etc/abs/abs.conf
Normal file
13
etc/abs/abs.conf
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
#
|
||||||
|
# /etc/abs/abs.conf
|
||||||
|
#
|
||||||
|
|
||||||
|
# the top-level directory of all your PKGBUILDs
|
||||||
|
[ "$ABSROOT" = "" ] && ABSROOT="/var/abs/"
|
||||||
|
|
||||||
|
#
|
||||||
|
# Supfiles to be parsed by abs (in this order)
|
||||||
|
# (prefix a module with a ! to disable it)
|
||||||
|
#
|
||||||
|
SUPFILES=(arch extra !unstable !community !testing)
|
||||||
|
|
15
etc/abs/supfile.arch
Normal file
15
etc/abs/supfile.arch
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
#
|
||||||
|
# /etc/abs/supfile.arch
|
||||||
|
#
|
||||||
|
|
||||||
|
# this is the host containing the current PKGBUILD files
|
||||||
|
*default host=cvs.archlinux.org
|
||||||
|
|
||||||
|
*default release=cvs
|
||||||
|
*default delete
|
||||||
|
*default use-rel-suffix
|
||||||
|
*default compress
|
||||||
|
#*default umask=002
|
||||||
|
|
||||||
|
*default tag=CURRENT
|
||||||
|
arch
|
15
etc/abs/supfile.community
Normal file
15
etc/abs/supfile.community
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
#
|
||||||
|
# /etc/abs/supfile.community
|
||||||
|
#
|
||||||
|
|
||||||
|
# this is the host containing the community PKGBUILD files
|
||||||
|
*default host=cvs.archlinux.org
|
||||||
|
|
||||||
|
*default release=cvs
|
||||||
|
*default delete
|
||||||
|
*default use-rel-suffix
|
||||||
|
*default compress
|
||||||
|
#*default umask=002
|
||||||
|
|
||||||
|
*default tag=CURRENT
|
||||||
|
community
|
15
etc/abs/supfile.extra
Normal file
15
etc/abs/supfile.extra
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
#
|
||||||
|
# /etc/abs/supfile.extra
|
||||||
|
#
|
||||||
|
|
||||||
|
# this is the host containing the extra PKGBUILD files
|
||||||
|
*default host=cvs.archlinux.org
|
||||||
|
|
||||||
|
*default release=cvs
|
||||||
|
*default delete
|
||||||
|
*default use-rel-suffix
|
||||||
|
*default compress
|
||||||
|
#*default umask=002
|
||||||
|
|
||||||
|
*default tag=CURRENT
|
||||||
|
extra
|
16
etc/abs/supfile.testing
Normal file
16
etc/abs/supfile.testing
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
#
|
||||||
|
# /etc/abs/supfile.testing
|
||||||
|
#
|
||||||
|
|
||||||
|
# this is the host containing the testing PKGBUILD files
|
||||||
|
*default host=cvs.archlinux.org
|
||||||
|
|
||||||
|
*default release=cvs
|
||||||
|
*default delete
|
||||||
|
*default use-rel-suffix
|
||||||
|
*default compress
|
||||||
|
#*default umask=002
|
||||||
|
|
||||||
|
*default tag=TESTING
|
||||||
|
arch
|
||||||
|
extra
|
15
etc/abs/supfile.unstable
Normal file
15
etc/abs/supfile.unstable
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
#
|
||||||
|
# /etc/abs/supfile.unstable
|
||||||
|
#
|
||||||
|
|
||||||
|
# this is the host containing the unstable PKGBUILD files
|
||||||
|
*default host=cvs.archlinux.org
|
||||||
|
|
||||||
|
*default release=cvs
|
||||||
|
*default delete
|
||||||
|
*default use-rel-suffix
|
||||||
|
*default compress
|
||||||
|
#*default umask=002
|
||||||
|
|
||||||
|
*default tag=CURRENT
|
||||||
|
unstable
|
|
@ -1,18 +0,0 @@
|
||||||
#!/hint/bash
|
|
||||||
#
|
|
||||||
# @sysconfdir@/makepkg.conf.d/fortran.conf
|
|
||||||
#
|
|
||||||
|
|
||||||
#########################################################################
|
|
||||||
# FORTRAN LANGUAGE SUPPORT
|
|
||||||
#########################################################################
|
|
||||||
|
|
||||||
# Flags used for the Fortran compiler, similar in spirit to CFLAGS. Read
|
|
||||||
# linkman:gfortran[1] for more details on the available flags.
|
|
||||||
#FFLAGS="-O2 -pipe"
|
|
||||||
#FCFLAGS="$FFLAGS"
|
|
||||||
|
|
||||||
# Additional compiler flags appended to `FFLAGS` and `FCFLAGS` for use in debugging. Usually
|
|
||||||
# this would include: ``-g''. Read linkman:gfortran[1] for more details on the wide
|
|
||||||
# variety of compiler flags available.
|
|
||||||
#DEBUG_FFLAGS="-g"
|
|
|
@ -1,17 +0,0 @@
|
||||||
#!/hint/bash
|
|
||||||
#
|
|
||||||
# @sysconfdir@/makepkg.conf.d/rust.conf
|
|
||||||
#
|
|
||||||
|
|
||||||
#########################################################################
|
|
||||||
# RUST LANGUAGE SUPPORT
|
|
||||||
#########################################################################
|
|
||||||
|
|
||||||
# Flags used for the Rust compiler, similar in spirit to CFLAGS. Read
|
|
||||||
# linkman:rustc[1] for more details on the available flags.
|
|
||||||
#RUSTFLAGS="-C opt-level=3"
|
|
||||||
|
|
||||||
# Additional compiler flags appended to `RUSTFLAGS` for use in debugging.
|
|
||||||
# Usually this would include: ``-C debuginfo=2''. Read linkman:rustc[1] for
|
|
||||||
# more details on the available flags.
|
|
||||||
#DEBUG_RUSTFLAGS="-C debuginfo=2"
|
|
|
@ -1,33 +1,15 @@
|
||||||
#!/hint/bash
|
|
||||||
#
|
#
|
||||||
# @sysconfdir@/makepkg.conf
|
# /etc/makepkg.conf
|
||||||
#
|
#
|
||||||
|
|
||||||
#########################################################################
|
#########################################################################
|
||||||
# SOURCE ACQUISITION
|
# SOURCE ACQUISITION
|
||||||
#########################################################################
|
#########################################################################
|
||||||
#
|
#
|
||||||
#-- The download utilities that makepkg should use to acquire sources
|
#-- The FTP/HTTP download utility that makepkg should use to acquire sources
|
||||||
# Format: 'protocol::agent'
|
FTPAGENT="/usr/bin/wget --continue --passive-ftp --tries=3 --waitretry=3 --no-check-certificate"
|
||||||
DLAGENTS=('file::/usr/bin/curl -qgC - -o %o %u'
|
#FTPAGENT="/usr/bin/snarf"
|
||||||
'ftp::/usr/bin/curl -qgfC - --ftp-pasv --retry 3 --retry-delay 3 -o %o %u'
|
#FTPAGENT="/usr/bin/lftpget -c"
|
||||||
'http::/usr/bin/curl -qgb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
|
|
||||||
'https::/usr/bin/curl -qgb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
|
|
||||||
'rsync::/usr/bin/rsync --no-motd -z %u %o'
|
|
||||||
'scp::/usr/bin/scp -C %u %o')
|
|
||||||
|
|
||||||
# Other common tools:
|
|
||||||
# /usr/bin/snarf
|
|
||||||
# /usr/bin/lftpget -c
|
|
||||||
# /usr/bin/wget
|
|
||||||
|
|
||||||
#-- The package required by makepkg to download VCS sources
|
|
||||||
# Format: 'protocol::package'
|
|
||||||
VCSCLIENTS=('bzr::breezy'
|
|
||||||
'fossil::fossil'
|
|
||||||
'git::git'
|
|
||||||
'hg::mercurial'
|
|
||||||
'svn::subversion')
|
|
||||||
|
|
||||||
#########################################################################
|
#########################################################################
|
||||||
# ARCHITECTURE, COMPILE FLAGS
|
# ARCHITECTURE, COMPILE FLAGS
|
||||||
|
@ -36,82 +18,49 @@ VCSCLIENTS=('bzr::breezy'
|
||||||
CARCH="@CARCH@"
|
CARCH="@CARCH@"
|
||||||
CHOST="@CHOST@"
|
CHOST="@CHOST@"
|
||||||
|
|
||||||
#NPROC=2
|
#-- Exclusive: will only run on @CARCHFLAGS@
|
||||||
|
# -mtune builds exclusively for an architecture
|
||||||
#-- Compiler and Linker Flags
|
# -mcpu optimizes for an architecture, but builds for the whole processor family
|
||||||
#CPPFLAGS=""
|
CFLAGS="-@ARCHSWITCH@=@CARCHFLAGS@ -O2 -pipe"
|
||||||
#CFLAGS="-O2 -pipe"
|
CXXFLAGS="-@ARCHSWITCH@=@CARCHFLAGS@ -O2 -pipe"
|
||||||
#CXXFLAGS="-O2 -pipe"
|
|
||||||
#LDFLAGS=""
|
|
||||||
#LTOFLAGS="-flto"
|
|
||||||
#-- Make Flags: change this for DistCC/SMP systems
|
#-- Make Flags: change this for DistCC/SMP systems
|
||||||
#MAKEFLAGS="-j2"
|
#MAKEFLAGS="-j2"
|
||||||
#-- Debugging flags
|
|
||||||
#DEBUG_CFLAGS="-g"
|
|
||||||
#DEBUG_CXXFLAGS="-g"
|
|
||||||
|
|
||||||
#########################################################################
|
#########################################################################
|
||||||
# BUILD ENVIRONMENT
|
# BUILD ENVIRONMENT
|
||||||
#########################################################################
|
#########################################################################
|
||||||
#
|
#
|
||||||
# Makepkg defaults: BUILDENV=(!distcc !color !ccache check !sign)
|
# Defaults: BUILDENV=(!fakeroot !distcc color !ccache)
|
||||||
# A negated environment option will do the opposite of the comments below.
|
|
||||||
#
|
#
|
||||||
|
#-- fakeroot: Allow building packages as a non-root user
|
||||||
#-- distcc: Use the Distributed C/C++/ObjC compiler
|
#-- distcc: Use the Distributed C/C++/ObjC compiler
|
||||||
#-- color: Colorize output messages
|
#-- color: Colorize output messages
|
||||||
#-- ccache: Use ccache to cache compilation
|
#-- ccache: Use ccache to cache compilation
|
||||||
#-- check: Run the check() function if present in the PKGBUILD
|
|
||||||
#-- sign: Generate PGP signature file
|
|
||||||
#
|
#
|
||||||
BUILDENV=(!distcc color !ccache check !sign)
|
BUILDENV=(fakeroot !distcc color !ccache)
|
||||||
#
|
#
|
||||||
#-- If using DistCC, your MAKEFLAGS will also need modification. In addition,
|
#-- If using DistCC, your MAKEFLAGS will also need modification. In addition,
|
||||||
#-- specify a space-delimited list of hosts running in the DistCC cluster.
|
#-- specify a space-delimited list of hosts running in the DistCC cluster.
|
||||||
#DISTCC_HOSTS=""
|
#DISTCC_HOSTS=""
|
||||||
#
|
|
||||||
#-- Specify a directory for package building.
|
|
||||||
#BUILDDIR=/tmp/makepkg
|
|
||||||
|
|
||||||
#########################################################################
|
#########################################################################
|
||||||
# GLOBAL PACKAGE OPTIONS
|
# GLOBAL PACKAGE OPTIONS
|
||||||
# These are default values for the options=() settings
|
# These are default values for the options=() settings
|
||||||
#########################################################################
|
#########################################################################
|
||||||
#
|
#
|
||||||
# Makepkg defaults:
|
# Default: OPTIONS=(strip !docs !libtool emptydirs)
|
||||||
# OPTIONS=(!strip docs libtool staticlibs emptydirs !zipman !purge !debug !lto !autodeps)
|
|
||||||
# A negated option will do the opposite of the comments below.
|
|
||||||
#
|
#
|
||||||
#-- strip: Strip symbols from binaries/libraries
|
#-- strip: Strip symbols from binaries/libraries
|
||||||
#-- docs: Save doc directories specified by DOC_DIRS
|
#-- docs: Save doc and info directories
|
||||||
#-- libtool: Leave libtool (.la) files in packages
|
#-- libtool: Leave libtool (.la) files in packages
|
||||||
#-- staticlibs: Leave static library (.a) files in packages
|
#-- emptydirs: Leave empty directories in packages
|
||||||
#-- emptydirs: Leave empty directories in packages
|
|
||||||
#-- zipman: Compress manual (man and info) pages in MAN_DIRS with gzip
|
|
||||||
#-- purge: Remove files specified by PURGE_TARGETS
|
|
||||||
#-- debug: Add debugging flags as specified in DEBUG_* variables
|
|
||||||
#-- lto: Add compile flags for building with link time optimization
|
|
||||||
#-- autodeps: Automatically add depends/provides
|
|
||||||
#
|
#
|
||||||
OPTIONS=(strip docs libtool staticlibs emptydirs zipman purge !debug !lto !autodeps)
|
OPTIONS=(strip !docs libtool emptydirs)
|
||||||
|
|
||||||
#-- File integrity checks to use. Valid: ck, md5, sha1, sha224, sha256, sha384, sha512, b2
|
#-- File integrity checks to use. Valid: md5, sha1, sha256, sha384, sha512
|
||||||
INTEGRITY_CHECK=(ck)
|
INTEGRITY_CHECK=(md5)
|
||||||
#-- Options to be used when stripping binaries. See `man strip' for details.
|
#-- Info and doc directories to remove (if option set correctly above)
|
||||||
STRIP_BINARIES="@STRIP_BINARIES@"
|
DOC_DIRS=(usr/{,share/}{info,doc} opt/gnome/{,share/}{info,doc,gtk-doc})
|
||||||
#-- Options to be used when stripping shared libraries. See `man strip' for details.
|
|
||||||
STRIP_SHARED="@STRIP_SHARED@"
|
|
||||||
#-- Options to be used when stripping static libraries. See `man strip' for details.
|
|
||||||
STRIP_STATIC="@STRIP_STATIC@"
|
|
||||||
#-- Manual (man and info) directories to compress (if zipman is specified)
|
|
||||||
MAN_DIRS=({usr{,/local}{,/share},opt/*}/{man,info})
|
|
||||||
#-- Doc directories to remove (if !docs is specified)
|
|
||||||
DOC_DIRS=(usr/{,local/}{,share/}{doc,gtk-doc} opt/*/{doc,gtk-doc})
|
|
||||||
#-- Files to be removed from all packages (if purge is specified)
|
|
||||||
PURGE_TARGETS=(usr/{,share}/info/dir .packlist *.pod)
|
|
||||||
#-- Directory to store source code in for debug packages
|
|
||||||
DBGSRCDIR="/usr/src/debug"
|
|
||||||
#-- Prefix and directories for library autodeps
|
|
||||||
LIB_DIRS=('lib:usr/lib' 'lib32:usr/lib32')
|
|
||||||
|
|
||||||
#########################################################################
|
#########################################################################
|
||||||
# PACKAGE OUTPUT
|
# PACKAGE OUTPUT
|
||||||
|
@ -123,39 +72,7 @@ LIB_DIRS=('lib:usr/lib' 'lib32:usr/lib32')
|
||||||
#PKGDEST=/home/packages
|
#PKGDEST=/home/packages
|
||||||
#-- Source cache: specify a fixed directory where source files will be cached
|
#-- Source cache: specify a fixed directory where source files will be cached
|
||||||
#SRCDEST=/home/sources
|
#SRCDEST=/home/sources
|
||||||
#-- Source packages: specify a fixed directory where all src packages will be placed
|
|
||||||
#SRCPKGDEST=/home/srcpackages
|
|
||||||
#-- Log files: specify a fixed directory where all log files will be placed
|
|
||||||
#LOGDEST=/home/makepkglogs
|
|
||||||
#-- Packager: name/email of the person or organization building packages
|
#-- Packager: name/email of the person or organization building packages
|
||||||
#PACKAGER="John Doe <john@doe.com>"
|
#PACKAGER="John Doe <john@doe.com>"
|
||||||
#-- Specify a key to use for package signing
|
|
||||||
#GPGKEY=""
|
|
||||||
|
|
||||||
#########################################################################
|
# vim: set ft=sh ts=2 sw=2 et:
|
||||||
# COMPRESSION DEFAULTS
|
|
||||||
#########################################################################
|
|
||||||
#
|
|
||||||
COMPRESSGZ=(gzip -c -f -n)
|
|
||||||
COMPRESSBZ2=(bzip2 -c -f)
|
|
||||||
COMPRESSXZ=(xz -c -z -)
|
|
||||||
COMPRESSZST=(zstd -c -z -q -)
|
|
||||||
COMPRESSLRZ=(lrzip -q)
|
|
||||||
COMPRESSLZO=(lzop -q)
|
|
||||||
COMPRESSZ=(compress -c -f)
|
|
||||||
COMPRESSLZ4=(lz4 -q)
|
|
||||||
COMPRESSLZ=(lzip -c -f)
|
|
||||||
|
|
||||||
#########################################################################
|
|
||||||
# EXTENSION DEFAULTS
|
|
||||||
#########################################################################
|
|
||||||
#
|
|
||||||
PKGEXT='@PKGEXT@'
|
|
||||||
SRCEXT='@SRCEXT@'
|
|
||||||
|
|
||||||
#########################################################################
|
|
||||||
# OTHER
|
|
||||||
#########################################################################
|
|
||||||
#
|
|
||||||
#-- Command used to run pacman as root, instead of trying sudo and su
|
|
||||||
PACMAN_AUTH=()
|
|
||||||
|
|
|
@ -1,47 +1,15 @@
|
||||||
#
|
#
|
||||||
# @sysconfdir@/pacman.conf
|
# /etc/pacman.conf
|
||||||
#
|
#
|
||||||
# See the pacman.conf(5) manpage for option and repository directives
|
# See the pacman manpage for option directives
|
||||||
|
|
||||||
#
|
#
|
||||||
# GENERAL OPTIONS
|
# GENERAL OPTIONS
|
||||||
#
|
#
|
||||||
[options]
|
[options]
|
||||||
# The following paths are commented out with their default values listed.
|
LogFile = /var/log/pacman.log
|
||||||
# If you wish to use different paths, uncomment and update the paths.
|
|
||||||
#RootDir = @ROOTDIR@
|
|
||||||
#DBPath = @localstatedir@/lib/pacman/
|
|
||||||
#CacheDir = @localstatedir@/cache/pacman/pkg/
|
|
||||||
#LogFile = @localstatedir@/log/pacman.log
|
|
||||||
#GPGDir = @sysconfdir@/pacman.d/gnupg/
|
|
||||||
#HookDir = @sysconfdir@/pacman.d/hooks/
|
|
||||||
HoldPkg = pacman glibc
|
HoldPkg = pacman glibc
|
||||||
#XferCommand = /usr/bin/curl -L -C - -f -o %o %u
|
|
||||||
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
||||||
#CleanMethod = KeepInstalled
|
|
||||||
Architecture = auto
|
|
||||||
|
|
||||||
# Pacman won't upgrade packages listed in IgnorePkg and members of IgnoreGroup
|
|
||||||
#IgnorePkg =
|
|
||||||
#IgnoreGroup =
|
|
||||||
|
|
||||||
#NoUpgrade =
|
|
||||||
#NoExtract =
|
|
||||||
|
|
||||||
# Misc options
|
|
||||||
#UseSyslog
|
|
||||||
#Color
|
|
||||||
#NoProgressBar
|
|
||||||
CheckSpace
|
|
||||||
#VerbosePkgLists
|
|
||||||
ParallelDownloads = 5
|
|
||||||
#DownloadUser = alpm
|
|
||||||
#DisableSandbox
|
|
||||||
|
|
||||||
# PGP signature checking
|
|
||||||
#SigLevel = Optional
|
|
||||||
#LocalFileSigLevel = Optional
|
|
||||||
#RemoteFileSigLevel = Optional
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# REPOSITORIES
|
# REPOSITORIES
|
||||||
|
@ -50,30 +18,28 @@ ParallelDownloads = 5
|
||||||
# - local/custom mirrors can be added here or in separate files
|
# - local/custom mirrors can be added here or in separate files
|
||||||
# - repositories listed first will take precedence when packages
|
# - repositories listed first will take precedence when packages
|
||||||
# have identical names, regardless of version number
|
# have identical names, regardless of version number
|
||||||
# - URLs will have $repo replaced by the name of the current repo
|
|
||||||
# - URLs will have $arch replaced by the name of the architecture
|
|
||||||
#
|
|
||||||
# Repository entries are of the format:
|
|
||||||
# [repo-name]
|
|
||||||
# Server = ServerName
|
|
||||||
# Include = IncludePath
|
|
||||||
#
|
|
||||||
# The header [repo-name] is crucial - it must be present and
|
|
||||||
# uncommented to enable the repo.
|
|
||||||
#
|
#
|
||||||
|
#[testing]
|
||||||
|
#Server = ftp://ftp.archlinux.org/testing/os/@CARCH@
|
||||||
|
|
||||||
# An example of a disabled remote package repository with multiple servers
|
[current]
|
||||||
# available. To enable, uncomment the following lines. You can add preferred
|
# Add your preferred servers here, they will be used first
|
||||||
# servers immediately after the header and they will be used before the
|
Include = /etc/pacman.d/current
|
||||||
# default mirrors.
|
|
||||||
#[core]
|
[extra]
|
||||||
#SigLevel = Required
|
# Add your preferred servers here, they will be used first
|
||||||
#Server = ftp://ftp.example.com/foobar/$repo/os/$arch/
|
Include = /etc/pacman.d/extra
|
||||||
# The file referenced here should contain a list of 'Server = ' lines.
|
|
||||||
#Include = @sysconfdir@/pacman.d/mirrorlist
|
[community]
|
||||||
|
# Add your preferred servers here, they will be used first
|
||||||
|
Include = /etc/pacman.d/community
|
||||||
|
|
||||||
|
#[unstable]
|
||||||
|
# Add your preferred servers here, they will be used first
|
||||||
|
#Include = /etc/pacman.d/unstable
|
||||||
|
|
||||||
# An example of a custom package repository. See the pacman manpage for
|
# An example of a custom package repository. See the pacman manpage for
|
||||||
# tips on creating your own repositories.
|
# tips on creating your own repositories.
|
||||||
#[custom]
|
#[custom]
|
||||||
#SigLevel = Optional TrustAll
|
#Server = file:///home/custompkgs
|
||||||
#Server = file:///home/packages
|
|
||||||
|
|
8
etc/pacman.d/.cvsignore
Normal file
8
etc/pacman.d/.cvsignore
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
Makefile
|
||||||
|
Makefile.in
|
||||||
|
community
|
||||||
|
current
|
||||||
|
extra
|
||||||
|
mirrorlist
|
||||||
|
release
|
||||||
|
unstable
|
9
etc/pacman.d/Makefile.am
Normal file
9
etc/pacman.d/Makefile.am
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
pkgsysconfdir = ${sysconfdir}/pacman.d
|
||||||
|
dist_pkgsysconf_DATA = community current extra release unstable
|
||||||
|
|
||||||
|
$(dist_pkgsysconf_DATA): mirrorlist
|
||||||
|
sed "s|@@REPO@@|$@|g" <$< >$@
|
||||||
|
|
||||||
|
clean-local:
|
||||||
|
rm -f $(dist_pkgsysconf_DATA)
|
||||||
|
|
70
etc/pacman.d/mirrorlist.in
Normal file
70
etc/pacman.d/mirrorlist.in
Normal file
|
@ -0,0 +1,70 @@
|
||||||
|
#
|
||||||
|
# @@REPO@@: Arch Linux @@REPO@@ repository
|
||||||
|
#
|
||||||
|
|
||||||
|
# United States
|
||||||
|
Server = ftp://ftp.archlinux.org/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://ftp.nethat.com/pub/linux/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://ftp-linux.cc.gatech.edu/pub/linux/distributions/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://mirror.cs.vt.edu/pub/ArchLinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://ftp.ibiblio.org/pub/linux/distributions/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
|
||||||
|
# Europe
|
||||||
|
# - Austria
|
||||||
|
Server = ftp://gd.tuwien.ac.at/opsys/linux/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Belgium
|
||||||
|
Server = ftp://ftp.belnet.be/packages/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Czech Republic
|
||||||
|
Server = ftp://ftp.sh.cvut.cz/MIRRORS/arch/@@REPO@@/os/@CARCH@
|
||||||
|
# - Estonia
|
||||||
|
Server = ftp://ftp.estpak.ee/pub/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Finland
|
||||||
|
Server = ftp://ftp.sixnix.net/pub/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - France
|
||||||
|
Server = ftp://ftp.rez-gif.supelec.fr/pub/Linux/distrib/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://mir1.archlinuxfr.org/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://mir2.archlinuxfr.org/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://distrib-coffee.ipsl.jussieu.fr/pub/linux/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Germany
|
||||||
|
Server = ftp://ftp.tu-chemnitz.de/pub/linux/sunsite.unc-mirror/distributions/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://ftp.hosteurope.de/mirror/ftp.archlinux.org/@@REPO@@/os/@CARCH@
|
||||||
|
# - Great Britain
|
||||||
|
Server = http://ftp.parrswood.manchester.sch.uk/Mirrors/ftp.archlinux.org/@@REPO@@/os/@CARCH@
|
||||||
|
# - Greece
|
||||||
|
Server = ftp://ftp.ntua.gr/pub/linux/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Ireland
|
||||||
|
Server = ftp://ftp.heanet.ie/mirrors/ftp.archlinux.org/@@REPO@@/os/@CARCH@
|
||||||
|
# - Italy
|
||||||
|
Server = ftp://mi.mirror.garr.it/mirrors/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Lithuania
|
||||||
|
Server = ftp://saule.mintis.lt/pub/linux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Netherlands
|
||||||
|
Server = ftp://ftp.nluug.nl/pub/metalab/distributions/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://ftp.surfnet.nl/pub/os/Linux/distr/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Norway
|
||||||
|
Server = ftp://mirror.djzradio.net/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Poland
|
||||||
|
Server = ftp://sunsite.icm.edu.pl/site/linux-sunsite/distributions/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://mirror.icis.pcz.pl/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Portugal
|
||||||
|
Server = ftp://gul.est.ips.pt/repos/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://cesium.di.uminho.pt/pub/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://darkstar.ist.utl.pt/pub/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
# - Romania
|
||||||
|
Server = ftp://ftp.iasi.roedu.net/mirrors/archlinux.org/@@REPO@@/os/@CARCH@
|
||||||
|
# - Sweden
|
||||||
|
Server = ftp://ftp.ds.hj.se/pub/os/linux/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = ftp://ftp.gigabit.nu/@@REPO@@/os/@CARCH@
|
||||||
|
# - Switzerland
|
||||||
|
Server = ftp://archlinux.puzzle.ch/@@REPO@@/os/@CARCH@
|
||||||
|
# - Ukraine
|
||||||
|
Server = ftp://ftp.linux.kiev.ua/pub/Linux/ArchLinux/@@REPO@@/os/@CARCH@
|
||||||
|
|
||||||
|
# Australia
|
||||||
|
Server = ftp://mirror.pacific.net.au/linux/archlinux/@@REPO@@/os/@CARCH@
|
||||||
|
|
||||||
|
# Asia
|
||||||
|
# - China
|
||||||
|
Server = http://mirror.vxmatrix.net/ArchLinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = http://dxmirror.vxmatrix.net/ArchLinux/@@REPO@@/os/@CARCH@
|
||||||
|
Server = http://cncmirror.vxmatrix.net/ArchLinux/@@REPO@@/os/@CARCH@
|
507
install-sh
Executable file
507
install-sh
Executable file
|
@ -0,0 +1,507 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# install - install a program, script, or datafile
|
||||||
|
|
||||||
|
scriptversion=2006-10-14.15
|
||||||
|
|
||||||
|
# This originates from X11R5 (mit/util/scripts/install.sh), which was
|
||||||
|
# later released in X11R6 (xc/config/util/install.sh) with the
|
||||||
|
# following copyright and license.
|
||||||
|
#
|
||||||
|
# Copyright (C) 1994 X Consortium
|
||||||
|
#
|
||||||
|
# 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
|
||||||
|
# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
|
||||||
|
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
|
||||||
|
# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
#
|
||||||
|
# Except as contained in this notice, the name of the X Consortium shall not
|
||||||
|
# be used in advertising or otherwise to promote the sale, use or other deal-
|
||||||
|
# ings in this Software without prior written authorization from the X Consor-
|
||||||
|
# tium.
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# FSF changes to this file are in the public domain.
|
||||||
|
#
|
||||||
|
# Calling this script install-sh is preferred over install.sh, to prevent
|
||||||
|
# `make' implicit rules from creating a file called install from it
|
||||||
|
# when there is no Makefile.
|
||||||
|
#
|
||||||
|
# This script is compatible with the BSD install script, but was written
|
||||||
|
# from scratch.
|
||||||
|
|
||||||
|
nl='
|
||||||
|
'
|
||||||
|
IFS=" "" $nl"
|
||||||
|
|
||||||
|
# set DOITPROG to echo to test this script
|
||||||
|
|
||||||
|
# Don't use :- since 4.3BSD and earlier shells don't like it.
|
||||||
|
doit="${DOITPROG-}"
|
||||||
|
if test -z "$doit"; then
|
||||||
|
doit_exec=exec
|
||||||
|
else
|
||||||
|
doit_exec=$doit
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Put in absolute file names if you don't have them in your path;
|
||||||
|
# or use environment vars.
|
||||||
|
|
||||||
|
mvprog="${MVPROG-mv}"
|
||||||
|
cpprog="${CPPROG-cp}"
|
||||||
|
chmodprog="${CHMODPROG-chmod}"
|
||||||
|
chownprog="${CHOWNPROG-chown}"
|
||||||
|
chgrpprog="${CHGRPPROG-chgrp}"
|
||||||
|
stripprog="${STRIPPROG-strip}"
|
||||||
|
rmprog="${RMPROG-rm}"
|
||||||
|
mkdirprog="${MKDIRPROG-mkdir}"
|
||||||
|
|
||||||
|
posix_glob=
|
||||||
|
posix_mkdir=
|
||||||
|
|
||||||
|
# Desired mode of installed file.
|
||||||
|
mode=0755
|
||||||
|
|
||||||
|
chmodcmd=$chmodprog
|
||||||
|
chowncmd=
|
||||||
|
chgrpcmd=
|
||||||
|
stripcmd=
|
||||||
|
rmcmd="$rmprog -f"
|
||||||
|
mvcmd="$mvprog"
|
||||||
|
src=
|
||||||
|
dst=
|
||||||
|
dir_arg=
|
||||||
|
dstarg=
|
||||||
|
no_target_directory=
|
||||||
|
|
||||||
|
usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE
|
||||||
|
or: $0 [OPTION]... SRCFILES... DIRECTORY
|
||||||
|
or: $0 [OPTION]... -t DIRECTORY SRCFILES...
|
||||||
|
or: $0 [OPTION]... -d DIRECTORIES...
|
||||||
|
|
||||||
|
In the 1st form, copy SRCFILE to DSTFILE.
|
||||||
|
In the 2nd and 3rd, copy all SRCFILES to DIRECTORY.
|
||||||
|
In the 4th, create DIRECTORIES.
|
||||||
|
|
||||||
|
Options:
|
||||||
|
-c (ignored)
|
||||||
|
-d create directories instead of installing files.
|
||||||
|
-g GROUP $chgrpprog installed files to GROUP.
|
||||||
|
-m MODE $chmodprog installed files to MODE.
|
||||||
|
-o USER $chownprog installed files to USER.
|
||||||
|
-s $stripprog installed files.
|
||||||
|
-t DIRECTORY install into DIRECTORY.
|
||||||
|
-T report an error if DSTFILE is a directory.
|
||||||
|
--help display this help and exit.
|
||||||
|
--version display version info and exit.
|
||||||
|
|
||||||
|
Environment variables override the default commands:
|
||||||
|
CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG
|
||||||
|
"
|
||||||
|
|
||||||
|
while test $# -ne 0; do
|
||||||
|
case $1 in
|
||||||
|
-c) shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-d) dir_arg=true
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-g) chgrpcmd="$chgrpprog $2"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
--help) echo "$usage"; exit $?;;
|
||||||
|
|
||||||
|
-m) mode=$2
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
case $mode in
|
||||||
|
*' '* | *' '* | *'
|
||||||
|
'* | *'*'* | *'?'* | *'['*)
|
||||||
|
echo "$0: invalid mode: $mode" >&2
|
||||||
|
exit 1;;
|
||||||
|
esac
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-o) chowncmd="$chownprog $2"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-s) stripcmd=$stripprog
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-t) dstarg=$2
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-T) no_target_directory=true
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
--version) echo "$0 $scriptversion"; exit $?;;
|
||||||
|
|
||||||
|
--) shift
|
||||||
|
break;;
|
||||||
|
|
||||||
|
-*) echo "$0: invalid option: $1" >&2
|
||||||
|
exit 1;;
|
||||||
|
|
||||||
|
*) break;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
if test $# -ne 0 && test -z "$dir_arg$dstarg"; then
|
||||||
|
# When -d is used, all remaining arguments are directories to create.
|
||||||
|
# When -t is used, the destination is already specified.
|
||||||
|
# Otherwise, the last argument is the destination. Remove it from $@.
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
if test -n "$dstarg"; then
|
||||||
|
# $@ is not empty: it contains at least $arg.
|
||||||
|
set fnord "$@" "$dstarg"
|
||||||
|
shift # fnord
|
||||||
|
fi
|
||||||
|
shift # arg
|
||||||
|
dstarg=$arg
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test $# -eq 0; then
|
||||||
|
if test -z "$dir_arg"; then
|
||||||
|
echo "$0: no input file specified." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
# It's OK to call `install-sh -d' without argument.
|
||||||
|
# This can happen when creating conditional directories.
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test -z "$dir_arg"; then
|
||||||
|
trap '(exit $?); exit' 1 2 13 15
|
||||||
|
|
||||||
|
# Set umask so as not to create temps with too-generous modes.
|
||||||
|
# However, 'strip' requires both read and write access to temps.
|
||||||
|
case $mode in
|
||||||
|
# Optimize common cases.
|
||||||
|
*644) cp_umask=133;;
|
||||||
|
*755) cp_umask=22;;
|
||||||
|
|
||||||
|
*[0-7])
|
||||||
|
if test -z "$stripcmd"; then
|
||||||
|
u_plus_rw=
|
||||||
|
else
|
||||||
|
u_plus_rw='% 200'
|
||||||
|
fi
|
||||||
|
cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;;
|
||||||
|
*)
|
||||||
|
if test -z "$stripcmd"; then
|
||||||
|
u_plus_rw=
|
||||||
|
else
|
||||||
|
u_plus_rw=,u+rw
|
||||||
|
fi
|
||||||
|
cp_umask=$mode$u_plus_rw;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
|
for src
|
||||||
|
do
|
||||||
|
# Protect names starting with `-'.
|
||||||
|
case $src in
|
||||||
|
-*) src=./$src ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if test -n "$dir_arg"; then
|
||||||
|
dst=$src
|
||||||
|
dstdir=$dst
|
||||||
|
test -d "$dstdir"
|
||||||
|
dstdir_status=$?
|
||||||
|
else
|
||||||
|
|
||||||
|
# Waiting for this to be detected by the "$cpprog $src $dsttmp" command
|
||||||
|
# might cause directories to be created, which would be especially bad
|
||||||
|
# if $src (and thus $dsttmp) contains '*'.
|
||||||
|
if test ! -f "$src" && test ! -d "$src"; then
|
||||||
|
echo "$0: $src does not exist." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test -z "$dstarg"; then
|
||||||
|
echo "$0: no destination specified." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
dst=$dstarg
|
||||||
|
# Protect names starting with `-'.
|
||||||
|
case $dst in
|
||||||
|
-*) dst=./$dst ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# If destination is a directory, append the input filename; won't work
|
||||||
|
# if double slashes aren't ignored.
|
||||||
|
if test -d "$dst"; then
|
||||||
|
if test -n "$no_target_directory"; then
|
||||||
|
echo "$0: $dstarg: Is a directory" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
dstdir=$dst
|
||||||
|
dst=$dstdir/`basename "$src"`
|
||||||
|
dstdir_status=0
|
||||||
|
else
|
||||||
|
# Prefer dirname, but fall back on a substitute if dirname fails.
|
||||||
|
dstdir=`
|
||||||
|
(dirname "$dst") 2>/dev/null ||
|
||||||
|
expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
|
||||||
|
X"$dst" : 'X\(//\)[^/]' \| \
|
||||||
|
X"$dst" : 'X\(//\)$' \| \
|
||||||
|
X"$dst" : 'X\(/\)' \| . 2>/dev/null ||
|
||||||
|
echo X"$dst" |
|
||||||
|
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
|
||||||
|
s//\1/
|
||||||
|
q
|
||||||
|
}
|
||||||
|
/^X\(\/\/\)[^/].*/{
|
||||||
|
s//\1/
|
||||||
|
q
|
||||||
|
}
|
||||||
|
/^X\(\/\/\)$/{
|
||||||
|
s//\1/
|
||||||
|
q
|
||||||
|
}
|
||||||
|
/^X\(\/\).*/{
|
||||||
|
s//\1/
|
||||||
|
q
|
||||||
|
}
|
||||||
|
s/.*/./; q'
|
||||||
|
`
|
||||||
|
|
||||||
|
test -d "$dstdir"
|
||||||
|
dstdir_status=$?
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
obsolete_mkdir_used=false
|
||||||
|
|
||||||
|
if test $dstdir_status != 0; then
|
||||||
|
case $posix_mkdir in
|
||||||
|
'')
|
||||||
|
# Create intermediate dirs using mode 755 as modified by the umask.
|
||||||
|
# This is like FreeBSD 'install' as of 1997-10-28.
|
||||||
|
umask=`umask`
|
||||||
|
case $stripcmd.$umask in
|
||||||
|
# Optimize common cases.
|
||||||
|
*[2367][2367]) mkdir_umask=$umask;;
|
||||||
|
.*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;;
|
||||||
|
|
||||||
|
*[0-7])
|
||||||
|
mkdir_umask=`expr $umask + 22 \
|
||||||
|
- $umask % 100 % 40 + $umask % 20 \
|
||||||
|
- $umask % 10 % 4 + $umask % 2
|
||||||
|
`;;
|
||||||
|
*) mkdir_umask=$umask,go-w;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# With -d, create the new directory with the user-specified mode.
|
||||||
|
# Otherwise, rely on $mkdir_umask.
|
||||||
|
if test -n "$dir_arg"; then
|
||||||
|
mkdir_mode=-m$mode
|
||||||
|
else
|
||||||
|
mkdir_mode=
|
||||||
|
fi
|
||||||
|
|
||||||
|
posix_mkdir=false
|
||||||
|
case $umask in
|
||||||
|
*[123567][0-7][0-7])
|
||||||
|
# POSIX mkdir -p sets u+wx bits regardless of umask, which
|
||||||
|
# is incompatible with FreeBSD 'install' when (umask & 300) != 0.
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
|
||||||
|
trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0
|
||||||
|
|
||||||
|
if (umask $mkdir_umask &&
|
||||||
|
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
if test -z "$dir_arg" || {
|
||||||
|
# Check for POSIX incompatibilities with -m.
|
||||||
|
# HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
|
||||||
|
# other-writeable bit of parent directory when it shouldn't.
|
||||||
|
# FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
|
||||||
|
ls_ld_tmpdir=`ls -ld "$tmpdir"`
|
||||||
|
case $ls_ld_tmpdir in
|
||||||
|
d????-?r-*) different_mode=700;;
|
||||||
|
d????-?--*) different_mode=755;;
|
||||||
|
*) false;;
|
||||||
|
esac &&
|
||||||
|
$mkdirprog -m$different_mode -p -- "$tmpdir" && {
|
||||||
|
ls_ld_tmpdir_1=`ls -ld "$tmpdir"`
|
||||||
|
test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
then posix_mkdir=:
|
||||||
|
fi
|
||||||
|
rmdir "$tmpdir/d" "$tmpdir"
|
||||||
|
else
|
||||||
|
# Remove any dirs left behind by ancient mkdir implementations.
|
||||||
|
rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null
|
||||||
|
fi
|
||||||
|
trap '' 0;;
|
||||||
|
esac;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if
|
||||||
|
$posix_mkdir && (
|
||||||
|
umask $mkdir_umask &&
|
||||||
|
$doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir"
|
||||||
|
)
|
||||||
|
then :
|
||||||
|
else
|
||||||
|
|
||||||
|
# The umask is ridiculous, or mkdir does not conform to POSIX,
|
||||||
|
# or it failed possibly due to a race condition. Create the
|
||||||
|
# directory the slow way, step by step, checking for races as we go.
|
||||||
|
|
||||||
|
case $dstdir in
|
||||||
|
/*) prefix=/ ;;
|
||||||
|
-*) prefix=./ ;;
|
||||||
|
*) prefix= ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
case $posix_glob in
|
||||||
|
'')
|
||||||
|
if (set -f) 2>/dev/null; then
|
||||||
|
posix_glob=true
|
||||||
|
else
|
||||||
|
posix_glob=false
|
||||||
|
fi ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
oIFS=$IFS
|
||||||
|
IFS=/
|
||||||
|
$posix_glob && set -f
|
||||||
|
set fnord $dstdir
|
||||||
|
shift
|
||||||
|
$posix_glob && set +f
|
||||||
|
IFS=$oIFS
|
||||||
|
|
||||||
|
prefixes=
|
||||||
|
|
||||||
|
for d
|
||||||
|
do
|
||||||
|
test -z "$d" && continue
|
||||||
|
|
||||||
|
prefix=$prefix$d
|
||||||
|
if test -d "$prefix"; then
|
||||||
|
prefixes=
|
||||||
|
else
|
||||||
|
if $posix_mkdir; then
|
||||||
|
(umask=$mkdir_umask &&
|
||||||
|
$doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break
|
||||||
|
# Don't fail if two instances are running concurrently.
|
||||||
|
test -d "$prefix" || exit 1
|
||||||
|
else
|
||||||
|
case $prefix in
|
||||||
|
*\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;;
|
||||||
|
*) qprefix=$prefix;;
|
||||||
|
esac
|
||||||
|
prefixes="$prefixes '$qprefix'"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
prefix=$prefix/
|
||||||
|
done
|
||||||
|
|
||||||
|
if test -n "$prefixes"; then
|
||||||
|
# Don't fail if two instances are running concurrently.
|
||||||
|
(umask $mkdir_umask &&
|
||||||
|
eval "\$doit_exec \$mkdirprog $prefixes") ||
|
||||||
|
test -d "$dstdir" || exit 1
|
||||||
|
obsolete_mkdir_used=true
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test -n "$dir_arg"; then
|
||||||
|
{ test -z "$chowncmd" || $doit $chowncmd "$dst"; } &&
|
||||||
|
{ test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } &&
|
||||||
|
{ test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false ||
|
||||||
|
test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1
|
||||||
|
else
|
||||||
|
|
||||||
|
# Make a couple of temp file names in the proper directory.
|
||||||
|
dsttmp=$dstdir/_inst.$$_
|
||||||
|
rmtmp=$dstdir/_rm.$$_
|
||||||
|
|
||||||
|
# Trap to clean up those temp files at exit.
|
||||||
|
trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
|
||||||
|
|
||||||
|
# Copy the file name to the temp name.
|
||||||
|
(umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") &&
|
||||||
|
|
||||||
|
# and set any options; do chmod last to preserve setuid bits.
|
||||||
|
#
|
||||||
|
# If any of these fail, we abort the whole thing. If we want to
|
||||||
|
# ignore errors from any of these, just make sure not to ignore
|
||||||
|
# errors from the above "$doit $cpprog $src $dsttmp" command.
|
||||||
|
#
|
||||||
|
{ test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \
|
||||||
|
&& { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \
|
||||||
|
&& { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \
|
||||||
|
&& { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } &&
|
||||||
|
|
||||||
|
# Now rename the file to the real destination.
|
||||||
|
{ $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null \
|
||||||
|
|| {
|
||||||
|
# The rename failed, perhaps because mv can't rename something else
|
||||||
|
# to itself, or perhaps because mv is so ancient that it does not
|
||||||
|
# support -f.
|
||||||
|
|
||||||
|
# Now remove or move aside any old file at destination location.
|
||||||
|
# We try this two ways since rm can't unlink itself on some
|
||||||
|
# systems and the destination file might be busy for other
|
||||||
|
# reasons. In this case, the final cleanup might fail but the new
|
||||||
|
# file should still install successfully.
|
||||||
|
{
|
||||||
|
if test -f "$dst"; then
|
||||||
|
$doit $rmcmd -f "$dst" 2>/dev/null \
|
||||||
|
|| { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null \
|
||||||
|
&& { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }; }\
|
||||||
|
|| {
|
||||||
|
echo "$0: cannot unlink or rename $dst" >&2
|
||||||
|
(exit 1); exit 1
|
||||||
|
}
|
||||||
|
else
|
||||||
|
:
|
||||||
|
fi
|
||||||
|
} &&
|
||||||
|
|
||||||
|
# Now rename the file to the real destination.
|
||||||
|
$doit $mvcmd "$dsttmp" "$dst"
|
||||||
|
}
|
||||||
|
} || exit 1
|
||||||
|
|
||||||
|
trap '' 0
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
# Local variables:
|
||||||
|
# eval: (add-hook 'write-file-hooks 'time-stamp)
|
||||||
|
# time-stamp-start: "scriptversion="
|
||||||
|
# time-stamp-format: "%:y-%02m-%02d.%02H"
|
||||||
|
# time-stamp-end: "$"
|
||||||
|
# End:
|
|
@ -1,5 +1,6 @@
|
||||||
.deps
|
.deps
|
||||||
.libs
|
.libs
|
||||||
|
Makefile
|
||||||
|
Makefile.in
|
||||||
*.lo
|
*.lo
|
||||||
*.la
|
*.la
|
||||||
libalpm.pc
|
|
148
lib/libalpm/Doxyfile
Normal file
148
lib/libalpm/Doxyfile
Normal file
|
@ -0,0 +1,148 @@
|
||||||
|
# Doxyfile 1.4.5
|
||||||
|
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Project related configuration options
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
PROJECT_NAME = libalpm
|
||||||
|
PROJECT_NUMBER =
|
||||||
|
OUTPUT_DIRECTORY =
|
||||||
|
CREATE_SUBDIRS = NO
|
||||||
|
OUTPUT_LANGUAGE = English
|
||||||
|
USE_WINDOWS_ENCODING = NO
|
||||||
|
BRIEF_MEMBER_DESC = YES
|
||||||
|
REPEAT_BRIEF = YES
|
||||||
|
ABBREVIATE_BRIEF = "The $name class" \
|
||||||
|
"The $name widget" \
|
||||||
|
"The $name file" \
|
||||||
|
is \
|
||||||
|
provides \
|
||||||
|
specifies \
|
||||||
|
contains \
|
||||||
|
represents \
|
||||||
|
a \
|
||||||
|
an \
|
||||||
|
the
|
||||||
|
ALWAYS_DETAILED_SEC = NO
|
||||||
|
INLINE_INHERITED_MEMB = NO
|
||||||
|
FULL_PATH_NAMES = YES
|
||||||
|
STRIP_FROM_PATH =
|
||||||
|
STRIP_FROM_INC_PATH =
|
||||||
|
SHORT_NAMES = NO
|
||||||
|
JAVADOC_AUTOBRIEF = NO
|
||||||
|
MULTILINE_CPP_IS_BRIEF = NO
|
||||||
|
DETAILS_AT_TOP = NO
|
||||||
|
INHERIT_DOCS = YES
|
||||||
|
SEPARATE_MEMBER_PAGES = NO
|
||||||
|
TAB_SIZE = 8
|
||||||
|
ALIASES =
|
||||||
|
OPTIMIZE_OUTPUT_FOR_C = YES
|
||||||
|
OPTIMIZE_OUTPUT_JAVA = NO
|
||||||
|
BUILTIN_STL_SUPPORT = NO
|
||||||
|
DISTRIBUTE_GROUP_DOC = NO
|
||||||
|
SUBGROUPING = YES
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Build related configuration options
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
EXTRACT_ALL = NO
|
||||||
|
EXTRACT_PRIVATE = NO
|
||||||
|
EXTRACT_STATIC = NO
|
||||||
|
EXTRACT_LOCAL_CLASSES = YES
|
||||||
|
EXTRACT_LOCAL_METHODS = NO
|
||||||
|
HIDE_UNDOC_MEMBERS = YES
|
||||||
|
HIDE_UNDOC_CLASSES = YES
|
||||||
|
HIDE_FRIEND_COMPOUNDS = NO
|
||||||
|
HIDE_IN_BODY_DOCS = NO
|
||||||
|
INTERNAL_DOCS = NO
|
||||||
|
CASE_SENSE_NAMES = YES
|
||||||
|
HIDE_SCOPE_NAMES = NO
|
||||||
|
SHOW_INCLUDE_FILES = YES
|
||||||
|
INLINE_INFO = YES
|
||||||
|
SORT_MEMBER_DOCS = YES
|
||||||
|
SORT_BRIEF_DOCS = NO
|
||||||
|
SORT_BY_SCOPE_NAME = NO
|
||||||
|
GENERATE_TODOLIST = YES
|
||||||
|
GENERATE_TESTLIST = YES
|
||||||
|
GENERATE_BUGLIST = YES
|
||||||
|
GENERATE_DEPRECATEDLIST= YES
|
||||||
|
ENABLED_SECTIONS =
|
||||||
|
MAX_INITIALIZER_LINES = 30
|
||||||
|
SHOW_USED_FILES = YES
|
||||||
|
SHOW_DIRECTORIES = YES
|
||||||
|
FILE_VERSION_FILTER =
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to warning and progress messages
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
QUIET = NO
|
||||||
|
WARNINGS = YES
|
||||||
|
WARN_IF_UNDOCUMENTED = YES
|
||||||
|
WARN_IF_DOC_ERROR = YES
|
||||||
|
WARN_NO_PARAMDOC = NO
|
||||||
|
WARN_FORMAT = "$file:$line: $text"
|
||||||
|
WARN_LOGFILE =
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the input files
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
INPUT =
|
||||||
|
FILE_PATTERNS = *.c
|
||||||
|
RECURSIVE = NO
|
||||||
|
EXCLUDE =
|
||||||
|
EXCLUDE_SYMLINKS = NO
|
||||||
|
EXCLUDE_PATTERNS =
|
||||||
|
EXAMPLE_PATH =
|
||||||
|
EXAMPLE_PATTERNS = *
|
||||||
|
EXAMPLE_RECURSIVE = NO
|
||||||
|
IMAGE_PATH =
|
||||||
|
INPUT_FILTER =
|
||||||
|
FILTER_PATTERNS =
|
||||||
|
FILTER_SOURCE_FILES = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to source browsing
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
SOURCE_BROWSER = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the alphabetical class index
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
ALPHABETICAL_INDEX = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the HTML output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_HTML = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the LaTeX output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_LATEX = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the RTF output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_RTF = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the man page output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_MAN = YES
|
||||||
|
MAN_OUTPUT = ../../doc
|
||||||
|
MAN_EXTENSION = .3
|
||||||
|
MAN_LINKS = YES
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the XML output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_XML = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the Perl module output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_PERLMOD = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Configuration options related to the preprocessor
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
ENABLE_PREPROCESSING = YES
|
||||||
|
MACRO_EXPANSION = NO
|
||||||
|
EXPAND_ONLY_PREDEF = NO
|
||||||
|
SEARCH_INCLUDES = YES
|
||||||
|
INCLUDE_PATH =
|
||||||
|
INCLUDE_FILE_PATTERNS =
|
||||||
|
PREDEFINED =
|
||||||
|
EXPAND_AS_DEFINED =
|
||||||
|
SKIP_FUNCTION_MACROS = YES
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Configuration options related to the dot tool
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
CLASS_DIAGRAMS = NO
|
50
lib/libalpm/Makefile.am
Normal file
50
lib/libalpm/Makefile.am
Normal file
|
@ -0,0 +1,50 @@
|
||||||
|
AUTOMAKE_OPTIONS = gnu
|
||||||
|
|
||||||
|
SUBDIRS = po
|
||||||
|
|
||||||
|
lib_LTLIBRARIES = libalpm.la
|
||||||
|
include_HEADERS = alpm_list.h alpm.h
|
||||||
|
|
||||||
|
localedir = $(datadir)/locale
|
||||||
|
DEFS = -DLOCALEDIR=\"$(localedir)\" @DEFS@
|
||||||
|
|
||||||
|
AM_CFLAGS = -fvisibility=hidden -pedantic -D_GNU_SOURCE
|
||||||
|
|
||||||
|
EXTRA_DIST = Doxyfile
|
||||||
|
|
||||||
|
libalpm_la_SOURCES = \
|
||||||
|
add.h add.c \
|
||||||
|
alpm.h alpm.c \
|
||||||
|
alpm_list.h alpm_list.c \
|
||||||
|
backup.h backup.c \
|
||||||
|
be_files.c \
|
||||||
|
cache.h cache.c \
|
||||||
|
conflict.h conflict.c \
|
||||||
|
db.h db.c \
|
||||||
|
deps.h deps.c \
|
||||||
|
error.h error.c \
|
||||||
|
group.h group.c \
|
||||||
|
handle.h handle.c \
|
||||||
|
log.h log.c \
|
||||||
|
md5.h md5.c \
|
||||||
|
md5driver.c \
|
||||||
|
package.h package.c \
|
||||||
|
provide.h provide.c \
|
||||||
|
remove.h remove.c \
|
||||||
|
server.h server.c \
|
||||||
|
sha1.h sha1.c \
|
||||||
|
sync.h sync.c \
|
||||||
|
trans.h trans.c \
|
||||||
|
util.h util.c \
|
||||||
|
versioncmp.h versioncmp.c
|
||||||
|
|
||||||
|
libalpm_la_LDFLAGS = -no-undefined -version-info $(LIB_VERSION_INFO)
|
||||||
|
libalpm_la_LIBADD = -larchive -ldownload -lm
|
||||||
|
|
||||||
|
if HAS_DOXYGEN
|
||||||
|
all: doxygen.in
|
||||||
|
|
||||||
|
doxygen.in:
|
||||||
|
doxygen $(srcdir)/Doxyfile
|
||||||
|
|
||||||
|
endif
|
1378
lib/libalpm/add.c
1378
lib/libalpm/add.c
File diff suppressed because it is too large
Load diff
|
@ -1,7 +1,6 @@
|
||||||
/*
|
/*
|
||||||
* add.h
|
* add.h
|
||||||
*
|
*
|
||||||
* Copyright (c) 2006-2025 Pacman Development Team <pacman-dev@lists.archlinux.org>
|
|
||||||
* Copyright (c) 2002-2006 by Judd Vinet <jvinet@zeroflux.org>
|
* Copyright (c) 2002-2006 by Judd Vinet <jvinet@zeroflux.org>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
@ -15,15 +14,21 @@
|
||||||
* GNU General Public License for more details.
|
* GNU General Public License for more details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
|
||||||
|
* USA.
|
||||||
*/
|
*/
|
||||||
#ifndef ALPM_ADD_H
|
#ifndef _ALPM_ADD_H
|
||||||
#define ALPM_ADD_H
|
#define _ALPM_ADD_H
|
||||||
|
|
||||||
#include "db.h"
|
#include "db.h"
|
||||||
#include "alpm_list.h"
|
#include "alpm_list.h"
|
||||||
#include "trans.h"
|
#include "trans.h"
|
||||||
|
|
||||||
int _alpm_upgrade_packages(alpm_handle_t *handle);
|
int _alpm_add_loadtarget(pmtrans_t *trans, pmdb_t *db, char *name);
|
||||||
|
int _alpm_add_prepare(pmtrans_t *trans, pmdb_t *db, alpm_list_t **data);
|
||||||
|
int _alpm_add_commit(pmtrans_t *trans, pmdb_t *db);
|
||||||
|
|
||||||
#endif /* ALPM_ADD_H */
|
#endif /* _ALPM_ADD_H */
|
||||||
|
|
||||||
|
/* vim: set ts=2 sw=2 noet: */
|
||||||
|
|
1244
lib/libalpm/alpm.c
1244
lib/libalpm/alpm.c
File diff suppressed because it is too large
Load diff
3304
lib/libalpm/alpm.h
3304
lib/libalpm/alpm.h
File diff suppressed because it is too large
Load diff
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue