summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2016-01-22 08:28:37 (GMT)
committerBoris Kolpackov <boris@codesynthesis.com>2016-01-22 08:28:37 (GMT)
commit1ae3f97f48b44488a2f70441e86a67bec8ba1177 (patch)
tree1aa3d7d7ade90d4287e84f477aae0e42f8419dbd
parent9ade866cc3a23138930cac8de37869026583667c (diff)
Use libformat and libprint to be more enterprise-grade and web-scale
-rw-r--r--hello/buildfile5
-rw-r--r--hello/hello.cxx5
-rw-r--r--manifest2
3 files changed, 9 insertions, 3 deletions
diff --git a/hello/buildfile b/hello/buildfile
index 4903a33..c18fa98 100644
--- a/hello/buildfile
+++ b/hello/buildfile
@@ -1,4 +1,7 @@
-lib{hello}: {hxx cxx}{hello}
+import libs = libformat%lib{format}
+import libs += libprint%lib{print}
+
+lib{hello}: {hxx cxx}{hello} $libs
cxx.poptions += -I$src_root
lib{hello}: cxx.export.poptions = -I$src_root
diff --git a/hello/hello.cxx b/hello/hello.cxx
index 65d0aa7..46d9f6e 100644
--- a/hello/hello.cxx
+++ b/hello/hello.cxx
@@ -2,7 +2,8 @@
#include <hello/hello>
-#include <iostream>
+#include <format/format>
+#include <print/print>
using namespace std;
@@ -11,6 +12,6 @@ namespace hello
void
say (const string& n)
{
- cout << "Hello, " << n << '!' << endl;
+ print (format ("Hello", n));
}
}
diff --git a/manifest b/manifest
index c0229dc..c5c5cc2 100644
--- a/manifest
+++ b/manifest
@@ -11,3 +11,5 @@ goal is to show a canonical build2/bpkg project/package.
url: http://www.example.org/libhello
email: hello-users@example.org
requires: c++11
+depends: libformat [1.0.0 2.0.0-); compatible with libformat-1.X.Y
+depends: libprint [1.0.0 2.0.0-); compatible with libprint-1.X.Y