summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorespie <espie@openbsd.org>2009-12-30 09:39:08 +0000
committerespie <espie@openbsd.org>2009-12-30 09:39:08 +0000
commitec56d8ff0c2ce7ee6b4d04e85ac864677ec5cfb4 (patch)
treed803b9603b1e4d15bd165229e5b5ee5c96d888c2
parentactually cache architecture, as intended (diff)
downloadwireguard-openbsd-ec56d8ff0c2ce7ee6b4d04e85ac864677ec5cfb4.tar.xz
wireguard-openbsd-ec56d8ff0c2ce7ee6b4d04e85ac864677ec5cfb4.zip
infrastructure for url elements
-rw-r--r--usr.sbin/pkg_add/OpenBSD/PackingElement.pm14
-rw-r--r--usr.sbin/pkg_add/OpenBSD/PackingList.pm8
2 files changed, 17 insertions, 5 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/PackingElement.pm b/usr.sbin/pkg_add/OpenBSD/PackingElement.pm
index d2bd11d5edb..2b6e32923c3 100644
--- a/usr.sbin/pkg_add/OpenBSD/PackingElement.pm
+++ b/usr.sbin/pkg_add/OpenBSD/PackingElement.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: PackingElement.pm,v 1.166 2009/12/30 09:37:55 espie Exp $
+# $OpenBSD: PackingElement.pm,v 1.167 2009/12/30 09:39:08 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
@@ -871,6 +871,18 @@ sub keyword() { "localbase" }
__PACKAGE__->register_with_factory;
sub category() { "localbase" }
+package OpenBSD::PackingElement::Url;
+our @ISA=qw(OpenBSD::PackingElement::Unique);
+
+sub keyword() { "url" }
+__PACKAGE__->register_with_factory;
+sub category() { "url" }
+
+# XXX don't incorporate this in signatures.
+sub write_no_sig()
+{
+}
+
package OpenBSD::PackingElement::Conflict;
our @ISA=qw(OpenBSD::PackingElement::Meta);
diff --git a/usr.sbin/pkg_add/OpenBSD/PackingList.pm b/usr.sbin/pkg_add/OpenBSD/PackingList.pm
index f19edfe19c3..004e7657640 100644
--- a/usr.sbin/pkg_add/OpenBSD/PackingList.pm
+++ b/usr.sbin/pkg_add/OpenBSD/PackingList.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: PackingList.pm,v 1.95 2009/12/26 16:58:11 espie Exp $
+# $OpenBSD: PackingList.pm,v 1.96 2009/12/30 09:39:08 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
@@ -236,7 +236,7 @@ sub UpdateInfoOnly
# XXX optimization
if (m/^\@arch\b/o) {
while (<$fh>) {
- if (m/^\@(?:depend|wantlib|conflict|option|pkgpath)\b/o) {
+ if (m/^\@(?:depend|wantlib|conflict|option|pkgpath|url)\b/o) {
&$cont($_);
} elsif (m/^\@(?:groups|users|cwd)\b/o) {
last;
@@ -252,7 +252,7 @@ sub UpdateInfoOnly
}
return;
}
- next unless m/^\@(?:name\b|depend\b|wantlib\b|conflict|\b|option\b|pkgpath\b|comment\s+subdir\=|arch\b)/o;
+ next unless m/^\@(?:name\b|depend\b|wantlib\b|conflict|\b|option\b|pkgpath\b|comment\s+subdir\=|arch\b|url\b)/o;
&$cont($_);
}
}
@@ -438,7 +438,7 @@ sub match_pkgpath
}
our @unique_categories =
- (qw(name digital-signature no-default-conflict manual-installation always-update extrainfo localbase arch));
+ (qw(name url digital-signature no-default-conflict manual-installation always-update extrainfo localbase arch));
our @list_categories =
(qw(conflict pkgpath incompatibility updateset depend