diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2018-05-04 14:42:58 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2018-05-04 14:46:36 +0200 |
commit | e541a7f334971f913b1033d9e8f4f75f1de02703 (patch) | |
tree | c609304002b77001fd356b02e94b6c75a2d178f0 /hello/hello | |
parent | e9802dbaedcbde98232a46abac22349cb5909ca8 (diff) |
Regenerate hello using bdep-new
Diffstat (limited to 'hello/hello')
-rw-r--r-- | hello/hello/.gitignore | 5 | ||||
-rw-r--r-- | hello/hello/buildfile | 5 | ||||
-rw-r--r-- | hello/hello/hello.cxx | 16 | ||||
-rw-r--r-- | hello/hello/testscript | 9 |
4 files changed, 35 insertions, 0 deletions
diff --git a/hello/hello/.gitignore b/hello/hello/.gitignore new file mode 100644 index 0000000..c1648ba --- /dev/null +++ b/hello/hello/.gitignore @@ -0,0 +1,5 @@ +hello + +# Testscript output directory (can be symlink). +# +test-hello diff --git a/hello/hello/buildfile b/hello/hello/buildfile new file mode 100644 index 0000000..4a510b0 --- /dev/null +++ b/hello/hello/buildfile @@ -0,0 +1,5 @@ +import libs = libhello%lib{hello} + +exe{hello}: {hxx ixx txx cxx}{*} $libs test{testscript} + +cxx.poptions =+ "-I$out_root" "-I$src_root" diff --git a/hello/hello/hello.cxx b/hello/hello/hello.cxx new file mode 100644 index 0000000..0c63c7b --- /dev/null +++ b/hello/hello/hello.cxx @@ -0,0 +1,16 @@ +#include <iostream> + +#include <libhello/hello.hxx> + +using namespace std; + +int main (int argc, char* argv[]) +{ + if (argc < 2) + { + cerr << "error: missing name" << endl; + return 1; + } + + hello::say_hello (cout, argv[1]); +} diff --git a/hello/hello/testscript b/hello/hello/testscript new file mode 100644 index 0000000..cefda39 --- /dev/null +++ b/hello/hello/testscript @@ -0,0 +1,9 @@ +: basics +: +$* 'World' >'Hello, World!' + +: missing-name +: +$* 2>>EOE != 0 +error: missing name +EOE |