History log of /freebsd-10.1-release/usr.sbin/pkg_install/create/main.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 272461 02-Oct-2014 gjb

Copy stable/10@r272459 to releng/10.1 as part of
the 10.1-RELEASE process.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 241830 22-Oct-2012 eadler

Warn users when using pkg tools if it looks like they
be be pkgng users.

Reviewed by: bapt (earlier version)
Reviewed by: kwm
Approved by: cperciva
MFC after: 3 days


# 228990 30-Dec-2011 uqs

Spelling fixes for usr.sbin/


# 222035 17-May-2011 flz

Backout libinstall.a -> libpkg commit.

Discussed with: erwin, brooks, bapt


# 213718 12-Oct-2010 flz

- Add support for xz compression to pkg_create, bzip2 remains the default
compression algorithm.
- Bump PKG_INSTALL_VERSION to 20101012.

Submitted by: mm
MFC after: 1 month


# 207113 23-Apr-2010 flz

- Take libinstall.a out of pkg_install and make it a proper shared library.
- Rework the wrapper support to check libpkg version as well as pkg_install
version.
- Add libfetch to _prebuild_libs.
- There are no new features introduced.

Notes: the API is not stable, so basically, do not use libpkg in your
projects for now. Also there's no manpage for libpkg yet, because the API
will change drastically. I repeat, do not use libpkg for now.


# 201226 29-Dec-2009 ed

Add missing `void' keywords.


# 180361 08-Jul-2008 keramida

Enable the -n option of pkg_create(1).

The changes to make the option work are already in place, but I missed
the patch hunk that adds it to the getopt() option-handling loop.

Pointy hat: keramida
Approved by: flz
MFC after: 1 week


# 179835 16-Jun-2008 flz

Remove support for RELENG_4 (__FreeBSD_version < 500039).

MFC after: 1 day


# 179433 30-May-2008 flz

- Add long options to pkg_install.
- Remove check for '-?' as it's not listed in authorized options.
- Bump PKG_INSTALL_VERSION to 20080530.


# 179366 27-May-2008 keramida

Update usage strings to add a missing -n option.

Noticed by: Matthias Apitz, matthias.apitz at oclc.org


# 179352 27-May-2008 keramida

Add a -n option to pkg_create(1), to inhibit duplicate work.

When run without this option, multiple runs of `pkg_create -Rb' will
recreate common packages multiple times. This can take a lot of time
for large packages. With the -n option `pkg_create -b' checks with
stat(2) and skips packages that already exist.

Note that this may *not* be safe of the existing output file is not
really a package, or if it has been corrupted, modified or otherwise
tinkered with between subsequent pkg_create runs. For this and POLA
reasons, the default behavior is to *rebuild* the packages, and the -n
option can be used when we know it is `safe' to run in no-regenerate
mode.

Inspired by: A post to freebsd-questions
by Matthias Apitz &lt; matthias.apitz at oclc.org &gt;
Reviewed by: marcus, flz
Approved by: marcus
MFC after: 2 weeks


# 173412 07-Nov-2007 kevlo

Cleanup of userland __P use


# 162803 29-Sep-2006 ru

Fix usage().


# 159554 12-Jun-2006 obrien

Allow variable amounts of verbosity.


# 157808 17-Apr-2006 krion

Use bzip2(1) by default to compress package tarball on
__FreeBSD_version >= 500039.

Submitted by: Alex Lyashkov <umka@sevcity.net>
MFC after: 5 days


# 152210 08-Nov-2005 krion

Introduce 3 new options for pkg_create(1), -x for using basic
regular expressions for pkg-name, -E for extended regexps and -G for
exact matching.

Submitted by: mux
MFC after: 3 days


# 147043 06-Jun-2005 sobomax

Add -R modifier for the mode when pkg_create(8) creates package file
from the locally installed package. When this modifier is specified
pkg_create(8) will also create package files for all packages on
which that locally installed package depends.

MFC after: 5 days


# 131277 29-Jun-2004 eik

- pkg_create: new flag -S (clean room installation)

- pkg_create: checksum meta files too

PR: 66032


# 113594 17-Apr-2003 kris

* Add explicit conflict-checking to the package tools. Packages can
register a list of other packages with which they conflict (via the
-C option to pkg_create), and they will refuse to install (unless -f is
specified) if one of the listed packages is already present.

* Update documentation for the new feature as well as fleshing out some
existing documentation.

* Bump PKG_INSTALL_VERSION so this feature can be tested for.

Submitted by: Sergey Matveychuk <sem@ciam.ru>
PR: bin/47145
MFC after: 2 weeks


# 95161 20-Apr-2002 obrien

Improve the Bzip2 handling.

Sponsored by: FreeBSD Mall, Inc.


# 93520 01-Apr-2002 obrien

Fix SCM ID's.


# 85470 25-Oct-2001 sobomax

