summaryrefslogtreecommitdiff
path: root/scripts/makepkg.sh.in
Commit message (Collapse)AuthorAge
* makepkg: fix overzealous PGP signature file matchingDan McGee2011-09-01
| | | | | | | | The regex wasn't rooted at the end of the filename, nor was it matching a period/dot before the file extension. The end result was this matched a file named '07_all_sig.patch' which is totally broken. Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: fix sanity checking in versioningDave Reisner2011-09-01
| | | | | | | | Read the entire variable, respecting escapes, which are necessary to retain for the successive eval. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: read filenames in a while loopDave Reisner2011-09-01
| | | | | | | | Further improvments on 2ca27ab which will allow the changelog and install script files to contain whitespace. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: fix breakage in eval'ing quoted stringsDave Reisner2011-09-01
| | | | | | | Broken in 2ca27a by me, trying to fix another problem. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: quote re-evaluation of simple varsDave Reisner2011-08-19
| | | | | | | | | | | | | | This is a safety measure to prevent simple code injection. $ i="foo bar" $ eval i="$i" bash: bar: command not found $ eval i=\"$i\" $ echo "|$i|" |foo bar| Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: deal with variable substitution when checking sanityAllan McRae2011-08-18
| | | | | | | | | | | If any of pkgver, pkgrel or epoch contained a variable substitution, then it needed to be evaluated before checking its value conformed to the rules. [Dan: add quotes around RHS] Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* Add makepkg -S which is an alias to makepkg --sourceSebastien Luttringer2011-08-18
| | | | | | | | makepkg --source is a often used go make source package like for AUR. Have a -S shortcut will save the world. Signed-off-by: Sebastien Luttringer <seblu@seblu.net> Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix trailing whitespace in whole codebaseDan McGee2011-08-17
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: don't hardcode path to stripDave Reisner2011-08-15
| | | | | Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* Update several translation stringsDan McGee2011-08-08
| | | | | | | * Fix typos/capitalization * Make sure large blocks of text are translated in one unit Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: ignore epoch when undeclaredDave Reisner2011-08-08
| | | | | | | | | | | | | | | In this case, we skip the epoch versioning entirely, as if it were declared as 0. Prevents errors such as: /usr/bin/makepkg: line 244: ((: ! : syntax error: operand expected (error token is " ") ==> Finished making: cower-git :20110808-1 (Mon Aug 8 17:17:27 EDT 2011) Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: refactor checking source integrityAllan McRae2011-07-27
| | | | | | | | | Move the source integrity checking into its own function as the code was duplicated and is now more complicated with the separation of the two checks types. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: more control of skipping integrity checksAllan McRae2011-07-27
| | | | | | | | | Allows the skipping of all integrity checks (checksum and PGP) or either the checksum or PGP checks individually. Original-patch-by: Wieland Hoffman <theminew@googlemail.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: Add support for verifying pgp signaturesWieland Hoffmann2011-07-27
| | | | | | | | | | | | | Many projects provide signature files along with the source code archives. It's good to check these, too, when verifying the integrity of source code archives. Not everybody is using gpg so the verification can be disabled with --skippgpcheck. Additionally, only a warning is displayed when the key that signed the source file is unknown. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: get package version with overridesAllan McRae2011-07-27
| | | | | | | | | | | When epoch, pkgver and/or pkgrel were overridden in a split package function, makepkg failed hard finding the real version for checking if packages were already built or trying to install packages. Fix the get_full_version function to deal with overrides and return the actual package version. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: allow epoch to be overriddenAllan McRae2011-07-27
| | | | | | | | We can override pkgver and pkgrel so it is only logical to add epoch to that list Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: check arch overrides for required architectureAllan McRae2011-07-27
| | | | | | | | Check any overrides of the "arch" variable contain the required architecture. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: check overrides for pkgrel and pkgverAllan McRae2011-07-27
| | | | | | | | Enforce syntax checking for pkgrel and pkgver overrides in package functions. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: pkgver and pkgrel can not have whitespaceAllan McRae2011-07-27
| | | | | | | There is always someone who tries to break things (cough *Dave* cough...) Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* Merge branch 'maint'Dan McGee2011-07-18
|\
| * makepkg: fix issue with filenames with spaces and noextractAllan McRae2011-07-18
| | | | | | | | | | | | | | | | | | | | | | 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>
* | makepkg: only test for writable PKGDEST when needed.Rogutės Sparnuotos2011-07-18
| | | | | | | | | | | | | | | | | | 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>
* | makepkg: remove unused -C option from option listDave Reisner2011-07-14
| | | | | | | | | | | | | | 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>
* | makepkg: skip devel_check when reading from a pipeDave Reisner2011-07-14
| | | | | | | | | | Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* | makepkg: Remove pre-optimization from in_array()DJ Mills2011-07-14
| | | | | | | | | | | | | | 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>
* | makepkg: Remove OPT_TEMP hack in parse_options callDJ Mills2011-07-14
| | | | | | | | | | | | | | | | 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>
* | Add 'compress' compression format as an available optionDan McGee2011-07-14
| | | | | | | | | | | | | | | | 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>
* | fix vim syntax highlighting of .sh filesFlorian Pritz2011-06-30
| | | | | | | | | | | | | | | | | | | | 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>
* | Merge remote-tracking branch 'dave/makepkg'Dan McGee2011-06-30
|\ \
| * | makepkg: simplify SIGNPKG checkDave Reisner2011-06-28
| | | | | | | | | | | | Signed-off-by: Dave Reisner <d@falconindy.com>
| * | makepkg: fix vim syntax highlightingDave Reisner2011-06-28
| | | | | | | | | | | | Signed-off-by: Dave Reisner <d@falconindy.com>
| * | makepkg: remove unneeded echoDave Reisner2011-06-28
| | | | | | | | | | | | Signed-off-by: Dave Reisner <d@falconindy.com>
* | | makepkg: only source user override if using default config fileDan McGee2011-06-30
| | | | | | | | | | | | | | | | | | | | | 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>
* | | makepkg: fix typo (missing quotes)Rémy Oudompheng2011-06-30
| | | | | | | | | | | | | | | | | | 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>
* | | makepkg: fix removing symbolic linkAllan McRae2011-06-30
|/ / | | | | | | | | | | | | | | | | 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>
* | Revert "Merge branch 'master' of git://projects.archlinux.org/pacman"Dan McGee2011-06-27
| | | | | | | | | | | | | | This reverts the merge of 2d32a9a3a348d25d6d0f3d12752399bf7fdf6570, which reverts the commit 8581694ceb63f4ed2854206b38574599c3d9df28. Thanks Dave for the dirty branch and non-clean rebase! :) Dave broke it.
* | Merge remote-tracking branch 'dave/repo-add'Dan McGee2011-06-27
|\ \
| * \ Merge branch 'master' of git://projects.archlinux.org/pacmanDave Reisner2011-06-24
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * '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
| * | | makepkg: fix incorrect parenthesis in gettext callDave Reisner2011-06-24
| | | | | | | | | | | | | | | | | | | | | | | | allan broke it in 4bdb868a. Signed-off-by: Dave Reisner <d@falconindy.com>
* | | | Remove -f option from ln for POSIX complianceEric Bélanger2011-06-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | | | makepkg: Add warning if VCS tool is not present when determining latest VCS ↵Eric Bélanger2011-06-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | | | makepkg: Move check for sudo into check_software functionEric Bélanger2011-06-27
| |/ / |/| | | | | | | | | | | | | | 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>
* | | makepkg: Remove a lone quotation markWieland Hoffmann2011-06-24
| | | | | | | | | | | | | | | | | | | | | Allan broke it in 4bdb868. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* | | makepkg: remove the cleancache optionAllan McRae2011-06-24
|/ / | | | | | | | | | | | | | | | | 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>
* | makepkg: clean-up of output messagesAllan McRae2011-06-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | Merge branch 'po-split'Dan McGee2011-06-23
|\ \
| * | po/: split into scripts/po/ and src/pacman/po/Dan McGee2011-06-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | | makepkg: Added checks in check_software for distcc, ccache, strip and gzipEric Bélanger2011-06-23
| | | | | | | | | | | | | | | | | | | | | Dan: slightly shorten some of the messages. Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
* | | makepkg: remove distcc/makeflags option interactionDan McGee2011-06-23
|/ / | | | | | | | | | | | | | | | | | | | | 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>
* | makepkg: fix 'check_sofware' typoDan McGee2011-06-22
| | | | | | | | | | | | Allan broke it! Signed-off-by: Dan McGee <dan@archlinux.org>