1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-08-13 17:03:46 -04:00
Commit Graph

55 Commits

Author SHA1 Message Date
Allan McRae
7e5dea5d32 pacman-key: add dependency on parse_options to Makefile
Signed-off-by: Allan McRae <allan@archlinux.org>
2011-07-19 10:27:54 +10:00
Florian Pritz
9efd10cd2a fix vim syntax highlighting of .sh files
vim recognises what type of shell script it's dealing with by looking at
the shebang. If detection fails it falls back to sh which doesn't
support some bash features. Adding a normal, possibly broken, shebang
which gets fixed by the Makefile allows vim to detect bash syntax.

Signed-off-by: Florian Pritz <bluewind@xinu.at>
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-30 10:44:45 -05:00
Dan McGee
09c803783d pacman-optimize: use output library
We already use msg() and error() in here, might as well just use the
standard functions. In addition, fix one translated message that would
have printed ERROR twice if anyone ever saw it.

Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-27 13:30:41 -05:00
Dave Reisner
db172b09c5 repo-add: add new command, repo-elephant
_    _
  / \__/ \_____
 /  /  \  \    `\
 )  \''/  (     |\
 `\__)/__/'_\  / `
    //_|_|~|_|_|
    ^""'"' ""'"'

Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-27 14:10:03 -04:00
Dan McGee
a4a7006a13 po/: split into scripts/po/ and src/pacman/po/
This is the first step at separating the pacman message catalog and the
scripts message catalog. Makefiles, configure.ac, and other such files
are adjusted accordingly, as well as renaming files. The TEXTDOMAIN of
scripts is also adjusted.

Note that no actual pot or po files get changed here; these will get
pruned in a future commit so each catalog contains only the necessary
messages.

Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23 22:50:01 -05:00
Allan McRae
06cb713f39 Clean up makefile for script generation
We no longer have any python scripts in our scripts/ directory so
we can simplify the makefile a bit.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-15 09:19:56 -05:00
Allan McRae
4272b37d3d scripts: refactor output formatting functions
Move the common output formatting functions into a separate
library file and import that into each script.  makepkg is
excluded due to its additional color formatting.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-15 09:18:05 -05:00
Allan McRae
6f3a2145b0 makepkg: move option parsing code to separate file
This move the getopt replacement function parse_options out of
makepkg.sh.in and into a separate file.  The code is inserted
into the relevant place in makepkg using m4.

This will allow the reuse of the option parsing code in other
scripts (i.e. pacman-key) while avoiding code duplication.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-15 09:16:38 -05:00
Allan McRae
451cd2c88d Fix bracket type in makefile
Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-09 14:14:46 -05:00
Allan McRae
87072ff639 Fix name of original files in scripts
Our scripts all currently say:

Generated from foo.in; do not edit by hand.

Fix this to say foo.sh.in, which is the actual original file name.

Signed-off-by: Allan McRae <allan@archlinux.org>
2011-06-08 17:36:03 +10:00
Denis A. Altoé Falqueto
ae20f88202 pacman-key: keyring management tool
The script pacman-key will manage pacman's keyring. It imports, exports,
fetches from keyservers, helps in the process of trusting and updates
the trust database.

Signed-off-by: Denis A. Altoé Falqueto <denisfalqueto@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
2011-03-23 01:59:42 -05:00
Xavier Chantry
e277e838d7 Makefile: Use git describe --dirty for GIT VERSION
dirty indicates if the repo has uncommited changes or not when building,
so dont hardcode this info.

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-01-22 10:02:57 -06:00
Allan McRae
d98bacd4ec Add script to update pacman database format
The pacman-db-upgrade script was added to detect old pacman database
formats and upgrade them.

Currently performs the merging of depends files into desc files in
the local database.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-12-12 21:42:41 -06:00
Dan McGee
6eedf06fcc Fix bash shell location check
BASH is defined when you are actually using bash during configure, which
sucks because it ends up being '/bin/sh', messing up all of our scripts.
Change the name of the variable we use in configure, and also ensure we get
a full path to the executable by using AC_PATH_PROGS rather than
AC_CHECK_PROGS. Finally, change the variable name everywhere we use it.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 17:50:54 -05:00
Nezmer
05f0a28932 Use sysconfdir, localstatedir, BASH instead of hardcoded values
This applies to contrib/ files, our scripts, and the documentation.

Dan: fix 'make clean' in contrib/ directory.

Signed-off-by: Nezmer <git@nezmer.info>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-11 20:29:22 -05:00
Allan McRae
68dcabdfbe Remove DBEXT usage
With commit 5dffef78, the repo database always has a symlink
of the form reponame.db.  Use that filename and let libarchive
determine the compression type.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-07-07 07:25:55 -05:00
Allan McRae
0ea52e3a4f makepkg: try standard paths for coreutils du
Attempt to find "du" from coreutils in the standard paths and if
not revert to the version in the users PATH.  Using the full path
prevents issues such as FS#19932, where a different and incompatible
version of du is put earlier in the users path.