Make `-b' option actually work as advertised.


# 85019 16-Oct-2001 sobomax

Fix "off by 1" error introduced in the previous commit by replacing strncpy(3)
with strlcpy(3).

MFC after: 2 weeks


# 85002 15-Oct-2001 sobomax

Use strncpy(3) instead of strcpy(3) to copy optarg into a fixed-sized buffer.

Prompted by: dd
MFC after: 2 weeks


# 84672 08-Oct-2001 sobomax

OOPS, delete some commented out debugging code committed along with r.1.25.

MFC after: 2 weeks


# 84671 08-Oct-2001 sobomax

(forced)

Forgot to mention: creation of a full-fleged package archive requires some
changes in bsd.ports.mk, because currently it doesn't install some files
that are usually packed into the package archive (+MTREE_DIRS, +DISPLAY
and so on). Support for this will be committed later.


# 84670 08-Oct-2001 sobomax

- Allow package archive to be created from a locally installed package. This
allows for an easy way to backup old version of port prior to installing
a new one;
- silence compiler warnings by killing some unused variables and adding
all includes necessary.

MFC after: 2 weeks


# 71513 24-Jan-2001 sobomax

Make `-y' option actually work.

Submitted by: reg


# 71373 22-Jan-2001 sobomax

- Add ability to handle bzip2-compressed packages;
- fix cosmetics to shut-up compiler in -pedantic mode (axe several unused vars
and provide default clause in several switch() statements).

No response from: -ports


# 71095 16-Jan-2001 sobomax

- Fix a nasty bug where pkg_create doesn't gzip package if lengh of package
name is less than 5 and doesn't contain recognizeable suffix (one of .tar or
.tgz), while gzip's it if lengh of the name greater than 4. For example
`pkg_create [options] pkg1' will create pkg1.tar, while
`pkg_create [options] pkg11' will create pkg11.tgz;
- use TRUE/FALSE as a values for boolean variables instead of explicit 1/0 and
erroneous YES in one case.

MFC candidate.


# 67454 23-Oct-2000 sobomax

Add "-o" option to pkg_create(1) and pkg_info(1). This option intended to record
a path of the port from which package has been created within FreeBSD Ports
Collection and will be used to improve pkg_version(1) and similar tools.

Reviewed by: ports@FreeBSD.org, jkh
Approved by: jkh


# 50479 27-Aug-1999 peter

$Id$ -> $FreeBSD$


# 48170 24-Jun-1999 imp

'?' shouldn't be in the usage string. Unknown characters are already
converted to '?'.


# 48143 23-Jun-1999 billf

If we are going to have a case for '?' then we should define it in Options.

Submitted by: Ben Olson <bseth@chc-chimes.com>


# 41866 16-Dec-1998 jkh

Make it possible to have separate install scripts as well as have
an on-delete script.

Submitted by: Rajesh Vaidheeswarran <rv@fore.com>


# 30221 08-Oct-1997 charnier

Use err(3). Cosmetics in usage string and man page.


# 26473 06-Jun-1997 jkh

Add support for srcdir overrides.


# 24428 31-Mar-1997 imp

compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.


# 22997 22-Feb-1997 peter

Revert $FreeBSD$ to $Id$


# 21673 14-Jan-1997 jkh

Make the long-awaited change from $Id$ to $FreeBSD$

This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.


# 11780 25-Oct-1995 jkh

Bring forward my changes from 2.1


# 8857 30-May-1995 rgrimes

Remove trailing whitespace.


# 7986 21-Apr-1995 jkh

1. Add proper dependencies to the library in my Makefiles. This was pointed
out by Bruce.
2. Add a "feature" to pkg_create (OK, OK, it's a miserable hack!) to get
it to dump its internal packing list out so that the `fake-pkg' rule in
bsd.port.mk can generate a more meaningful packing list.


# 7713 09-Apr-1995 jkh

Add true support for dependency lists.

1. pkg_create now has a -P argument for specifying dependencies on the
command line.
2. pkg_add will honor dependencies and chain-load them automatically if
it finds the required package(s) in the same directory as the package
that is being loaded. For best results, install packages from a directory
containing all the packages you'll possibly need
(like /usr/ports/packages/all).

2 remaining flaws:

1. pkg_add looks in one place (where you were when you loaded the primary
pkg) for depended packages. If you can come up with a search path scheme
that's not a total hack - be my guest!

2. Recursive dependency expansion can result in the name of a dep being
listed more than once. This doesn't bother pkg_add since it checks
for package existance with pkg_info and will skip already-loaded packages.
I don't know how/if pkg_delete handles this yet, however. I need to look
into it.


# 4996 05-Dec-1994 jkh

Many of John T. Kohl's patches from NetBSD. Thanks, John!
Submitted by: jkohl


# 1520 19-May-1994 alm

Add `-h' option to force tar to follow symbolic links


# 1364 16-Apr-1994 jkh

Whoops, -Y and -N would work better if they were in the getopts string!


# 1337 05-Apr-1994 jkh

Add -N and -Y flags for auto-answer feature.


# 445 12-Sep-1993 jkh

Added and doc'd -X flag to pkg_create that allows you to specify an exclude
list for the final package.


# 383 05-Sep-1993 jkh

Made staging area configurable rather than assuming /tmp (-t)


# 379 03-Sep-1993 jkh

Lots of misc tweaks, support for arbitrary separators in pkg_info, more
intelligent name handling in pkg_create. Most of these files are changed
because of rcsid's being different in my cvs tree and freefall's (foo).


# 328 25-Aug-1993 jkh

This commit was generated by cvs2svn to compensate for changes in r327,
which included commits to RCS files with non-trunk default branches.


# 327 25-Aug-1993 jkh

The release version of my package install suite. Please see man pages
for info.