Commit graph

101 commits

Author SHA1 Message Date
adrianp
7178eb82ce Be more intelligent when setting PVDIR. If pkg_install<20070714 then use
PKGVULNDIR; else extract the current setting using audit-packages -Q and use
that.  In addition to this mkreadme can still be called with -V to specify
a pkg-vulnerabilities file that will override any automatic detection.
2007-08-02 22:42:05 +00:00
jlam
21129d3f69 Don't bother using environment variables to pass info the shlib-type
shell script.  Just specify everything on the command line.  Also,
since shlib-type is a plain-old shell script with no bells and whistles,
we can safely run it with "sh" and not "${SH}", which is necessary
because "${SH}" isn't defined at this point.
2007-08-02 16:00:33 +00:00
jlam
6c4f985be1 Rewrite in a more portable way (basically cripple ourselves to Solaris
/bin/sh).
2007-08-02 15:46:33 +00:00
jlam
2d76049e1e Add back a facility to rebuild the run-time library search paths database
on platforms that need it.

XXX Right now, if the platform needs it, then it runs for every package.
XXX This needs to be fixed to only run for packages that install shared
XXX libraries.

* Move mk/plist/shlib-type to mk/scripts.

* Move definition of SHLIB_TYPE from mk/plist/plist.mk to bsd.pkg.mk.

* Move inclusion of bsd.pkginstall.mk below bsd.tools.mk so that it
  can use SHLIB_TYPE.  This is necessary because SHLIB_TYPE's value
  is the result of evaluating a command, and the command needs "TOOL"
  definitions provided by bsd.tools.mk.
2007-07-18 18:01:02 +00:00
martti
5867247b54 Remove trailing spaces. 2007-05-28 11:07:00 +00:00
adrianp
e345235eb8 * Add an extra -V option to mkreadme to support a non-standard PKGVULNDIR
* Add the necessary changes to allow genreadme.awk to process the v1.1.0
  format pkg-vulnerabilities file.
* Changes are fully backward compatable i.e. mkreadme should be able to
  parse v1.0.0 and v1.1.0 format files.
2007-02-18 00:08:36 +00:00
adrianp
f58ba92ec6 Don't mention -m in the example when the script does not support it. 2007-01-08 20:52:59 +00:00
rillig
b51c2d32b3 Added the FAIL command, which can be prepended to an arbitrary shell
command, making it return with a non-zero exit status.

The first use of it is in a command called FAIL_MSG, which prints an
error message and exits immediately. ERROR_MSG itself doesn't do that.
2007-01-06 19:53:01 +00:00
martti
e2610fb8c8 Remove trailing tabs. 2006-12-15 13:15:06 +00:00
martti
2cc4216d5e Remove trailing spaces. 2006-12-15 12:46:23 +00:00
rillig
212ec91f00 Removed setargs_from_cmd, as it is unused. 2006-10-22 00:35:26 +00:00
dmcmahill
c667b853e3 Update the usage output to reflect current reality. Noted by Stoned
Elipot.
2006-07-28 20:52:35 +00:00
dmcmahill
99b57ce645 remove spurious empty line at the top of the summary files 2006-07-28 18:41:53 +00:00
dmcmahill
63bfc354d4 Allow the binpkg-cache script to also generate pkg_summary.gz files
if requested.  Suggested by Joerg Sonnenberger.
2006-07-28 02:41:07 +00:00
dmcmahill
4d7c638162 Add a script that can be used to scan for NO_BIN_ON_FTP packages using
the cache files left by the README.html generation.  This is indended
to be used to monitor a ftp server, not for generating a file list for
uploading to a ftp server.
2006-07-01 11:11:21 +00:00
dmcmahill
c0b92b7ce2 When producing the list of directories containing binary packages, do
some extra processing to ensure that we have a list of unique directories.
Otherwise we end up with two problems:

  - cache files get rebuilt all the time because they get built once for each
    path to the directory in question and since the path ends up in the cache,
    it is always declared out of date.

  - we end up with multiple links to the same binary package in the README.html
    files.