Signed-off-by: Allan McRae <allan@archlinux.org>
2010-06-30 08:27:29 -05:00
Xavier Chantry
35bbc96b99 replace rankmirrors by bash clone
This removes python optdepends in pacman package

This bash clone is a courtesy of
Matthew Bruenig <matthewbruenig@gmail.com>

Signed-off-by: Xavier Chantry <shiningxc@gmail.com>
2009-10-11 15:08:06 -05:00
Allan McRae
c27904661e makepkg: make in-place sed portable
Do a sed replacement in-place is not very portable.  On Mac OSX and
BSDs, the syntax is "sed -i ''" where as with GNU sed the command is
"sed -i''" or just "sed -i".  This patch detects which command should
be used during configure.

Credit to Kevin Barry who researched this issue and provided a patch
to work around this using temporary backup files.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2009-04-26 09:22:23 -05:00
Xavier Chantry
9fa18d9a4b Add pkgdelta script to create deltas.
This should obsolete the delta support in makepkg. Having a separate script
should be more flexible.

Example usage:
$ pkgdelta repo/tzdata-2009a-1-x86_64.pkg.tar.gz repo/tzdata-2009b-1-x86_64.pkg.tar.gz
==> Generating delta from version 2009a-1 to version 2009b-1
==> Generated delta : 'repo/tzdata-2009a-1_to_2009b-1-x86_64.delta'

Signed-off-by: Xavier Chantry <shiningxc@gmail.com>
2009-03-15 18:10:15 +01:00
Allan McRae
8f26bb9052 makepkg: move BUILDSCRIPT from makepkg.conf
Commit 4b183bf9 moved makepkg.conf sourcing to after the parsing
of options, breaking the -p option and --help output.  The solution
is to move BUILDSCRIPT out of makepkg.conf.  This patch moves the
definition BUILDSCRIPT back to makepkg itself and adds configure
option to allow easy changing of this value during build time.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2009-01-03 00:13:54 -06:00
Dan McGee
f8b689d48e Merge branch 'maint'
Conflicts:
	lib/libalpm/dload.c
	po/it.po
	scripts/makepkg.sh.in
2009-01-02 22:48:52 -06:00
Dan McGee
cb03817ee8 Small makefile update
Use the proper call for symlink creation

Signed-off-by: Dan McGee <dan@archlinux.org>
2009-01-02 22:46:48 -06:00
Dan McGee
f1f8f0e1c2 Quiet up the make process a bit
When we do our sed edits, we really don't need every command printed out to
the terminal. Now with "make -s", the output is quite palatable.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-10-12 21:36:30 -05:00
Dan McGee
282eeadc68 Factor shell script size command into configure script
Commit 149839c539 introduced a small behavior regression as a drawback
for a better portability. repo-add now includes the approximate size (to the
nearest KB) rather than an exact size due to the switching of the du command
to a more portable form. Instead of sacrificing the exact size, use
configure to help us determine a valid command to acquire our filesize and
place it in the sync database.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-19 23:29:56 -05:00
Xavier Chantry
11695bd0d7 repo-add cleanup.
* change ln -s to ln -sf in the Makefile to prevent a failure when the link
already exists.
* make test_repo_db_file simpler and more natural, move the complexity out
of it.
* remove one $cmd = repo-remove check that wasn't needed

Signed-off-by: Xavier Chantry <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-29 17:37:45 -05:00
Dan McGee
a1dfa8e61f Combine repo-add and repo-remove into one script
They shared about 75% of their code, so there is no real reason we should
maintain them separately. Merge the differences accordingly and add a check
based on the basename of the command used to decide what behavior to follow.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-14 11:31:18 -05:00
Dan McGee
636610432a Allow GIT version to be used in pacman builds
Add a new configure flag, --enable-git-version, that allows the output of
'git describe' to be used in the version string associated with this
package. This could aid in debugging for users that are using a development
version of pacman and we should be able to figure out which cut of code they
are using.

Sample output:
$ pacman --version
Pacman v3.1.4-190-g4cfa-dirty - libalpm v2.3.1

$ makepkg --version
makepkg (pacman) 3.1.4-190-g5861-dirty

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-31 12:06:34 -05:00
Dan McGee
4fad7855fa Remove gensync and updatesync from normal distribution
Move these two scripts into contrib/, and start the process of de-automaking
them by removing the @sysconfdir@ references and the gettext initialization.
The removal of all gettext will soon follow.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-02 14:12:34 -06:00
Dan McGee
6f86f46c96 Remove makeworld from pacman package
This is an Arch-specific tool (although others could find use in it), so
off to the standalone ABS package it goes.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-06 10:42:35 -06:00
Dan McGee
e0e33c329f Remove hardcoded DBEXT value from script
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-06 09:44:28 -06:00
Dan McGee
741fa31603 Remove abs from the pacman repository
abs has always been an Arch Linux specific tool, and although it is used
primarily by pacman and makepkg, it should not be included with a distro-
agnostic tarball. In addition, maintenance of the script would be better
outside of pacman and would allow for more frequent updates.

