Commit Graph

138 Commits

Author SHA1 Message Date
8d1ed3fe6d Replaced egrep call, bumped to version 5.40.10 2023-02-03 10:32:32 -06:00
Matt Housh
b7506660aa Makefile: fixed version, tweaked dist target 2022-12-19 17:20:51 -06:00
Matt Housh
1a32b7f940 pkgmk: added '--format=gnutar' to bsdtar call in build_package() to deal with some locale issues 2022-04-13 18:07:08 -05:00
55b485f202 pkgmk: use curl as the default download program 2022-01-13 13:47:06 +01:00
c2ebd044e0 pkgmk: set LC_ALL to C.UTF-8 2021-12-18 15:43:00 +01:00
bd31e5150b adjust copyright year 2021-10-05 10:52:37 +02:00
be21f295db Makefile: bump version 2021-10-05 10:41:50 +02:00
65b585fe25 pkgmk: call signify with absolute path 2021-10-05 10:41:04 +02:00
8976af7afe Makefile: add new man-page pkgfile.5 2021-10-05 10:04:10 +02:00
6d1ab3aa05 pkgfile.5: new man-page, initial work by fun 2021-10-05 09:59:50 +02:00
5dc730000e pkgmk: add possibility to change the name of downloaded tarballs 2021-10-05 09:57:07 +02:00
Fredrik Rinnestam
9ca0da6512 readd bz2 support - don't commit while drunk 2018-11-17 21:11:16 +01:00
Fun
d51cdd1c8f pkgadd: add lzip support (closes FS#1638)
It should complete the commit ae5df6094b ('pkgmk: dropped bzip2 support, added support for lzip').

Signed-off-by: Fun <just.the.real.fun@gmail.com>
2018-04-10 23:18:51 +02:00
Fun
ece7f90bf8 faster strip_files() function
Tested with a port with 5500 output files, from which 53 candidates
for stripping. The timing was:
	- 30  secs (old code)
	- 0.2 secs (new code - current patch)
	- 1.4 secs (new code with proper quoting - not commited)

Most of the time is spent in getting the output from the file program.

The old code started the file program for every file.

The new/present code starts N=$(nproc) processes in parallel with 10 input
files for each 'file' process. The output of the file program is feed
to an awk process which filters-out only the candidates for stripping.
This process runs in parallel too (but with one file per strip process).

The --no-buffer options is used because it sounds good (the strip should
start as soon as one of the file processes has a verdict for one of
their 10 files), but I didn't measure it.

The "xargs -r -L10 -P$N" command will miss the files with spaces.
For a file named "a b" it will spawn:
	file "a" "b"
A slower version, with proper quoting, "xargs -r -L1 -P$N -I{} file ... '{}'",
will spawn:
	file "a b"

* xargs will force -L1 if -I{} is used

Given that the file process doesn't return error codes for non-existing
files, and that there is a very low probability that we have ports with
filenames constaining spaces that are worth stripping them, I choose to
keep the faster (non perfect) version.
2018-03-25 03:06:43 +02:00
Fredrik Rinnestam
9acb4ea98b pkgutils 5.40.7 2018-02-14 17:17:57 +01:00
Fredrik Rinnestam
ae5df6094b pkgmk: dropped bzip2 support, added support for lzip 2018-02-07 18:22:25 +01:00
Fredrik Rinnestam
60825521fb pkgadd.conf: Don't overwrite rc.d/wlan on update 2018-01-27 11:51:29 +01:00
Fredrik Rinnestam
f1ba8d109c bump version 2017-11-30 17:28:57 +01:00
Fredrik Rinnestam
a3865f21a9 pkgmk: use --compression=none for wget by default. 2017-11-30 17:28:09 +01:00
Fredrik Rinnestam
d4dd1897d3 bump version 2017-09-20 17:49:39 +02:00
just_fun
7a4d802ecf Add JOBS to pkgmk.conf 2017-09-20 17:49:07 +02:00
just_fun
35b56a38e0 pkgmk: fix the up-to-date option (avoid unnecesarry rebuilds)
build_needed() function returns true/yes if a source is missing,
even when the target/package exists and is up-to-date. This
behaviour triggers unnecesarry rebuilds.

Because only the remote sources can be missing and
we don't want to rebuild a port just because we've deleted
some of its remote sources, this patch changes that condition
from:
    ( the source is missing OR  is newer than the target/package )
to
    ( the source exists     AND is newer than the target/package )
2017-09-20 17:49:07 +02:00
Fredrik Rinnestam
99ded8b59c pkgmk: dont export PKG, SRC FS#1367 2017-09-20 17:48:46 +02:00
Fredrik Rinnestam
74dcad9831 bump version to 5.40.4 2017-09-19 23:50:10 +02:00
Fredrik Rinnestam
fa01237ebc cleanup 2017-09-19 23:46:09 +02:00
Fredrik Rinnestam
4da22c0066 added sepen's patch for pkgadd config-file 2017-09-19 23:45:19 +02:00
just_fun
a11b004805 pkgadd: avoid fake installations if unpacking fails
This patch aborts the package installation and remove the package
from the database on any extraction error. This fixes FS#620.

I don't know why the extraction errors were ignored (even documented).
The initial commit already had this behaviour. Another odd thing
is that the install status of the package was commited to the database
before it was installed while there are exceptions used in pkg_install():
 - archive open error
 - empty archive
 - archive read error
Any of these errors will falsely mark the package as installed (maybe
not a big problem with upgrades).

To avoid breaking something (else), this fix kicks in
only with fresh installs (not upgrades).

Thanks Erich Eckner, for pointing out that the issue
is reproductible with a read-only destination. Otherwise,
I don't think I would have looked at this issue.

A test case is presented with the FS issue, just in case someone
who loves C++ enough to dig deeper or have more knowledge about
the history of this program would take a closer look.
2017-09-19 23:44:01 +02:00
Predrag Ivanovic
62e416b52c pkgmk.in: Add 7z to unpack_source function
Libarchive(bsdtar) can extract 7-Zip archives since 3.0, so
add them as supported source

Ref:
https://github.com/libarchive/libarchive/wiki/LibarchiveFormats
2017-09-19 20:11:19 +02:00
Fredrik Rinnestam
8dfe440b32 pkgutils-5.40.3 2017-05-08 18:45:38 +02:00
just_fun
858ea9a42b pkgmk: update .md5sum if present (even when the port was signed) 2017-04-19 18:17:12 +02:00
Fredrik Rinnestam
0e976e8beb bump Makefile version 2017-04-08 22:36:21 +02:00
Fredrik Rinnestam
08ac3d2cb1 pkgmk: ignore md5sums unless signatures are missing 2017-04-05 21:58:09 +02:00
cc3c4ec779 pkgmk: Remove check for empty $source in check_signature(), patch by just_fun 2017-02-28 20:02:26 +01:00
e7e9779f60 pkgadd: fix deprecated warning, patch by tnut 2017-02-28 13:32:16 +01:00
Fredrik Rinnestam
dcb8845eaf pkgmk: Removed checking for in make_signature()
this is an artifact from make_md5sum() and NOT needed for make_signature().
In fact, this check breaks make_signature() because now packages that don't
have a $source don't get any .signature at all, even though it can
(and should) create a sha256 for the footprint and Pkgfile.

Patch by Camille (onodera).
2017-02-23 18:29:10 +01:00
Fredrik Rinnestam
e5c99f7b1a Fixed various style errors and some typos. Patch by Camille (onodera). 2017-02-23 18:24:27 +01:00
Fredrik Rinnestam
8db4bc01e2 pkgmk: don't assume file will print a ',' with future releases 2017-02-18 20:02:32 +01:00
Fredrik Rinnestam
8a13560ef8 pkgmk: Actually strip executables and objects. Patch by Roman Oreshnikov
FS#1378
2017-02-18 18:04:59 +01:00
Fredrik Rinnestam
8ecaa590f0 pkgmk.conf: include PKGMK_IGNORE_MD5SUM and PKGMK_IGNORE_SIGNATURE variables 2017-02-08 22:14:03 +01:00
Fredrik Rinnestam
c8549cddc0 signify related updates to pkgmk.8.in 2017-02-07 21:01:52 +01:00
Fredrik Rinnestam
66f664ffb7 updated copyright to 2017 2017-02-07 21:01:46 +01:00
Thomas Penteker
ca8de90525 pkgmk.in: fix typo in the help text 2016-11-30 23:18:12 +01:00
06c526de4e update copyright year 2016-10-05 11:26:26 +02:00
9033d1650c pkgmk: extract archives with tar.lz extension 2016-10-04 15:31:41 +02:00
Thomas Penteker
53ec86f6a3 Merge branch 'signed' 2016-08-06 20:17:57 +02:00
Thomas Penteker
3cfc840e9b pkgmk.8: minor documentation adjustments 2016-08-06 20:15:45 +02:00
Fredrik Rinnestam
cc70834811 Makefile: bump version to 5.40 2016-06-15 19:19:34 +02:00
Thomas Penteker
e3999adb34 document new command-line switches in pkgmk.8 2016-04-21 00:04:40 +02:00
Thomas Penteker
b60717c3bc clean ups and -cs now checks the signature even if the binary package is already present 2016-04-08 01:06:13 +02:00
Thomas Penteker
430a36bfa2 fix indentation even more 2016-04-07 22:48:26 +02:00