Commit Graph

632 Commits

Author SHA1 Message Date
wiz d0fb2fc679 Use MaxPathSize instead of PATH_MAX (like everywhere else here). 2006-01-08 12:20:54 +00:00
christos 5d62e1710e sync with pkgsrc version. 2006-01-04 23:36:14 +00:00
dillo 4793781929 (pkg_do) When marking already installed package as manually installed,
only print message if we succeeded.

Noted by wiz.
2005-12-08 19:26:28 +00:00
ben d221099506 Specify the full path to tar when unpacking a package.
Modify pfcexec so the new process file name can be different from argv[0].
This fix is from Peter Postma, and it addresses PR#32228
2005-12-06 01:07:30 +00:00
hubertf e968750664 Only warn about running as non-root when -v is given
(or when running in non-unprivilegedmode, but how to detect?)
2005-12-03 01:08:38 +00:00
ben ab821d396a Correct PAX_CMD to be pax. 2005-11-28 01:49:39 +00:00
ben 81789679db Conditionally include header files, and include nbcompat.h
Addresses PR#32149
2005-11-23 14:58:16 +00:00
tron 173505f438 Remove unused variable "argc" in function apply_perms(). 2005-11-23 12:01:30 +00:00
ben ed4b2f6172 Reduce the use of the system() function in pkg_install to avoid quoting
problems.  Instead, use exec*() functions.

Replace PUSHOUT() macro and string buffers with a function that
operates on data structures.

If it is necessary to copy files into place from staging area, then use
pax to copy them.

Add functions in pexec.c to create a pipe for sending data to a child
process.  Replace pipe code in create/perform.c with these functions.
Use these functions instead of command-line arguments when copying files
into place from staging area.

Three system() references remain: @exec, @unexec, and vsystem().
2005-11-23 04:59:14 +00:00
dillo f05d706e05 Bump version for ``pkg_info -Q against local binary packages'' fix. 2005-11-14 09:41:43 +00:00
dillo b6b652227e Fix first part of PR 32068: pkg_info -Q broken for local binary packages
Add BUILD_INFO_FNAME to the files to extract for SHOW_BI_VAR.
2005-11-14 09:39:44 +00:00
agc 2ca444e0bd Get rid of cvs merge botch in previous. 2005-11-13 20:37:23 +00:00
agc d6e9c48326 The Dewey number comparison routines were added by myself in 2002 in
revision 1.32 of pkg_install/lib/str.c, and have absolutely nothing to
do with the original FreeBSD utilities.

Place the appropriate (3 clause) copyright on this file.
2005-11-13 20:07:41 +00:00
wiz 41fb8f4fed Handle -1 return value from dewey_match. 2005-11-13 19:48:35 +00:00
wiz 45be6e647e Do not use errx in dewey_match, return -1 instead. 2005-11-13 19:48:19 +00:00
wiz 7ef0b27ab9 Remove some unnecessary header includes. 2005-11-08 20:16:53 +00:00
dillo e68029a308 Bump version for pkg_info -B fix. 2005-11-07 23:20:49 +00:00
dillo 831ae4eb35 Don't add INSTALLED_INFO to the list of files to extract from binary
packages, it will never be there.

Fixes pkg_info -B against binary packages broken when INSTALLED_INFO
support was added.
2005-11-07 23:19:55 +00:00
wiz 752535d165 Replace wait(2) with equivalent waitpid(2); for Linux, reported by wulf@
on tech-pkg.
2005-11-07 22:57:07 +00:00
wiz 2fa51c716a Sync with pkgsrc: wrap some headers in #ifs. 2005-11-07 22:53:41 +00:00
wiz a1e41eed09 Use config.h and add appropriate #if HAVE_FOO_H. 2005-11-06 12:40:02 +00:00
wiz f0f9d6a437 Add compat #ifdefs from pkgsrc, to make syncing easier between the
two versions.
2005-11-05 13:11:02 +00:00
hannken ba2ee12485 Make it compile on sparc/sparc64. Cast size_t to int for field precision. 2005-11-04 09:26:05 +00:00
dillo 8af62fd627 Split dewey compare functions into their own file dewey.c so they
can be used in a forthcoming Perl module.

Joint work with Thomas Klausner.
2005-11-03 21:59:55 +00:00
dillo 75b9797969 Implement framework to store variable=value pairs about an installed package.
Use this in pkg_add to mark installed dependencies as automatically installed.

pkg_add: new flag -A: marks package as automatically installed.
pkg_admin: new commands set and unset to modify variable pairs for
	   installed packages.
pkg_info: report these variable pairs with -Q/-B.
	  new flag -u: report only manually installed packages (not
	  installed with pkg_add -A).
	  Error out if -a/-u and a package name is specified.

Joint work with Thomas Klausner.