Committed during the freeze becuase this is a real bug which is encountered
daily.
2006-06-21 14:13:27 +00:00
dmcmahill
a7548e9708 undo most of the last commit which was a mistake. 2006-06-08 11:18:04 +00:00
dmcmahill
21bdb7a787 When using find to search for the "All" directories containing binary
packages, use -follow.  Hopefully this will pick up all of the binary
packages again after the ftp.netbsd.org reorganization.
2006-06-06 11:10:31 +00:00
jlam
c78510391e Refactor "fetch" and "extract" code into correspondingly named
subdirectories of pkgsrc/mk.  Move the following files around for
locality:

	pkgsrc/mk/scripts/extract  -> pkgsrc/mk/extract/extract
	pkgsrc/mk/bsd.sites.mk     -> pkgsrc/mk/fetch/sites.mk

Also get rid of the recursive make for the "fetch" and "extract"
targets.  This basically merges the "fetch" and "extract" phases into
the "patch" phase.

There is still much more work to do to simplify the fetch code, but
this is a good start.
2006-06-06 03:05:48 +00:00
wiz
a818e03080 Recognize -tar.gz as tar.gz files. PR 33571 by Dieter Roelants. 2006-05-30 23:51:38 +00:00
dmcmahill
c72147afb6 when generating the list of pkgsrc packages, use
${BMAKE} show-subdir-var VARNAME=SUBDIR
instead of just grepping through the makefiles.  This seems
to be a litle more robust.  Suggested by Joerg Sonnenberger.
2006-05-29 02:41:26 +00:00
dmcmahill
9f0c8c2d39 strip trailing comments when searching for SUBDIR+= lines in the Makefiles 2006-05-28 16:34:09 +00:00
salo
27e4f856bf Back to pkg-vulnerabilities format 1.0.0. 2006-04-15 15:00:24 +00:00
jlam
ffdd852782 Remove an unsed script -- print-la-libnames was replaced with
plist/libtool-expand after the plist module was committed.
2006-03-22 22:51:53 +00:00
adrianp
28554c4f65 Add .tar.bz support 2006-02-19 15:38:23 +00:00
rillig
3297636963 - Added "set -e" at the top of the file to prevent uncontrolled execution.
- Added "set -u" at the top of the file to prevent spelling errors.
- Renamed UNZIP to UNZIP_CMD, since that is used by the rest of pkgsrc.
- Found a singleton use of $extract_options and replaced it with
  ${EXTRACT_OPTS_LHA}.
- Took the default assignment for TMPDIR out of the block. All other
  entries are tools.
- Removed unnecessary variables.
- Make sure that distfile can always be resolved, even if the current
  working directory is changed.
- Provide default values for all EXTRACT_OPTS_* variables, as close as
  possible to the point where they are used.
- Replaced all "$@" with ${1+"$@"} to avoid errors when no parameters are
  given.
- Made the removal of the temporary file for .tar extraction more robust.
2006-02-04 18:06:47 +00:00
joerg
afe110c086 .tar.z is a valid tar extension. 2006-02-03 11:22:12 +00:00
joerg
d9221c21a4 Fix unrar usage: the command to extract is 'x', without hyphen. 2006-02-02 14:28:17 +00:00
jlam
03451a917b Ensure that decompress_cat and tarprog always have vaild default values
in the case where the user makes bad option choices on the command line.
2006-01-24 15:26:06 +00:00
jlam
b032c82c21 If the package directory doesn't exist, then return a non-zero code. This
allows us to distinguish the case where everything is what we expect, and
any deviations from that main case.
2006-01-23 18:38:27 +00:00
wiz
6b00839b12 Handle *.ZIP the same way as *.zip -- fixes fonts/cyberbit-ttf extraction. 2006-01-23 17:52:02 +00:00
jlam
ae4a2129c3 While walking the dependency graph, push the dependencies onto the
stack in the reverse order that show-depends-pkgpaths outputs them.
This makes the top element of the stack the first child dependency
that was marked as "pushed".  This change orders the default "postfix"
output of this script in such a way that for any package listed in
the output, there is no earlier package that depends on it.

