Commit Graph

554 Commits

Author SHA1 Message Date
Allan McRae a991c9a71f Always log builds in makechrootpkg
It is very helpful to always log the build output in makechrootpkg
so pass "-L" as a standard option to makepkg.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:04 +02:00
Dan McGee 022cd3d523 archrelease: call 'svn copy' once for all files
We don't need to invoke svn copy on each file; it accepts multiple
arguments. This cut Allan's time releasing one patch-friendly package
from 5 minutes to 2 minutes.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:04 +02:00
Jan Alexander Steffens (heftig) a790c39c7d makechrootpkg: If chroot is missing, exit instead of usage
I'm not sure why this was handled differently than the other
error conditions.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:04 +02:00
Jan Alexander Steffens (heftig) e66a1f3cd8 makechrootpkg: Add option to explicitly run namcap
Installs namcap if needed, *after* building the package,
contrary to the former way of having to have namcap installed,
e.g. via makedepends.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:03 +02:00
Jan Alexander Steffens (heftig) 7a9f808a0f makechrootpkg: Source PKGBUILD only once
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:03 +02:00
Jan Alexander Steffens (heftig) b9070bf0b8 makechrootpkg: Use nullglob
Use nullglob instead of checking for existence. If the glob doesn't
match any files, it will be removed instead of staying unexpanded.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:03 +02:00
Jan Alexander Steffens (heftig) 1df6799747 makechrootpkg: Always set PKGDEST and SRCDEST
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:03 +02:00
Jan Alexander Steffens (heftig) e41deee5e5 makechrootpkg: Replace $workdir with . ($PWD)
$workdir is never used when we change directory, so it's superfluous.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:03 +02:00
Jan Alexander Steffens (heftig) 004ced2a33 makechrootpkg: Eliminate appname, only used once
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:03 +02:00
Jan Alexander Steffens (heftig) 733668f4cc makechrootpkg: Bashify syntax
No functional change. Eliminates unused variables RUN and FORCE.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:03 +02:00
Lukas Fleischer 21daec135a Makefile: Add a cleanup target
Allows for using `make clean` to remove any output files generated by
make(1).

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:02 +02:00
Lukas Fleischer 46c4def073 Support non-standard install locations
This build system overhaul allows for adding (define-style) macros to
our scripts. All source files are now suffixed with ".in" to clarify
that they might contain unprocessed defines. The Makefile provides a new
rule to preprocess source files and generate proper output scripts.

Also, add a "@pkgdatadir@" define (as used in GNU Autotools) and use it
instead of hardcoded paths to "/usr/share/devtools" everywhere. We
missed this when adding PREFIX support to the build system in commit
35fc83ce7d.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2011-10-07 21:53:02 +02:00
Lukas Fleischer 142b032212 zsh_completion: Fix package completion
Make use of _devtools_completions_all_packages() instead of using
_devtools_completions_installed_packages(). The latter was removed
during an earlier review of the patch adding ZSH completion (now
6350ec04 in master) but we forgot to change two references.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-29 13:59:55 +02:00
Lukas Fleischer 5f8458f197 commitpkg: Avoid unnecessary use of basename(1)
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-29 13:58:50 +02:00
Lukas Fleischer 50c311c261 archbuild: Avoid unnecessary use of basename(1)
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-29 13:58:49 +02:00
Lukas Fleischer ef10f6c799 archbuild: Proper quoting, use double brackets
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-29 13:58:49 +02:00
Lukas Fleischer d70918d18a archbuild: Use array for base packages
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-29 13:58:49 +02:00
Pierre Schmitz 6da47a8f6a prepare release 2011-08-25 21:39:49 +02:00
Lukas Fleischer 6350ec0461 Add ZSH completion
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 19:26:12 +02:00
Lukas Fleischer 3da3a5486f checkpkg: Use a pipe to sort package lists
No need to do this after we already wrote the package list to a file.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:22:13 +02:00
Lukas Fleischer 7020d2351b checkpkg: Use read builtin to get new ".so" files
The read shell builtin is the proper way to read single lines. Also,
simplify grep(1) and awk(1) invocations and use a single awk(1)
expression, that supports extracting file names with spaces, instead.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:21:24 +02:00
Lukas Fleischer 7952d6fbfc checkpkg: Avoid unnecessary use of grep(1)/basename(1)
Use parameter expansion instead of invoking external binaries here.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:20:41 +02:00
Lukas Fleischer 3c175e98bd checkpkg: Avoid unnecessary use of sed(1) and cut(1)
We already use `pacman -Sddp` here which should always only return a
single package URL for regular packages. No need to extract the first
field of the last line. Also, specify "--print-format '%l'" explicitly
to make this consistent even if pacman(8)'s default value changes some
day.

