aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libbpkg/manifest.cxx26
-rw-r--r--libbpkg/manifest.hxx4
-rw-r--r--tests/manifest/testscript2
3 files changed, 31 insertions, 1 deletions
diff --git a/libbpkg/manifest.cxx b/libbpkg/manifest.cxx
index 4f53fbc..e41099e 100644
--- a/libbpkg/manifest.cxx
+++ b/libbpkg/manifest.cxx
@@ -1150,7 +1150,21 @@ namespace bpkg
if (m.build_email)
bad_name ("build email redefinition");
- m.build_email = parse_email (v, "build", true);
+ m.build_email = parse_email (v, "build", true /* empty */);
+ }
+ else if (n == "build-warning-email")
+ {
+ if (m.build_warning_email)
+ bad_name ("build warning email redefinition");
+
+ m.build_warning_email = parse_email (v, "build warning");
+ }
+ else if (n == "build-error-email")
+ {
+ if (m.build_error_email)
+ bad_name ("build error email redefinition");
+
+ m.build_error_email = parse_email (v, "build error");
}
else if (n == "priority")
{
@@ -1502,6 +1516,16 @@ namespace bpkg
serializer::merge_comment (*m.build_email,
m.build_email->comment));
+ if (m.build_warning_email)
+ s.next ("build-warning-email",
+ serializer::merge_comment (*m.build_warning_email,
+ m.build_warning_email->comment));
+
+ if (m.build_error_email)
+ s.next ("build-error-email",
+ serializer::merge_comment (*m.build_error_email,
+ m.build_error_email->comment));
+
for (const auto& d: m.dependencies)
s.next ("depends",
(d.conditional
diff --git a/libbpkg/manifest.hxx b/libbpkg/manifest.hxx
index bae3ffe..b9e7f92 100644
--- a/libbpkg/manifest.hxx
+++ b/libbpkg/manifest.hxx
@@ -262,6 +262,8 @@ namespace bpkg
// email
// package-email
// build-email
+ // build-warning-email
+ // build-error-email
//
class email: public std::string
{
@@ -452,6 +454,8 @@ namespace bpkg
butl::optional<email_type> email;
butl::optional<email_type> package_email;
butl::optional<email_type> build_email;
+ butl::optional<email_type> build_warning_email;
+ butl::optional<email_type> build_error_email;
std::vector<dependency_alternatives> dependencies;
std::vector<requirement_alternatives> requirements;
std::vector<build_constraint> build_constraints;
diff --git a/tests/manifest/testscript b/tests/manifest/testscript
index f9a42cb..4f9a9a9 100644
--- a/tests/manifest/testscript
+++ b/tests/manifest/testscript
@@ -115,6 +115,7 @@
package-email: libfoo-1.2.3+2@example.org; Bug reports are welcome.
build-email: libfoo-builds@example.org; Mailing list for bbot notification\
emails.
+ build-warning-email: libfoo-issues@example.org; Email for libfoo issues.
depends: libz ~1.0.0 | libz ^2.0.0
depends: libgnutls <= 1.2.3 | libopenssl >= 2.3.4
depends: ? libboost-regex >= 1.52.0; Only if C++ compiler does not support\
@@ -151,6 +152,7 @@
license: LGPLv2
url: http://www.example.org/projects/libbar/
email: libbaz-users@example.org
+ build-error-email: libbaz-issues@example.org; Email for libbaz issues.
location: libbaz/libbaz-+2-3.4A.5+3.tar.gz
sha256sum: b5b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
EOF