Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/scripts/makepkg.sh.in
AgeCommit message (Collapse)Author
2017-05-08libmakepkg: look for architecture-specific hashes in get_integlistJack O'Connor
`makepkg -g` looks for existing checksums in the PKGBUILD file, so that it can generate new sums of the same type. Previously it only checked variables of the form "sha256sums", and not "sha256sums_x86_64". That meant it would always fall back to MD5 for packages with only architecture-specific sources. This change makes it look at architecture-specific checksums too to determine the type. Signed-off-by: Jack O'Connor <oconnor663@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org> (cherry picked from commit 56de155296a57fb3fcd8ae64aed00fd18fe2f22e) [andrew@archlinux.org: patch adapted to makepkg.sh.in]
2017-05-08makepkg: ignore the architecture for --printsrcinfoAlastair Hughes
Signed-off-by: Alastair Hughes <hobbitalastair@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org> (cherry picked from commit 87082e3f44c4f92c63d881db38a0fff0565fc9bc)
2016-02-23makepkg: do not run prepare() with --noextractEvangelos Foutras
This is partial revert of 8454daa7feef (makepkg: run pkgver() and prepare() with --noextract). Reasoning for the reversion (copied from FS#43498): Running prepare() when --noextract is used no longer allows running 'makepkg -o && makepkg -e' with any PKGBUILD that applies patches in prepare(). [1] Sure there's --noprepare which restores the old behavior, but that's a lot of extra typing for what I believe is a much more common use of --noextract. For OP's use case of doing git bisects, you can specify the commit in the source array and thus skip --noextract since makepkg will checkout the correct commit each time. [1] I often extract the sources using 'makepkg -o', manually edit some source files, and then use 'makepkg -e' to package it (while possibly repeating the edit/package steps). Signed-off-by: Allan McRae <allan@archlinux.org>
2016-02-21only include .SRCINFO comments in source tarballDominik Fischer
This avoids introducing unnecessary changes to the time stamp into package repositories that regularly use --printsrcinfo to update the .SRCINFO file. Signed-off-by: Allan McRae <allan@archlinux.org>
2016-02-20makepkg: remove pkg from OPT_LONG arrayAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2016-02-20Revert "makepkg: Empty/create only $pkgdir's relevant to current PKGBUILD"Allan McRae
This reverts commit f9423cfa5d5b9f2041b70676438082faad1cd1ee. This created issue when building packages with debug info multiple times. It could be fixed, but it confirmed my initial opinion that keeping other directories in $pkgdirbase was wrong. Use different BUILDDIRs if you want to build different things from a single PKGBUILD.
2016-02-20Make "makepkg -g" ignore the current architecture.Alastair Hughes
Commit 663c74150ab4ba6d3adc55b0e3f539557a16e352 (makepkg: merge arch dependent variables after PKGBUILD linting) broke "makepkg -g" on a PKGBUILD which did not include the current architecture, by moving the lint_pkgbuild call before GENINTEG was processed. Fix that by setting IGNOREARCH for the "-g" option. Signed-off-by: Allan McRae <allan@archlinux.org>
2016-01-25makepkg: do not run prepare() and pkgver() with --repackageAllan McRae
Bug introduced with commit 8454daa7. Reported-by: Zuyi Hu <hzy068808@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
2016-01-04Update copyright years for 2016Allan McRae
make update-copyright OLD=2015 NEW=2016 Signed-off-by: Allan McRae <allan@archlinux.org>
2015-12-15makepkg: run pkgver() and prepare() with --noextractAllan McRae
Modifications made to the source before running with --noextract may alter the version string returned by pkgver(). Always run this function if present and check build status before proceeding. Fixes FS#46800. Also run prepare() when --noextract is used (unless --noprepare is specified). Signed-off-by: Allan McRae <allan@archlinux.org>
2015-12-06makepkg: record build information in .BUILDINFOAllan McRae
This information can be used to reproduce build conditions, which can then be used to determine if a package builds reproducibly. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-12-06makepkg: add whirlpool to the list of hashing algorithmsLuke
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-11-23makepkg: merge arch dependent variables after PKGBUILD lintingAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-11-23makepkg: remove obsolete commentAllan McRae
Behaviour changed in commit dce82f9d. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-10-28makepkg: fix $pkgname element duplicationBenjamin Yates
run_split_packaging did not preserve the $pkgname array correctly, and would create duplicate entries in the list during restore. After restoring the backup (a b c) would become (a b c b c). This probably went unnoticed because during --install, pacman would reconcile the duplicates. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-10-22makepkg: Fix hard-coded debug suffixMohammad Alsaleh
Signed-off-by: Mohammad Alsaleh <CE.Mohammad.AlSaleh@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
2015-10-19makepkg: Set CCACHE_BASEDIR to make paths in $srcdir relativeJan Alexander Steffens (heftig)
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-10-19makepkg: Correctly layer distcc and ccacheJan Alexander Steffens (heftig)
ccache expects further compiler wrappers to be specified via CCACHE_PREFIX. Otherwise, ccache will hash the wrapper executable instead of the real one. Signed-off-by: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
2015-10-19libmakepkg: Add check_buildoption for distcc and ccacheJan Alexander Steffens (heftig)
makepkg used to check OPTIONS too, which could override BUILDENV. Implement a new function that handles these options more like OPTIONS. This also reduces code duplication a bit. Signed-off-by: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
2015-10-19makepkg: separate "sourcefile" into two wordsAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-09-23makepkg: remove ability to build individual packagesAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-09-22makepkg: remove FORCE_VER variableAllan McRae
This variable is no longer in VCS building. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-07-20libmakepkg: move color settings to functionAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-07-20dont remove x bit when marking pkgdir RODave Reisner
f170a94c137d355 potentially causes $pkgdirbase/$pkg to be undeleteable with -R or -C if a previous build was interrupted. We simply can't traverse to this directory, and rm blows up. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-06-20makepkg: Add flag for printing SRCINFO to stdoutJohannes Löthberg
This commit adds a makepkg option to generate and print the SRCINFO file for a PKGBUILD, required by the new AUR, to stdout. AUR 4.0 will use Git instead of source tarballs for uploading packages, so making makepkg capable of printing the SRCINFO would simplify package management, instead of having to extract it from a source tarball. It is also useful for scripting other things, so that instead of having to parse PKGBUILDs, one can make makepkg generate the SRCINFO and then you can parse that instead, which is much simpler and less error-prone. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-19libmakepkg: extract functions for source download and extractionAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-19libmakepkg: extract functions for handling source URLsAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-19libmakepkg: move more functions for extracting information from PKGBIULDsAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-19libmakepkg: extract more utility functionsAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-16libmakepkg: extract get_full_version and get_pkg_archAllan McRae
These functions group in with other functions that extract PKGBUILD information. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-16makepkg: merge validate_pkgver into check_pkgverAllan McRae
The check that pkgver is non-empty done in check_pkgver should also be performed after running the pkgver() function. Merge validate_pkgver into check_pkgver and run check_pkgver after updating pkgver. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-16libmakepkg: extract PKGBUILD linting functionsAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-16libmakepkg: extract in_arrayAllan McRae
2015-05-16libmakepkg: move functions for extracting pkgbuild attributesAllan McRae
Also rename some functions for clarity: funcgrep -> grep_function extract_global_var -> extract_global_variable extract_function_var -> extract_function_variable pkgbuild_get_attribute -> get_pkgbuild_attribute Signed-off-by: Allan McRae <allan@archlinux.org>
2015-05-12makepkg: Empty/create only $pkgdir's relevant to current PKGBUILDDavid Macek
Currently makepkg clears the whole $pkgbasedir which is needless. Moreover, in the obscure case of multiple makepkg runs (with different $pkgname) that share a $pkgdirbase, only $pkgdir's from the last run will remain. Since I consider the contents of $pkgdir an important artifact, this commit restricts the deletion to individual $pkgdir's. When CLEANUP is set, the behavior is unchanged. Discussed in: https://lists.archlinux.org/pipermail/pacman-dev/2015-February/019939.html Signed-off-by: Allan McRae <allan@archlinux.org>
2015-03-26Add makepkg option --packagelistIvy Foster
makepkg --packagelist prints the name of each package that would normally be produced, minus $PKGEXT, and exits. Implements FS#42150 Signed-off-by: Ivy Foster <joyfulgirl@archlinux.us> Signed-off-by: Allan McRae <allan@archlinux.org>
2015-03-26makepkg: write validpgpkeys to .SRCINFOAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-03-26Merge branch 'maint'Allan McRae
2015-03-26Make get_pkg_arch treat arch as an arrayIvy Foster
We use the get_pkg_arch function with the package name parameter in two places: 1) checking if the package is already built 2) installing build packages Currently this failed when a package override for "arch" was an array, despite all our documentation stating that it is indeed an array. This change makes these two places fail if there is package override for arch that is not an array - i.e. of the form arch='i686'. Signed-off-by: Ivy Foster <joyfulgirl@archlinux.us> Signed-off-by: Allan McRae <allan@archlinux.org>
2015-03-26fix source package signing with SRCPKGDIR setChristian Hesse
Signed-off-by: Christian Hesse <mail@eworm.de> Signed-off-by: Allan McRae <allan@archlinux.org>
2015-03-15libmakepkg: move helper functions into tidy/stripAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-20Merge branch 'maint'Allan McRae
2015-02-14Fix Bazaar cloning in makepkg.Renato Silva
There was some manual check to know if the local repository was really a clone of the one specified in PKGBUILD. This check has been removed because it is buggy and not necessary. It is buggy because this check needs to be semantic, not a simple string comparison. For example, I was blocked from building a PKGBUILD because Bazaar was returning two different strings for the same location (for HTTP one was url-encoded while the other was not, and for local paths one was absolute while the other was relative). While this may be a bug in Bazaar, the check is unreliable since the comparison is not semantic (http://foo.com/%2Bplus and http://foo.com/+plus obviously refer to the same location for example). Specially, it is useless because the intention is updating the existing local clone. However, if the local clone is not a real clone of the repository specified in PKGBUILD (which was what this buggy check tried to tell), next step which is a pull operation will fail anyway. This is because bzr pull does not perform merges, it just makes one branch into a mirror of another. There was a reason provided when this manual check was added for Git, but no reason provided for copying such check when Bazaar support was added, see commits below. In fact, Mercurial lacks such manual check. * c926c39b0481ec3db931fff1f86db0c49d78976b * 3b02f80dcb3159a7ab0c673d5eae971ad7504e7f Fixes FS#43448. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-12libmakepkg: move package checking out of tidy_installAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-01makepkg: split package tidying into libmakepkgAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-01makepkg: split PKGBUILD/makepkg.conf option checking to libmakepkgAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-01makepkg: rename other_options to build_optionsAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-01makepkg: split message functions into libmakepkgAllan McRae
This performs all the needed work for libmakepkg to be included in tarballs, installed into the correct place, and read into makepkg. Also change the install root for libmakepkg to an architecture independant location. Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-01add option to optimize PNG images with optipngChristian Hesse
This can decrease package size by optimizing PNG image size. Images are just stored with better compression and/or filter options. The actual image content is not altered. Additionally this can automatically fix broken PNG images which caused some trouble lately. Signed-off-by: Christian Hesse <mail@eworm.de> Signed-off-by: Allan McRae <allan@archlinux.org>
2015-02-01remove globbing for upx and make UPXFLAGS an array variableChristian Hesse
Signed-off-by: Christian Hesse <mail@eworm.de> Signed-off-by: Allan McRae <allan@archlinux.org>