summaryrefslogtreecommitdiffstats
path: root/scripts/makepkg.sh.in
AgeCommit message (Collapse)AuthorFilesLines
2011-07-18makepkg: fix issue with filenames with spaces and noextractAllan McRae1-1/+1
Specifying a filename with spaces in a PKGBUILDs noextract array fails due to a lack of quoting. Fixes FS#25100. Reported-by: Thomas Weißschuh <thomas_weissschuh@lavabit.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-07-18makepkg: only test for writable PKGDEST when needed.Rogutės Sparnuotos1-1/+1
There is no need for a writable PKGDEST when using the --nobuild or --geninteg flags. Allan: added --geninteg Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-07-14makepkg: remove unused -C option from option listDave Reisner1-1/+1
We nuke it from the completion file as well along with its longopt. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-07-14makepkg: skip devel_check when reading from a pipeDave Reisner1-2/+2
Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-07-14makepkg: Remove pre-optimization from in_array()DJ Mills1-1/+0
The '[[ -z' test in in_array() is redundant, so remove it. Signed-off-by: DJ Mills <danielmills1@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
2011-07-14makepkg: Remove OPT_TEMP hack in parse_options callDJ Mills1-3/+1
Instead of hacking around the error trap, simply do an explicit test for failure. Signed-off-by: DJ Mills <danielmills1@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
2011-07-14Add 'compress' compression format as an available optionDan McGee1-0/+2
This adds the '.tar.Z' option to both repo-add and makepkg for no other reason than "why not", and because bsdtar supports it natively with the '-Z' flag. Also update the documentation accordingly. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-30fix vim syntax highlighting of .sh filesFlorian Pritz1-1/+1
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-30Merge remote-tracking branch 'dave/makepkg'Dan McGee1-5/+3
2011-06-30makepkg: only source user override if using default config fileDan McGee1-2/+3
Otherwise there is no way to easily test or run with a standalone config file without outside interference. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-30makepkg: fix typo (missing quotes)Rémy Oudompheng1-2/+2
Signed-off-by: Rémy Oudompheng <remy@archlinux.org> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-30makepkg: fix removing symbolic linkAllan McRae1-1/+1
The path was not being stripped from $file before prefixing with $srcdir resulting in the attempted removal of a very weird filename. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-29makepkg: simplify SIGNPKG checkDave Reisner1-3/+1
Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-29makepkg: fix vim syntax highlightingDave Reisner1-1/+1
Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-29makepkg: remove unneeded echoDave Reisner1-1/+1
Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-28Revert "Merge branch 'master' of git://projects.archlinux.org/pacman"Dan McGee1-1/+1
This reverts the merge of 2d32a9a3a348d25d6d0f3d12752399bf7fdf6570, which reverts the commit 8581694ceb63f4ed2854206b38574599c3d9df28. Thanks Dave for the dirty branch and non-clean rebase! :) Dave broke it.
2011-06-27Merge remote-tracking branch 'dave/repo-add'Dan McGee1-1/+1
2011-06-27Remove -f option from ln for POSIX complianceEric Bélanger1-6/+12
Fixes FS#24893. Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-27makepkg: Add warning if VCS tool is not present when determining latest VCS ↵Eric Bélanger1-7/+25
revision Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-27makepkg: Move check for sudo into check_software functionEric Bélanger1-7/+7
Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Merge branch 'master' of git://projects.archlinux.org/pacmanDave Reisner1-36/+2
* 'master' of git://projects.archlinux.org/pacman: pactree: carry a list of databases for dep resolution makepkg: Remove a lone quotation mark makepkg: remove the cleancache option Don't require a transaction for sync DB updates Move locking functions to handle Add a 'valid' flag to the database object Move database 'version' check to registration time Do database signature checking at load time
2011-06-24makepkg: Remove a lone quotation markWieland Hoffmann1-1/+1
Allan broke it in 4bdb868. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24makepkg: remove the cleancache optionAllan McRae1-35/+1
This is a fairly useless feature given all it does is an "rm" on a directory. It is also unlikely that you would want to remove the entire SRCDEST anyway, but rather just the old files. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24makepkg: fix incorrect parenthesis in gettext callDave Reisner1-1/+1
allan broke it in 4bdb868a. Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-24makepkg: clean-up of output messagesAllan McRae1-51/+51
There was a lot of inconsistency in how strings that should not be translated (program names, option flags, PKGBUILD directives, etc) were handled. This patch moves them all outside the gettext invocation for consistency and to prevent accidental translation. Note that some of these may need reverted if they cause difficulties in translation due to gettext usage in bash not taking positional parameters for arguments. A quick survey of current translations indicates that this issue will be rare. Also, we should be able to catch these before a full string freeze given we are going to probably need a "developer preview" release before the next release series. Signed-off-by: Allan McRae <allan@archlinux.org>
2011-06-24Merge branch 'po-split'Dan McGee1-1/+1
2011-06-24po/: split into scripts/po/ and src/pacman/po/Dan McGee1-1/+1
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-24makepkg: Added checks in check_software for distcc, ccache, strip and gzipEric Bélanger1-0/+32
Dan: slightly shorten some of the messages. Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24makepkg: remove distcc/makeflags option interactionDan McGee1-3/+0
Way back in c94bfbaba when refactoring makepkg options handling, I added these lines to unset MAKEFLAGS if '!distcc' was set in a PKGBUILD (not taking into account makepkg.conf settings). This was an attempt to say "if it is broken in distcc, it is probably broken even more". However, this is silly as one should be using '!makeflags' as well. Remove the linkage. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: fix 'check_sofware' typoDan McGee1-1/+1
Allan broke it! Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: add software check functionAllan McRae1-16/+43
Add a function that checks for the software needed by makepkg to process a PKGBUILD with the requested options. This allows makepkg to bail early in the packaging process. Many other checks can be added to this function... Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: move comment into correct placeAllan McRae1-4/+5
Oops... Introduced by commit d21f6ca4. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: adjust libprovides/depends messagesAllan McRae1-2/+2
Contractions are less clear for non-native speakers so should be avoided (and cause syntax highlighting issues). Also, the 'provides' and 'depends' strings are not to be translated. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: allow specifying alternative build directoryAllan McRae1-2/+16
Add a BUILDDIR variable (which can be overridden in the environment) to specify an alternative location for building the package. This is useful for people who want to build on a different filesystem for improved performance (e.g. tmpfs). Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: Add UPX compression supportAllan McRae1-1/+12
This patch enables the automatic compression of executable binaries using UPX when the 'upx' options is specified in makepkg.conf or the PKGBUILD. Additional arguments can be passed to UPX by specifying the UPXFLAGS variable. Original-patch-by: Bryce Gibson <bryce@gibson-consulting.com.au> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-20makepkg: fix broken syntax (double $)Florian Pritz1-1/+1
Signed-off-by: Florian Pritz <bluewind@xinu.at> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-15makepkg: create source package inside fakerootAllan McRae1-25/+40
Create source package files inside the fakeroot environment to ensure reasonable ownership of files within the archive. Fixes FS#24330. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-15makepkg: move option parsing code to separate fileAllan McRae1-87/+1
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-15makepkg: reword purge messageAllan McRae1-1/+1
Clarfiy that it is unwanted files are being removed rather than "other" files (whatever they are...). Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-14Merge remote-tracking branch 'florian/sodeps'Dan McGee1-2/+85
2011-06-07Merge branch 'maint'Dan McGee1-1/+1
Conflicts: lib/libalpm/add.c
2011-06-07makepkg: fix creation of source package with -pAllan McRae1-1/+1
When creating a source package using an non-local buildscript via the -p option, the inclusion of changelog and install files would fail. Fixes FS#24567. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-01makepkg: add libdepends supportFlorian Pritz1-1/+40
The user adds libaries to the depends array without a version. These must end with .so. Example: depends=(glibc libc.so) find_libdepends() looks for ELF files (not symlinks because these could point outside of pkgdir) in $pkgdir, extracts the library sonames the binary links to and outputs depends seperated by spaces. This list contains all libraries needed by the package. Example: libfoo.so=3-64 write_pkginfo() only keeps .so depends with version information and warns the user about unneded ones. Support-by: Thomas Bächler <thomas@archlinux.org> Support-by: Christoph Schied <Christoph.Schied@uni-ulm.de> Signed-off-by: Florian Pritz <bluewind@server-speed.net>
2011-05-27makepkg: add libprovides supportFlorian Pritz1-1/+45
The user adds libaries to the provides array without a version. These must end with .so. Example: provides=(readline libreadline.so) find_libprovides() looks for .so files (not symlinks because these could point outside of pkgdir) in $pkgdir, extracts the library soname (ld links the binary to this name) and outputs provides seperated by spaces. This list contains all libraries provided by the package. Example: libfoo.so=3-64 write_pkginfo() only keeps .so provides with version information and warns the user about unneded ones. Support-by: Thomas Bächler <thomas@archlinux.org> Support-by: Christoph Schied <Christoph.Schied@uni-ulm.de> Signed-off-by: Florian Pritz <bluewind@server-speed.net>
2011-05-04Merge branch 'maint'Dan McGee1-1/+1
2011-05-02makepkg: quote variable that may contain spacesAllan McRae1-1/+1
Prevents failures when $PKGDEST contains spaces (FS#24002) Patch-by: Sebastien Duthil Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-04-21makepkg, pacman-key: unify help message with other scriptsIvan Kanakarakis1-1/+1
The help message changed to match the one rankmirrors script has. It's clearer as to what the --help switch does. Signed-off-by: Ivan Kanakarakis <ivan.kanak@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-04-21Add configure option to specify package signing keyAllan McRae1-6/+8
Add the "GPGKEY" option to makepkg.conf for specifying signing packages with the non-default key from the keyring. Is overridded by makepkg's --key option. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-04-16Merge branch 'maint'Dan McGee1-1/+1
Conflicts: lib/libalpm/alpm.h lib/libalpm/trans.c Signed-off-by: Dan McGee <dan@archlinux.org>
2011-04-13makepkg.sh.in: fix a GNU-ism in su invocationRémy Oudompheng1-1/+1
GNU su supports the -c option to specify a command to execute. However, other flavours of su may have a different interpretation of the '-c' flag (e.g. FreeBSD and OpenBSD). The behaviour is correct when '-c' follows an explicit username. Signed-off-by: Rémy Oudompheng <remy@archlinux.org> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>