As discussed on tech-pkg.
2005-11-03 21:16:41 +00:00
joerg 82543d8598 Treat FTP error 450 like 550, otherwise pkg_add from a proftpd server
can hang.

Submitted-by: Eirik Nygaard
2005-10-30 21:52:02 +00:00
hubertf b7cc645889 Bump version to 20050718 for fixed IGNORE_RECOMMENDS handling. 2005-07-18 09:09:35 +00:00
hubertf aba8b403bc Fix PR pkg/30658: don't fail for pkgs that were built with IGNORE_RECOMMENDED,
just issue a warning.

Checked by wiz@, no reply from original author (rh@) after several weeks. :(
2005-07-18 09:06:48 +00:00
hubertf 390553bef2 cleanup: preserve errno. Needed so err() functions ran after running
cleanup(0) print the correct error message.
2005-06-29 01:40:42 +00:00
hubertf 9a9bdaa985 Fix 'pkg_add -R' handling - not registering really means not touching
the pkgdb too - useful for pkg_add as non-root!
2005-06-29 01:39:37 +00:00
wiz 7a9582b62a Spread some more unsigned for less casts. 2005-05-31 22:29:41 +00:00
wiz 0ba4110751 Move unsigned to where it belongs, to remove a cast. 2005-05-31 21:03:58 +00:00
wiz 8529448f16 Comment out too noisy warning. 2005-05-30 19:44:03 +00:00
wiz 1723911d3c Add ranges support to the pkg_* tools. See mail on tech-pkg or
pkg_info(1) for details.
Co-production with dillo@.
Bump PACKAGE_TOOLS_VERSION to 20050530.
2005-05-30 13:10:14 +00:00
minskim 773938ed0f If a pattern does not have any suffix, assume that it matches both
".tbz" and ".tgz".  This allows to install binary package dependencies
that are not exact matches, but satisfy requirements.

Bump version to 20050529.
2005-05-29 19:16:18 +00:00
rillig 360e66cfd6 Output the error string when renaming a dependency file fails. This has
happened to me when I had a misnamed directory in the pkgdb directory.
2005-05-10 00:06:57 +00:00
wiz 968dbe95c1 Instead of exec(2)ing rmdir(1), just use rmdir(2).
Reviewed by dillo.
2005-05-07 15:09:41 +00:00
wiz 0ae4504a04 Fix Dq argument, which somehow ended up on the next line. 2005-05-06 23:02:39 +00:00
wiz 756bc811ee Document the vulnerable subdir.
Reviewed by dillo and rillig.
Some minor fixes while I am here. Bump date.
2005-05-06 22:45:56 +00:00
hubertf a958e20048 For -L, mention that files that were dynamicallt created upon installation
(@exec, ...) are not listed.

Based on patch by Peter Bex <Peter.Bex@student.kun.nl>
2005-04-18 12:28:46 +00:00
tron 9f15a6aa01 Fix bad format string which broke the build on LP64 platforms. 2005-04-07 20:22:40 +00:00
dmcmahill ad90bf7a93 Fix a minor bug in the estimation of required disk space. In particular
make sure we use a data type which is big enough.  This fixes a problem
where pkg_add-ing of a binary package which is between 512 Mb and 1 Gb
failes because the estimated required disk space is negative due to over
flowing in the calculation
2005-04-05 16:37:50 +00:00
hubertf be04a114e9 Bump PKGTOOLS_VERSION to today's date to allow telling in which version
PR 24744 was fixed (affects lib/ftpio.c).
2005-03-18 00:12:35 +00:00
hubertf fdbe9a372b Address PR pkg/24744 by Jarmo Jaakkola <jarmo.jaakkola@iki.fi>:
* ftp.fi.netbsd.org returns "257" in return to a "cd" command, accept that
   (in addition to 250 and 550). Seems to be allowed per RFC 959.
 * Make buffer for reply bigger (not too big, as it may hit performance).
2005-03-18 00:01:11 +00:00
rillig b9387c8736 Never access argv[i+1] before you know that argv[i] != NULL. Approved
by wiz.
2005-03-11 22:52:04 +00:00
agc db4720ccb4 Clarify the "OS mismatch" message:
+ state that it is simply a warning
+ make it clearer what the mismatch is
2005-03-06 23:40:41 +00:00
wiz 773cef6c8c Explicitly mention where the canonical location
for these sources is, to avoid confusion when this file gets
copied somewhere else.
2005-03-01 13:19:51 +00:00
grant 16133f304b mdoc fixes: use Sq and Dq instead of ' " and '' 2005-02-26 14:09:57 +00:00
grant 196c8f5e9b initialise a variable before using it. pkg_info binpkg.tgz would pass
garbage on the command line to tar(1).
2005-02-20 14:41:05 +00:00
grant f079891560 cast return value of min_free() to uint64_t. 2005-02-20 09:04:18 +00:00