In other words, you can take the default output and install from first
to last and never need to install any dependencies, because any
dependencies are guaranteed to have already been installed earlier.
2006-01-21 22:16:13 +00:00
jlam
d04be0cdcb duh... stacks are LIFOs not FIFOs. 2006-01-21 21:46:24 +00:00
jlam
fd7b3b4b47 Allow using standard input for the archive contents for tar and shar
extraction.
2006-01-21 19:26:09 +00:00
jlam
c7dd4d5b8f Fix the case where -X excludefile is used so that we don't error out trying
to remove "".
2006-01-21 18:21:08 +00:00
jlam
9e65705d03 Teach the extract script how to exclude files specified on the command
line from extraction when using tar (it already knew how to do it for pax).
2006-01-21 18:01:26 +00:00
jlam
53a8e34fec Teach extract how to extract *.z files using gzip. 2006-01-21 16:48:10 +00:00
jlam
42c1f7217d Teach the extract script a "-d dir" option to extract into a specific
directory.
2006-01-21 16:40:19 +00:00
jlam
e5ae84bc32 Fix up the comments, and add a fall-through for unrecognized archive
formats.
2006-01-21 15:33:05 +00:00
jlam
f6a5617420 Fix other instance of _ZOO -> _ZIP and remove a debugging line. 2006-01-21 14:31:56 +00:00
jlam
722d39d511 unzip should be using EXTRACT_OPTS_ZIP, not *_ZOO. 2006-01-21 14:23:08 +00:00
jlam
863c8a3454 Teach the extract script to simply copy the distfile over to the
current working directory by default if it can't figure out what type
of archive it is.  This handles the most common case of overriding
EXTRACT_CMD in package Makefiles, which is to copy a C file or a Perl
script over to the work directory.

Also, modify the script to allow the file format to be specified on
the command line via a -f option, which will force the extract script
to interpret the archive as the specified a format.  This covers the
case where there is a distfile with an unusual file extension that is
actually in well-known format, and we would like to just tell the
extract script which format this is.
2006-01-21 05:24:36 +00:00
jlam
6f807e3cce Teach this script a default extraction method for *.bin files (which are
what Sun packagse its JRE/JDKs as).  While here, cleanup up the comments
slightly.
2006-01-20 23:58:49 +00:00
jlam
f14f207bfd Support listing files/patterns for exclusion in an "excludefile",
which is correctly parsed and translated into the correct syntax for
the underlying tool.
2006-01-20 22:26:12 +00:00
jlam
e9396cdb62 Add some whitespace for readability. 2006-01-20 20:00:44 +00:00
jlam
3afa428cae Fix processing of -t tarprog. 2006-01-20 20:00:15 +00:00
jlam
348fa15438 First pass at a script that replaces many of the variables, loops and
logic in bsd.pkg.extract.mk.  This script "knows" how to extract files
depending on their file extension.
2006-01-20 18:00:45 +00:00
jlam
1de033d120 Add a "-s pkgsrcdir" option that allows specifying the path to the pkgsrc
directory tree on the command line more easily.
2006-01-18 18:21:56 +00:00
jlam
ca35caf06f Modify the show-depends-pkgpaths implementation so that we don't assume
package directories specified in DEPENDS lines begin with "../..".  The
new standalone script pkgsrc/mk/scripts/pkg_path will canonicalize them
into package paths relative to ${PKGSRCDIR}.
2006-01-18 18:03:08 +00:00
jlam
eb3653b4a8 whitespace nit. 2006-01-18 17:43:08 +00:00