pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/mk/pkgformat/pkg
Module Name: pkgsrc
Committed By: jlam
Date: Wed Oct 4 04:13:00 UTC 2017
Modified Files:
pkgsrc/mk/pkgformat/pkg: reduce-depends.awk
pkgsrc/mk/pkgformat/pkg/tests: reduce-depends_test
Log Message:
reduce-depends.awk: Match version strings containing tilde (~).
To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 pkgsrc/mk/pkgformat/pkg/reduce-depends.awk
cvs rdiff -u -r1.1 -r1.2 pkgsrc/mk/pkgformat/pkg/tests/reduce-depends_test
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/mk/pkgformat/pkg/reduce-depends.awk
diff -u pkgsrc/mk/pkgformat/pkg/reduce-depends.awk:1.7 pkgsrc/mk/pkgformat/pkg/reduce-depends.awk:1.8
--- pkgsrc/mk/pkgformat/pkg/reduce-depends.awk:1.7 Sun Oct 1 22:58:19 2017
+++ pkgsrc/mk/pkgformat/pkg/reduce-depends.awk Wed Oct 4 04:13:00 2017
@@ -1,6 +1,6 @@
#!/usr/bin/awk -f
#
-# $NetBSD: reduce-depends.awk,v 1.7 2017/10/01 22:58:19 jlam Exp $
+# $NetBSD: reduce-depends.awk,v 1.8 2017/10/04 04:13:00 jlam Exp $
#
# Copyright (c) 2006-2017 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -145,7 +145,7 @@ BEGIN {
# Match version numbers with an ERE.
# XXX This matches more than it should.
- VERSION_RE = "[0-9A-Za-z._+]+"
+ VERSION_RE = "[0-9A-Za-z._~+]+"
# Gather all dependencies into the patterns array. Index 0 of the
# patterns[pkgpath] array is the number of patterns associated with
Index: pkgsrc/mk/pkgformat/pkg/tests/reduce-depends_test
diff -u pkgsrc/mk/pkgformat/pkg/tests/reduce-depends_test:1.1 pkgsrc/mk/pkgformat/pkg/tests/reduce-depends_test:1.2
--- pkgsrc/mk/pkgformat/pkg/tests/reduce-depends_test:1.1 Sun Oct 1 04:00:40 2017
+++ pkgsrc/mk/pkgformat/pkg/tests/reduce-depends_test Wed Oct 4 04:13:00 2017
@@ -374,6 +374,30 @@ EOF
}
###
+### tildes_in_versions_test
+###
+
+atf_test_case tildes_in_versions_test
+
+tildes_in_versions_test_head()
+{
+ atf_set "descr" "tildes in versions strings"
+}
+
+tildes_in_versions_test_body()
+{
+ cat > input << EOF
+pkg_install>=1~1:../../pkgtools/pkg_install
+pkg_install<2:../../pkgtools/pkg_install
+EOF
+ cat > expected << EOF
+pkg_install>=1~1<2:../../pkgtools/pkg_install
+EOF
+ check_reduce input expected
+ atf_pass
+}
+
+###
### multiple_package_dependencies_test
###
@@ -417,5 +441,6 @@ atf_init_test_cases()
atf_add_test_case disjoint_test
atf_add_test_case strings_in_versions_test
atf_add_test_case underscores_in_versions_test
+ atf_add_test_case tildes_in_versions_test
atf_add_test_case multiple_package_dependencies_test
}
Home |
Main Index |
Thread Index |
Old Index