Use bash parameter expansion instead of sed(1) to extract the file name
from the URL.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:20:08 +02:00
Lukas Fleischer ddb08cb9a1 checkpkg: Proper quoting, use double brackets
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:18:36 +02:00
Lukas Fleischer 88a929cfc0 archrelease: Fix behaviour with non-standard trunk name
Do not hardcode the name of the package trunk directory and accept
varying directory names, such as "gnome-unstable". Regression introduced
in 8384ad849d.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:17:19 +02:00
Lukas Fleischer c24209028a archrelease: Copy new files from trunk
Currently, files that have just been added to trunk are not copied to
the repositories when invoking archrelease, as `svn ls` does not list
them if we don't `svn update` explicitly before. Use `svn ls -r HEAD` to
include everything from current HEAD. Fixes FS#25680.

Reported-by: Eric Bélanger <snowmaniscool@gmail.com>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:16:26 +02:00
Lukas Fleischer 61010062ff commitpkg: Release to all repositories at once
Make use of archrelease's multi-tag capability invoke it once instead of
re-launching it for for each individual tag.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:14:33 +02:00
Lukas Fleischer 6ef4d5f30b archrelease: Accept multiple tags
This allows for releasing to multiple repositories with a single commit:

----
$ archrelease community-{i686,x86_64}
copying trunk to community-i686...done
copying trunk to community-x86_64...done
releasing package...done
----

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:13:45 +02:00
Lukas Fleischer 40ddf4d44f archrelease: Check for subdirectories early
Ensure we do not mess with version control if there are any
subdirectories in the package trunk.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:10:30 +02:00
Lukas Fleischer b445920d55 archrelease: Remove redundant directory check
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 11:09:01 +02:00
Lukas Fleischer 7887d9bb47 archco: Fix usage message
Point out that we allow passing more than two packages here.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-25 10:59:00 +02:00
Dave Reisner 35573fe147 archrelease: declare known_files as an array
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-18 10:11:27 +02:00
Dave Reisner 5688152f41 archrelease: use bashier syntax
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-18 10:11:27 +02:00
Dave Reisner e1312ec493 archrelease: call svn rm only once
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-18 10:11:27 +02:00
Dave Reisner e652dc8085 commitpkg: use getopts to parse options
Signed-off-by: Dave Reisner <d@falconindy.com>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-18 10:11:27 +02:00
Dave Reisner ba4f28cc43 commitpkg: declare rsyncopts as an array
Signed-off-by: Dave Reisner <d@falconindy.com>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-18 10:11:27 +02:00
Lukas Fleischer dc7b96e917 commitpkg: Fix leading whitespace in commit messages
Commit c51cc8d365 erroneously introduced a
tab character that is prepended to the body of each commit message. Fix
this by using C-style newline escape sequences which will avoid further
whitespace issues caused by re-indentation of code at this point.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-15 17:01:31 +02:00
Pierre Schmitz cb25d50913 prepare release 2011-08-14 23:31:35 +02:00
Pierre Schmitz c51cc8d365 Only commit if needed 2011-08-14 21:30:08 +02:00
Pierre Schmitz e64c1d33eb prepare release 2011-08-14 14:12:54 +02:00
Pierre Schmitz 19f3a868f4 update makepkg.conf from pacman 3.5.4-4 2011-08-14 14:12:34 +02:00
Pierre Schmitz f1ee5208ed supress svn verbose output 2011-08-13 23:02:45 +02:00
Pierre Schmitz b97b245d52 prepare release 2011-08-13 22:58:08 +02:00
Lukas Fleischer ee970f0bde commitpkg: Provide a commit message template
Generate a message template when omitting the commit message (includes
the same subject line that is used if a commit message is specified).

Also, use two newlines to separate the subject line from the message
body as it looks much clearer that way.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-13 20:33:44 +02:00
Lukas Fleischer 35fc83ce7d Makefile: Add PREFIX support
Default to "/usr/local" which should be used if you want to build
devtools from sources and install without using a package manager.

Use `make PREFIX=/usr install` to install to "/usr" instead.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-13 20:31:22 +02:00
Lukas Fleischer 51b5d69cfc archrelease: Fix removal of repository content
Fix the `svn rm` invocation when releasing to a repository that already
contains some files. `svn ls` only returns basenames, so we need to
prepend the path here.

Regression introduced in 8384ad849d.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-13 20:20:21 +02:00
Lukas Fleischer 30bcca88d3 commitpkg: Use positive patterns in SVN checks
In addition to what we had before, this will also detect:

* Non-existent files.
* Files that are missing or scheduled for deletion.
* Ignored files.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-13 20:18:35 +02:00
Lukas Fleischer 25aae4ecfe commitpkg: Avoid unnecessary use of grep(1)
Use bash patterns instead of using grep(1) to check if a source file
contains the string "://".

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-13 20:18:11 +02:00
Lukas Fleischer c8ba49c6a1 commitpkg: Proper quoting in version control checks
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
2011-08-13 20:15:19 +02:00
Pierre Schmitz e63c5f26a2 Remove communityco on uninstall 2011-08-13 20:11:34 +02:00