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
2008-10-31Merge branch 'maint'Dan McGee
2008-10-31makepkg: actually fix passing PKGBUILD from pipeAllan McRae
If PKGBUILD (BUILDSCRIPT) is not found, test for information from a pipe and use that. Fixes FS#9187. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-10-31makepkg: fix bash substitution to work under older versionsDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-10-28makepkg: enable passing PKGBUILD from pipeAllan McRae
Do not attemp to update pkgver/pkgrel when reading a SCM based PKGBUILD from a pipe. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-10-28Merge branch 'maint'Dan McGee
2008-10-28makepkg: fix updating PKGBUILD when building SCM packagesAllan McRae
Fixes a bug and resets pkgrel to 1 when bumping pkgver Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-10-12makepkg: allow compression type to be autodetectedDan McGee
Inspired by commit 7e8f1469c4168875b54956d63884b8583ce99e38, use our given PKGEXT or SRCEXT to determine what method of compression to use on the package we create. If the extension is invalid, this should fall back to creating a non-compressed tar file. Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-26Merge branch 'maint'Dan McGee
2008-08-25makepkg : allow to specify a download filenameXavier Chantry
A source entry can now have the following form, to specify a different filename : "filename::http://path/to/file" Of course, the old syntax is still supported : "http://path/to/file" And as before, in the second case, the filename used is simply "file". This fixes FS#11292, because handling multiple source files with the same name is now possible (just choose a different filename). But it will also allow to deal much more nicely with funny url like this by using a sane filename (and unfortunately, there are quite a few) : http://www.vim.org/scripts/download_script.php?src_id=6992 Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-23makepkg : add --config option for an alternate config file.Xavier Chantry
Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-23makepkg: check all integrity sums found in the PKGBUILDDan McGee
Currently we use the INTEGRITY_CHECK array from makepkg.conf to limit both the integrity sums generated and checked. It doesn't make a whole lot of sense to ignore integrity sums that are present in a PKGBUILD, so this patch will enable checking any that are available, but will only print a warning about missing sums for those types found in INTEGRITY_CHECK. It also adds a slight optimization of checking for openssl- we only need to check once now because we use the same program for all checks. Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-23Treat info pages like man pagesAllan McRae
As far a package building is concerned, info pages need to be treated in the same fashion as man pages in that they both can be compressed. This separates them from other forms of documentation and so it makes sense to make that distinction within makepkg. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-23makepkg : localize the Y/n part of the question.Xavier Chantry
pacman already localizes the yesno stuff, so doing the same in makepkg is more consistent. Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-23makepkg: do insensitive comparisons of checksums.Xavier Chantry
This fixes FS#11283 , which was originally reported on the forums : http://bbs.archlinux.org/viewtopic.php?id=53794 Insensitive comparisons were implicitly made before since md5sum --status was used for checking. Now that we use openssl and compare checksums manually in bash, we lost that feature. This can be easily reintroduced using tr '[A-F]' '[a-f]' What convinced me to fix it is that the md5 command line tool generates md5sums in upper case by default : http://www.fourmilab.ch/md5/ And finally, A-F and a-f are the same in hex and both are used. Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-13Fix error when sourcing profile scriptAllan McRae
With the "set -e" property set, a failure when sourcing /etc/profile can cause makepkg to exit without error message. The bash-completion package activates this bug. Fixes FS#11179. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-09Fix creation of source package with local source filesAllan McRae
Fixes FS#11149. Signed-off-by: Allan McRae <allan@archlinux.org>
2008-08-04makepkg: fix download functions with weird urls.Xavier Chantry
This fixes FS#11076. 1) quote the url in get_downloadclient 2) only enable nullglob where it is needed You can see in 7fc306cd41 that nullglob was only enabled for one part, and that it already caused other problems, which were fixed in 7ff5a917fd0. Thanks to Henning Garus for pointing out that nullglob was problematic with urls containing expansion char like '?'. 3) change get_downloadcmd which displayed the download command line to download_file which actually executes the download. It seems nicer that way. Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-08-04makepkg: Clarify usage instructions for --allsource/--sourceDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-29makepkg: Fix STRIP_DIRS test.Xavier Chantry
Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-29makepkg : use /etc/profileXavier Chantry
This fixes FS#9486. source /etc/profile instead of all individual files in /etc/profile.d/* (which is done by /etc/profile anyway). Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-24makepkg: add packages to pkgdeps list only after successful installAllan McRae
This fixed FS#9403. With this you can use "makepkg -sr", install the dependencies, Ctrl+c during the makedepends installation and have makepkg remove the installed packages on the exit. Previously makepkg tried to also remove the makedepends which were not installed. The deplist="" line in remove_deps is due to an obscure bug where local varaibles from the handle_deps function seem stay in scope because we never formally exited it. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-20Make strip paths configurableAllan McRae
This patch introduces a new STRIP_DIRS makepkg.conf option to change makepkg's search path when stripping binaries. Original work by: Thomas Bächler <thomas@archlinux.org> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-19Strip *.a libraries in makepkgAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-19Use LC_ALL=C everywhereAllan McRae
Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-15Use "pacman -S $dep" in makepkg's dependency resolvingNagy Gabor
This method is equivalent with pacman's resolvedeps. $dep can be any (versioned) dependency. Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-15makepkg: speed up svn revision check for large repositoriesDan McGee
Using the suggestion from FS#10905, use 'svn info' rather than 'svn log' to get the current revision number, which is much quicker for large Subversion repositories. Eventually git will rule the world. :) Signed-off-by: Dan McGee <dan@archlinux.org>
2008-07-07Merge branch 'maint'Dan McGee
2008-06-27Remove symlinks to libtool filesAllan McRae
This prevents dangling symlinks to removed libtool files when the !libtool option is used. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-22Additional path quoting and srcdir/pkgdir usageAllan McRae
Removes the remaining $startdir/{src,pkg} usage and adds quoting around (hopefully) all remaining path variables Signed-off-by: Allan McRae <mcrae_allan@hotmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-15makepkg: add several quotes needed after nullglob.Xavier Chantry
After the "shopt -s nullglob" change, all regular expressions should be properly quoted. This commit only fixes the ones I found, there are probably others left, so this should be kept in mind for easier future fixing. Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-15makepkg: Add missing quotes for the source array.Xavier Chantry
Now makepkg can handle filenames with whitespaces in the source array. Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-15Use openssl for checksum verification instead of *sum utilitiesSebastian Nowicki
md5sum, sha1sum, etc, do not exist on BSD systems by default. Openssl is a good portable alternative. This also brings in a dependency for openssl. Closes FS#10530. Signed-off-by: Sebastian Nowicki <sebnow@gmail.com> Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-14Move geninteg block in makepkg before error checkingAllan McRae
This patch moves the generating of integrity checks to before any error checking takes place in the PKGBUILD file. This allows integrity generation to complete when unrelated errors exist in a PKGBUILD file and allows the removal of multiple checks of the GENINTEG variable that would otherwise be needed. In addition a minor fix is made to a comment. Signed-off-by: Allan McRae <mcrae_allan@hotmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-12Merge branch 'maint'Dan McGee
2008-06-12Use shell builtin to list files for package inclusionDan McGee
On BSD systems, as super user, the 'ls' command displays all dot files by default, causing these to get included when not intended. If we use the bash glob operator, we can avoid issues with ls on different platforms; however, we need to turn the nullglob shell option on first to ensure we don't have problems in empty directories. Originally-noticed-by: Sebastian Nowicki <sebnow@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-08makepkg: remove deprecated --usesudo codeDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-08makepkg: add --allsource optionAllan McRae
This supplements the --source option and does nearly the same thing, except downloaded source files are included in the archive as well. The sources are now packages with a pkgname/ prefix. Original-work-by: Dan McGee <dan@archlinux.org> Signed-off-by: Allan McRae <mcrae_allan@hotmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-01Don't require --force when using the --nobuild optionAnton Fiuman
makepkg should not abort with error when a user uses the --nobuild option to extract sources if a package has already been built. Signed-off-by: Anton Fiuman <llexiw@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-31makepkg: remove some dead TODO codeDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-29makepkg - add check for valid options in PKGBUILDAllan McRae
This patch removes the code block in makepkg that checked for depreciated options in a PKGBUILD and provided a workaround. Unknown and depreciated options are upgraded to error conditions. Also, removed TODO regarding including install script if exists and $install is unset. That should never happen. Signed-off-by: Allan McRae <mcrae_allan@hotmail.com> Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-29No error in makepkg when removing deps failsAllan McRae
Catches error from when pacman is unable to remove dependencies after successfully building package and prints warning. Fixes FS#10039. Signed-off-by: Allan McRae <mcrae_allan at hotmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-29Use chown 0:0 instead of root.rootSebastian Nowicki
On BSD systems using a dot as a separator is not allowed. On Mac OSX it is deprecated. A colon should be used instead. BSD systems also use the "wheel" group instead of "root" to indicate the "super user" group. Both groups use the id of 0. Signed-off-by: Sebastian Nowicki <sebnow@gmail.com> Acked-by: Aaron Griffin <aaronmgriffin@gmail.com> Acked-by: Dan McGee <dan@archlinux.org> Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-29Use "legacy mode" on Mac OSX (for file command)Sebastian Nowicki
For some reason `file` on Mac OSX has different arguments than BSD and Linux; -i no longer prints out the mime strings. With the environment variable COMMAND_MODE set to "legacy", `file` behaves more like it does on Linux and BSD, i.e., `file -i` prints the mime type. Signed-off-by: Sebastian Nowicki <sebnow@gmail.com> Acked-by: Dan McGee <dan@archlinux.org> Acked-by: Aaron Griffin <aaronmgriffin@gmail.com> Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-29Allow an unprivileged user to create packages without fakerootSebastian Nowicki
When fakeroot was not in BUILDENV and the user was not root, makepkg still tried to use fakeroot for building packages. BUILDENV is now checked to see if fakeroot is enabled. If it is not enabled the package can still be built, but root will not have ownership of files. This is useful when users want to make packages for personal use and don't care about ownership. Closes FS#10450. Signed-off-by: Sebastian Nowicki <sebnow@gmail.com> Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-29du -b is not available on BSD, use du -k instead.Xavier Chantry
This fixes FS#10459. There is apparently no portable ways to get the apparent size of a file, like du -b does. So the best compromise seems to get the block size in kB, and then convert that to byte so that we keep compatibility. Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-29Replace usage of "cp -s" with the more portable "ln -s"Sebastian Nowicki
The "-s" argument does not exist on BSD, and neither does "--remove-destination". This patch replaces the calls to "cp -s --remove-destination" with the equivalent "rm -f" and "ln -s" calls, in order to increase portability. Signed-off-by: Sebastian Nowicki <sebnow@gmail.com> Signed-off-by: Xavier Chantry <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-13Remove --builddeps from makepkgDan McGee
This really should be in an external script, as it is not makepkg's job to rebuild your system. Signed-off-by: Dan McGee <dan@archlinux.org>
2008-05-10makepkg: Unify start and end messagesDan McGee
I've always found it odd why the package version is shown at the start but not the end of the package build. Fix it, and while we are at it, add the $CARCH variable to the display too. Signed-off-by: Dan McGee <dan@archlinux.org>
2008-04-29Merge branch 'maint'Dan McGee
2008-04-27makepkg: fix strip section to allow spaces in pathsDaenyth Blank
Inside tidy_install, change the section which strips libraries to use find | while read rather than for foo in `find`. This should allow whitespaces in filenames to still be processed correctly. This fixes FS#10294. Signed-off-by: Daenyth Blank <Daenyth+git@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>