This also facilitates our move away from a cvsup/csup dependent tool for
syncing PKGBUILDs.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-21 11:05:38 -06:00
Dan McGee
b5f8a44beb Move scripts from *.in to *.sh.in so gettext can determine type
If we move the scripts from *.in to *.sh.in and *.py.in, gettext can pull the
required strings to translate a whole lot easier. Do this.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-07-06 18:43:24 -04:00
Andrew Fyfe
e0afe6e94a Autotool clean up.
* Add vim modeline to Makefile.am and configure.ac
	* Fix white space in Makefile.am and configure.ac
	* Add contrib/wget-xdelta.sh to EXTRA_DIST in Makefile.am

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-04 22:24:29 -04:00
Andrew Fyfe
241832853c scripts/abs.in: Rearrange/Cleanup.
* Rearrange the script.
        * Add gettext support.
        * Clean up usage message.

        * Add PACKAGE_BUGREPORT to substitution in scripts/Makefile.am

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-04 21:59:17 -04:00
Dan McGee
1698022bea Fix pacman-optimize autoconf paths
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-04 17:35:31 -04:00
Andrew Fyfe
6d649473fa FS7319: Add option to disable the inclusion of abs script.
Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-05-31 18:44:00 -04:00
Dan McGee
b6387b954f scripts: do autoconf path replacement right
This should finally get the path replacement in our scripts right. This
is the way the autoconf package itself does it and should not need much
further tweaking.

Threw in a few trailing whitespace corrections from the scripts as well.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-05-30 11:04:49 -04:00
Dan McGee
103c7243a2 Get --help and --version options working on all scripts
Added the autoconf option std-options to the scripts/ directory, which
checks to ensure all programs have both --help and --version options. A
few things needed cleaning up to get this working. To test these types
of options, use the 'make distcheck' target.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-05-29 16:53:15 -04:00
Andrew Fyfe
26c32b017e Remove extra_dist from scripts/Makefile.am
This is automaticly done by autoconf.

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:28 -04:00
Andrew Fyfe
e9e19b7cc6 autotool scripts/updatesync
- move scripts/updatesync -> scripts/updatesync.in
	- add -V --version options to scripts/updatesync.in
	- add autotool commands to generate scripts/updatesync

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:28 -04:00
Andrew Fyfe
48946b624b autotool scripts/repo-remove
- move scripts/repo-remove -> scripts/repo-remove.in
	- add -V --version options to scripts/repo-remove.in
	- add autotool commands to generate scripts/repo-remove

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:27 -04:00
Andrew Fyfe
f6b0869ee5 autotool scripts/repo-add
- move scripts/repo-add -> scripts/repo-add.in
	- add -V --version options to scripts/repo-add.in
	- add autotool commands to generate scripts/repo-add

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:27 -04:00
Andrew Fyfe
95720106bb autotool scripts/pacman-optimize
- move scripts/pacman-optimize -> scripts/pacman-optimize.in
	- add -V --version options to scripts/pacman-optimize.in
	- add autotool commands to generate scripts/pacman-optimize

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:27 -04:00
Andrew Fyfe
ab53ee1e7c autotool scripts/makeworld
- move scripts/makeworld to scripts/makeworld.in
	- add -V --version options to scripts/makeworld.in
	- add autotool commands to generate scripts/makeworld

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:27 -04:00
Andrew Fyfe
a2d018a954 autotool scripts/gensync
- move scripts/gensync -> scripts/gensync.in
	- add -V --version options to scripts/gensync.in
	- add autotool commands to generate scripts/gensync

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:27 -04:00
Andrew Fyfe
2b6bc5bcda autotool scripts/abs
- move scripts/abs -> scripts/abs.in
	- add -V --version options to scripts/abs.in
	- add autotool commands to generate scripts/abs

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:27 -04:00
Andrew Fyfe
c3876845b2 fix existing autotools in scripts/*
- Remove scripts/makepkg on 'make distclean'
	- scripts/makepkg.in: set myver on ./configure

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
2007-05-27 17:16:27 -04:00
Dan McGee
01bb564e70 * TODO updates.
* Makefile.am updates for Aaron's move of re-pacman to contrib.
2007-02-26 15:10:53 +00:00
Dan McGee
332c127109 Big commit here, I'll try to cover all the bases.
* Updated all of the language files, as the POT file was updated. NOTE FOR
  TRANSLATORS, try to base your next contribution off of these, notice how
  some msgids and messages have been wrapped to the next line- it makes it
  easier to read anyway.
* More Makefile.am/configure.ac updates. 'make dist' and 'make distclean' now
  work properly, with only one caveat- the automatic testing in distclean
  doesn't do so hot as it is compiled with a default configure, which includes
  the fakeroot-proof code (which does not cooperate with pactest).
* Added a Makefile.am for the pactest directory.
2007-02-22 21:34:51 +00:00