Commit Graph

287 Commits

Author SHA1 Message Date
Chantry Xavier dae3f9deef Add zipman makepkg option.
All other steps in tidy_install function were already controlled by an
option in makepkg.conf, so this patch adds an option for the man page
compression step too.
This will allow to keep man pages uncompressed, which is required for some
special meta man page, like the zshall one (see FS#4580).

Ref: http://www.archlinux.org/pipermail/pacman-dev/2008-March/011472.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2008-03-16 23:22:17 +01:00
Roman Kyrylych f56f7ff391 makepkg: Support for resuming source downloads
Download to *.part and remove the suffix if successful, thus md5sums will be
checked only for complete files, and next time makepkg will resume
downloading of partial file instead of complaining about invalid md5sums.

Old DLAGENTS format is still supported.

Late fix: Do not try to download %u first

The output of grep was not suppressed, thus the output of get_downloadcmd
was wrong because of extra line at the beginning that contained an
unsubstituted (with %o and %u) entry from DLAGENTS.

Signed-off-by: Roman Kyrylych <roman@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-03-10 18:45:58 -05:00
Dan McGee 73ac9f7b27 Merge branch 'maint' 2008-03-01 16:24:42 -06:00
Dan McGee d49f42ba75 Remove small remnant of old force=y option
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-27 13:14:05 -06:00
Dan McGee 4bd52f3fe4 Merge branch 'maint'
Remove gettext() function addition from gensync and updatesync in master as
gettext is no longer used in them anyway.
2008-02-20 18:58:04 -06:00
Mark Constable 420c8846b9 Fix two missing BUILDSCRIPT variables in makepkg.
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2008-02-20 18:50:56 -06:00
Dan McGee 3559306546 scripts: allow usage when gettext is not installed
Address the issue of our scripts not working so great when gettext is not
available. This has come up in multiple bug reports, and is relatively easy
to address by adding a simple check and a stub function if gettext was not
found that simply echos the original message.

Addresses concerns from FS#9214 and FS#9607.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-17 21:25:41 -06:00
Dan McGee 6b07b5d345 Merge branch 'maint'
Conflicts:

	lib/libalpm/be_files.c
	lib/libalpm/package.c
2008-02-15 19:40:22 -06:00
Chantry Xavier 17180890a5 makepkg : set sane umask before source extraction.
This fixes FS#9242 and FS#9362.

Set umask before the sources are extracted, and after the /etc/profile.d/*
files are sourced in handledeps.
This sourcing of profile.d files is why umask was moved to the build
function in the first place, as can be seen in commit ac965ed401.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2008-02-11 20:40:43 -06:00
Dan McGee bfc024eab3 Merge branch 'maint' 2008-02-07 20:16:16 -06:00
Dan McGee 14ee1be1ef makepkg: do a quick check for the VCS binaries
Fixes FS#9230. Ensure we have the VCS binaries available when doing the
development version number checking.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-07 20:09:59 -06:00
Chantry Xavier e81dec9b8c remove --force option from repo-add.
The force option should only be specified in the PKGBUILD with
options=(force).  This information should be handled like any other meta
info, and there is no need to have a special repo-add option for it.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
[Dan: fix up a few more references in contrib/ scripts, etc]
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-05 19:35:41 -06:00
Dan McGee eca30ed66a Merge branch 'maint'
Conflicts:

	contrib/gensync
	contrib/updatesync
2008-02-05 19:31:23 -06:00
Chantry Xavier 69bc5ea5e2 add 'force' to PKGINFO, have repo-add respect it.
Ref: http://www.archlinux.org/pipermail/pacman-dev/2008-January/011023.html
Also see FS#9347 and FS#9349.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-02 18:55:40 -06:00
Chantry Xavier 37bb99abfa repo-remove: print an error in case of an empty db
When removing the last packages from a database, repo-remove silently
failed. Now an error is printed.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-02 18:52:37 -06:00
Dan McGee 4fad7855fa Remove gensync and updatesync from normal distribution
Move these two scripts into contrib/, and start the process of de-automaking
them by removing the @sysconfdir@ references and the gettext initialization.
The removal of all gettext will soon follow.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-02 14:12:34 -06:00
Dan McGee 7786bf6024 Add deprecation warnings to gensync and updatesync
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-02 13:57:15 -06:00
Alex Merry b1103a3eaf updatesync: incorrect package deletion logic
Fixes FS#9279.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-02-02 10:09:06 -06:00
Dan McGee c028014f96 makepkg: ensure binaries in /opt/* are stripped
The path selection for stripping binaries was slightly off, so any binaries
in subdirectories of opt/ were missed. Fixes FS#9342.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-27 21:07:44 -06:00
Chantry Xavier f950c26307 makepkg : improve determination of svn revision.
The previous sed command matched every line starting with r.
For example, with mpd-svn package in aur, the svn log output was rather big,
and there were several lines starting with r (the actual revision : r7155,
but also other lines starting with reverting and run), so this broke makepkg:

> makepkg
==> Determining latest svn revision...
  -> Version found: 7155
everting
un
sed: -e expression #1, char 27: unterminated `s' command

To make the sed command more bullet proof, I added the -q option of svn log,
which produces a quieter output, without the log.
And I changed the sed command to only match numbers for the revision.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-27 11:49:24 -06:00
Chantry Xavier 73ee64d49f workaround for a gettext string starting with --.
Workaround found in Advanced Bash-Scripting Guide, localization section.
"added a \0 (NULL) at the beginning of the sentence."

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2008-01-20 14:30:26 -06:00
Dan McGee 003adb7646 makepkg: add check to ensure we have non-URL files in build dir
Pacman 3.0 printed the following message if a file could not be found:
  ERROR: xxx was not found in the build directory and is not a proper URL.

We lost this logic in 3.1 when moving to the DLAGENT type stuff, so a
not-found file got passed all the way to the download logic where it failed
with a odd error message. Bring back some logic to ensure only files with
URLs get past a certain point, and fail if the file is not available.

Fixes FS#9208.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-20 12:32:37 -06:00
Dan McGee fd86c62db8 Fix typos in code comments
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-13 23:26:31 -06:00
Dan McGee ffff094126 makepkg: Oops! Lost the colon after forcever in opts parsing
I screwed this up here:
916e226b78

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-13 19:16:58 -06:00
Scott Horowitz 916e226b78 makepkg: Introduce --holdver option to prevent bumped pkgrel
This allows us to keep the --forcever option internal to makepkg.

Fixes FS#9194.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-13 18:42:26 -06:00
Chantry Xavier 8186dc11a9 Ensure correct dir permissions in the database.
Fix for FS#9176.
A previous commit (6e8daa553b) already forced all database files to 644.
Now the directories are also forced to 755.

Additionally, repo-add now sets the umask to 022, just like makepkg does, to
fix the problem at its root.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-13 12:51:37 -06:00
Travis Willard bbe02ec57f Update Gensync and Updatesync to use new PKGEXT variable
Previously, this caused both scripts to look for
pkgname-pkgver-pkgrel-arch..pkg.tar.gz - extra period has been removed.

Fixes FS#9190.

Signed-off-by: Travis Willard <travis@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-13 12:21:36 -06:00
Dan McGee b1a231427b makepkg: Ensure we include all manpage directories in compression line
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-09 18:33:12 -06:00
Karolina Lindqvist 33f6fda8b6 makepkg: add package name to output when installing package
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-09 18:33:11 -06:00
Dan McGee dd5bc808ea makepkg: Fix issues with --asroot and building dependencies
The --asroot option was not passed to recursive calls of makepkg.

In addition, a 'cd' call was done only on the fakeroot branch instead of
both fakeroot and root branches. Move it outside the conditional.

Noticed-by: Karolina Lindqvist <karolina.lindqvist@kramnet.se>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-08 09:15:30 -06:00
Dan McGee 6f86f46c96 Remove makeworld from pacman package
This is an Arch-specific tool (although others could find use in it), so
off to the standalone ABS package it goes.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-06 10:42:35 -06:00
Dan McGee e0e33c329f Remove hardcoded DBEXT value from script
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-06 09:44:28 -06:00
Dan McGee 14e4366c78 makepkg: add application/zip to the recognized types
The recent upgrade of magic.mime in the file program changed the mime type
output to application/zip instead of application/x-zip as it is a registered
type. Unfortunately we then just skipped zip file extraction becuase of this
change.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-05 16:44:43 -06:00
Gustavo Chain 728b601f7b scripts: extra exit() calls in usage() function
Remove the exit() calls from usage as they should be handled by the caller.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-05 16:44:43 -06:00
Dan McGee c26039240d Remove mentions of ABS from makepkg
Kill off some of the $ABSROOT stuff that was still hanging around in there.

Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-05 14:35:40 -06:00
Dan McGee fbd88a8212 Remove .FILELIST generation from makepkg (and elsewhere)
This is something pacman can do on its own straight from the archive, and we
will reduce the chance of problems occurring becuase of inproper FILELIST
generation as we have had in the past with special characters in filenames.

Once we remove it from makepkg. we can remove any usage of it from all of
our other tools, including pacman, pactest, and contrib/ utilities.

Note that removing it from pacman uncovered a few other bugs anyway, so this
was probably a good move.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-29 11:58:23 -06:00
K. Piche c84feb92db Makepkg missing check for empty pkgname
I thought it was wierd that makepkg didn't do a sanity check for the
$pkgname.  This makes for a simple first try at a GIT patch.

Signed-off-by: K. Piche <kevin@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-28 19:54:45 -06:00
Dan McGee 9addd88a7d Do not move man pages to a non-FHS location
Fixes Arch Linux bug FS#8839.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-21 15:47:30 -06:00
Dan McGee 741fa31603 Remove abs from the pacman repository
abs has always been an Arch Linux specific tool, and although it is used
primarily by pacman and makepkg, it should not be included with a distro-
agnostic tarball. In addition, maintenance of the script would be better
outside of pacman and would allow for more frequent updates.

This also facilitates our move away from a cvsup/csup dependent tool for
syncing PKGBUILDs.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-21 11:05:38 -06:00
Chantry Xavier ebae8bd009 update of translation-help and fix a typo in gensync.
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-12-19 18:21:27 -06:00
Dan McGee 20bad3b839 Set the default packager to "Unknown Packager"
There is no real reason to make it look like someone that can't bother to
set the packager variable is official in any way, so remove the Arch Linux
reference from makepkg.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-16 22:00:12 -06:00
Dan McGee 9781d0d637 Update GNU GPL boilerplate and copyright dates
Update the GPL boilerplate to direct people to the GNU website for a copy of
the license, as well as bump all of Judd's copyrights to 2007.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-10 22:55:39 -06:00
Allan McRae 9615d82343 Compress hard linked man pages
This fixes FS#5392.  If hard links are present for a man page, all
other hard linked files are removed, the man page is zipped and the
hard links are updated to the newly compress man page.

Signed-off-by: Allan McRae <mcrae_allan@hotmail.com>
[Dan: use find -samefile option, don't fail if one of mandirs is
nonexistent]
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-04 18:55:44 -06:00
Dan McGee dbc2f902db pacman-optimize: add note saying sync would be helpful
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-13 20:56:15 -06:00
Nathan Jones c29209e7b6 repo-add: Ensure only adding package's deltas.
repo-add was adding the delta files of any package that started with the
same package name plus a hyphen.

In this example, deltatest-libs delta files were added to the deltatest
package:

$ repo-add deltatest.db.tar.gz deltatest-1.0.2-1-i686.pkg.tar.gz
==> Extracting database to a temporary location...
==> Adding package 'deltatest-1.0.2-1-i686.pkg.tar.gz'
  -> Removing existing package 'deltatest-1.0.2-1'...
  -> Creating 'desc' db entry...
  -> Computing md5 checksums...
  -> Creating 'depends' db entry...
  -> Creating 'deltas' db entry...
  -> Added delta 'deltatest-1.0.2rc3-1_to_1.0.2-1-i686.delta'
  -> Added delta 'deltatest-libs-1.0.0-1_to_1.0.1-1-i686.delta'
==> Creating updated database file /tmp/deltatest.db.tar.gz

Signed-off-by: Nathan Jones <nathanj@insightbb.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-13 00:13:21 -06:00
Giovanni Scafora 5cd6ffda72 makeworld: gettext support
Signed-off-by: Giovanni Scafora <linuxmania@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-11 09:42:19 -06:00
Roman Kyrylych 6f5ee2432c makepkg: remove .pacsave files when uninstalling dependencies
Signed-off-by: Roman Kyrylych <roman@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-11 09:39:39 -06:00
Scott Horowitz dd2d6f980b Correctly handle version comparisons for SVN/CVS/etc PKGBUILDS.
Retrieve SVN/CVS/etc revision number before checking if the
package has already been built. This allows building a newer
version of a developmental package without having to use -f.
Now -f will only be needed if the latest SVN/CVS/etc revision
is the same as the built package.

Signed-off-by: Scott Horowitz <stonecrest@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-08 07:15:37 -06:00
Sebastian Nowicki cb04b3a5f3 Fix mercurial complaining about directory already existing
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-05 21:10:35 -06:00
Roman Kyrylych 4a5e7b6bd1 Add support for arch='any'
Signed-off-by: Roman Kyrylych <roman@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-04 09:50:04 -06:00